Solana Validator Documentation

What is a Validator?

A validator is a computer that helps to run the Solana network. Each validator executes a program that keeps track of all accounts on the Solana cluster and validates transactions being added to the network. Without validators, Solana would not be able to function.
The more independent entities that run validators, the less vulnerable the cluster is to an attack or catastrophe that affects the cluster.

For a more in depth look at the health of the Solana network, see the Solana Foundation Validator Health Report .

By becoming a validator, you are helping to grow the network. You are also learning first hand how the Solana cluster functions at the lowest level. You will become part of an active community of operators that are passionate about the Solana ecosystem.

验证器是帮助运行 Solana 网络的计算机。每个验证器都会执行一个程序,该程序跟踪 Solana 集群上的所有帐户并验证添加到网络中的交易。如果没有验证器,Solana 将无法运行。

运行验证器的独立实体越多,集群就越不容易受到影响集群的攻击或灾难的影响。

要更深入地了解运行状况有关 Solana 网络的详细信息,请参阅 Solana 基金会验证者健康报告
通过成为验证者,您将帮助发展网络。您还将直接了解 Solana 集群如何在最低级别运行。您将成为对 Solana 生态系统充满热情的活跃运营商社区的一部分。

Consensus vs RPC

Before we discuss validators in more detail, it’s useful to make some distinctions. Using the same validator software, you have the option of running a voting/consensus node or choosing to instead run an RPC node. An RPC node helps Solana devs and others interact with the blockchain but for performance reasons should not vote. We go into more detail on RPC nodes in the next section, what is an rpc node.

For this document, when a validator is mentioned, we are talking about a voting/consensus node. Now, to better understand what your validator is doing, it would help to understand how the Solana network functions in more depth.

在我们更详细地讨论验证器之前,做一些区分很有用。使用相同的验证器软件,您可以选择运行投票/共识节点或选择运行 RPC 节点。 RPC 节点可帮助 Solana 开发人员和其他人与区块链交互,但出于性能原因不应投票。我们将在下一节中更详细地介绍 RPC 节点,即什么是 RPC 节点。

在本文档中,当提到验证器时,我们谈论的是投票/共识节点。现在,为了更好地了解验证器正在做什么,将有助于更深入地了解 Solana 网络的运作方式。

Proof Of Stake

Proof of stake is the blockchain architecture that is used in Solana. It is called proof of stake because token holders can stake their tokens to a validator of their choice. When a person stakes their tokens, that person still owns the tokens and can remove the stake at any time. The staked tokens represent their trust in that validator. When a person stakes their tokens to a validator, they are given a return of some amount of tokens as a reward for helping to run and secure the network. The more tokens you have staked to a validator the more rewards you receive. A validator that has a large amount of tokens staked to it has a larger vote share in consensus. A validator, therefore, is given more opportunities to produce blocks in the network proportional to the size of the stake in the validator. The validator that is currently producing blocks in the network is known as the leader.

权益证明是 Solana 中使用的区块链架构。它被称为权益证明,因为代币持有者可以将他们的代币抵押给他们选择的验证者。当一个人质押其代币时,该人仍然拥有这些代币,并且可以随时移除质押。质押的代币代表了他们对该验证者的信任。当一个人将其代币抵押给验证者时,他们会获得一定数量的代币回报,作为帮助运行和保护网络的奖励。您向验证者质押的代币越多,您获得的奖励就越多。拥有大量代币的验证者在共识中拥有更大的投票份额。因此,验证者有更多机会在网络中生成与验证者权益大小成比例的区块。当前在网络中生成区块的验证者被称为领导者。

Proof Of Work: For Contrast

Solana is not a proof of work system. Proof of work is a different blockchain architecture in which a computer (often called a miner), works to solve a cryptographic problem before anyone else on the network is able to solve it. The more often the computer solves these problems, the more rewards the miner receives. Because of the incentive to solve a hard computational problem first, miners often use many computers at the same time. The number of computers used to solve these problems leads to large energy consumption and resulting environmental challenges.

