February 22

How to Set Up a Nexus Node from Scratch

Setting up a Nexus node allows you to participate in the network and earn Nexus Points. This guide will walk you through the process of installing and running a Nexus node on a fresh Ubuntu server.

Prerequisites

Before starting, ensure you have:

  • A Linux-based server (Ubuntu recommended)
  • SSH access to the server (e.g., using MobaXterm or Terminal)
  • Basic knowledge of command-line operations

Step 1: Connect to Your Server

If you haven't already, connect to your remote server via SSH:

ssh user@your_server_ip

Replace user with your username and your_server_ip with your server's IP address.

Step 2: Update and Install Required Dependencies

Run the following commands to update your system and install necessary packages:

sudo apt update && sudo apt upgrade -y
sudo apt install -y curl git build-essential pkg-config libssl-dev protobuf-compiler

These dependencies are required for compiling and running the Nexus node.

Step 3: Install Rust

Rust is necessary for building the Nexus node. Install it using:

curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh

Follow the on-screen instructions and reload your shell:

source $HOME/.cargo/env

Step 4: Install the Nexus CLI

Use the following command to download and install the Nexus CLI:

curl https://cli.nexus.xyz/ | sh

This command will automatically install the necessary components.

Step 5: Initialize and Run the Node

After installation, initialize the Nexus node with:

nexus-cli init

Agree to the Nexus Beta Terms of Use and follow the instructions provided.

Then, start the node:

nexus-cli start

Step 6: Verify Node Status

To check if your node is running properly, use:

nexus-cli status

If everything is set up correctly, you should see information about your node's connection and synchronization status.

Troubleshooting

If you encounter issues, try the following:

  • Ensure all dependencies are installed (pkg-config, libssl-dev, protobuf-compiler)
  • Re-run source $HOME/.cargo/env if Rust commands are not recognized
  • Check logs for errors using:journalctl -u nexus-node.service -f

Congratulation!

You have now successfully set up a Nexus node! Your node will start contributing to the network and earning Nexus Points. Keep your system updated and monitor logs for any issues.

For more details, visit the official Nexus documentation.