Becoming a Masternode — The Guide

Masternodes (MNOs) play an integral role in the Wienchain ecosystem. MNOs provide a key function for Wienchain by guaranteeing fast, smooth and secure transfer of data. To provide these important services, MNOs are rewarded in WIEN coins. Masternodes also have voting rights allowing them to play an important role in Wienchain governance.

Setup

Setting up a Masternode requires a basic understanding of Linux and blockchain technology, as well as an ability to follow instructions closely. It also requires regular maintenance and careful security. There are some decisions to be made along the way, and optional extra steps to take for increased security.

Install a VPS server

Please refer to: https://medium.com/@wienchain/wienchain-vps-setup-for-masterodes-134b52e42cf

Install the Masternode (Unix):

Once the VPS server is up and installed, connect to the server using ssh. Sudo to the previously created user and run the following command.

Configure the daemon to run:

Use a specific user to be more secure than using root

sudo su - mn1user

Get the latest version from GitHub

Extract it.

Now you have…

tar -zxvf wienchaincore-1.0.1.1-linux64.tar.gz

Run the node. It will create a directory .wienchain. By default, the node will run on the 8888 port

cd /home/mn1user/

./wienchaind -disablewallet -daemon

Add a few nodes to boost the sync process

If you get the following msg:

error: Could not locate RPC credentials. No authentication cookie could be found, and no rpcpassword is set in the configuration file (/home/fut1/.wienchain/wienchain.conf)

Then restart the deamon.

More ip can be found on that page

https://api.wienchain.com/masternode_list

./wienchain-cli addnode 54.169.151.28:8888 onetry

./wienchain-cli addnode 172.104.60.96:8888 onetry

./wienchain-cli addnode 52.90.240.97:8888 onetry

./wienchain-cli addnode 3.87.139.223:8888 onetry

./wienchain-cli addnode 139.162.62.92:8888 onetry

Running this command will show you once the Masternode if synchronized

“IsBlockchainSynced”: true

./wienchain-cli mnsync status

{

“AssetID”: 999,

“AssetName”: “MASTERNODE_SYNC_FINISHED”,

“AssetStartTime”: 1585281989,

“Attempt”: 0,

“IsBlockchainSynced”: true,

“IsSynced”: true,

“IsFailed”: false

}

Open another terminal and run the tail command.

It will show up the sync progress

tail -f .wienchain/debug.log

Install the WIEN latest QT Wallet (Windows Desktop)

Download the latest version for window or mac: https://github.com/wienchain/wienchain-core/releases

Unzip and run wienchien.exe

Here we select a custom data directory to have enough space (Around 200MB shall be enough)

Once the process is complete the following screen will be displayed, depending on your bandwidth it shall take a few minutes.

Then a second process is started that will sync Wienchain blockchain

If the process is running correctly you shall see a screen similar to

If this is not the case then open the tools/Debug Console

Then head to Peers

If this window is empty, then add a few nodes to help the sync boot up.

To do so go in to the console run the following commands one by one:

addnode 13.48.134.167:8888 onetry

addnode 54.169.151.28:8888 onetry

addnode 172.104.60.96:8888 onetry

addnode 52.90.240.97:8888 onetry

addnode 3.87.139.223:8888 onetry

addnode 139.162.62.92:8888 onetry

As per below:

It shall help the process to start.

Once the blockchain is synchronized, the following screen shall appear:

Get an address to pay protx fee

Execute the command getaccountaddress feeSourceAddress in Debug console

Mark down the fee source address here, WY4UG9vqTMfCQoZLyzujMC6JuFUmCDmob4

Deposit to fee source address

Send 0.001 WIEN to the previously generated fee source address,

here WY4UG9vqTMfCQoZLyzujMC6JuFUmCDmob4

Wait for 15 confirmations

Note: you can send any amount as long as there is enough to cover transaction fee or use an address that already have funds

Using the web wallet:

You should see the following message on your Windows wallet

Using the explorer you shall see your transaction as per :

https://explorer.wienchain.com/en/address/WY4UG9vqTMfCQoZLyzujMC6JuFUmCDmob4

Then make sure to wait for 15 confirmations

GetMasternode address

Execute command getaccountaddress mymasternode in Debug console.

Write down this address, here the address shall be:

WfVAeAhf8N6CGe6iFhxoUzjcM32zDxmkaf

Deposit to the Masternode address(collateralAddress)

Send EXACTLY 25,000 WIEN to the Masternode address previously generated.

Wait for 15 confirmations

Note: Make sure the “Subtract fee from amount” is unchecked, if you are sending from the Wienchain QT wallet.

is unchecked, if you are sending from the Wienchain QT wallet. Note: Send exactly 25,000 WIEN, any other amount is not recognized

Using the web wallet

Similarly to the fee transaction, kindly make sure to wait for 15 confirmations. Once 15 transactions has been confirmed the transaction shall appear like this.

Get voting/owner address

Execute command getaccountaddress myvotingaddress in Debug console

Mark down the voting address, here : Wjjw2S8MLBTDERRSdXwbwZG5c4wuBq1qbe

