cPanel DNS Cluster setup (/w 2x cPanel DNS Only VPS)

wintech2003

Well-Known Member
PartnerNOC
Sep 15, 2010
103
28
78
Greece
cPanel Access Level
DataCenter Provider
Hello,

I have setup two VPSs with cPanel DNS Only in two different geographical locations, and created a DNS cluster with my one cPanel webserver.

Code:
       +---------+
       |webserver|
       +---------+
            |
     +------+------+
     |             |      
+---------+   +---------+
|  dns1   |   |  dns2   |
+---------+   +---------+
Things seem to work but I still want to confirm with someone who already has something like this setup, that my settings are correct and not the opposite of what they should be :)

So here is the configuration of each server under "Configure Cluster":

Webserver:
http://f.cl.ly/items/0Q3f2F3i0t1Q1E1a2N3u/webserver.jpg

dns1:
http://f.cl.ly/items/3G0u3F2T2k1q3k1h1a32/dns1.jpg

dns2:
http://f.cl.ly/items/1x08340q2E1S3b070y0s/dns2.jpg

So to sum up:

On webserver I have added:
"dns1" setup as synchronize changes
"dns2" setup as synchronize changes

on dns1 I have added
"webserver" setup as standalone

on dns2 I have added
"webserver" setup as standalone

I this cluster setup correct?

Thanks in advance,
George
 

cPanelTristan

Quality Assurance Analyst
Staff member
Oct 2, 2010
7,607
40
248
somewhere over the rainbow
cPanel Access Level
Root Administrator
Hello George,

Thank you for the extremely clear details on how you've set up your clustering on these 3 machines. You have properly set them up to where the webserver will push out zones to dns1 and dns2 machines. Everything is properly set from what you've shown on how we recommend doing a DNS cluster setup.

If you have any other questions, please let us know.

Thanks!
 

cPanelTristan

Quality Assurance Analyst
Staff member
Oct 2, 2010
7,607
40
248
somewhere over the rainbow
cPanel Access Level
Root Administrator
Correct, you do not need bind to run locally when you already have these machines set to cluster.
 

designmania

Member
Nov 10, 2011
12
0
51
cPanel Access Level
Root Administrator
I follow the exact steps from this thread to setup my clustering environment for 2 web servers and 2 dns servers. However, I got "Looks like your nameservers do not agree on the SOA serial." or "Your nameservers disagree in the SOA serial number field" kind of error message.

When I change the roles to "Synchronize changes" on all servers (nameservers and webservers), I don't get this kind of message. So, is there any more settings that I need to change? Thanks!
 

Bigstack14

Member
Nov 23, 2010
12
0
51
Thanks for this info.. However I was wondering if I would be able to use the main WHM/Cpanel be ns1. and then have a VPS be ns2..

kinda like

Code:
          +-------------------+
       |         webserver          |
       | dns1 (ns1.domain.com) |
       +-------------------------+
                    |
      +-----------+-----------+
      |  dns2  (ns2.domain.com)  |
         +--------------------+
Can anyone show or guide me on how do do this?
 

cPanelTristan

Quality Assurance Analyst
Staff member
Oct 2, 2010
7,607
40
248
somewhere over the rainbow
cPanel Access Level
Root Administrator
If you are going to use your webserver as both the webserver and your ns1 nameserver machine, then you'd have to set it up like the following:

On webserver, dns1 machine for WHM > Configure Cluster area:
"dns2 machine" setup as synchronize changes

On dns2 machine for WHM > Configure Cluster area:
"webserver dns1 machine" setup as standalone
 

indoc0der

Member
Sep 4, 2011
18
1
53
cPanel Access Level
Root Administrator
thanks all, great tutorial. one question, how to implementation if i have 2 cPanel/WHM webserver and 2 cPanel dnsonly? is that configuration support with server have many IP? in my personal case now :

