loading

Masternode Guide

QUICK COMMERCIUM™ MASTERNODE SETUP GUIDE
(linux local + linux vps)

QUICK COMMERCIUM MASTERNODE SETUP GUIDE

(linux local + linux vps)

We will use two terminals, one for local side and other for VPS side. Indentation of steps means that you are inside the commercium directory.

A) Local setup


sudo apt-get update && sudo apt-get install libgomp1
cd && mkdir commercium && cd commercium
wget https://github.com/CommerciumBlockchain/CommerciumContinuum/releases/download/v1.0.5/commercium_continuum-v1.0.5-linux.tar.gz
tar zxvf commercium_continuum-v1.0.5-linux.tar.gz
cp commercium_continuum-v1.0.5-linux/* .
./fetch_params.sh
cd
mkdir .commercium
nano .commercium/commercium.conf
paste this in the file, then ctrl + x, yes, enter to save and exit. The last 4 lines are commented out, we will edit them later.

txindex=1
daemon=1
server=1
listen=1
rpcuser=youruser
rpcpassword=yourpassword
rpcport=2020
rpcallowip=127.0.0.1
port=2019
#masternode=1
#masternodeaddr=VPS_ADDRESS:2019
#masternodeprivkey=PRIVKEY
#externalip=VPS_ADDRESS:2019
Start the daemon

 ./commercium/commerciumd
Now while it syncs proceed to B.

B) VPS setup

Repeat the eleven steps in A) to get commercium running on your VPS.

C) Masternode configuration


cd commercium
./commercium-cli masternode genkey
The output of this command is PRIVKEY

./commercium-cli getnewaddress
The output of this command is MN_ADDRESS

./commercium-cli sendtoaddress MN_ADDRESS 100000
With this command you will fund the masternode address with the exact amount it needs. Wait 5~10 minutes for the transaction to get several confirmations. Meanwhile we can finish setting up commercium.conf

./commercium-cli stop
Open the conf

nano ~/.commercium/commercium.conf
Edit the file, uncommenting the last 4 lines and replacing VPS_ADDRESS and PRIVKEY with the appropriate data. VPS_ADDRESS is the IP address of your VPS

txindex=1
daemon=1
server=1
listen=1
rpcuser=youruser
rpcpassword=yourpassword
rpcport=2020
rpcallowip=127.0.0.1
port=2019
masternode=1
masternodeaddr=VPS_ADDRESS:2019
masternodeprivkey=PRIVKEY
externalip=VPS_ADDRESS:2019
Get the TXHASH

./commercium-cli masternode outputs
The output of this command is TXHASH (the long string between quotation marks)
and OUTPUTIDX (a number, most frequently 0 or 1).

nano ~/.commercium/masternode.conf
Edit this file according to this format:
ALIAS VPS_ADDRESS:2019 PRIVKEY TXHASH OUTPUTIDX
where ALIAS is a name of your choice for the masternode, for example MN
ctrl + x, yes, enter to save and exit

./commercium-cli stop
./commerciumd

D) Finish configuration on the VPS


/commercium/commercium-cli stop
nano .commercium/commercium.conf
#Here you paste the file from local setup, ctrl + x, yes, enter to save and exit
nano .commercium/masternode.conf
#Here you paste the file from local setup, ctrl + x, yes, enter to save and exit
./commercium/commerciumd

E) Start the masternode and check it (local wallet and VPS)


#In the local terminal:
#If the system is synced the output of this command will be success.
./commercium-cli startmasternode all missing

#In the VPS terminal
#This should show you the message “Masternode successfully started”.
./commercium-cli masternode debug
Congratulations, your masternode is operative.

F) TROUBLESHOOTING AND ADVICES


1. Sometimes the message “Masternode successfully started” takes a while to appear in the VPS commercium client. Be patient, the node information needs some time to propagate.

2. ./commercium-cli masternode list | grep VPS_ADDRESS

Helps you check if your node is up or not.

3. Double check that your masternode outputs are correct in the file masternode.conf in both local and VPS. Issue the command:

./commercium-cli masternode outputs

and check the strings.

4. ./commercium-cli help

and

5. ./commercium-cli masternode help

are your friends.