Solana, in contrast, does not incentivize validators to use many computers to solve a computational problem. Because a validator would like to have a larger amount staked to it, there is no real advantage for an independent validator to using many different computers. Here, you can see a comparison of Solana’s environmental impact.

Solana 不是工作量证明系统。工作量证明是一种不同的区块链架构,其中计算机(通常称为矿工)在网络上的其他任何人能够解决加密问题之前先解决该问题。计算机解决这些问题的次数越多,矿工获得的奖励就越多。由于首先解决困难的计算问题的动机,矿工经常同时使用多台计算机。用于解决这些问题的计算机数量会导致大量的能源消耗并带来环境挑战。

相比之下,Solana 不会激励验证者使用许多计算机来解决计算问题。由于验证者希望投入更多资金,因此独立验证者使用许多不同的计算机并没有真正的优势。在这里,您可以看到 Solana 对环境影响的比较

Proof Of History

Proof of history, PoH, is one of the key innovations in Solana that allows transactions to be finalized very quickly. At a high level, PoH allows validators in the cluster to agree on a cryptographically repeatable clock. Both proof of stake and proof of work architectures mentioned above are architectures that bring the cluster to consensus. In other words, these algorithms decide which blocks should be added to the blockchain. Proof of history is not a consensus architecture, but rather a feature in Solana that makes block finalization faster in the proof of stake system.

Understanding how PoH works is not necessary to run a good validator, but a very approachable discussion can be found in this Medium article. Also, the Solana whitepaper does a good job of explaining the algorithm in an approachable way for the more technically minded.

历史证明 PoH 是 Solana 的关键创新之一,它允许交易非常快速地完成。在较高层面上,PoH 允许集群中的验证者就加密可重复时钟达成一致。上面提到的权益证明和工作量证明架构都是使集群达成共识的架构。换句话说,这些算法决定哪些区块应该添加到区块链中。历史证明不是共识架构,而是 Solana 中的一个功能,它可以使权益证明系统中的区块最终确定更快。

了解 PoH 的工作原理对于运行一个好的验证器来说并不是必要的,但可以进行一个非常平易近人的讨论。在这篇Medium文章中找到。此外,Solana 白皮书以平易近人的方式很好地为技术人员解释了该算法。

Your Role As A Validator

As a validator, you are helping to secure the network by producing and voting on blocks and to improve decentralization by running an independent node. You have the right to participate in discussions of changes on the network. You are also assuming a responsibility to keep your system running properly, to make sure your system is secure, and to keep it up to date with the latest software. As more individuals stake their tokens to your validator, you can reward their trust by running a high performing and reliable validator. Hopefully, your validator is performing well a majority of the time, but you should also have systems in place to respond to an outage at any time of the day. If your validator is not responding late at night, someone (either you or other team members) need to be available to investigate and fix the issues.

Running a validator is a technical and important task, but it can also be very rewarding. Good luck and welcome to the community.

作为验证者,您可以通过生成区块并进行投票来帮助保护网络安全,并通过运行独立节点来提高去中心化程度。您有权参与网络变更的讨论。您还承担着保持系统正常运行、确保系统安全并使用最新软件保持最新状态的责任。随着越来越多的人将他们的代币抵押给您的验证器,您可以通过运行高性能且可靠的验证器来回报他们的信任。希望您的验证器在大部分时间都表现良好,但您还应该拥有适当的系统来响应一天中任何时间的中断。如果您的验证器在深夜没有响应,则需要有人(您或其他团队成员)来调查并解决问题。

运行验证器是一项技术性且重要的任务,但它也可能非常有价值。祝你好运,欢迎来到社区。

What is an RPC Node?

An RPC (Remote Procedure Call) node runs the same software as a validator, but it does not participate in the consensus process. Technically you could run the RPC software and also allow your node to vote as a consensus node, but it is strongly discouraged because your node will not be performant enough to do either task well.

