🐳Docker
Author: Godwin
System Requirements
CPU
OS
RAM
DISK
8 Cores (Fastest per core speed)
Debian 12/Ubuntu 22.04
16 GB
2TB+ (SSD or NVME preffered)
Run a tracing node
Geth's debug and txpool APIs and OpenEthereum's trace module provide non-standard RPC methods for getting a deeper insight into transaction processing. Supporting these RPC methods is important because many projects, such as The Graph, rely on them to index blockchain data.CommentCommentTo use the supported RPC methods, you need to run a tracing node. This guide covers the steps on how to setup and sync a tracing node on Moonbeam using Docker.
Pre-Requisites
sudo apt update -y && sudo apt upgrade -y && sudo apt autoremove -y
sudo apt install -y wget curl screen git ufwSetting up Firewall
sudo ufw default deny incoming
sudo ufw default allow outgoing
sudo ufw allow 22/tcp
sudo ufw allow 80
sudo ufw allow 443Enable Firewall
Install Docker
Run this command to remove any conflicting docker
Add Docker's official GPG key:
Add the repository to ppt sources:
Install docker
Setting up a domain name to access RPC
Get the IP address of the host machine, you can use the following command in a terminal or command prompt.
Set an A record for a domain, you need to access the domain's DNS settings and create an A record that points to the IP address of the host machine. This configuration allows users to reach your domain by resolving the domain name to the specific IP address associated with your host machine.
Create Moonriver directory
The first command, mkdir moonriver, will create a new directory named moonriver in the current location. The second command, cd moonriver, will change your current working directory to the newly created base directory. Now you are inside the base directory and can start storing docker-compose and related files in it.
Create .env file
Paste the following into the file.
Make Database directory and set necessary permissions
Create a directory for WASM overrides:
Create docker-compose.yml
Create and paste the following into the docker-compose.yml
Note that you have to:
Replace
INSERT_YOUR_NODE_NAMEin two different places. This name can be whatever you want it to be named. For InfraDAO, you can use the name of the serverReplace
INSERT_RAM_IN_MBfor 50% of the actual RAM your server has. For example, for 32 GB RAM, the value must be set to16000. The minimum value is2000, but it is below the recommended specsFor an overview of the flags used in the following start-up commands, plus additional commonly used flags, please refer to the Flags page of our documentation
Monitor logs for errors
The expected output after successful launch should look like this:
Test Moonriver RPC
You can call the JSON-RPC API methods to confirm the node is running. For example, call eth_syncing to return the synchronization status. It will return the starting, current, and highest block, or false if not synchronizing (or if the head of the chain has been reached)
Replace https://{YOUR_DOMAIN} with actual domain name or host ip:
Expected out:
Last updated
Was this helpful?