Hiểu về Masternode#

Overview#

Masternode, đã từng là độc nhất cho mạng lưới Dash, nhưng bây giờ trở nên một công nghệ phổ biến và được đưa lên những nền tảng blockchain khác. Phần tài liệu này sẽ mô tả những nguyên tắc và cơ chế của masternode và các dịch vụ mà chúng cung cấp đặc biệt cho mạng lưới Dash.

Simply put, a masternode is a server with a full copy of the Dash blockchain, which guarantees a certain minimum level of performance and functionality to perform certain tasks related to block validation, as well as InstantSend and CoinJoin, as the and instant transaction and privacy features in Dash are called. The masternodes are paid for this service, using a concept known as Proof of Service. This is in addition to the Proof of Work done by miners to secure the blockchain. Masternodes are also allowed to vote on governance and funding proposals, with each masternode receiving one vote (yes/no/abstain) on each proposal submitted to the system.

Anyone can run a masternode. The objective is to have enough decentralization to ensure that no single person controls a significant fraction of the masternodes. However, to avoid bloating the network with unnecessary masternodes or encouraging reckless operators, there is one condition that needs to be fulfilled: proof of ownership of DASH collateral. The coins don't need to be in the masternode, but they need to be kept in a certain way that is transparent to the entire network. If the owner moves or spends those coins, the masternode stops working and payment ceases.

Masternodes are paid by the network for the InstantSend, CoinJoin and governance services they provide. 20% of the block subsidy goes to the budget with the remaining 80% split between miners and masternodes per this block reward reallocation table. Then, every 16,616 blocks (approximately 30.29 days), a superblock is created that contains the entire 20% payout to the budget proposal winners. Masternodes are selected for payment in each block (approximately every 2.6 minutes) from a deterministic masternode list, and moved to the back of the list after payment. As more masternodes are created, the duration between payments increases. If the collateral behind a masternode is spent, or if a masternode stops providing services to the network for more than one hour, it is removed from the list until normal service resumes. In this way, masternodes are given incentive to provide efficient and reliable services to the network.

Việc có nhiều máy chủ lưu giữ toàn bộ bản sao của blockchain và làm việc cho đồng coin làm cho nó trở nên cực kỳ hữu ích. Nhờ có hệ thống phần thường này, làm cho không còn rủi ro do việc thiếu masternode, và do đó các nhà phảt triển có thể dựa vào đó để nhanh chóng triển khai những tính năng phi tập trung mới mà họ muốn thực hiện. Đây thực sự là điểm mạnh của Dash - một hệ thống tạo động lực cho hàng ngàn máy chủ nằm phân tán hoạt động 24x7 có nghĩa là Dash có thể mở rộng một cách hiệu quả hơn và triển khai các dịch vụ nhanh chóng hơn các blockchain mà chạy hoàn toàn bởi những người tình nguyện không được trả công. Càng có nhiều masternode mạng lưới của Dash càng tốt hơn và an toàn hơn.

As of September 2023, the Dash network has almost 3500 masternodes located in 19 countries and hosted on over 140 ISPs. The block reward is approximately 2.310 Dash, so the selected masternode receives 1.344 Dash per payment or approximately 6 Dash per month. The block reward decreases by 7.14% approximately once per year, so the annual earnings for a masternode owner is approximately 7% of the collateral, and will decrease over time as calculated here. See this tool to calculate real-time payment rates, and this site for various real-time statistics on the masternode network.

Evolution Masternodes (evonodes)#

Evolution Masternodes (evonodes) are a subset of masternodes that have been created to host Dash Platform. An evonode is a lot like a regular masternode with the following differences:

Masternode

Evonode

Collateral

1000 DASH

4000 DASH (4X the collateral for normal masternodes)

Specs

Lesser than evonode

Higher than normal masternodes

Service

Only Dash Core

Both Dash Core and Platform

Voting Weight

1 node gets 1 vote

Has 4 times the voting power of a normal masternode

Masternode Concepts#

A list of available documentation appears below:

Important concepts:

  • Masternodes are "registered" and begin offering services when a ProRegTx special transaction containing a particular key is written to the blockchain.

  • The ProRegTx references the transaction id (txid) and index holding the collateral. The IP address and port of the masternode are also defined in this transaction.

  • Lệnh ProRegTx có chứa 2 địa chỉ Dash (cũng được gọi là các khoá công khai) và một khoá công khai BLS, chúng đại diện cho 3 vai trò khác nhau trong masternode và xác định quyền nâng cấp và bỏ phiếu. Các khoá đó là:

    1. ownerKeyAddr: Đây là một địa chỉ Dash (khoá công khai) kiểm soát bởi chủ masternode. Địa chỉ này khác với địa chỉ dùng cho việc đặt cọc. Bởi vì chủ sở hữu sử dụng khoá riêng liên kết với địa chỉ này để thực hiện giao dịch ProUpRegTx, do vậy nó phải là duy nhất cho mỗi masternode.

    2. operatorPubKey: Đây là khoá công khai BLS của người vận hành masternode. Chỉ có người vận hành mới có thể thực hiện giao dịch ProUpServTx. Bởi vì khoá vận hành được sử dụng trong quá trình vận hành masternode để ký các thông điệp P2P liên quan đến masternode, thông điệp liên quan đến quorum và kích hoạt việc bỏ phiếu quản trị, nên các khoá BLS phải là duy nhất cho mỗi masternode.

    3. votingKeyAddr: Đây là một địa chỉ Dash (khoá công khai) được sử dụng cho việc bỏ phiếu đề xuất. Việc bỏ phiếu ký với khoá riêng tương ứng hợp lệ khi masternode còn trong tập các masternode được đăng ký.

  • Masternode owners should specify an address different from the collateral to receive payments in the ProRegTx. The owner may optionally specify a non-zero percentage as payment to a separate masternode operator, if applicable.

  • Cấu hình masternode sau đó có thể cập nhật bằng việc sử dụng các giao dịch ProUpServTx, ProUpRegTx và ProUpRevTx. Hãy xem Cập nhật thông tin masternode trong DIP003 và Thông tin cập nhật masternode trong tài liệu này để biết thêm chi tiết.

Tiến trình cài đặt hoặc nâng cấp một masternode là như sau:

  1. Cài đặt máy chủ và hệ điều hành

  2. Cài đặt phần mềm Dash và đồng bộ blockchain

  3. Sinh một cặp khoá BLS và nhập khoá riêng vào masternode

  4. Chuẩn bị cho một giao dịch ProRegTx

  5. Ký cho giao dịch ProRegTx

  6. Gửi một giao dịch ProRegTx đã được ký

Bước 1 có thể bỏ qua nếu bạn đã có sẵn một máy chủ. Bước 2 và 3 cần truy cập trực tiếp vào masternode. Bước 3 và 4 yêu cầu truy cập đến một ví Dash Wallet (hoặc DMT). Bước 5 cần truy cập đến ví có chứa khoản đặt cọc. Bước 6 cần một số dư Dash để trả cho phí giao dịch.

Masternodes so với đào coin#

Dash, cũng giống như Bitcoin và hầu hết các loại tiền kỹ thuật số, là dựa trên một sổ cái phi tập trung chứa tất cả các giao dịch, được biết là một blockchain. Blockchain này được đảm bảo thông qua một cơ chế đồng thuận; trong trường hợp của cả Dash và Bitcoin, cơ chế đồng thuận đó là Proof of Work (PoW). Các thợ mỏ cố gắng giải quyết bài toán khó, họ nhận quyền tạo một khối mới vào blockchain. Nếu tất cả những người khác đang chạy phần mềm đó đồng ý rằng bài toán đã dược giải một cách chính xác, khối sẽ được tạo vào blockchain và thợ mỏ đó nhận được phần thưởng.

Dash works a little differently from Bitcoin, however, because it has a two-tier network. The second tier is powered by masternodes (Full Nodes), which enable financial privacy (CoinJoin), instant transactions (InstantSend), and the decentralized governance and budget system. Because this second tier is so important, masternodes are also rewarded when miners discover new blocks. The breakdown is as follows: 80% of the block subsidy is split between the miner and a masternode per the distribution found here, while 20% is reserved for the budget system (created by superblocks every month).

Hệ thống masternode được gọi là Proof of Service (PoSe), từ khi masternode cung cấp những dịch vụ quan trọng cho mạng lưới. Thực ra, toàn bộ mạng lưới được giám sát bởi các masternode, nó có khả năng từ chối những khối được tạo không đúng bởi các thợ mỏ. Nếu một thợ mỏ cố gắng chiếm đoạt toàn bộ phần thưởng khối cho mình hoặc cố gắng chạy một phiên bản cũ của phần mềm Dash, thì mạng lưới masternode sẽ làm cho khối đó trở nên mồ côi, và nó sẽ không được đưa vào blockchain.

In short, miners power the first tier, which is the basic sending and receiving of funds and prevention of doublespending. Masternodes power the second tier, which provide the added features that make Dash different from other cryptocurrencies. Masternodes do not mine, and mining computers cannot serve as masternodes. Additionally, each masternode is “secured” by DASH collateral. Those DASH remain under the sole control of their owner at all times, and can still be freely spent. The funds are not locked in any way. However, if the funds are moved or spent, the associated masternode will go offline and stop receiving rewards.

Logic thanh toán#

Since Dash version 0.13.0, masternode payments are entirely deterministic and based on a simple list sort algorithm. Dash version 0.13.0 implemented DIP003 which defines two sets of masternodes.

  1. Trọn bộ, nó có chứa tất cả các masternode đã được đăng ký mà chưa tiêu mất khoản tiền trong các giao dịch đặt cọc.

  2. Hợp lệ, là một tập hợp con của Trọn Bộ nó có chứa tất cả các masternode mà không được đánh dấu là bị cấm Proof of Service (PoSe).

Mỗi masternode trong tập các masternode hợp lệ, xác định bởi mã của giao dịch đăng ký liên kết với khối mà nó được thanh toán lần cuối. Nếu nó chưa từng nhận được thanh toán hoặc bị cấm do không đáp ứng được yêu cầu về PoSe, thì tại block đó nó sẽ được đăng ký như là lần đầu và dịch vụ sẽ được khôi phục trở lại. Một danh sách được sắp xếp tăng dần theo thứ tự độ cao của khối và giá trị băm ProRegTx (như là một bộ ngắt trong trường hợp có hai masternode cùng được đăng ký trong cùng một block), và cái nào đăng ký trước sẽ được chọn để thanh toán.

Evonode Payment Logic#

Because the reward distribution percentages are fixed, the number of evonodes is expected to stabilize around a fixed number based on the total number of masternodes (considering the current number of ~3850 Masternodes, ~450 evonodes are expected). This is because if there are more than that fixed number of evonodes, running a regular MN will be more profitable than running an evonode, and hosts will convert their evonodes into MNs.

Evonodes will receive 100% of the fees generated from Platform and 37.5% of the masternode portion of Core block rewards. Regular MNs will receive the remaining 62.5% of the masternode portion of Core block rewards and 0% of Platform fees.

Proof of Service#

Proof of Service (PoSe) là một hệ thống tính điểm dùng để xác định liệu một masternode có cung cấp các dịch vụ một cách trung thực không. Một số tiêu chí được cậy cho việc tính toán, do vậy không thể chơi trò với hệ thống bằng việc làm cho các masternode có thể bị cấm PoSe vì không trả lời các yêu cầu ping bằng việc, ví dụ việc tấn công từ chối dịch vụ DDoS trước khi thanh toán. Mỗi lần thất bại trong việc cung cấp dịch vụ dẫn đến việc tăng điểm PoSe so với điểm tối đa, nó bằng với số lượng masternode đã đăng ký. Nếu điểm số bằng với số masternode được được đăng ký thì một lệnh cấm PoSe sẽ được kích hoạt và masternode phải được sửa chữa để đảm bảo cung cấp những dịch vụ đáng tin cậy và đăng ký vào danh sách lại sử dụng một lệnh ProUpServTx. Quy luật tính điểm hiện tại trong Dash 0.14 là:

  • Không tham gia vào DKG= 66% hình phạt

  • Mỗi khối tiếp theo làm giảm điểm PoSe xuống 1

Lựa chọn Quorum#

Trong những phiên bản trước của Dash, một nhóm tối thiểu 10 masternode được lựa chọn một cách tức thời để khoá các giao dịch InstantSend. Từ phiên bản 0.14 của Dash, một nhóm tối thiểu được xác định trước, gồm có các masternode đang và có thời gian hoạt động lâu nhất trên mạng. Trong khi chúng vẫn có nhiệm vụ cho các giao dịch InstantSend, cơ chế khoá này đã thay đổi để tự động khoá một cách tối đa các giao dịch trên mạng mà đạt được những yêu cầu theo như mô tả ở đây. Các Masternode bây giờ cũng chịu trách nhiệm cho nhiều chức năng đồng thuận hơn, như ChainLocks. Các nhóm tối thiểu các masternode được lập nên thông qua một quá trình sinh khoá phân tán. Nếu không tham gia được vào DKG thì thậm chí kết quả sẽ bị khoá PoSe như đã mô tả ở trên.

Các yêu cầu cho masternode#

  • DASH collateral: Hosting a master node requires a large amount of DASH collateral. Arguably the hardest part. Dash can be obtained from exchanges such as Poloniex, Bittrex, Kraken and LiveCoin. Shapeshift's service is also an excellent way.

  • A server or VPS running Linux: Most recent guides use Ubuntu 20.04 LTS. We recommend VPS services such as Vultr and DigitalOcean, although any decent provider will do. Generally an instance with low to average specifications will do, although performance requirements will increase according to this roadmap.

  • Có một địa chỉ IP dành riêng: Thường được đi cùng với một máy chủ/máy chủ ảo.

In addition to the DASH held in collateral, masternodes also have minimum hardware requirements. For Dash versions 20.0 and higher, these requirements are as follows:

Tối thiểu

Đề xuất

CPU

2x 2 GHz

3x 2 GHz

RAM

4 GB + 2 GB swap

8 GB + 4 GB swap

Ổ Đĩa

60 GB

80 GB

Mạng

750 GB/mth

1 TB/mth

Masternode bandwidth use ranges between 600-900 GB per month and will grow as the network does.

Dash Evolution#

The exact hardware requirements for Dash Evolution masternodes have yet to be determined, although some pointers can be taken from the roadmap and this blog post. It should be possible to run Dash masternodes on normal VPS servers until the block size reaches approximately 20 MB, after which custom hardware such as GPUs and eventually ASICs may be required.