A node that runs RPC has a much different purpose in the cluster. An RPC node responds to requests about the blockchain and also allows users of the RPC node to submit new transactions to be included in blocks.

For example, a website might request to transfer tokens from wallet A to wallet B (given wallet A’s permission). That website would have to use wallet A to sign a transaction and then send it to an RPC node to be submitted to the leader. So you could think of running an RPC node as a similar engineering task to providing an api for others to use.

The users of the RPC node are often developers, so this option may require a more technical understanding of Solana. To better understand RPC node operations, you’ll want to become familiar with the different RPC calls. You can find the RPC API here.

RPC(远程过程调用)节点运行与验证器相同的软件,但它不参与共识过程。从技术上讲,您可以运行 RPC 软件并允许您的节点作为共识节点进行投票,但强烈建议不要这样做,因为您的节点的性能不足以很好地完成任一任务。

运行 RPC 的节点有很大不同集群中的目的。 RPC 节点响应有关区块链的请求,还允许 RPC 节点的用户提交要包含在块中的新交易。

例如,网站可能请求将代币从钱包 A 转移到钱包 B(假设钱包 A 的允许)。该网站必须使用钱包 A 签署交易,然后将其发送到 RPC 节点以提交给领导者。因此,您可以将运行 RPC 节点视为类似于提供 api 供其他人使用的工程任务。

RPC 节点的用户通常是开发人员,因此此选项可能需要对 Solana 有更多的技术了解。为了更好地理解 RPC 节点操作,您需要熟悉不同的 RPC 调用。您可以在此处找到RPC API

Validator Frequently Asked Questions

What is a validator?

A validator is a computer that runs a software program to verify transactions that are added to the Solana blockchain. A validator can be a voting validator or a non voting validator.

验证器是运行软件程序来验证添加到 Solana 区块链的交易的计算机。验证者可以是投票验证者或非投票验证者。

What is an RPC node?

An RPC node is also a computer that runs the validator software. Typically, an RPC node does not vote on the network. Instead the RPC node’s job is to respond to API requests.

什么是RPC节点?​
RPC节点也是运行验证器软件的计算机。通常,RPC 节点不会在网络上投票。相反,RPC 节点的工作是响应 API 请求。

What is a cluster?

What is Proof of Stake?

Proof of Stake (PoS) is a blockchain architecture. Solana is a Proof of Stake blockchain

权益证明(PoS)是一种区块链架构。 Solana 是一种权益证明区块链

What is Proof of Work? Is running a Solana validator the same as mining?

No, a Solana validator uses Proof of Stake. It does not use Proof of Work (often called mining).

不,Solana 验证器使用权益证明。它不使用工作量证明(通常称为挖矿)。

Who can operate a validator?​

Anyone can operate a validator. All Solana clusters are permissionless. A new operator can choose to join at any time.

任何人都可以操作验证器。所有 Solana 集群都是无需许可的。新的运营商可以随时选择加入。

Is there a validator set or limited number of validators that can operate?​

No, all Solana clusters are permissionless. There is no limit to the number of active validators that can participate in consensus. Validators participating in consensus (voting validators) incur transaction fees for each vote. A voting validator can expect to incur up to 1.1 SOL per day in vote transaction fees.
是否存在可以运行的验证器集或有限数量的验证器?​

不,所有 Solana 集群都是无需许可的。参与共识的活跃验证者数量没有限制。参与共识的验证者(投票验证者)每次投票都会产生交易费用。投票验证器每天最多需要产生 1.1 SOL 的投票交易费用。

What are the hardware requirements for running a validator?

Minimum SOL requirements​

There is no strict minimum amount of SOL required to run a validator on Solana.
However in order to participate in consensus, a vote account is required which has a rent-exempt reserve of 0.02685864 SOL. Voting also requires sending a vote transaction for each block the validator agrees with, which can cost up to 1.1 SOL per day.

最低 SOL 要求​
在 Solana 上运行验证器所需的 SOL 没有严格的最低金额。
但是,为了参与共识,需要一个具有 0.02685864 SOL 免租金储备的投票账户。投票还需要为验证者同意的每个区块发送投票交易,每天的费用最高可达 1.1 SOL。

