Setting Up an External Passive Relay Node
This quick start guide walks through setting up an external relay node with the help of CNTOOLs.
This quick start guide walks through setting up an external relay node with the help of CNTOOLs.
Major credits and appreciation to the fine folks at Cardano Community Guild Operators for creating and maintaining CNtool, a most helpful swiss army knife for pool operators. You MUST be familiar with how ADA staking works and possess fundamental Linux system administration skills before continuing this guide.
Relay nodes do not have any keys, so they cannot produce blocks. Instead, relays act as proxies between the core network nodes and the Internet, establishing a security perimeter around the core, block-producing network nodes. Since external nodes cannot communicate with block-producing nodes directly, relay nodes ensure that the integrity of the core nodes and the blockchain remains intact, even if one or more relays become compromised.
A different server/VM (not located on the same machine as your block-producer node)
Installs prerequisite dependencies and creates folder structure.
Reload environment variables.
Familiarize yourself with the folder structure created by CNtools.
To clone the git repository, type:
To compile binaries, type the following commands where <NodeVersion>
is the node version number or branch that you want to build:
To install the compiled binaries, type:
To verify that the correct Cardano node and command line versions are installed, type:
Using systemd services to run your Cardano nodes offers the following benefits:
Auto-start your node when the computer reboots due to maintenance, power outage, etc.
Automatically restart crashed node processes.
Maximize your stake pool up-time and performance.
Nice work. Your node is now managed by the reliability and robustness of systemd. Below are some commands for using systemd.
To confirm that the node service is active, type:
To display the status of the node service, type:
To restart the node service, type:
To stop the node service, type:
To filter logs, type:
OR
OR
To start the relay node, type:
To install Guild LiveView, type:
To run Guild Liveview, type:
Sample output of Guild Live View
For more information, refer to the official Guild Live View docs.
Modify the CUSTOM_PEERS section of the topologyUpdater.sh
script to configure your relay node's connections to your other relays and block producer node. Refer to the official documentation for more info.
Deploy the scripts with deploy-as-systemd.sh
to setup and schedule the execution. This will handle automatically sending updates to the Topology Updater API as well as fetching new peers whenever the node is restarted.
Review your topology.json and check that it looks correct. Your new relay node's topology should contain your block producer node, your other relay nodes, and other public buddy relay nodes.
Specific to your networking setup or cloud provider settings, ensure your relay node's port 6000 is open and reachable.
Additionally, if you have prometheus-node-exporter installed for providing Grafana statistics, then you need to open ports 9100 and 12798. Do not forget to update prometheus.yml
on your prometheus server (aka relaynode1). Restart the prometheus service so that the new relay node appears in your dashboard.
Finally, add your NEW relay node IP/port information to your EXISTING block producer and/or relay node's topology file. Modify the CUSTOM_PEERS section of the topologyUpdater.sh
script.
For your block producer node, you'll want to manually add the new relay node information to your topology.json file.
Example snippet to add to your block producer's topology file. Add a comma to separate the nodes where appropriate.
For relay nodes, manage your topology file or modify the CUSTOM_PEERS section of the topologyUpdater.sh
script.
To refresh topology configurations for a node, you need to restart the node.
To restart nodes:
Type:
Repeat step 1 for each node having updated topology configurations.
On the Guild LiveView screen, press P
to view the peer list. You should see the connection to other node's IP address.
Did you find our guide useful? Send us a signal with a tip and we'll keep updating it.
It really energizes us to keep creating the best crypto guides.
Hang out and chat with our stake pool community on Telegram @ https://t.me/coincashew
Pro tip: Speed this step up by copying the db folder from another node you control.
Port Forwarding Tip: Check that your relay port 6000 is open with https://www.yougetsignal.com/tools/open-ports/ or https://canyouseeme.org/ .
Congrats on the new relay node.
Critical Security Reminder: Relay nodes must not contain any operational certifications
, vrf
, skey
or cold
` ``` keys.
Congrats on completing the guide.
Use cointr.ee to find our donation addresses.
Any feedback and all pull requests much appreciated.