Skip to content

Masternode Instructions Setup Guide

pc888 edited this page Aug 5, 2021 · 5 revisions

Masternode collateral is 10 000 BTA

MN collateral needs 15 confirmations to start MN

Getting started

Be aware, you are setting up a Masternode on a remote server, and keeping your BTA on a local PC. Your BTA is never in danger from the remote server. NOTE: Always do a backup of your WALLET.DAT if you have BTA on your computer.

Cold Wallet Setup

  1. Start your Bata wallet

  2. Make sure your wallet is fully synced

  3. Go to Help > Debug window > Console and create MN address with below command, you can give your MNaddress any suitable name. This guide will specify MN1: A Legacy address is compulsory!!!

getnewaddress "MN1" "legacy"

  1. Generate a private key for your masternode, then save it in a text file, you will need it later:

masternode genkey

  1. Send collateral to your masternode wallet. It can be sent with the GUI or use the command below. “False” means do not subtract transaction fee from the amount sent. Wait for 15 confirmations.

sendtoaddress "your masternode address" false

  1. You can check if you received the collateral sent with following command:

getreceivedbyaddress "your masternode address"

  1. For security reasons it’s recommended to encrypt your wallet with a password, make sure you remember the password or save it in a safe place as all the coins will be lost if you lose your password.

encryptwallet "passphrase"

There is a current bug when you try to send coins from encrypted wallet, it just won’t unlock. We are working hard to fix it. Temporarily you can go to Help > Debug window > Console and type the following temporarily: (60 is 60 seconds)

walletpassphrase "passphrase" 60

  1. In the debug console enter the following to get the output. Save it into that same text file you saved the private key. It’s your TX_ID and TX_INDEX, {‘TX_ID”:”TX_INDEX”}

  2. Edit your masternode.conf file:

*Windows: C:\Users\Appdata\Roaming\Bata , you can also use path %AppData%\Bata in Explorer *Mac: ~/Library/Application Support/Bata *Linux: ~/.Bata

Masternode config file:

  1. Open up an SSH Client (Putty) then log in to your VPS as root. You need to run an Ubuntu 16.04/18.04 VPS

  2. Autoinstall Bata masternode. You could omit all these options if you only want to install the Bata masternode without starting it and without sentinel. Sentinel can be installed later by adding “-s 1” after ./masternode.sh

  3. The script will also cater for easy masternode and sentinel updates.

a. The release is required and the script won’t go ahead without a release specified. Copy the latest release from the “Install Script Help”

wget https://raw.githubusercontent.com/BTA-BATA/Bataoshi/0.17/masternode.sh chmod 755 masternode.sh ./masternode.sh -r v0.17.1.17 -s -n

  1. Follow through the steps and supply the script the Masternode Private Key when it prompts for it.

  1. After the script completed you can copy the details that was generated with the script and save it in the Notepad doc with your other info you saved.

  2. Run the following command to check the masternode status:

bash /var/lib/bata/bata.menu.sh

– Start the masternode if the status is in a stopped state – Check the running state of the bata service – Run -getinfo on the masternode to see the sync status etc. – Edit the masternode config file – Check the masternode start status – Check masternode sync status (to be used with sentinel later on)

  1. If the masternode is fully synced by comparing the local wallet and “Run Masternode GetInfo” blocks count you can complete the rest of the setup on the local/desktop wallet with sentinel later on)

a) Go to your cold/desktop wallet and go to Settings > Options > Wallet and tick the boxes for “Enable Coin Control” and “Show Masternode Tab” then close the wallet so changes can take effect. Open it again so the masternodes.config file can load. Click on the “Send Tab” then click inputs and right click on the MN wallet and click “Unlock unspent”

b) Now click on the “Masternode Tab”, right click on your masternode and click “Start Alias” and confirm.

c) Go back to the VPS and run “Get Masternode Status”, the status should have changed to Masternode Started.

  1. The script created a new user called bata, you already changed the password for the account but can run the following command if you want to change the password again.

passwd bata

  1. Now go back to your VPS and run this command to make sure you installed the latest version.

batad -version

Clone this wiki locally