NoIP.com Dynamic DNS - installing the Dynamic Updater Client (DUC) on a RPi
 
Notifications
Clear all

NoIP.com Dynamic DNS - installing the Dynamic Updater Client (DUC) on a RPi  

  RSS
MG
 MG
(@mg)
Active Member
NoIP.com Dynamic DNS - installing the Dynamic Updater Client (DUC) on a RPi

Here are instructions to set up a NoIP.com Dynamic DNS updating service on the RPi, for use with Octoprint/PrusaPrint/Octopi.

Dynamic DNS allows access to your local network, by allocating a name to your network instead of an IP address (numbers). This Dynamic Updater Client (DUC) service will update the IP address stored at NoIP and the instructions below will get it to run automatically on the RPi (e.g. with Prusaprint/OctoPi).

First register with NoIP.com (e.g. username and create a NoIP password). Then you will need to create a free Dynamic DNS name, at noip.com e.g. myhome.hopto.org.

NOTE: You can get a free Dynamic DNS name, but you will need to refresh the DNS name at NoIP.com once a month. They will send you an email, just follow the instructions (it only takes a minute or two). Alternatively, you can get a paid Dynamic DNS with NoIP.com - which they will try to sell you. 

Once you've registered your Dynamic DNS name (e.g. myhome.hopto.org) you can use it to access your home or work network. To do that, you need to tell NoIP.com the number of you home/work IP address (e.g. 92.132.43.143). You can skip this step for now, as we want to use the RPi to do that job for us.

However, you will need to tell your Home/Work router where the RPi is located on your Home/Work network, if you want to access the RPi and OctoPi from the outside. You will need to obtain access to the configuration settings in your router for that - and forward a port (e.g. the HTTP port 80) to the same port on the RPi (e.g. located on the home network at 192.168.0.100). Different routers have different ways of doing this. On some routers, you might do that by setting up a new application/game. If your router allows it (which it normally does), allocate a fixed internal IP or MAC address to the RPi.

The following instructions will install the Dynamic Updater Client from NoIP.com onto the RPi, so that the Pi will automatically update the NoIP.com database with you home/work IP address (e.g. 92.132.43.143) and allocate your home/work network a name on the internet (e.g. myhome.hopto.org).

1. On the RPi, log in (user "Pi", enter password) to get the command line.

2. At the command line type the following. After each entry press “Enter.   

cd /etc/usr/local/src

sudo wget https://www.noip.com/client/linux/noip-duc-linux.tar.gz

sudo tar vzxf noip-duc-linux.tar.gz

cd noip-2.1.9-1

sudo make install

(This will create an app called noip2, in the /usr/local/bin folder)

(Further information can be found here: http://www.noip.com/support/knowledgebase/installing-the-linux-dynamic-update-client/)

After typing “sudo make install” you will be prompted to login with your No-IP account username and password. The account username is the NoIP.com login username, e.g. your email address (not the name of the Dynamic DNS, such as myhome.hopto.org). Note: if you have more than one Dynamic DNS on your account you will be asked for the name of the one you want to use).

When asked how often you want the update to happen, enter the number of minute, but you must choose 5 minutes or more. The interval is listed in minutes, if you choose 5 the update interval will be 5 minutes. If you choose 30 the interval will be 30 minutes. I set mine at 60 minutes.

This creates an encrypted configuration file no-ip2.conf, which is stored in /usr/local/etc

You can confirm that the service is working properly you can run the following command : sudo noip2 ­-S (Capital “S”)

Now, all you need to do is tell the RPi to run this noip2 app at boot-time. To do that edit the file /etc/rc.local, using an editor (e.g. nano, or vi)..

sudo nano /etc/rc.local

Insert the follow text near the start (I put it as a new line, after the comment line "#By default this script does nothing.")

sudo /usr/local/bin/noip2

save the rc.local file and exit the editor.

Reboot the Rpi by typing

sudo reboot

All done.

Now, each time the RPi is on, the Dynamic Updater Client (DUC) will run in background and keep the NoIP Dynamic DNS up to date with the current external IP address of your home/work network.

You can then use Smartphone apps like OctoPod anywhere you want, or simply access the OctoPi from a browser by typing in the web address, (e.g. http://myhome.hopto.org)

I hope you find this guide useful.

Posted : 12/08/2019 11:16 am
Share: