Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 5 Current »

Background

The RNode software runs as a server on the RChain network.  The RNode communications software uses gRPC, which uses TLS to secure TCP connections between validators and read-only nodes. The RChain network is a peer to peer network. In order for a RNode server instance to properly communicate with the rest of the network, secure bi-directional communication must be possible. Validators must be able to send queries to each other and must be able to receive connections from other validators.

Supported Network Configuration

The following network configuration is supported by the RChain communications software. 

Server → Router → Internet

The RNode server needs to be directly connected to the router.  The router needs to either support UPnP or have static NAT with port forwarding configured for ports 40400 - 40430.  If you wish to use a different set of ports, specify those at runtime with the --p option.

How Universal Plug and Play (UPnP) Works

RNode supports the UPnP protocol, which is commonly available on retail routers today. When RNode detects a UPnP gateway device, such as your wireless router, the node software will configure the router's firewall rules automatically. In many small business and home networks, this allows the user to run RNode as a validator without having to reconfigure their network.

Note - Node operators running Docker on Mac OS X will not be successful running RNode with UPnP. If you want to run with Docker on Mac OS X, you must configure static NAT and port forwarding manually. See "Routers without UPnP Support" below.

Test your network

A success message means your configuration should be successful connecting to the RChain network.

An error message means your network configuration may not be successful connecting to the RChain network. You need to investigate your configuration and possibly make changes.

Routers without UPnP Support

If your router does not support UPnP, you will have to configure Static NAT and Port forwarding manually.

Refer to your router's documentation and user guide for specific instructions. 


At a high level, you need to do the following:

  1. The machine that is running RNode has to be connected to the router and turned on.
  2. In the router configuration interface, configure static NAT for the machine.
  3. Configure port forwarding for ports 40400 - 40430

When configuration is complete, it should look something like this:

DeviceAllowed ApplicationsProtocolPort Number
My_RNode_serverRChaintcp40400-40430


Running Docker

If you wish to run rNode from within Docker, you must still configure your network settings to match the supported network configuration.  Additionally, you must run Docker with explicit port mapping options.  By default, Docker runs in network bridge mode.  

Example run command:

docker run -it -p 40400:40400 --name my_rnode_server -v "$HOME/var":/var rchain/rnode:latest run --default-timeout 6000 --no-upnp -b rnode://address_of_bootstrap_node


Note - Node operators running Docker on Mac OS X will not be successful running RNode with UPnP. If you want to run with Docker on Mac OS X, you must configure static NAT and port forwarding manually. See "Routers without UPnP Support" below.

Successful Connection


You will know if that your node has connected successfully if you see connection messages in the console.  Example:

Connected #{PeerNode 413838d431224dd68c5b097478d8d34efbe12cdc}

Error Messages


The RNode software automatically attempts to detect a UPnP gateway.  If you see the following message, you need to check that your network configuration is correct and your router supports UPnP.

INFO - trying to open port using uPnP....
INFO - [OK] no gateway found, no need to open any port.

RNode will make 5 attempts to connect to the bootstrap.  After the 5th attempt, RNode will exit.   If your RNode cannot connect, you will see the following message.

 Failed to connect to bootstrap (attempt 1/5)




  • No labels