Run a Testnet Node

Hardware Requirements

The minimum and recommended requirements to run a Testnet Persistence Node increase as it produces more blocks and more features are added. Thus, there are no exact hardware requirements that are permanently sufficient. A testnet node should always have redundant resources available.

  • Recommended:

    • 8 GB RAM

    • 100 GB SSD

    • 4 CPU

  • Operating System:

    • Recommended: Linux(x86_64)

    • Others: Windows/MacOS(x86)

Prerequisites

To successfully run a Persistence Testnet Node, we need to install a few prerequirements. Because running the Persistence software depends on them, prerequirements are also known as dependencies.

We need to install and/or setup 5 dependencies - Go, jq, gcc, make, and git.

Install Go

Ubuntu

  1. Remove any previous installation:

  2. Add the Go PPA to Your System:

    First, add the longsleep/golang-backports PPA to your system. This repository contains the latest version of Go. You can add it by running the following command in your terminal:

  3. Update Your Package List:

    After adding the PPA, update your package list to include the latest packages available in the repository:

  4. Install Go:

    Now, install Go using the apt package manager. This command will install the latest version of Go available in the PPA:

  5. Set Up Your Go Environment: After installation, set up your Go workspace and add Go binaries to your PATH. You can do this by adding the following lines to your ~/.profile file:

  6. Verify the Installation:

    Finally, verify that Go has been installed correctly by checking its version. You should see the latest version of Go as the output:

macOS

  1. Install Homebrew (if not already installed): If you don't have Homebrew on your macOS, you need to install it first. Visit the Homebrew website for installation instructions.

  2. Install Go using Homebrew: Open a terminal and run the following command:

  3. To ensure Go is installed correctly, check its version. In the terminal, type:

Install jq, git, gcc, and make

  1. Install:

    • Ubuntu: apt install jq git gcc make

    • macOS: brew install jq git gcc make

  2. Verify Installations:

    • Verify jq: jq --version (sample output: jq-1.6)

    • Verify gcc : gcc --version (sample output: gcc (Ubuntu 9.4.0-1ubuntu1~20.04.1) 9.4.0)

    • Verify make: make --version (sample output: GNU Make 4.2.1)

    • Verify git: git --version (sample output: git version 2.25.1)

Installation Steps

Install the persistenceCore Binary

Note The latest version available in the releases page might not be the one running on the test-core-2 chain. To ensure you're running the correct version, join the Discord Testnet Validator Announcements Channel.

  1. Clone the persistenceCore repository:

  2. Check what version is running on the test-core-2 chain by visiting the Discord Testnet Validators Announcements Channel.

  3. Switch to the branch of the latest version (v6.0.0-rc5 as of time of writing):

  4. Install the persistenceCore binary:

  5. Verify installation (sample output: v6.0.0-rc5):

Create or Import Key (XPRT Address)

  • Create key (ensure you safely store the mnemonic seed phrase):

  • Recover key (you'll be required to input your mnemonic seed phrase):

  • Verify the key was created successfully:

Create and Sync the Node

  1. Initialize the node (moniker = node name):

  2. Download the test-core-2 genesis file:

  3. Use StateSync to sync with the rest of the nodes. Follow the step-by-step guide below:

    • Run the following command and copy the values of trust_height and trust_hash. They are required in the next steps.

    • Open config:

    • Replace the existing settings in the opened file with the following:

    • Make sure you replace trust_height and trust_hash values with the ones you've copied in the previous step.

    Note: For an automated script for StateSync, follow the instructions on this link. Refer to peers here: peers.json . For additional helpful values like seeds, refer here: polkachu .

  4. Open the app.toml file (application-related configuration file):

  5. Change minimum-gas-prices to minimum-gas-prices = "0.005uxprt"

  6. Start the node:

  7. Because we used StateSync to sync with the other nodes, it shouldn't take more than 10 minutes to complete. In the meantime, a lot of output messages will pop one after another.

  8. When the node is completely synced, you should observe a similar output:

    Alternatively, you can use the following command (response must be false):

Node operations

Upgrade the Node's Software

Last updated

Was this helpful?