DNS Notification With Inadyn

Using the Ubuntu Community pages (which are fantastic by the way) I setup Inadyn to update the IP for my DNS records. It was very simple because the community pages go through step by step. I might try to set up a mail server some day.

Install Inadyn using apt-get
sudo apt-get install inadyn
Then edit the config file so it knows the password and alias to update.
sudo vim /etc/inadyn.config
For some reason on my Gutsy install it didn’t create a config file so I created it.

The config file should be located in:
/etc/inadyn.config
and the content should look like this:

--username myusername
--password mypassword
--update_period 60000
--alias myhost.dyndns.org
--background

Change all “myusername”, “mypassword”, “myhost.dyndns.org” to your account and CName record. You can change the update_period but I left that to default.

You update multiple DNS names by inserting a new:
--alias myhost.dyndns.org
for every alias.

Save the config file and now and you can run inadyn manually with this command:
sudo /usr/sbin/inadyn
To automate the script you add a line in contrab. Open the contrab file
sudo crontab -e
add the following line to the end of the file:
@reboot /usr/sbin/inadyn
This will start inadyn on reboot and should update the IP according to the config.

Once you reboot, you can check if inadyn is running by typing this command:
ps -A | grep inadyn
A process called inadyn should be listed.

Related posts:

  1. Awstats
  2. Ubuntu 9.10 Grub2 No Timeout
  3. Linux Command Line Tips
  4. MySQL Tuning
  5. Samba GUI Config

About Danny

Young I.T software professional always studying and applying the knowledge gained and one way to do this is blogging. Dedicated to I.T since studying pure Information Technology since the age of 16, Danny is now in the industry that he has aimed since leaving school. View all posts by Danny → This entry was posted in Linux. Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *.

*

All comments must go through an approval and anti-spam process before appearing on the website. Please be patience and do not re-submit your comment if it does not appear.