DNS-Only -- Adding a new server to existing cluster. How to get all zonefiles copied over?

electric

Well-Known Member
Nov 5, 2001
789
10
318
Hello,

We have four DNS-Only nameservers, and we need to replace one of them. (IP is being changed.)

All our web servers have a "synchronize" relationship to each DNS-Only nameserver. Each DNS-Only nameserver has a "standalone" relationship to each web server.

Now we are building the new DNS-Only nameserver and have added it already to each of the web servers.

How do we get all the zonefiles that are on the other DNS-Only nameservers to the new DNS-Only nameserver?

In other words, how do we "populate" our new DNS-Only nameserver with all the zonefiles from all our web servers?

Thanks!
 
Last edited:

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,909
2,227
463
Hello :)

If you have linked the new DNS-Only server to the hosting servers, and configured the role to synchronize changes, then the zones should already be synced to the new DNS-Only server. If not, then you can simply sync the zones to that DNS-Only server via:

"WHM Home » DNS Functions » Synchronize DNS Records"

You can use the "Synchronize all zones to all servers" option.

Thank you.
 

electric

Well-Known Member
Nov 5, 2001
789
10
318
Hello :)

If you have linked the new DNS-Only server to the hosting servers, and configured the role to synchronize changes, then the zones should already be synced to the new DNS-Only server.
Yes, we have already created the new DNS-Only nameserver, and it is added to the cluster in all the web servers with the role of "Synchronize Changes". However, when I look in the "/var/named/" folder on the new DNS-Only nameserver, it is empty.

(I think this is as expected, right? It shouldn't have any zonefiles yet, unless a customer has edited their dns since the new nameserver was added to their server. Please correct me if I am not understanding.)

If not, then you can simply sync the zones to that DNS-Only server via:

"WHM Home » DNS Functions » Synchronize DNS Records"

You can use the "Synchronize all zones to all servers" option.
Should we enable the "Synchronize zones that are not configured on this server" option? Otherwise, will it only synchronize the zonefiles that are on that particular web server?

ie: We have a dozen web servers, all connected to four DNS-Only nameservers... one of which has no zonefiles. So now we need to populate the new nameserver with ALL zonefiles from the dozen web servers. Should I run the above synchronize on each web server? Or is it sufficient to run it from only one of them, and it will magically figure out and sync *all* zonefiles, regardless of what web server the domain is on?

Thanks!

-- Also, we have a lot of zone files (about 25k across the dozen web servers). I think maybe I should run this via command line? Do you know what is the proper command line to do the required sync?

Thanks again!
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,909
2,227
463
If you prefer to use the command line, then you can utilize the following command:

Code:
/usr/local/cpanel/scripts/dnscluster syncall --full
You could run this command on each hosting server if necessary.

Thank you.
 

electric

Well-Known Member
Nov 5, 2001
789
10
318
If you prefer to use the command line, then you can utilize the following command:

Code:
/usr/local/cpanel/scripts/dnscluster syncall --full
You could run this command on each hosting server if necessary.
If necessary? I have no idea... that's why I'm here asking you. :)

If I run this command on webserver1, will it synchronize *all* zones from *all* webservers connected to the cluster of four DNS-Only nameservers?

Or do I need to also run the same command on webserver2, and webserver3, and webserver4, and webserver5, etc?
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,909
2,227
463
I would go ahead and run that command on all hosting servers if their zones have not yet synced to the DNS-Only server.

Thank you.