IMPORTANT: If you have not already completed DigiNode Setup on your Raspberry Pi, then please go here and first complete STEP 6.
Step 7 - Give the Raspberry Pi a fixed IP address and setup Port Forwarding
Setting up port forwarding is probably the trickiest part of the entire setup, simply because all routers are different. However, it is also probably the most important step, since it makes it possible for other nodes on the Internet to find yours. Without doing this, your node is not able to fully support the network.
A Brief Primer on IP Addresses - Dynamic vs Static
Every single device on your LAN is identified by its IP address - a string of numbers separated by periods (e.g. 192.168.1.125). By default, your router's DHCP server assigns a Dynamic IP Address to every device that connects to the network. Each connected device can periodically renew the lease on the IP address it has been allocated, but should it disappear from the network, the IP address is released for another device to use. This helps prevent the router from running out of IP addresses, but it means that a device on your network is not guaranteed to always be available at its current IP address.
IP addresses on a local network are typically in the range from 192.168.1.1 to 192.168.1.254. The router itself will usually take one of these (usually 192.168.1.1 or 192.168.1.254) and will then have DHCP allocate all or some of the remaining addresses for use by the other devices on your network.
Sometimes it can be beneficial for a device to always have the same IP address (i.e. a Static IP address) each time it connects to the network. This is very useful for servers. In the case of your DigiNode, giving it a Static IP means you will always be able to easily find it on your network, and more importantly forward internet traffic to it.
In order to assign a Static IP address to your DigiNode device, and to forward the required ports, you will need to access to your router's management area.
Step 7.1 - Login to the web interface of your router
Built into almost every router is a web interface that can be used to manage it. The IP address, username and password to access this varies depending on your router manufacturer. In most cases, there is usually a sticker on the router itself telling you how to connect to it, similar to the example below.
The sticker on your router, will hopefully tell you the website address (or IP address) to access the admin page, along with the username and password. If it does not include these, try googling your router make and model to find out the default username and password. (Note: The admin password is not the same as the wifi password.)
You can also try visiting http://whatsmyrouterip.com/ or https://www.routerpasswords.com/ for help finding the default login and password for your router model.
Once you have found the login credentials, enter the IP address or web address into your browser, and then log in to the web interface using the username and password.
If you are struggling to gain access, share your router make and model in the DigiNode Tools Telegram group, and someone will try and help you.
Once you are successfully logged in to your router you can continue on with the next step.
Step 7.2 - Adjust the range of dynamic IP addresses [OPTIONAL]
If you have not already done so, it can sometimes be helpful to adjust the range of dynamic IP addresses on your router, so you have some space outside of it to assign Static IP addresses. (Note: This step is optional, but it can be helpful to keep things tidy.)
In the example above, IP addresses have been organised as follows:
IP Address Range | Devices |
192.168.1.1 - 192.168.1.30 | Static IP addresses |
192.168.1.31 - 192.168.1.253 | Dynamic IP addresses |
192.168.1.254 | Router (Gateway) |
This means that as long as Static IP addresses are kept between 1 and 30 then will never clash with any Dynamic IP addresses.
By adjusting your DHCP server range, you can safely assign a Static IP addresses outside that range, safe in the knowledge they will not clash.
Step 7.3 - Assign a Static IP Address to your Pi
The method for setting a Static IP address varies from router to router. The best way to know how to do it for yours is to google the make and model with the words 'assign static ip'.
In the example below, the process involves locating the DigiNode device in the current list of active DHCP leases (the dynamic addresses) and copying its MAC address. Then, in the 'Static DHCP lease configuration' below that, enter the MAC address, along with the desired IP address for that device, and its hostname. Clicking the green '+' button will add the entry, and 'Save' will save the change.
On some routers, like the 'BT HomeHub' the process differs in that you need to click on the device in the list of connected devices and then set to always use this IP. (You can manually change the IP address itself above.)
For your changes to take effect, it may be required to restart the Raspberry Pi and/or the Router particularly if the IP address of the device has been changed.
At any point, you can run 'DigiNode Dashboard' and to check the current local IP address of the Raspberry Pi.
Once you have successfully, given your device a Static IP address, make a note of it since it will make it easy to access your DigiNode in future. you can then proceed to the next step.
A Brief Primer on Port Forwarding
Port forwarding, sometimes called port mapping, allows computers or services on the public Internet to connect to a computer or service on your local private network. Your router has an external IP address on the public internet, and through port mapping, incoming requests from the internet to a specific port can be redirected to a specific local device on your network.
Your router's public IP address can be thought of like the address of an office building, with the local IP addresses representing floors in the building, and port numbers representing specific rooms on each floor. Port forwarding rules help ensure that a message arriving at the building makes its way to the correct room. In normal use, the public internet can only ever see the building, not what floors, and rooms it has available. Port forwarding lets you selectively make specific rooms available to the public internet, while keeping the rest of the building off-limits.
Step 7.4 - Enable Port Forwarding
The DigiByte blockchain is made up of hundreds of other nodes like yours. To make it easy for these other nodes to connect to yours from the Internet, it is essential that you enable port forwarding for your DigiByte full node and/or DigiAsset Node. If you fail to do this, their ability to support the network will be severely limited.
If you set up a Mainnet DigiNode, the default ports you need to forward are:
- DigiByte Core: 12024 TCP
- IPFS: 4001 TCP
If you setup a Testnet DigiNode, the default ports you need to forward are:
- DigiByte Core: 12026 TCP
- IPFS: 4004 TCP
The method for opening these ports varies from router to router. Like the previous step, the best way to know how to do it for yours is to google the make and model with the words 'port forward' to find instructions specific to your router.
You can also try visiting: https://portforward.com/router.htm (Click on the manufacturer of your router for port forwarding instructions for your specific model.)
The principle involves creating a new port forwarding rule, that will take internet traffic arriving at your router on a specific port (or ports), and redirect it onto a specific device within your network, typically on the same port(s). How the rule identifies your DigiNode device varies from router to router - it might ask you to simply select your DigiNode from a list of connected devices. It may alternatively ask for the MAC address, IP address or hostname of the DigiNode.
In the screenshot example below, it shows the two rules that have been created for the DigiNode. For 'DigiByte Core', the rule will take external traffic on the internet on port 12024 and redirect it internally to device 'diginode' also on port 12024. The rule is identifying the DigiNode by its hostname, in this instance. If you mirror these settings on your router then it should work.
Once you have successfully opened the required ports, you can run 'DigiNode Dashboard' and use the built in port tester to check that it is working.
Step 7.5 - Install Case Software for the fan and power button (if needed)
If your Raspberry Pi case comes with a power button and/or fan, you may need to install software so that they work properly. If you are using the 'Argon One M.2' case, DigiNode Setup can install this for you. Enter diginode-setup
at the command line and choose 'Extras' from the main menu.
Wrapping Up: Please share your #DigiNode on social media!
If you have followed all the steps, your DigiNode on your Raspberry Pi should now be up and running! 🍾🥂🚀
Please take a moment to share on social media that you are now running your own #DigiNode. The more people who run one, the more robust and decentralized the DigiByte network becomes.
To be kept informed of updates, please join the DigiNode Telegram Group. You can also follow @diginode.tools on Bluesky or @diginodetools on X.
Please Donate to Support DigiNode Tools!
I created DigiNode Tools because I want to make it easy for everybody to run a DigiByte Node and DigiAsset Node. I have devoted thousands of hours working on this goal, all for the benefit of the DigiByte community. If this guide has helped you, and you find DigiNode Tools useful, you are kindly requested to make a donation so that I can keep improving it. Many thanks, Olly
dgb1qv8psxjeqkau5s35qwh75zy6kp95yhxxw0d3kup
Thank you very much for your support!
Find me on Bluesky @olly.st and X @saltedlolly.