Get the transaction details

Execute command masternode outputs in Debug console

You will receive an array of valid transaction pairs of “collateralHash” : “collateralIndex”

Mark down the collateralHash and collateralIndex

{

“079f48253b3d1c45893533c5e40640198c2bc11ae7096df20f33224bf76e1618”: “0”

}

This number shall be the txId of the transaction of the 25.000 WIEN, like in the following url:

Generate a BLS key pair

A public/private BLS key pair is required to operate a Masternode. The private key is specified on the Masternode itself, and allows it to be included in the deterministic Masternode list once a provider registration transaction with the corresponding public key has been created.

If you are using a hosting service, they may provide you with their public key, and you can skip this step. If you are hosting your own Masternode or have agreed to provide your host with the BLS private key, generate a BLS public/private keypair in WienChain Core by clicking Tools > Debug console and entering the following command:

bls generate

Then on your vpc masternode edit the ~/.wienchain/wienchain.conf and add the following

Stop the masternode server

Restart the masternode server

Prepare a ProRegTx transaction

We will now prepare an unsigned ProRegTx special transaction using the protx register_prepare command in Debug console. This command has the following syntax:

protx register_prepare collateralHash collateralIndex ipAndPort ownerKeyAddr

operatorPubKey votingKeyAddr operatorReward payoutAddress feeSourceAddress

Example, the command need to be on one line:

protx register_prepare 079f48253b3d1c45893533c5e40640198c2bc11ae7096df20f33224bf76e1618 0 139.180.159.91:8888 Wjjw2S8MLBTDERRSdXwbwZG5c4wuBq1qbe 984e9686750eeafaf8d9bd8d11d1bd9a257dd157a0026656bf5dd4464dd9c6d924c375fc08b36ff42e2bc0c7e2cb4d9e Wjjw2S8MLBTDERRSdXwbwZG5c4wuBq1qbe 0 WNt7sFM7HMCpWvkCWjEEZ1pBswCqUe2Jh1 WY4UG9vqTMfCQoZLyzujMC6JuFUmCDmob4

Paste this command to the console

Next we will use the collateralAddress and signMessage fields to sign the transaction, and the output of the tx field to submit the transaction.

Sign the ProRegTx transaction

Now we will sign the content of the signMessage field using the private key for the collateral address as specified in collateralAddress. Note that no internet connection is required for this step, meaning that the wallet can remain disconnected from the internet in cold storage to sign the message.

signmessage WfVAeAhf8N6CGe6iFhxoUzjcM32zDxmkaf “WNt7sFM7HMCpWvkCWjEEZ1pBswCqUe2Jh1|0|Wjjw2S8MLBTDERRSdXwbwZG5c4wuBq1qbe|Wjjw2S8MLBTDERRSdXwbwZG5c4wuBq1qbe|5f7c9835d53a2288ff9adab0a68b8d8dff01b36bdcb7e0c0d83ae359a987fa7a”

Output:

IEkM0FyvAvHAueo2RFcKb5iqL4dVlHKe04yr680SITiSRTaboGlOLwLPsZJLNtGo6WFxztXnUsZwetRfUMEuBNA=

Submit the signed message

protx register_submit tx sig

Where:

tx: The serialized transaction previously returned in the tx output field from the protx register_prepare command

sig: The message signed with the collateral key from the signmessage command

protx register_submit 03000100019fabd51d8f4d5706e642ed310f0dcbeb7a63cf9226e61cd9b4b2ed8949e2dc1f0000000000feffffff01c1840100000000001976a91466f778d91792cab87db7c54a62f2ac1e7aad559188ac00000000d101000000000018166ef74b22330ff26d09e71ac12b8c194006e4c5333589451c3d3b25489f070000000000000000000000000000ffff8bb49f5b22b8e7176b4fb7b6217facc1b0e4ddf1c1077d7f584a984e9686750eeafaf8d9bd8d11d1bd9a257dd157a0026656bf5dd4464dd9c6d924c375fc08b36ff42e2bc0c7e2cb4d9ee7176b4fb7b6217facc1b0e4ddf1c1077d7f584a00001976a914024927d235ab3a8ad8c4e328a31696e44efb337288ace474bd76847d6338a8909c3b587d7010041280b4802b762e51ea42fab045e06b00 IEkM0FyvAvHAueo2RFcKb5iqL4dVlHKe04yr680SITiSRTaboGlOLwLPsZJLNtGo6WFxztXnUsZwetRfUMEuBNA

Validate the signed message

A new transaction should appear

Enable the masternode tab

From the main menu, select Settings > Options > Wallet

Check Show Masternodes Tab, click OK

Close Wienchain-qt wallet

Start Wienchain-qt wallet

Go to Masternodes Tab

You should be able to see your Masternode details

Note: The status will be PRE_ENABLED, after few minutes, you will see the status change to ENABLED

After reaching the block indicated here 152272 you will receive the payment here :

That’s it!

Congratulations on setting up your first Masternode! Please reach out to us on Discord if you need any assistance.

Join the Wienchain community today!