Install Idena node on VPS

VPS (Virtual private server) is considered as advanced setup. Basically this is setup on linux, so you have to know some basic linux stuff. There is no graphical interface, which makes it even more dificult for linux begginers.

1. Get two months free credits on one of the following VPS providers:
Register at Hetzner
Register at Vultr
Register at Digital Ocean

Choose VM instance that has minimum 2GB of ram memory. This will not work if you use arm based CPU VPS, or Raspberry Pi. You can take a look here how to compile Idena node for Raspberry Pi.

2. Once you register account, you must enter your credit/debit card.

3. Chose Ubuntu 20.04 x64 as a operating system for your server.

4. Under your VPS console you'll find your server IP ADDRESS and PASSWORD for root user. We will need those two to connect from your PC to VPS. Let's presume you are running Windows on your home PC.

5. Download Putty, and install it. It's a free program that will help you to connect and control your server.

6. Download this file connect.bat and save it on your desktop. Right click on it and Edit. If Windows ask if you want to run it, run it.

When connect.bat file is opened for editing in notepad, it will contain these lines

@echo off
start "Putty" "C:Program FilesPuTTYputty.exe" -ssh -L 9999:localhost:9009 root@IP_ADDRESS 22 -pw PASSWORD

You need to change last line, to enter your IP_ADDRESS and PASSWORD from step 4. After that, save connect.bat and close Notepad.

7. Doubleclick on a connect.bat, it will ask you to confirm some key, say Yes.

8. Now that we are successfuly loged into server, let's install Idena Manager. Idena Manager is script that will make your node instalation very easy.

Copy this line and paste it in Putty window by right clicking anywhere in the window, then press enter

source <(curl -sL https://bit.ly/idena-manager-installer)

For us to continue, we need to know. Do you allready have active Idena identity? Or are you just setting up node for new identity?

a) If you have active Idena identity, we must find your private key on your PC, go to:

%appdata%Idenanodedatadirkeystore

(best if you copy paste this in some folders address) there you will find nodekey file. Open it with notepad and copy it.
ALSO, IMPORTANT, BACKUP THIS, THIS IS YOUR PRIVATE KEY, DON'T SHARE IT WITH ANYONE.

Put your nodekey here, which you copied in step above. Copy and paste this line in Putty window. This will install your node.

idena-manager add -w "PUT_HERE_YOUR_NODEKEY" -k "123"

confirm with enter when it asks you for a install location
ATTENTION: after your confirm location, it can take few minutes for node to be installed. Be patient untill you get new message

b) If you are setting up node for new identity, use this command

idena-manager add -w "" -k "123"
confirm with enter when it asks you for a install location

9. Configure Idena client to use node on your VPS. Open idena on PC, go to Settings>Node. Turn off «Run built-in node», turn on «Connect to remote node», set:

Node address:
http://localhost:9999
Node api key:
123


Save both settings

Now when you go to client, you should see your identity/address/robot.

Now, you need to make connection every time you want to open Idena client on PC (when making flips, doing validation, sending coins etc...)

But node runs on VPS with or without Idena client or connection. So now you can turn off your PC and close Idena App.

This setup might take some time, make sure to check if mining is on, after all that you've done.

As a last step, it does not hurt to add 1GB of swap memory to your server. That is virtual memory that can help your server if it runs low on RAM memory.

sudo fallocate -l 1G /swapfile2 && sudo chmod 600 /swapfile2 && sudo mkswap /swapfile2 && sudo swapon /swapfile2 && echo '/swapfile2 none swap sw 0 0' | sudo tee -a /etc/fstab

From time to time, make sure to check if your hard disk is full

df -h

To see current node logs use command:

tail -F log_stdout_node1.log

Ctrl+C to stop it

More useful
Author profile on Baffler
Share:

No comments