Running a RPC Node

RPC nodes do not directly participate in block production like consensus nodes. Instead, they are responsible for verifying transactions and facilitating communication between different nodes and between nodes and clients, promoting transaction verification and on-chain information retrieval.

1. Run with cess-nodeadm

1.1 Check the latest version of cess-nodeadm Latest version of cess-nodeadm: https://github.com/CESSProject/cess-nodeadm/tags ⚠️ Replace all occurrences of x.x.x in the following text with the latest version number. For example, if the latest version is v0.7.0, then replace x.x.x with 0.7.0.

1.2 Check the installed version of cess-nodeadm Enter cess version in the console to check if the nodeadm version is the latest. If nodeadm is the latest version, you can skip step 3. If not, proceed to step 3 to install. If you do not see nodeadm version, it means cess-nodeadm is not installed, and you need to proceed to step 3 to install.

1.3 Download and install the cess-nodeadm

wget https://github.com/CESSProject/cess-nodeadm/archive/vx.x.x.tar.gz
tar -xvf vx.x.x.tar.gz
cd cess-nodeadm-x.x.x/
./install.sh

1.4 Stop the RPC node service Enter the command: cess stop chain to stop the running RPC node service.

1.5 Define script configuration parameters

The archive mode saves all blocks, which is suitable for full node operation, otherwise, you can set the number of blocks to be saved

Enter cess node mode from 'tee/storage/validator/rpcnode' (current: rpcnode, press enter to skip): rpcnode
Enter cess node name (current: cess, press enter to skip): local-chain
Enter cess chain pruning mode, 'archive' or number (current: archive, press enter to skip): archive  #number of blocks saved

1.6 Start the RPC node

cess start chain

1.7 Check if the RPC node is synchronizing blocks normally

An RPC node will also be started automatically when the user runs the storage node using nodeadm or mineradm, unless an external chain is specified.

2. Run with source code

2.1 Environment Setup Requirements

  • OS required: Ubuntu 22+

  • Rust install:

  • Dependencies install:

  • ProtoBuf install (run as root):

2.2 Get the latest release version of cess-node Check the latest version of cess-node

You can get the latest version using one of the following methods:

Method 1: Download and unzip the release (e.g., cess-0.7.9-venus as example):

Method 2: Clone the repository with the latest tag:

2.3 Compile cess-node

Enter the cess-node directory:

⚠️ Note: The compilation may take approximately 25 minutes on an 8-core machine.

2.4 Start the RPC service

Use the -h flag to view more command options.

If the node is printing block synchronization logs, it means it's running successfully.

⚠️ It is recommended to use systemd, screen or tmux commands to run cess-node(RPC) if you want to keep cess-node running.

3. Run with Container

3.1 Environment Setup Requirements shell curl -fsSL https://get.docker.com | bash docker --version docker pull cesslab/cess-chain:premainnet

3.2 Running Command

Make sure that port 30336 and 9944 are not occupied by other processes.

Execute docker run -it --rm --entrypoint /opt/cess/cess-node cesslab/cess-chain:premainnet --help to get more information about the command options.

3.3 Check if the RPC node is synchronizing blocks normally

The rpc node log is down below and start to synchronize blocks.

Last updated

Was this helpful?