How to run a Nano node

Bruno Garcia
Oct 25, 2018 · 5 min read

The Nano protocol has been constantly improved by the developers. Nowadays, it is possible to run a Nano node on a $5/month server (DigitalOcean) easily. In this article, I will teach you how to run a Nano node on a $5/month server (DigitalOcean) but you can follow this tutorial on a Linux.

First of all, we should create a droplet on DigitalOcean. For this purpose, you should click on the green button “Create” and then, you should select the “Droplet” option to start the droplet configuration.

In this tutorial, we will use the Ubuntu 18.04 x64 distribution. Also, we will install Docker by clicking on the “One-click apps” tab and selecting Docker.

The simplest droplet costs $5 per month, that’s enough to run a Nano node, since the configurations are 1 GB of RAM, 1-core CPU, 25 GB of SSD storage and 1TB of monthly data transfer.

Let’s select the region where the server will be hosted, the default option is San Francisco 2, but you can choose the one of your preference depending on your region. Also we must not forget to select IPv6 as an additional option in the configuration. At the end, you can select a name for your droplet (or you can keep the default name) and click the green “Create” button.

Now, in the page of our droplet, we will have several options of management of our server, one of them is the option “Access”, that gives us the possibility of accessing the terminal of our server by the browser. For this purpose, select the “Access” option and click the blue “Launch Console” button.

To access the terminal, you will need the login (which is ‘root’ by default) and also the password, which will come in a message in your email. At the first login, you will be prompted to enter the current password and to enter a new password, to change it.

Now that we are accessing the terminal of our droplet, we can finally begin the installation and synchronization of our Nano node! If you are following this tutorial on a server other than Digital Ocean or on your personal computer, the commands should be the same. (Just remember to install Docker on your machine).

In the first command, we will import the official Nano docker container, so, you should enter the following command in the terminal:

sudo docker pull nanocurrency/nano

Now we have the official node Nano container, and we just need to enable it to start using our node. For this purpose, you should enter the command:

sudo docker run -d -p 7075:7075/udp -p 7075:7075 -p [::1]:7076:7076 -v ~:/root nanocurrency/nano

To check if the containers are currently active, we should enter the following command:

docker ps

The name of our current container is “gallant_turing”, this name is randomly generated by docker and will serve to refer to the container (the name of your container will most likely be another), for example, when we want to close it:

docker kill gallant_turing

If you want to update your node, close the current container, use the command to download the official container again and then the command to start the container. Therefore, your node will be upgraded to the latest version.

With our active container, we are able to make requests to our node! For example, we can ask for the current version:

curl -d '{ "action" : "version" }' [::1]:7076

We can request the number of synchronized and non-synchronized blocks:

curl -d '{ "action" : "block_count" }' [::1]:7076

Instead of “version” or “block_count”, you could use any available RPC action. To check the commands, see the official documentation.

An advanced tip: You can make RESTful POST requests to your node via ip from your server on port 7076.

Before finishing, we will create an address that will be our representative! For this purpose, we should generate a wallet and then an account in that wallet.

curl -d '{ "action" : "wallet_create" }' [::1]:7076
curl -d '{ "action": "account_create", "wallet": "63F31D1D5EC7258B252F94D6548E4D39BB6EA81A2D8DB39A2D68116AA5446AB0" }' [::1]:7076

Now, we have our representative account. You can send the generated account to anyone so that they use your node as their representatives, helping to decentralize the network!

If you have questions, do not hesitate to join our group at Discord!

This article was adapted from the Portuguese article made by Marcos Monteiro! Thanks!

Welcome to a place where words matter. On Medium, smart voices and original ideas take center stage - with no ads in sight. Watch
Follow all the topics you care about, and we’ll deliver the best stories for you to your homepage and inbox. Explore
Get unlimited access to the best stories on Medium — and support writers while you’re at it. Just $5/month. Upgrade

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store