Each step is required. If it’s not in the guide it is not required. Details matter; skip a detail and more than likely your SmartNode will not work. Take your time to read it patiently, follow the instructions, and verify each step is done correctly. And remember, do not give your private key to anybody or you will lose your funds.
Last updated Tuseday, October 28, 2018. This works with the latest v1.2.6.
This guide will cover step by step how to:
- Create your Vultr Instance that will meet the SmartNode requirements.
- Installing the SmartCash Node with a simple script.
- Creating the required “genkey” for a SmartNode. Each node must use a unique genkey.
- Making a 10,000 SMART collateral transaction.
- Configuring your desktop Node Client and starting your SmartNode
- Monitoring status of your SmartNode
First of all you need to create an account at Vultr. Here is my referral link: https://www.vultr.com/?ref=72959421
Vultr enables you to quickly create the required dedicated VPS instance at $5/month (if you use the $3.50 instance it can work with the swap space, but it’s not recommended). Once you do your first payment using credit card or PayPal you can send later payments using Bitcoin. Vultr generates invoices on the 1st of each month based off previous months usage. You can also easily create more nodes by creating a snapshot of your original SmartNode, which makes it easy to manage because the default password would be the same.
Once you create your account you need to deploy a new server instance at this link: https://my.vultr.com/deploy/
Select any server location. Spread out your nodes geographically to help support the SmartCash network.
Server Type: Select 64-bit OS, Ubuntu 18.04. See screenshot below .
Server Size select $5/month 25GB SSD, 1 CPU, 1024MB Memory, 1000GB bandwidth. Anything more is not required. You need one server per SmartNode.
You can try a 512MB Memory VPS if you also use the 4GB swap space setup. It’s less than the minimum specs but it is working okay for now.
You can leave all the options for sections 4-6 unchecked right now. Section 7 give your server any name. SmartNode is fine.
Click “deploy now” and Vultr will create your dedicated VPS server. It takes a a minute or two for it to get it ready for you.
You will see your server being created with the “installing” in orange and a spinning thing.
Take a moment now to go to your SmartCash Desktop Wallet, making sure it’s the latest version. You need a special smartnode genkey. You can generate that from your desktop wallet from About -> Debug -> Console and typing “smartnode genkey” without quotes. Here is a screenshot. Keep that written down you will need it in another few minutes to set up the VPS.
Now let’s go back to Vultr and check on your server at this page: https://my.vultr.com/.When it is done there will be an IP address written under the server name and the server will show Running in green on the right.
Write down the IP address as you will need it later. In my example it is 220.127.116.11.
Click on Manage on the right side of the row.
Now we need to connect to the server to manage it. You can find the username and password in the left side of the server info. Click the eye icon next to password so you can view the password and write it down.
Now we will log into the server using the built in Vultr Console Viewer. This tool does not support copy and paste so it is a little more tedious to use later. You can also use Bitvise or PuTTY to connect to the server. Just put the IP address into the connection field, port 22, and use the root login and password. This step is beyond the scope of this guide — so just look it up on google if you need help. Otherwise the console in Vultr is fine as we won’t be typing too many commands. You can login to the console in the top right of the current screen where it looks like a monitor. It’s in the right side of this screenshot
Click on view console and it will load up a new window to connect. First, make your window a little bigger by clicking the bottom right corner and resizing the window. Then login. Your login username is “root”, type that without quotes and press enter. Then type in the password and press enter. The password will not show up on the screen as you type don’t worry.
You will then be logged in and see this:
That’s great because you’re now connected to and sending commands to the server.
Now we need to start sending commands in. Let’s use the nice installs script that was created (you can browse here if you want to learn more about those: https://github.com/SmartCash/smartnode)
Notes about console: The console software does not support cut & paste. You will need to type commands and keys. The software also uses the US character set. If you are using an international keyboard layout and are having trouble to key in the special characters such as “/” please switch to a US keyboard layout or connect by SSH (guide by Vultr here).
Then press enter.
Then press enter.
It will prompt you that it will reboot. Press enter.
It will prompt you for a custom SSH port (it’s a security technique to change the default). You can change to anything — something between 100 and 1000 is fine. Just don’t use the SmartNode port of 9678. Write that down.
It will prompt you to type in a unique genkey which you created while the Vultr was being created. Type that in now being careful to type it correctly and exactly.
The script will download and install a bunch of requirements for SmartNodes.
When it is done, it will reboot the server. Now it will take a moment to reload the server.
If you have trouble getting synced up, try adding peers. Help is available in the Discord channel.
HIGHLY RECOMMENDED ADDITIONAL SWAP SPACE: I prefer to create more swap space since the VPS memory is a little low and this can improve stability. It uses more disk space but will still help.
Run the following commands:
(that first command is a lowercase L after fallocate)
sudo fallocate -l 4G /swapfile sudo chmod 600 /swapfile sudo mkswap /swapfile sudo swapon /swapfile sudo cp /etc/fstab /etc/fstab.bak echo '/swapfile none swap sw 0 0' | sudo tee -a /etc/fstab
To see that this worked you can type use the following command:
Free shows you the swap space. Here is a screenshot of showing installed swap space:
You can also check you have disk space left with this command:
You are done with the install but you still need to activate.
Last Step to Check on VPS SmartNode Status: Finally, let’s make sure the daemon is running with the command below and check on the status. Always check on VPS for status and don’t rely only on the desktop wallet, which can be out of sync.
smartcash-cli getinfo smartcash-cli smartnode status
*** IF YOUR NODE WALLET (Desktop Wallet) SHOWS NEW START REQUIRED ALWAYS CHECK ON VPS
PRESSING START ALIAS WHEN NOT NEEDED WILL RESET YOUR NODE POSITION ***
The wallet will load from the downloaded blocks. It takes up to an hour. Once that is done getinfo will show the current block and network state and smartnode status let’s you know how you are doing.
If you get to a screen like this below you’re good. All you need to do next is tell the SmartCash network to use your node, which you need to do from the desktop wallet. From the wallet you also need to create the 10,000 SMART transactions.
If your node is displaying “sync in progress” after doing the “smartcash-cli smartnode status” command, try this:
smartcash-cli snsync next
You need to do a 10K collateral transaction and activate the SmartNode from the desktop. See below, or skip down to text instructions.
Hannah has done a great video here on how to enable your SmartCash SmartNode here:
Steps for the NODE CLIENT – DESKTOP Portion of the Setup
Making Your 10K Collateral with Node Client (Desktop Wallet)
Before we start, makes sure you use active antivirus on this computer! Because you store your funds in this wallet you want to make sure it is secure. Do not deactivate your antivirus!
You are required to have 10,000 SMART as collateral for your node.
Each SmartNode requires this 10K to reside at a unique address. Only one 10K transaction will be counted per address.
To do this, create a new receiving address. On your desktop wallet, go to “File”, select “Receiving Addresses”, then click “+ New”. Write a label, you can call it “SmartNode1”.
It will show up in your list. Now you need to send 10K to it.
Right click on the receiving address and select “Copy Address”. Click Close.
Go to the Send button.
Paste the SmartNode1 address in the “Pay To:” field.
The amount should be: 10000
Leave the checkbox “include fee in amount” unchecked. The total cost will be a little over 10,000, but it will put exactly 10000 in the address.
—-> Make a new backup now. Go to File, Export Wallet and save wallet.dat somewhere safe. <—–
It takes about 6 confirmations, about 6 minutes, to confirm the transaction. If your blockchain is not synced you won’t see it yet. It’s okay if it shows only a transaction fee in the transaction history, the transfer still happened.
Tip: If you make more than one node make sure you lock the address and transaction of your existing nodes in the Send – Coin Control Features menu. Using that to send later 10K transactions is recommended so you don’t use existing collateral, invalidating the original nodes.
IMPORTANT: Your desktop wallet must have a smartcash.conf file in the %appdata%\SmartCash directory (Windows) or ~/Library/Application Support/SmartCash (Mac) with this line in the content: txindex=1 You may use Notepad or TextEdit to create or edit the file.
Required: Adding txindex=1 in smartcash.conf on desktop wallet:
In windows, go to this folder:
In OSX, go to this folder: ~/Library/Application Support/SmartCash
edit smartcash.conf (right click, edit. if it’s not there, create a new file in notepad. on Mac you can use Textedit or TextWrangler)
add the line:
It should look like this below. If you don’t have one there to edit, you can make one:
After that, If you haven’t done so already, bootstrapping speeds up loading the node client: https://smartcash.cc/txindexstrap.zip extract the files to replace the old blockchain data. Don’t mess with your wallet.dat and be sure to keep it backed up somewhere else.
Making your smartnode.conf file.
Please note, the latest node client has a GUI menu for this, although this method still works fine.
You need a few things:
Your Node IP Address
The genkey used for your node (from smartnode genkey command)
A txid and txid index from the 10K transaction
To get the txid, run the smartnode outputs command in the debug console where you made the genkey like so:
Click on Help -> Debug Window -> Console, then type where the cursor is blinking at the bottom: smartnode outputs
The blockchain must be synced up for this to display. Be sure to bootstrap to speed it up!
The txid you need is between quotes.
The txid index is the single number in quotes at the end. Usually 0 or 1.
In windows, go to this folder:
The default datadir is usually located here:
Make a line like so, making sure there is no # in front of it:
SmartNode1 128.148.354.198:9678 93HaYBVUCYjEMeeH1Y4sBGLALQZE1Yc1K64xiqgX37tGBDQL8Xg 2bcd3c84c84f87eaa86e4e56834c92927a07f9e18718810b92e0d0324456a67c 0
Save this text file.
In this example, 93HaYBVUCYjEMeeH1Y4sBGLALQZE1Yc1K64xiqgX37tGBDQL8Xg is a genkey that you used on your VPS matching that IP address.
In this example, 2bcd3c84c84f87eaa86e4e56834c92927a07f9e18718810b92e0d0324456a67c is a txid without quotes. You can use any of the txid if you do multiple nodes.
In this example, 0 is a txid index without quotes.
Tip: If you want to change VPS, make a new VPS with the same genkey. After you install it, update the IP address in your desktop smartnode.conf. Then just restart wallet and start alias again. This is best to do after you just receive a reward if you plan to switch hosts.
Activating your SmartNode
Load your wallet. The blockchain will sync. The SmartNode data will sync.
You should see in the “Smartnodes” tab in “My SmartNodes” the one you listed in the smartnode.conf file.
Select the new node and click “Start Alias”. Just don’t click it again later, because it will reset your wait time if you do that. Also be careful to only select the new node you need to start (and not a previous node).
It will then go to “pre-enabled” for up to an hour.
After that, it goes to “enabled”. Done!
Add the Telegram Monitoring Bot for the status of your node:
Go here: https://t.me/smartnodemonitorbot
Type this command in the chat with the bot to register your node for monitoring:
Remember to ENABLE notifications in telegram for this bot! Otherwise you won’t know something is happening that requires your attention. If you get an alert this is what you need to do to confirm something is happening and what you need to do (restart VPS usually fixes).
Checking Status of Your Node
DO NOT CLICK “START ALIAS” unless absolutely necessary. You will restart your waiting time.
The desktop wallet takes time to sync and correctly display the node status. Do not rely on that. Use the bot above.
If the bot or VPS says “expired”, that’s a sign you need to do something. Hopefully you had set it up to notify you when it went missing first. In that case, just restart your VPS, login, and make sure it’s running with:
smartcashd smartcash-cli smartnode status
If it says “new start required” after running for a while, and it also says that on the telegram bot, then that is the sign you need to do something. Make sure you set up swap space. Usually it’s just random bad luck on the host that had an issue at their datacenter.
Okay, you did all these steps and it’s not working… you get an error such as “can’t connect to server” after you load smartcashd. You can’t turn off the server with “smartcash-cli stop” … and “smartcash-cli getinfo” is not working either. This happens you need to look at the debug logs to find the error:
tail -n 20 ~/.smartcash/debug.log
Now, if you got something in the lines that says “Error: Invalid smartnodeprivkey Please see documentation.” that means the genkey is incorrect. Here’s an example like that below:
Most likely you typed it wrong or didn’t create one. You can use this command to edit the smartcash.conf file and correct the error.
Make sure it is correctly typed, case sensitive, and that there are no spaces at the end.
Save the file with “ctrl o” to save and then press enter to overwrite the current filename. Then do “ctrl x” to exit the nano editor.
After you do this restart your server:
Then log in again and check the status:
smartcashd smartcash-cli getinfo smartcash-cli smartnode status
Sometimes you may get a different error asking you to start with “-reindex or -reindex-chainstate”. The message looks like below:
In this case you just need to issue this command:
This will start up the daemon.
Another common error is using the same genkey for more than one node. You need unique genkeys that go to unique txid for unique collateral.
instructions to upgrade old nodes to v1.2.4.
If you installed using this guide you can upgrade using PPA on your VPS with the following commands, enter one at a time:
sudo apt update && sudo apt install smartcashd -y smartcash-cli stop smartcashd -reindex
To check if it worked type:
Among other info this should return: “protocol version”: 90026
The blocks will sync and peers will connect, shouldn’t take long to finish.
Finally, activate your upgraded SmartNode from the updated Node Client (Desktop Wallet) v1.2.4 with “Start alias”. Be sure to make a backup of wallet.dat also. Status will switch to PRE-ENABLED and to ENABLED after couple minutes.
Now you can check the SmartNode status on your VPS with:
smartcash-cli smartnode status
this should return: “status” : “Smartnode successfully started”
If you made a 16.04 Ubuntu OS you can upgrade to 18.04 with the “Change OS” option in Vultr. This will keep your IP address but you need to type in the same genkey. If you do that, you won’t need to do a new “start alias” as the collateral is already configured properly and the node is already in the known list.
Other things you must or should want to do:
- HIGHLY RECOMMENDED: Adding a Vultr Firewall for just 9678 – the script we used automatically drops traffic but any less traffic actually getting to your server firewall is better for your server.
Here is a guide on improving security of your vultr smartcash smartnode.
- OPTIONAL Add anti-ddos protection to the 9678 port with this anti-ddos script that uses iptables.
- OPTIONAL If you want to be able to copy and paste commands you can’t use Vultr view console. Add an authenticated user for SSH logins using public/private keys with Bitvise or PuTTY. If you do this you might as well disable root logins with password, or login with password keys entirely.
- OPTIONAL Copy your desktop smartnode.conf file somewhere as a backup in case you need to add the VPS to the SmartNode list again as a restart. It will be a littler faster than redoing it.
- REQUIRED: Create your 10000 SMART transactions that are required to be able to generate unique transaction keys to activate the node.
- REQUIRED: Your desktop wallet is up to date and synced up with the blockchain. Here’s how to speed it up: Wallet v1.2.3 are out please download here https://smartcash.cc/wallets/ . Please go to %appdata%/smartcash delete peers.dat, blocks, chainstate and sync. You can speed up sync process with bootstrap file http://proteanx.com/txindexstrap.zip ( need have txindex=1 in smartcash.conf, you have to create smartcash.conf in data folder).
- REQUIRED: Setting up a smartcash.conf file on your desktop wallet that uses the IP address of your node and port 9678, the genkey, and the special output from the 10,000 SMART transfer you need. A simple guide is here. Start at section 9: https://forum.smartcash.cc/t/smartcash-smartnode-setup-guide/2320http://smartnodes.cc/files/SmartCash_SmartNode_Setup_Guide_v1.2.pdf
- REQUIRED: Activate your SmartNode in the SmartNodes tab of the desktop wallet with the “start missing” command… why wait?
- HIGHLY RECOMMENDED: Assess your security practices — have you backed up your wallet.dat recently? Do you keep it safe and encrypted? Did you create a backup paper wallet? Have you thought about other security issues?
- A GOOD PRACTICE: Create a snapshot of your server on the Vultr snapshots tab. This is especially useful if you create multiple nodes and you do custom scripts or security. Then you can use the command “pico ~/.smartcash/smartcash.conf” to edit the configuration on any cloned snapshots from the vultr terminal. After you do that restart the daemon to load the updated configuration with the command “smartcash-cli stop” and “smartcashd” to stop and start. This is all that is required for your extra nodes, other than adding a second line in smartnode.conf on the desktop wallet with the required IP, genkey, transaction id and START MISSING in the wallet smartnodes tab.