What options do I have for setting up an external dns server?

To add redundancy to your dns system, it's often a good idea to setup a remote dns server to mirror your zones so that if one were to go offline, you'd have a backup.  With DirecAdmin, you have 3 options, varying in difficulty to setup.



1) Use the built in DNS Clusting Tool.  This requires 2 copies of DA, once on each server.  The 2 DirectAdmin can talk to each other copying zones between themselves.  To set it up, go to Admin Level -> MultiServer Setup (server A) and add the IP of the remote DirectAdmin server (server B) you'd like to transfer the zones to (send only).  If you want the other DirectAdmin server (B) to also send it's own zones back to the first server (A), then you'd do the same on it (Add A's IP onto server B's multiserver setup page).  Note that this same process can be used to setup 3 or more (as many as you wish) server, all talking together.  More info can be found here: help.directadmin.com/item.php?id=97.



2) Create your own transfer script, called by DA after each dns write.  There is a custom script called /usr/local/directadmin/scripts/custom/dns_write_post.sh that you can create (it does not exist, you have to write it) that will be called by DirectAdmin after each write of the dns zones in /var/named/domain.com.db.   You can add any language you want, DA will call it and pass all variables to it through the environment.  Your job would be to write a script to transfer the dns data over to your other dns server using your own means.  Script info:directadmin.com/features.php?id=450.



3) Create your own API for the multi server setup to call.  This option is similar to option 1, except that DirectAdmin would connect to some other serivce, possibly apache or anything you'd like, that you setup.  The idea behind this is that you can mirror the commands that DA is calling.  DA would call your scripts using the same command names and values, and you would in turn make those commands execute the same way that another DirectAdmin box would function normally.   This would be by far the most difficult of the methods, but would possibly be the most flexible and clean should you have a custom dns backup that is possibly database driven.   The commands used by DA are listed heredirectadmin.com/features.php?id=533.  I have yet to see anyone implement this, as would be a fair amount of work.


Was this article helpful?

mood_bad Dislike 2
mood Like 0
visibility Views: 14835