Code:
server1 (cPanel/WHM) - master.domain.tld (have 5 active domain)
ns1.domain.tld (1.1.1.1)
ns2.domain.tld (1.1.1.2)
ns3.domain.tld (1.1.1.3)
Code:
server3 (cPanel/WHM) - slave.domain.tld
ns4.domain.tld (2.2.2.2)
ns5.domain.tld (2.2.2.2)
ns6.domain.tld (2.2.2.3)
Code:
server3 (dnsonly) - third.domain.tld
ns7.domain.tld (3.3.3.1)
Code:
server4 (dnsonly) - fourth.domain.tld
ns8.domain.tld (4.4.4.1)
is configuration on #1 can work? thanks for your help and reply.
 

cPanelTristan

Quality Assurance Analyst
Staff member
Oct 2, 2010
7,607
40
248
somewhere over the rainbow
cPanel Access Level
Root Administrator
I am not understanding what you've provided for the code listing. If you have 2 web servers and 2 dns only machines, it would be:

webserver1 and webserver2 -> Configure Cluster -> dnsonly1 and dnsonly2 synchronize changes
dnsonly1 and dnsonly2 -> Configure Cluster -> webserver1 and webserver2 standalone

Basically, you only have the dns only machines listed in Configure Cluster on the web server machines with synchronization to those dns only, and you only have the web servers listed in Configure Cluster on the dns only machine with standalone set for the web servers.
 

galonet

Member
Aug 17, 2010
17
0
51
Has anyone tested ext3 vs ext4 file system performance on DNSOnly Servers?

And by that token, anyone tested partition configurations?

Thanks.
 

wintech2003

Well-Known Member
PartnerNOC
Sep 15, 2010
103
28
78
Greece
cPanel Access Level
DataCenter Provider
What if I want each of my webserver to only hold the Zone information of the domains they host?
I added a second webserver today to my initial setup (OP), and did exactly this:

webserver1 and webserver2 -> Configure Cluster -> dnsonly1 and dnsonly2 synchronize changes
dnsonly1 and dnsonly2 -> Configure Cluster -> webserver1 and webserver2 standalone

Now, although webserver2 only hosts one domain, when I go to "Edit DNS Zone", I see all the zones from webserver1 too.
What I want is 1-way synchronization, from webserver to dnsonly, and not back. So that each webserver only holds the zones of the domains he hosts.

Is this possible?

I am not understanding what you've provided for the code listing. If you have 2 web servers and 2 dns only machines, it would be:

webserver1 and webserver2 -> Configure Cluster -> dnsonly1 and dnsonly2 synchronize changes
dnsonly1 and dnsonly2 -> Configure Cluster -> webserver1 and webserver2 standalone

Basically, you only have the dns only machines listed in Configure Cluster on the web server machines with synchronization to those dns only, and you only have the web servers listed in Configure Cluster on the dns only machine with standalone set for the web servers.
 

cPanelTristan

Quality Assurance Analyst
Staff member
Oct 2, 2010
7,607
40
248
somewhere over the rainbow
cPanel Access Level
Root Administrator
Because you are clustered to the nameservers, you will see all the zones on the nameservers. It isn't syncing back in that instance, it's that you see the zones where you are syncing to for DNS. There is currently no way for "ownership" of a server to exist in the clustering setup we provide. By ownership, I'm speaking of one server owning zones and no other servers clustered to the nameservers holding those zones being able to see the zones. At this time, the functionality you desire doesn't exist. You'd have to uncluster the machine and just run the DNS on it if you want it to be unable to see other zones in the cluster.
 

soptecpe

Registered
Apr 18, 2012
3
0
51
cPanel Access Level
Root Administrator
hi i am trying do a clustering with 2 server and have a cuestion each server must have their ns names configured

example:
server1: atom.domain.com
ns1.stpdns.com 1.1.1.2
ns2.stpdns.com 1.1.1.3

server2: atom2.domain.com
ns3.stpdns.com 1.2.1.1
ns4.stpdns.com 1.2.1.2

and last doubt can i host a domain in server2 but with the ns1 and ns2 from server1 or i must set ns3 and ns4 from server2?

thank you
 
Last edited:

cPanelTristan

Quality Assurance Analyst
Staff member
Oct 2, 2010
7,607
40
248
somewhere over the rainbow
cPanel Access Level
Root Administrator
Are you going to be running DNS only machines for these nameservers or the nameservers will be on server1 and server2?

