Join the XRPL EVM Sidechain Devnet

Attention

The XRPL EVM compatible sidechain implementation is a proof of concept extension to the XRP Ledger protocol and is for development purposes only. There is no official amendment currently and it is not available on the production Mainnet. The EVM compatible sidechain bridge is connected to the XRP Ledger Devnet. Do not send transactions in Mainnet.

This tutorial walks you through the steps to install the existing XRP Ledger EVM Sidechain Devnet.

XRPL EVM Sidechain Node Hardware Requirements

  • Linux/AMD64 operating system.
  • 4 or more physical CPU cores.
  • At least 500GB of NVME SSD disk storage.
  • At least 32GB of RAM.
  • At least 100Mbps network bandwidth.

Installation Methods

Downloading Raw Binaries

A straightforward method that involves downloading the latest binaries and running them on your system. This method requires minimal prerequisites and is quick to set up.

Pre-requisites

  • None (Ensure your system meets the hardware requirements).

Steps

  1. Download the latest binaries from the official repository .
  2. Extract the binaries and move them to your preferred directory.
  3. Make the binaries executable:
    Copy
    Copied!
    chmod +x exrpd

Building from Source

This method involves cloning the source code repository and building the binaries from source. It is ideal for developers who want to customize the node.

Pre-requisites

  • make and gcc installed.

Steps

  1. Clone the repository:
    Copy
    Copied!
    git clone https://github.com/xrplevm/node.git
  2. Navigate to the project directory:
    Copy
    Copied!
    cd node
  3. Build the project:
    Copy
    Copied!
    make build
  4. The binaries will be available in the build directory.

Using Docker

A containerized approach that ensures the node runs in a consistent environment. This method is highly recommended for users who want to avoid dependency issues.

Pre-requisites

  • Docker 19+ installed.

Steps

  1. Pull the Docker image:
    Copy
    Copied!
    docker pull peersyst/exrp:latest
  2. Create an alias to run all commands inside the Docker container:
    Copy
    Copied!
    alias exrpd="docker run -it --rm -v ~/.exrpd:/root/.exrpd --entrypoint=\"\" peersyst/exrp:latest exrpd"

Using Cosmovisor for automated upgrades

A more advanced method using Cosmovisor, which automates the process of binary management and upgrades.

For detailed steps, refer to Using Cosmovisor for automated upgrades.

Initialize Node

The first task is to initialize the node, which creates the necessary validator and node configuration files.

  1. Initialize the chain parameters using the following command:
    Copy
    Copied!
    exrpd config chain-id exrp_1440002-1
  2. Create or add a key to your node. For this tutorial, we use the test keyring:
    Copy
    Copied!
    exrpd keys add <key_name> --keyring-backend test

    Note the key_name you enter as you need to reference it in subsequent steps.

    Note For more information on a more secure setup for your validator, refer to cosmos-sdk keys and keyrings and validator security.

  3. Initialize the node using the following command:
    Copy
    Copied!
    exrpd init <your_custom_moniker> --chain-id exrp_1440002-1

    Monikers can contain only ASCII characters. Using Unicode characters renders your node unreachable.

All these commands create your ~/.exrpd (i.e $HOME) directory with subfolders config/ and data/. In the config directory, the most important files for configuration are app.toml and config.toml.

Genesis & Seeds

  1. Copy the Genesis File.

    Download the genesis.json file from here and copy it to the config directory: ~/.exrpd/config/genesis.json. This is a genesis file with the chain-id and genesis accounts balances.

    Copy
    Copied!
    wget https://raw.githubusercontent.com/Peersyst/xrp-evm-archive/main/poa-devnet/genesis.json -O ~/.exrpd/config/genesis.json
    Attention

    Before jumping to the next item, make sure that the contents of the file ~/.exrpd/config/genesis.json match the contents of the file genesis.json.

    Verify the genesis configuration file:

    Copy
    Copied!
    exrpd validate-genesis
  2. Add Persistent Peer Nodes

    Set the persistent_peers field in ~/.exrpd/config/config.toml to specify peers with which your node maintains persistent connections. You can retrieve them from the list of available peers on the archive repo (https://raw.githubusercontent.com/Peersyst/xrp-evm-archive/main/poa-devnet/peers.txt).

    To get a list of entries from the peers.txt file in the PEERS variable, run the following command:

    Copy
    Copied!
    PEERS=`curl -sL https://raw.githubusercontent.com/Peersyst/xrp-evm-archive/main/poa-devnet/peers.txt | sort -R | head -n 10 | awk '{print $1}' | paste -s -d, -`

    Use sed to include them in the configuration. You can also add them manually:

    Copy
    Copied!
    sed -i.bak -e "s/^persistent_peers *=.*/persistent_peers = \"$PEERS\"/" ~/.exrpd/config/config.toml

    At this point you should have the list of the peers copied to the persistent_peers field in the config.toml file. You can verify this by running the following command:

    Copy
    Copied!
    cat ~/.exrpd/config/config.toml | grep persistent_peers

Run and Synchronize Your Node

To run and synchronize your node, follow the instructions in the Run and Synchronize Your Node guide.