Hardware Recommendations​

The hardware recommendations below are provided as a guide. Operators are encouraged to do their own performance testing.

硬件建议​
以下硬件建议仅供参考。我们鼓励运营商进行自己的性能测试。

CPU

12 cores / 24 threads, or more
2.8GHz base clock speed, or faster
SHA extensions instruction support
AMD Gen 3 or newer
Intel Ice Lake or newer
AVX2 instruction support (to use official release binaries, self-compile otherwise)
Support for AVX512f is helpful

CPU
12 核/24 线程或更高
2.8GHz 基本时钟速度,或更快
SHA 扩展指令支持
AMD Gen 3 或较新的
Intel Ice Lake或较新的
AVX2指令支持(使用官方发布的二进制文件,否则自编译)
对AVX512f的支持很有帮助

RAM

256GB or more
Error Correction Code (ECC) memory is suggested
Motherboard with 512GB capacity suggested

RAM
256GB或更多
错误纠正建议使用代码 (ECC) 内存
建议使用 512GB 容量的主板

Disk

PCIe Gen3 x4 NVME SSD, or better
Accounts: 500GB, or larger. High TBW (Total Bytes Written)
Ledger: 1TB or larger. High TBW suggested
OS: (Optional) 500GB, or larger. SATA OK
The OS may be installed on the ledger disk, though testing has shown better performance with the ledger on its own disk
Accounts and ledger can be stored on the same disk, however due to high IOPS, this is not recommended
The Samsung 970 and 980 Pro series SSDs are popular with the validator community

磁盘
PCIe Gen3 x4 NVME SSD 或更好
帐户:500GB 或更大。高 TBW(写入的总字节数)
分类帐:1TB 或更大。高 TBW 建议
操作系统:(可选)500GB 或更大。 SATA OK
操作系统可以安装在账本磁盘上,尽管测试显示账本在其自己的磁盘上性能更好
帐户和账本可以存储在同一磁盘上,但是由于高 IOPS,这是不推荐
三星 970 和 980 Pro 系列 SSD 在验证者社区中很受欢迎

GPUs

Not necessary at this time
Operators in the validator community do no use GPUs currently

目前没有必要
验证者社区中的操作者目前不使用 GPU

RPC Node Recommendations​

The hardware recommendations above should be considered bare minimums if the validator is intended to be employed as an RPC node. To provide full functionality and improved reliability, the following adjustments should be made.

RPC 节点建议​
如果验证器打算用作 RPC 节点,则应将上述硬​​件建议视为最低限度。为了提供完整的功能并提高可靠性,应进行以下调整。

CPU

16 cores / 32 threads, or more

CPU
16 核/32 线程或更多

RAM

512 GB or more if account-index is used

RAM
512 GB 或更多(如果使用帐户索引)

Disk

Consider a larger ledger disk if longer transaction history is required
Accounts and ledger should not be stored on the same disk

磁盘
如果需要更长的交易历史记录,请考虑更大的账本磁盘
帐户和账本不应存储在同一磁盘上

Virtual machines on Cloud Platforms​

While you can run a validator on a cloud computing platform, it may not be cost-efficient over the long term.
However, it may be convenient to run non-voting api nodes on VM instances for your own internal usage. This use case includes exchanges and services built on Solana.
In fact, the mainnet-beta validators operated by the team are currently (Mar. 2021) run on GCE n2-standard-32 (32 vCPUs, 128 GB memory) instances with 2048 GB SSD for operational convenience.
For other cloud platforms, select instance types with similar specs.
Also note that egress internet traffic usage may turn out to be high, especially for the case of running staked validators.

