Adding/Removing Servers from DNS Cluster - DNS Cleanup?

sneader

Well-Known Member
Aug 21, 2003
1,195
68
178
La Crosse, WI
cPanel Access Level
Root Administrator
I have a new cPanel server (Server A) and I would like to have an existing cPanel server (Server B) be a DNS Cluster partner with it. However, sometime next year another new cPanel server will come online (Server C), then I will want to remove Server B from the cluster and add Server C:

NOW: Server A <--> Server B
FUTURE: Server A <--> Server C

The question is: When I remove Server B from the Cluster, what do I need to do, to get the old Server A zone files off of Server B... and the Server B zone files off of Server A? Is that what the DNS Cleanup feature in WHM does? It says it removes "duplicated entries" but that isn't really what I need.

If this doesn't make sense, let me know! Otherwise, thanks in advance for a push in the right direction!

- Scott
 
Last edited:

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,261
463
Hello :)

The "Perform a DNS Cleanup" option will only remove duplicate DNS entries. You will have to manually delete the DNS Zones on a server after removing it from the cluster. The following feature request may be of interest to you:

Ownership and access control of zones in the dns server

Thank you.
 

sneader

Well-Known Member
Aug 21, 2003
1,195
68
178
La Crosse, WI
cPanel Access Level
Root Administrator
Hi Michael. Hmmm... OK... do you have any tips on the process to "manually delete the DNS Zones on a server after removing it from the cluster" ?

- Scott
 

fi77i

Well-Known Member
Aug 20, 2008
57
0
56
Uruguay
cPanel Access Level
Root Administrator
You can login to your WHM and remove the zones from the delete DNS zone section.

Main >> DNS Functions >> Delete DNS zone

Multiple zone selection is enable in whm and you can remove them all form there.

You can also remove them by hand via console by deleting the zone file in /var/named/<domain>.db but you need to remove the entries in /etc/named.conf for each zone also.

WHM way should be the easiest.
 
Last edited:

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,261
463
Hello :)

You could look at the files on the server that list your domain names. EX:

/etc/localdomains
/etc/remotedomains

Use these files to populate a list of domain names. Then, develop a custom bash script to exclude those domain names from deletion or copy the zones to another location. This will allow you to delete the DNS zones all domain names not added to the server.

Thank you.