Friday, November 5, 2010

Update No-IP.com and DynDNS.com Dynamic DNS with ddclient

I have registered several host names with two dynamic DNS service providers: DynDNS.com and No-IP.com, and I've been using ddclient and noip2 to update my dynamic IP address with these services, respectively.

I've recently installed a wireless router, so I poked at ddclient trying to figure out how to use it when the computer running it is behind a router, such that its IP address is an internal address (10.x.x.x) and not the external IP address that needs to be sent over to the dynamic DNS service.

This turns out to be pretty easy: just add use=web to /etc/ddclient.conf to have ddclient discover the external IP via the DynDNS.com IP checking service.

Along the way I've discovered that ddclient also supports No-IP.com - a fact that's only mentioned in the usage message that's displayed when running
ddclient --help
and after some futzing around I've come up with the following configuration file, in order to update both services with the same client, using their respective IP checking services:
use=web
web=http://ip1.dynupdate.no-ip.com/
protocol=noip, login=username, password='password' group_or_comma_separated_host_list
protocol=dyndns2, use=web, web=dyndns, server=members.dyndns.org, login=username, password='password' hostname
(according to the help message, it should've been possible to specify the first two lines inside the third line, but this doesn't work for some reason - I guess it's a bug).