I recently received an e-mail from my free dynamic DNS provider that said I can upgrade for a fee or I can every month login and re-validate that I’m still using their service.
As I’ve been mooching off of them for over 8 years I really can’t blame them and I fully understand this change.
When I moved my domains to Namecheap one of the options they provide is dynamic DNS so that’s the solution for me. But my FIOS router doesn’t support Namecheap so I setup ddclient on my basement Linux server.
Using Namecheap’s support forum I found what I needed. This post is really my note to myself for when I wipe out my Linux server again and I wonder “How did I do that again?”
Enable Dynamic DNS for your domain
Login to your Namecheap control panel and enable dynamic DNS for your domain. You’ll get a really long password string to use. Save that for now as you’ll need it later on.
Create the DNS entry you want for your host as an A record
I created it with an entry of 127.0.0.1 just as place holder. I’m not sure if this step is really necessary as dynamic DNS should let you create new entries on the fly. But Namecheap’s page says to do it and there’s no harm in prepping for that A record.
Install the ddclient package on your Linux server
I’m using Ubuntu 12.04.2 LTS and the command is simply
sudo apt-get install ddclient
The debconf setup will ask you some questions, just put in what you like. You’ll need to change those values in /etc/ddclient.conf anyway.
Modify the ddclient.conf file
My /etc/ddclient.conf looks like this.
################ # ddclient.conf # namecheap ################ use=web, web=checkip.dyndns.com/, web-skip='IP Address' protocol=namecheap server=dynamicdns.park-your-domain.com login=my-domain.com password='ReallYLongStringLooksLikeMD5orso' my-server
Details have been changed to protect the innocent.
Don’t mess with the server= line, they’re not being cute that really is the name of the dynamic DNS client end point.
The debconf settings that were put in previously won’t work so I deleted /var/cache/ddclient/ddclient.cache and re-ran ddclient manually.
$ sudo rm /var/cache/ddclient/ddclient.cache $ sudo ddclient SUCCESS: updating my-server: good: IP address set to 126.96.36.199
Cool. My server in on my private network so I’m using what my IP address looks like to the outside world.
The ddclient is running as a daemon and when my DHCP assigned IP changes (FIOS does that frequently, no idea why) my basement server will still be resolvable as my-server.my-domain.com. The client will run as long as my server is booted. I use that for testing
dumb and harmful ideas and it’s always on.
DNS tranquility has been restored to my world.