云平台上的虚拟机​
虽然您可以在云上运行验证器计算平台,从长远来看可能不具有成本效益。
但是,在 VM 实例上运行非投票 api 节点以供您自己的内部使用可能会很方便。该用例包括基于 Solana 构建的交易所和服务。
事实上,该团队运营的主网测试版验证器目前(2021 年 3 月)在 GCE n2-standard-32(32 个 vCPU、128 GB 内存)实例上运行配备 2048 GB SSD,以方便操作。
对于其他云平台,请选择具有相似规格的实例类型。
另请注意,出口互联网流量使用量可能会很高,尤其是在运行质押验证器的情况下。

Docker​

Running validator for live clusters (including mainnet-beta) inside Docker is not recommended and generally not supported. This is due to concerns of general Docker’s containerization overhead and resultant performance degradation unless specially configured.
We use Docker only for development purposes. Docker Hub contains images for all releases at solanalabs/solana.

Docker​
不建议且通常不支持在 Docker 内运行实时集群(包括 mainnet-beta)的验证器。这是由于担心一般 Docker 的容器化开销以及由此导致的性能下降,除非进行特殊配置。
我们仅将 Docker 用于开发目的。 Docker Hub 包含 solanalabs/solana 上所有版本的映像。

Software​

We build and run on Ubuntu 20.04.
See Installing Solana CLI for the current Solana software release.
Prebuilt binaries are available for Linux x86_64 on CPUs supporting AVX2 (Ubuntu 20.04 recommended). MacOS or WSL users may build from source.

软件​
我们在 Ubuntu 20.04 上构建并运行。
请参阅安装 Solana CLI 以了解当前的 Solana 软件版本。
预构建的二进制文件可用于支持 AVX2 的 CPU 上的 Linux x86_64(推荐 Ubuntu 20.04)。 MacOS 或 WSL 用户可以从源代码构建。

Networking​

Internet service should be at least 1GBbit/s symmetric, commercial. 10GBit/s preferred.

网络​
互联网服务应至少为 1GBbit/s 对称、商业。首选 10GBit/s。

Port Forwarding​

The following ports need to be open to the internet for both inbound and outbound
It is not recommended to run a validator behind a NAT. Operators who choose to do so should be comfortable configuring their networking equipment and debugging any traversal issues on their own.

端口转发​
以下端口需要向 Internet 开放以用于入站和出站
不建议在 NAT 后面运行验证器。选择这样做的运营商应该能够轻松地配置其网络设备并自行调试任何遍历问题。

Required​

8000-10000 TCP/UDP - P2P protocols (gossip, turbine, repair, etc). This can be limited to any free 13 port range with --dynamic-port-range

必需​
8000-10000 TCP/UDP - P2P 协议(​​八卦、涡轮机、修复等)。可以使用 --dynamic-port-range 限制为任何免费的 13 个端口范围

Optional​

For security purposes, it is not suggested that the following ports be open to the internet on staked, mainnet-beta validators.
8899 TCP - JSONRPC over HTTP. Change with `–rpc-port RPC_PORT``
8900 TCP - JSONRPC over Websockets. Derived. Uses RPC_PORT + 1

可选​
出于安全目的,不建议在质押的 mainnet-beta 验证器上向互联网开放以下端口.
8899 TCP - 基于 HTTP 的 JSONRPC。使用 `–rpc-port RPC_PORT``
8900 TCP - JSONRPC over Websockets 进行更改。衍生的。使用 RPC_PORT + 1

Can I run my validator at home?

Anyone can join the cluster including home users. You must make sure that your system can perform well and keep up with the cluster. Many home internet connections are not suitable to run a Solana validator. Most operators choose to operate their validator in a data center either by using a server provider or by supplying your own hardware at a colocation data center.

任何人都可以加入集群,包括家庭用户。您必须确保您的系统能够良好运行并跟上集群的步伐。许多家庭互联网连接不适合运行 Solana 验证器。大多数运营商选择通过使用服务器提供商或在托管数据中心提供自己的硬件来在数据中心运行验证器。

What skills does a Solana validator operator need?

  • 11
    点赞
  • 6
    收藏
    觉得还不错? 一键收藏
  • 打赏
    打赏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

0010000100

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值