The Nontechnical Guide to Onboarding an Ambrosus Masternode — Hetzner Edition

Jerome!
10 min readJul 12, 2020

This guide is targeted at non-technical users who are going through the process of onboarding a masternode onto AMB-NET. I have seen many community members struggling with setting up their masternode. This is usually because they do not understand the technical terminology used or have never worked with a unix terminal before. The goal of this guide is to break down the concepts for everyone to not only feel comfortable setting up their masternode, but also to understanding the reasoning for each step along the way.

Overview

  1. VPS Setup
  2. Setup Your Node
  3. Send tokens
  4. Running Your Node
  5. Final Comments

VPS Setup

What is a VPS?

A virtual private server allows users the ability to run their own server on shared physical resources. As an analogy, think about it like renting office space in a large office building. We own our space and we can customize it to our needs, but at the same time the building is shared with other people.

The term virtual private server is named as such because virtualization is the technology used that allows the host (in our case Hetzner) to split up a single server into multiple ones. The word private means the server will only be accessible by you and resources will be dedicated for your server as specified during the VPS setup (i.e. RAM, CPU, Storage etc.)

Why do I need a VPS?

Our VPS will be where we setup and run our node from. Instead of running our nodes from our own desktop machines, hosting on a VPS will allow us benefits such as reliable availability, ease of setup & configuration, and future scalability.

Step 1: Setup a Hetzner server

To begin, first create an account at Hetzner. The link is my referral link to Hetzner, you get €20 of free cloud credits (valid for 1 month) by using this link. It would be appreciated when you use this tutorial for setting up your node to use the referral link to show some appreciation of this article. Once you have done that you have access to the cloud control panel.

Next, login and create a new project. Call it whatever you’d like, I named mine “Ambrosus”. Go to your new project.

Create a new project
Enter your project name

We now go to the security tab and add a SSH key.

Add key

Use this link to create an SSH key. Store the public and private key safely somewhere away. Paste the public key you generated here.
And add a name to identify the SSH key.

Next add a server.

  • Location The geographical location can be chosen to your preference. Normally the one closest by.
  • Image Use the default Ubuntu OS image preselected: Ubuntu 22.04 LTS. Recommended is to use the latest LTS release.
  • Type Standard storage type local (NVMe SSD)
  • Plan CPX11. Not to be confused with CX11. Choosing a lower type tier will result in your node not functioning correctly as those don’t meet the minimum specs.
  • Volume and network Not needed, leave unselected.
  • SSH key Select the SSH key you have created previously
  • Name Give the server a meaningful name, e.g. Omega1
Further server details

Your server will start deploying.

Firewall

Since the Hetzner cloud firewall is out of beta stage its much more convenient to setup these rules from the control panel and apply them to your server.

Main overview of existing firewalls, yours will be empty initially

For Atlas let’s add this rule:

Firewall rules for Atlas

For Apollo let’s add this rule:

Firewall rules for Apollo

In the resources tab apply the firewall rule to your resource and press apply to server(s). Plural as you can update many at once, but if you are installing your first node probably there is only one server to be selected.

Setup your node

Step 2: Login into your VPS

For Windows users
You can use PuTTY to connect to your VPS. Here’s a good guide on how to do that. Use the IP address as listed in the IP address column to connect. The default username is ‘root’ and the ‘passphrase’ from the SSH key will allow you to login.

Use the IP address displayed to connect via Putty

For Mac /Linux Users

Begin by copying the IP address of your droplet. You can find it by viewing your droplet in your browser. Simply click on it to copy it to your clipboard. Next, open your terminal and type in the following command:

ssh root@<droplet_ip_address>

Replace “<droplet_ip_address>” with the address we had previously copied. This above command tells us we want to SSH into the root user at the following server IP address. If you setup a password for your SSH key, you’ll be prompted to enter it here. Say yes to any other prompts.

Note that root is a special superuser and is the default user who has all rights or permissions in our Linux operating system.

Just like that you’ll be connected to your VPS. You are now remotely accessing your private server!

If you recall, we setup our server with the Ubuntu OS. Other than the actual operating system, there is nothing else installed on our server. Time to change that.

Step 3: Retrieve and run the setup script

If you’ve been following the Ambrosus github, you’ll notice a project called ambrosus-nop. This is the tool created by the Ambrosus Technical team to facilitate onboarding your masternode.

Let’s start by downloading this tool into our server. Run the following commands:

wget https://nop.ambrosus.io/setup.sh
chmod +x setup.sh

The first command beginning with wget is a utility that retrieves the content of the setup script and related files we’ll need

The second command, chmod simply changes the permissions of the .sh file so that we’ll be able to run the script. The “x” is for executable

Now let’s run this script, its an interactive script so have you’ll be using your up/down arrows along with the enter key to make your selections.

./setup.sh

Options to select:

  • Main network
  • Create a new key, we need to either provide an existing key to a wallet we’ve created elsewhere or more simply we can just let the script create the new public/private key for us. We will choose the latter.
Address Private Key generation

IMPORTANT: Do not enter the private key to your Ethereum cold wallet, you will be creating an entirely new wallet above to use with the network

  • Select your node type and tier
Node type selection
The node tiers shown are Atlas tiers.

