MASTERNODE on Linux

Considering your wallet is completed and syncronized.
To create a PNX Masternode, you need to have EXACTLY 20.000 PNX.
First of all, let's change the phantomx.conf to allow load the MASTERNODE.

================ Section 01 // Getting additional infos ================

Get you private key using your WALLET ADDRESS - do not send it for anyone
Code:
/wallets/phantomx/phantomxd -datadir=/wallets/phantomx/wallet dumpprivkey <your WALLET ADDRESS>
Lost your ADDRESS WALLET? Run this command:
Code:
/wallets/phantomx/phantomxd -datadir=/wallets/phantomx/wallet getaccountaddress MN01
SAVE THIS PRIVATE KEY in a safety place

Identifying your EXTERNAL IP Address
Code:
dig +short myip.opendns.com @resolver1.opendns.com
Save this IP ADDRESS temporarily

================ Step 02 // Configuring your wallet ================

STOPPING your wallet
Code:
/wallets/phantomx/phantomxd -datadir=/wallets/phantomx/wallet stop

Changing the CONFIG file
Code:
vi /wallets/phantomx/wallet/phantomx.conf
change your CONF file similar with this:
rpcallowip=127.0.0.1
rpcuser=<user you want>
rpcpassword=<your password>
staking=0
server=1
listen=1
port=9340
masternode=1
masternodeaddr=<your IP ADDRESS listed above>:9340
masternodeprivkey=<your PRIVATE KEY listed above>

addnode=54.218.118.59:9340
addnode=54.218.118.59:9341

STARTING your wallet
Code:
/wallets/phantomx/phantomxd -datadir=/wallets/phantomx/wallet -daemon -server

Check if your wallet is update with the EXPLORER.
1 - Open the EXPLORER: http://explorer.phantomx.co
2 - Check the latest number of block
3 - Run the command bellow and the look the number on the parameter BLOCKS:
Code:
/wallets/phantomx/phantomxd -datadir=/wallets/phantomx/wallet getinfo

================ Step 03 // Sending PNX Coins ================

SEND EXACTLY 20.000 PNX for your new WALLET ADDRESS created on the process above

Waiting the TX be confirmed. You can accomplish it via:
Code:
/wallets/phantomx/phantomxd -datadir=/wallets/phantomx/wallet listtransactions

Check if your balance is OK (should have 20.000 PNX at this point):
Code:
/wallets/phantomx/phantomxd -datadir=/wallets/phantomx/wallet getbalance

================ Step 04 // Starting your Masternode ================

If all steps are OK, now you can start your Masternode
Code:
/wallets/phantomx/phantomxd -datadir=/wallets/phantomx/wallet masternode start

Wait 3-5 minutes and check if your IP is listed on MASTERNODES LIST
Code:
/wallets/phantomx/phantomxd -datadir=/wallets/phantomx/wallet masternode list | grep <your IP ADDRESS>

LINUX TIPS

These tips will allow you to create "shortcuts" instead of to right the full command in your console

================ Step 01 // Creating alias ================

ALIAS will help you to reduce the code when you are writing the code in the prompt.
Code:
alias pnx="/wallets/phantomx/phantomxd -datadir=/wallets/phantomx/wallet"

Now, type only:
Code:
pnx getinfo
instead of write
/wallets/phantomx/phantomxd -datadir=/wallets/phantomx/wallet getinfo

================ Step 02 // Saving the alias in your profile ================

Let's save the alias on your profile
Code:
cd ~
vi .bash_profile

If .bash_profile is NOT empty, ignore this step! If IS EMPTY, add this on the begin of the file .bash_profile:
Code:
# .bash_profile

# Get the aliases and functions
if [ -f ~/.bashrc ]; then
. ~/.bashrc
fi

# User specific environment and startup programs
PATH=$PATH:$HOME/bin
export PATH
That's fine, let's add the ALIAS on the end of file:
alias pnx="/wallets/phantomx/phantomxd -datadir=/wallets/phantomx/wallet"

================ Step 03 // Quick tips ================

Wallet HELP
Code:
pnx -?

To know the balance and POW / POS / Block
Code:
pnx getinfo

Get only the total of coins
Code:
pnx getbalance

List of lasts of transactions
Code:
pnx listtransactions

Transfering coins to another wallet
Code:
pnx sendtoaddress <wallet address destionation> <total PNX>

example:

pnx sendtoaddress YechFPuCc4wd8BLQpwjWsNKazRJa2qfJEF 100

================ Step 04 // Creating SCRIPT to start the wallet when the Linux is restarted ================

Creating the shell-script file:
Code:
cd /wallets
vi start_wallet.sh

Copy and paste this code:
Code:
echo Starting PHANTOMX wallet /wallets/phantomx/phantomxd -datadir=/wallets/phantomx/wallet -daemon -server
sleep 25
echo Starting PHANTOMX Masternode
/wallets/phantomx/phantomxd -datadir=/wallets/phantomx/wallet masternode start

================ Step 05 // Scheduling the Shell-Script ================

Opening the Ubuntu schedule in your local user
Code:
crontab -e
Copy and paste on the end of the file
Code:
@reboot /wallets/start_wallet.sh