Vesta- How to set up master-slave DNS cluster

If you are looking for the options to avoid any DNS-related downtime or the way to manage dns across all server you have, you might consider to set up dns cluster.

Create user dns-cluster on a server which will be used as dns slave

On the second server (slave) with vestacp you should create new user with name dns-cluster (via gui or cli)Code: 

v-add-user dns-cluster passowrd yourmail@example.tld

On the first server (master) you should run this command:

v-add-remote-dns-host slave.yourhost.com 8083 admin p4sw0rd

slave.yourhost.com – main ip of slave server
p4sw0rd – password for admin

Run following command on a master:

v-add-remote-dns-host slave.yourhost.com 8083 admin p4sw0rd

Password and host name should be replaced with relevant data of course.

This way you can set up master->slave or master-master-master cluster. There is no limitation on how to chain dns servers.

Now Enable Zone Transfer

enable AXFR (Zone Transfer) in Bind

Replace following string in the named configuration file:allow-transfer {“none”;};

withallow-transfer { XXX.YYY.ZZZ.111; XXX.YYY.ZZZ.222; };
also-notify { XXX.YYY.ZZZ.111; XXX.YYY.ZZZ.222; };

The location of this file on RHEL and CentOS: /etc/named.conf
The location of this file on Debian and Ubuntu: /etc/bind/named.conf

Share

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.