NYX Masternode Setup Guide for Linux

1) Upgrade OS by running the following commands:

apt-get update
apt-get upgrade
apt-get dist-upgrade

2) Install dependence (packages) for NYX

apt-get install software-properties-common nano libboost-all-dev libzmq3-dev libminiupnpc-dev libssl-dev libevent-dev 

3) Add Bitcoin repository so that you are able to install BerkeleyDB.

add-apt-repository ppa:bitcoin/bitcoin
apt-get update 

4) Install BerkeleyDB.

apt-get install libdb4.8-dev libdb4.8++-dev 

5) Create NYX Wallet directory.

mkdir nyx
cd nyx 

6) Download the lattest wallet version.

wget https://github.com/nyxpay/nyx/releases/download/v0.12.1.6/nyx-0.12.1-linux64.tar.gz
  
wget https://github.com/nyxpay/nyx/releases/download/v0.12.1.6/nyx-0.12.1-linux32.tar.gz  

7) Extract all files from the wallet tar.gz file using the tar command.

tar -xvf nyx-0.12.1-linux64.tar.gz  / tar -xvf nyx-0.12.1-linux32.tar.gz 

8) Start NYX wallet.

cd nyx-0.12.1/
./nyxd -daemon 

9) Make sure your wallet is syncing with the NYX network.

./nyx-cli getinfo 

If you are problems syncronizing the wallet, add the following nodes to your configuration file (nyx.conf) then simply restart your wallet.

addnode=185.117.75.155
addnode=104.216.8.36
addnode=185.117.75.183
addnode=104.216.8.37
addnode=185.106.120.172
addnode=84.200.84.212
addnode=185.82.200.167
addnode=84.200.17.119
addnode=178.211.39.121
addnode=209.134.3.7
addnode=172.245.157.159

10) Get nyx masternode address. This is the address where you should send exactly 1000 NYX.

./nyx-cli getaccountaddress 0 

Send the coins to the generated address and wait for 15 confirmations

11) Generate the private key for the masternode and copy it on a .txt file.

./nyx-cli masternode genkey 

12) Stop the wallet and open the conf file

./nyx-cli stop
nano ../.nyx/nyx.conf 

Copy the following two lines and paste them into the Nano window

rpcuser=YOUR_CUSTOM_USERNAME
rpcpassword=YOUR_CUSTOM_PASSWORD
rpcallowip=127.0.0.1
rpcport=4331
listen=1
server=1
daemon=1
externalip=YOUR_EXTERNAL_IP		
masternode=1
masternodeprivkey=MASTERNODE_PRIVATE_KEY

masternode_private_key is the private key that was generated at step 10

Now you can start the masternode and check it status.

./nyxd -daemon
./nyx-cli masternode start - Start the masternode
./nyx-cli masternode status - Check masternode status

If you would like to check on your wallet's balance and see if you have earned any rewards, enter this command. Any rewards earned from your masternode will appear in the immature_balance until they have reached 100 confirmations, and then they will move to your spendable balance..

./nyx-cli mnsync status
./nyx-cli getwalletinfo

If you are getting WATCHDOG_EXPIRED on mn status please install Sentinel from here (guide below files) : Install Sentinel