Important: in order to run a new Apollo node it requires a minimum stake of 1 million AMB.

  • URL

For Atlas:
Enter the IP address of your server, example: http://81.25.505.22
Don’t forget the “http://” prefix. This is how the network will be able to reach our node and used for the nodeinfo page. Do not use https:// as that is currently not supported.

Optionally: If you have an existing (sub)domain you can also use that and point the domain to the IP address. The benefit is that you can enter a URL for the nodeinfo page, instead of an IP but apart from that functionally there is no difference.

For Apollo:
Enter the IP address of your server, without http example: 81.25.505.22

  • Email address

You have now finished the main installation. In the background the installer has created a file called state.json. This file stores the result of the script you just completed, in here you can find the private and public key to the wallet you had created. Do not share the private key with anybody!

View the contents with the following command
nano ./ambrosus-nop/state.json

Save your address and private key securely for example in a password manager ! You will need it later to import into the MetaMask wallet.

At the end of this section you have:

  • Downloaded the ambrosus-nop tool onto your VPS
  • Completed the initial setup steps
  • Stored your node address and private key safely
  • Sent a request for whitelisting (by completing the setup)

Setup MetaMask

First, download MetaMask to your browser if it is not already installed. https://metamask.io/

Recall the wallet we previously created in Step 3 as part of running the setup script. Let’s start with importing our new wallet into MetaMask.

First click on the MetaMask extension in your browser, it asks you to create a new wallet or import one with a seed phrase. Since we don’t have a seed phrase for our wallet, just create a new wallet to get to the next screen.

After creating an account, click on the Account button in the upper right corner, you’ll probably have a colorful image there, and select import account.

Here you’ll paste in the private key to your wallet. See below if you are unsure how to get that.

If you are looking for your private key, recall the state.json file that was created on our server. In that file you can find your private key. Paste that into the form and click import.

Now our wallet is imported into MetaMask. Theres one more step before we send our tokens over, we need to add the Ambrosus Network.

Complete Step 2 in Vlad’s post and return here https://medium.com/@vladtrifa/how-to-connect-to-amb-net-with-metamask-6964c71e217e

Step 4: Send tokens

With MetaMask configured and having native AMB already from Kucoin/P2PB2B/Binance, you can now send your stake for the masternode you are onboarding to the public address of your wallet from step 3. For example, for Atlas Omega that’s 75,000. To ensure we cover gas fees I would recommend 100 extra tokens (total of 75,100). Failing to do so may get the node up and running, but you will end up failing to receive bundles as it lacks the AMB to pay for gas fees.

Step 5: Whitelisting email

Once the transfer is completed you can send a whitelisting request to support@ambrosus.io (subject: Atlas Omega Whitelist Request).

Enter the output from the command below in the email, you can copy by selecting and right mouse click in the Putty window and paste in the email body.

cat ./ambrosus-nop/output/TOS.txt

And the following parts from state.json (minus the private key!!!)

{
network: main,
address: 0x123456789
role: Atlas Omega
email: youremail@gmail.com
url: http://127.0.0.1
...
}

Afterwards wait until whitelisting confirmation by the tech team, usually it takes 24 hours (weekdays).

Running Your Node

Step 6: Finishing the setup

Once you’ve heard back from the team with your whitelist confirmation, you are ready to run your node!

Connect to your VPS and run the following script. Note this script is different than the one we previously ran. Refer to the previous steps if you forgot how to connect to your VPS.

./setup2.sh

Go through the interactive menu again and select any that apply to you. Once you are done with the script you’ll be officially onboarded!

The node will now start to sync the blockchain , which can take up to roughly 12–24 hours. You can monitor the sync process by going to http://stats.ambrosus.io and enter your node address. The block of your node must reach the same as the the last network block before it starts working (the nodeinfo page will only come up after sync has finished).

If you would like to see how many bundles you’ve successfully stored so far (Atlas) or to see your block rewards (Apollo) simply search your address in the explorer.

https://explorer.ambrosus.io/atlas
https://explorer.ambrosus.io/apollo

Congratulations, you’re officially an Ambrosus masternode operator!

Final Comments

Restrict access

As an extra security step, you can decide to restrict root access via SSH. This will prevent hackers from stealing our information and gaining access to our server. The first step to doing this is creating a new user that you will use to login, followed by restricting access to anyone trying to login to our server using a username and password. You will instead connect to the VPS using SSH keys as mentioned above.

Here is a good doc that covers the steps needed to take on our Ubuntu environment.

Backup Wallet/Key
Be sure to backup your private/public key to the address we created. If you have a password manager, create a secure note. Even better, store it securely offline on paper.

Monitor for Node software updates
Your node has an automatic update function. However keep an eye on slack and the telegram channel for required updates.

Monitor for OS Updates
Ubuntu regularly has OS updates that you need to install. Make sure to keep your VPS OS up to date using:

sudo apt update
sudo apt upgrade
Reboot the system if kernel was updated by typing sudo reboot command.

Hall of fame
Thanks to subliminal-amb for creating the original guide.

Migration & Other providers
Not looking to host on Hetzner? There are more guides available for other cloud providers.

Already running a node on another cloud provider? Use this link on how to move your existing Atlas server. Apollo migration instructions here.

--

--