Issues getting DNS Master/Slave to work properly

3 posts / 0 new
Last post
#1 Mon, 12/08/2014 - 02:41
trenzterra

Issues getting DNS Master/Slave to work properly

Hi all,

I am attempting to run my own DNS servers for my domain 'domain.com'. So I've set glue records in my registrar for 'ns1.domain.com' and 'ns2.domain.com'.

So on the server corresponding to ns1.domain.com, I installed Virtualmin. On ns2.domain.com, I installed Webmin and BIND.

Thereafter, I followed the instructions on http://www.virtualmin.com/documentation/dns/slave-configuration and managed to set-up ns2.domain.com as a slave successfully.

I tried creating a master zone from Webmin in ns1.domain.com and I saw that it was transferred successfully to ns2.domain.com.

However, the problem arises when I try to add a Virtual Server for 'domain.com' from within ns1.domain.com:

(1) Even though the output page shows that it copied DNS settings to the slave successfully, when I login to Webmin on ns2.domain.com, although the zone record for 'domain.com' is created, addresses etc. have not been copied over.

(2) In the DNS records created for 'domain.com' as seen on ns1.domain.com, the A record for 'ns2.domain.com' points to the IP of ns1.domain.com instead of ns2.domain.com.

Thus, for some reason, Virtualmin isn't playing nice with my slave configuration for some reason. I have to manually edit the zone file in Webmin on ns1.domain.com AFTER creating the virtual server in Virtualmin in order for all my addresses etc. to be transferred over.

What am I doing wrong here?

Mon, 12/08/2014 - 08:51
trenzterra

Well I managed to get to the root of the problem: Basically the directory /var/lib/bind in both master and slaves need to be set to bind:bind.

I followed the instructions here: https://www.virtualmin.com/node/32727

[quote]I recall similar issues a while ago, which I solved by changing the default ownership for new zones in the Webmin config to "bind:bind" (Webmin -> Servers -> BIND -> Module Config -> Zone file options -> Owner for zone files". Existing zone files you need to "chown" manually.[/quote]

Still, when I create the virtual server at domain.com, both ns1.domain.com and ns2.domain.com still default to ns1.domain.com's IP. That is a small issue though since you only set up domain.com once.

Tue, 12/09/2014 - 04:50
tpnsolutions
tpnsolutions's picture

Hi,

Drop me a line on Skype and I'll get you squared away.

Best Regards,
Peter Knowles
TPN Solutions

Email: pknowles@tpnsolutions.com
Phone: 604-229-0715 (new)
Skype: tpnsupport
Website: http://www.tpnsolutions.com
Best Regards,
Peter Knowles | TPN Solutions
Email: pknowles@tpnsolutions.com | Skype: tpnassist
Topic locked