Masternode setup on Windows with 2 wallets
Last updated
Last updated
In the article https://docs.fix.network/fix/english-documentation/fix-masternodes-1/masternode-setup-on-windows-with-1-wallet we describe how to set up a masternode on Windows with 1 wallet. In this manual we will use two FIX wallets to set up a masternode on Windows.
In this guide we will refer to the two wallets as a remote wallet and a local wallet. We call a wallet local if we store our FIX coins in it, use it to send and receive payments, and stake. We call a wallet a remote wallet if it is empty, blank and only has one purpose – to be always online with a static IP address and store the masternode private key.
First of all, we need to explain the downsides and limitations of using one wallet for both purposes, instead of two wallets as per this guide. When we use just one wallet, this poses a security risk because your wallet is always online with a known masternode IP address. Somebody can use this information to gain access to your FIX wallet and coins. The single IP address in use is also a limitation factor because you will only be able to start one copy of the same wallet. If you know that you don't have additional hardware and won’t plan to start more than one masternode, that option makes sense. However, if you like to separate your coins and masternode, please continue below.
The masternode requires the remote wallet to be on a VPS server or a computer with a static IP address, always on and stay connected. We first start with the local wallet, which contains your coins that are used for staking as well as sending the masternode payment. We won’t cover the FIX wallet setup process because it is described in the following article: https://docs.fix.network/fix/english-documentation/fix-wallet/windows. We presume that you already have a FIX wallet installed on your PC or laptop.
To start, we need a masternode private key. We have to generate it. Let’s open our local wallet and go to Tools > Debug console. In the console type the text
masternode genkey
Copy the result somewhere - in Notepad for example. It will look something like 93HaYBVUCYjEMeeH1Y4sBGLALQZE1Yc1K64xiqgX37tGBDQL8Xg (Image 1).
Now you have to enter the lines below Image 2 into the configuration file fix.conf on your remote wallet (on your VPS server or second computer). You can access it directly in the folder where your wallet is installed, or click Tools > Open Wallet Configuration Files (Image 2). If you see a system request regarding which program you want to open it with, you can choose Notepad again.
You have to write (or paste) the following information inside:
rpcuser=longrandomusername
rpcpassword=longerrandompassword
rpcallowip=127.0.0.1
server=1
daemon=1
logtimestamps=1
maxconnections=256
masternode=1
externalip=31.32.33.34
port=17464
masternodeprivkey=93HaYBVUCYjEMeeH1Y4sBGLALQZE1Yc1K64xiqgX37tGBDQL8Xg
externalip=31.32.33.34 is your IPv4 address - for IPv6 the address has to be in square brackets [2a03:7777:2222:12:1111:dddd:aaaa:8888]) - and masternodeprivkey=93HaYBVUCYjEMeeH1Y4sBGLALQZE1Yc1K64xiqgX37tGBDQL8Xg - the masternode genkey which we have already generated.
After you have finished editing the fix.conf file and saved it, close the remote wallet and start it again. All necessary changes will have been integrated.
We will now go to the local wallet. You need to send exactly 1 million FIX (1,000,000) to any of your wallet addresses. For better clarity you can name this address during the creation process. How to do this is described in the manual Using the wallet - https://docs.fix.network/fix/english-documentation/fix-wallet/using-your-wallet, or just run the following command via Tools > Debug Console to create a new adress with a suitable name (e.g. MN)
getaccountaddress ChooseAnyNameForYourMasternode
Now that you have the address ready you can send the 1,000,000 FIX collateral to it.
Wait until the first confirmation for the transaction output to be visible in the console. Go to Tools > Debug Console to find out the TXID. Type the command:
masternode outputs
Two fields similar to Image 3 will come up - txhash and outputidx. The results from those will be entered into the masternode.conf file.
Open the masternode.conf file directly in the wallet folder or via Tools > Open the Masternode Configuration File and fill it in like in the example below:
<MN alias> <unique IP address>:17464 <your MN private key> <transaction ID (txhash)> <output index 0 or 1 (outputidx)>. Also see the example of Image 4.
Save and close the conf file and restart your wallet. Wait for the MN collateral transaction to receive 16 confirmations before starting the masternode.
Go to the Masternodes tab. The new MN should be present with an alias, IP address and the MISSING status, which indicates the masternode has not been started yet.
In the Transactions tab you can check whether the MN transaction has received at least 16 confirmations. If it has, go back to the Masternodes tab to start the masternode. Right-click on the MN and do Start alias (Image 5). The MISSING status will have changed to ENABLED and your masternode has started. Good job!
Now you want to double-check the MN status in the remote wallet. Open the console via Tools > Debug console and type
masternode status
The latest status will come up with the message Masternode successfully started, similar to Image 6.
For good practice it is best to also check the status on the FIX explorer website - https://explorer.fix.network/masternodes - and find your masternode via the search bar. Your MN status here will be set as Active.
After starting the masternode its status changes in the following order:
ACTIVE --> For around 2-3 hours after starting it (on the explorer)
ENABLED --> For around 2-3 hours after starting it (in the wallet)
EXPIRED --> It will be for just a couple of minutes (on the explorer)
REMOVED --> For just a couple of minutes (on the explorer)
MISSING --> It will be for just 5-10 minutes (in the wallet)
ENABLED --> This is the final status for both the wallet and the explorer. The masternode will remain in this status while it's running and Active time will start increasing.
*NOTE: if the masternode status is set as MISSING in your local wallet, always check its status in the masternode explorer - https://explorer.fix.network/masternodes. It might be showing EXPIRED or REMOVED there during the starting process which is correct. It is always better to double-check the status with the community rather than hastily do Start alias again!
The first MN reward The average time it takes to receive the first reward is calculated in hours with the formula millions_locked_before_your_MN_is_enabled*2.6/60. At the time of writing the total number of millions that are locked in MNs is 2,500 million, so 2500*2.6/60=108.33 hours or approximately 4 days, 12 hours and 20 minutes.