As for putting a domain in server2 but using the ns1 and ns2 from server1, you could do that sure, but you'd have to put the zone onto each server.
 

n47412

Registered
Apr 7, 2011
2
0
51
Is it possible to run the 2 dns in the web server and the 2 dns in the cPanel DNS? Or maybe you could give some alternative?
 

InterServed

Well-Known Member
Jul 10, 2007
268
14
68
cPanel Access Level
DataCenter Provider
Hello,

We have the following dns-cluster setup:
dns-map.png

Issue we have:

- On webserver1 we have customers that use branded nameservers on their domains :
ns1.customerdomain.tld -> A record to our dns1 IP
ns2.customerdomain.tld -> A record to our dns2 IP

On webserver1 /etc/nameserverips we have the following:
dns1-IP=ns1.dns1-hostname.tld
dns2-IP=ns2.dns2-hostname.tld

dns1-IP=ns1.customerdomain.tld
dns2-IP=ns2.customerdomain.tld

As soon as we disabled bind locally on the webserver1 the customer domains that use branded nameservers are no longer working because no dns resolution.
If we enable the bind locally on the webserver everything works.

Do we do something wrong ?
 

Radich

Registered
Dec 28, 2012
1
0
1
cPanel Access Level
Root Administrator
Hello,

i have some question. if i have 2 physical server on both have web+dns:
web1+dns1 <--->web2+dns2
i must set "Synchronize changes" on both side or something else?
 

equens

Well-Known Member
Feb 8, 2002
282
5
318
Hello,

We have the following dns-cluster setup:
View attachment 13391

Issue we have:

- On webserver1 we have customers that use branded nameservers on their domains :
ns1.customerdomain.tld -> A record to our dns1 IP
ns2.customerdomain.tld -> A record to our dns2 IP

On webserver1 /etc/nameserverips we have the following:
dns1-IP=ns1.dns1-hostname.tld
dns2-IP=ns2.dns2-hostname.tld

dns1-IP=ns1.customerdomain.tld
dns2-IP=ns2.customerdomain.tld

As soon as we disabled bind locally on the webserver1 the customer domains that use branded nameservers are no longer working because no dns resolution.
If we enable the bind locally on the webserver everything works.

Do we do something wrong ?
I think that you must to add these brands name servers manually from webserver1, and then these zones will appear in your dns1 and dns2

Hello,

i have some question. if i have 2 physical server on both have web+dns:
web1+dns1 <--->web2+dns2
i must set "Synchronize changes" on both side or something else?
I prefer this configuration to prevent the copy of all zones in all your servers:

ANameserver 1Nameserver 2
cPanel DNSONLY 1 (Standalone)ns1.webserver.com?
cPanel DNSONLY 2 (Standalone)ns2.webserver.com?
cPanel 1 (Write Only)ns1.webserver.comns2.webserver.com
cPanel 2 (Write Only)ns1.webserver.comns2.webserver.com
cPanel 3 (Write Only)ns1.webserver.comns2.webserver.com

But I dude how to configure the dns Setup in every server, option A or B:

BNameserver 1Nameserver 2
cPanel DNSONLY 1 (Standalone)ns1.webserver.com?
cPanel DNSONLY 2 (Standalone)ns2.webserver.com?
cPanel 1 (Write Only)ns3.webserver.comns4.webserver.com
cPanel 2 (Write Only)ns5.webserver.comns6.webserver.com
cPanel 3 (Write Only)ns7.webserver.comns8.webserver.com

I added ? because the default setup on cPanel DNS requires two name servers, but we can delete the second name server after finish the setup, can anyone confirm if this is the correct way?
 

milindras

Member
Dec 29, 2010
22
0
51
UK
If you are going to use your webserver as both the webserver and your ns1 nameserver machine, then you'd have to set it up like the following:

On webserver, dns1 machine for WHM > Configure Cluster area:
"dns2 machine" setup as synchronize changes

On dns2 machine for WHM > Configure Cluster area:
"webserver dns1 machine" setup as standalone
Many Thanks. How do I check zones are sync to dns2 machines? Where should I check in centos?

THanks