Run an RPC Node
An RPC node provides JSON-RPC and WebSocket endpoints for developers, dApps, indexers, infrastructure providers, and testing or integration environments. RPC nodes verify chain data but do not participate in consensus or require staking.
Do not expose the node's CometBFT RPC endpoint publicly. Only expose application RPC endpoints that are required for your deployment, and protect them with appropriate access controls and rate limiting.
1. System Requirements
Recommended:
- OS: Ubuntu 22.04 LTS
- CPU: 4 cores
- RAM: 8–16 GB
- Storage: 500 GB+ NVMe SSD
- Network: High-bandwidth connection
- Dependencies: git, jq, curl, make, build-essential, pkg-config
- Go: v1.25+
Install dependencies:
Install Go
2. Install Shardeum Node Binary
Clone the Shardeum EVM repository:
Fetch the latest release tags and check out the currently supported testnet release:
Replace <supported-testnet-release> with the release tag currently supported for Shardeum testnet.
Build and install the binary (may take several minutes):
Add the Go bin directory to PATH:
Verify the installation:
3. Environment Variables
4. Initialize the Node
5. Copy Genesis File
The expected chain ID is:
6. Configure Pruning
For a typical RPC node, custom pruning helps manage storage while retaining recent state.
Edit:
$HOME/.testnet/$NODE_ID/config/app.toml
Set:
If you require complete historical state, run an Archive Node instead using:
7. Enable JSON-RPC
Edit:
$HOME/.testnet/$NODE_ID/config/app.toml
Under the existing [json-rpc] section, set:
8. Start and Sync the Node
Start:
Verify sync status:
Or tail the log:
Wait until fully synced.
9. Optional: Enable gRPC and REST Endpoints
Edit:
$HOME/.testnet/$NODE_ID/config/app.toml
Under the existing [grpc] section, set:
Under the existing [api] section, set:
Enable these only if required by your infrastructure or testing flow.
Restart the node after making changes.
If using systemd:
10. Firewall Configuration
Before enabling UFW, allow SSH access so you do not lock yourself out:
Allow P2P traffic:
Allow the RPC endpoints required for your deployment:
If you enabled the optional gRPC or REST endpoints, also allow:
Then enable and check the firewall:
Do not expose port 26657 (CometBFT RPC) publicly. Restrict sensitive endpoints to localhost or trusted systems, and protect public RPC endpoints with suitable rate limiting and reverse-proxy controls.
11. systemd Service (Recommended)
Check the installed Shardeum binary path:
Create the service file:
Example content:
The example below assumes the node was installed and initialized as the
rootuser. If you used another system user, replaceUser=rootand/root/.testnet/rpcnodewith the corresponding user and node-home path.
Replace <shardeumd-binary-path> with the path returned by command -v shardeumd.
If the node is already running from the manual startup command, stop that process before starting the systemd service.
Reload systemd, then enable and start the service:
12. Scaling RPC Nodes (Optional)
For higher traffic or team-based testing:
- Use load balancers such as Nginx, HAProxy, or AWS ELB
- Run multiple RPC nodes behind a reverse proxy
- Rate-limit requests to avoid overload
- Separate public RPC from internal infrastructure RPC
- Run dedicated indexing services in parallel where required
13. Useful Commands
Check sync
Check network peers:
Check logs
Query JSON-RPC:
14. Troubleshooting
RPC endpoint not responding
- Confirm JSON-RPC is enabled in
app.toml - Confirm IP binding is correct
- Check firewall rules
- Check that the node is fully synced
High latency
- Check CPU, memory, disk I/O, and network utilization
- Review RPC request volume and rate limits
- Confirm that the node remains fully synced
- Add additional RPC nodes behind a proxy if required
Node stuck catching up
- Check peers
- Restart node
- Verify time sync (NTP)
- Confirm you are using the correct testnet chain ID and genesis file
15. Important Notes
- Testnet Chain ID:
shardeum-testnet - EVM Chain ID:
8119 - Network: Shardeum EVM Testnet (subject to change)
- Genesis File: Use the testnet genesis file included with the supported release.
- Archive Mode: Use
pruning = "nothing"only when complete historical state is required. - Testnet configuration may change between testnet phases.
RPC Node Setup Complete
Your RPC node is operational and ready to serve JSON-RPC and WebSocket traffic for the Shardeum testnet.
Use this setup for:
- Testing environments
- dApp and wallet integrations
- Indexers and infra services
- Exchange and backend validation flows