Web Hosting Talk







View Full Version : True DNS clustering + cPanel??


OffbeatAdam
10-12-2009, 11:25 AM
Greetings Everyone,

The problem: cPanel "DNS Clustering" is a misnomer. Distributed load does not mean distribute the exact same data on every server. A true clustered solution has distributed load for different portions of its service allowing for an exceptional increase in capacity. In cPanel's case, the maximum is still the same maximum, it is merely redundant. Therefore, one could easily say that DNS Clustering is not clustering at all, but merely replication for HA.

My desired solution: While I know that cPanel will likely never support the likes of a custom DNS solution (even BIND has better custom solutions, note: "reload" is the wrong way to add a new zone), I do have the ability to develop certain solutions to "bridge the gap" so to speak. I've been googling my butt off trying to see if this has already been done.

I assume that when a DNS update is pushed via cpanel in a dns clustered environment, it sends some sort of information via its API, be it soap, json or whatever. This information then is intercepted by the dns cluster, applied to its zone files (or created on this server if new), and then a reload is initiated.

If this information IS in fact transmitted in this fashion, accessing it would make using -any- dns solution that CAN be truly clustered (and expandable into the millions of domains) relatively simple.

Obviously there are different bits of information that are needed:

Every server will need to know what zones exist, so that the cpanel client experience does not change.
Every server will need to believe this clustered DNS solution is in fact a cpanel DNS system.

And so on.

Thats where the difficulty is.

I don't want to build a complicated solution, I want to build an XML-ish listener in whatever language (probably PHP due to time and C as soon as I could complete it) that will update my database-driven DNS solution, ie PowerDNS, and make it available to the community - ultimately because I'm sick of running a whole bunch of dns servers and them crashing once the reseller count reaches a certain height.

Any assistance would be appreciated!

Thanks,

Adam

Steven
10-12-2009, 12:32 PM
Greetings Everyone,

The problem: cPanel "DNS Clustering" is a misnomer. Distributed load does not mean distribute the exact same data on every server. A true clustered solution has distributed load for different portions of its service allowing for an exceptional increase in capacity. In cPanel's case, the maximum is still the same maximum, it is merely redundant. Therefore, one could easily say that DNS Clustering is not clustering at all, but merely replication for HA.

My desired solution: While I know that cPanel will likely never support the likes of a custom DNS solution (even BIND has better custom solutions, note: "reload" is the wrong way to add a new zone), I do have the ability to develop certain solutions to "bridge the gap" so to speak. I've been googling my butt off trying to see if this has already been done.

I assume that when a DNS update is pushed via cpanel in a dns clustered environment, it sends some sort of information via its API, be it soap, json or whatever. This information then is intercepted by the dns cluster, applied to its zone files (or created on this server if new), and then a reload is initiated.

If this information IS in fact transmitted in this fashion, accessing it would make using -any- dns solution that CAN be truly clustered (and expandable into the millions of domains) relatively simple.

Obviously there are different bits of information that are needed:

Every server will need to know what zones exist, so that the cpanel client experience does not change.
Every server will need to believe this clustered DNS solution is in fact a cpanel DNS system.

And so on.

Thats where the difficulty is.

I don't want to build a complicated solution, I want to build an XML-ish listener in whatever language (probably PHP due to time and C as soon as I could complete it) that will update my database-driven DNS solution, ie PowerDNS, and make it available to the community - ultimately because I'm sick of running a whole bunch of dns servers and them crashing once the reseller count reaches a certain height.

Any assistance would be appreciated!

Thanks,

Adam

How many domains are you having it crashing on? Theres serveral hosts where whom utilize 10k+ domains on cpanels dns cluster.

At any rate. You can develop and application and have cpanel call it to handle dns.

Inside tweak settings:

Application for processing dns requests. The default is to use cPanel Dns cluster system located at /usr/local/cpanel/whostmgr/bin/dnsadmin. (Recommended: leave blank to use the default).

OffbeatAdam
10-12-2009, 12:50 PM
How many domains are you having it crashing on? Theres serveral hosts where whom utilize 10k+ domains on cpanels dns cluster.

At any rate. You can develop and application and have cpanel call it to handle dns.

Inside tweak settings:

The numerical situation is somewhat of a catch-22. The hardware that the DNS runs on isn't relatively up to date hardware, as part of budgeting. In addition, while the total # of root domains is small, in that 10k+ area - the type of hosting we provide (rather, the customers that we provide) brings the total zone file count up to the 60-100k range.

The side affect to this is, that in addition to this being a problem on 32bit 2650 with 6GB of RAM, this same issue will easily branch the same relatively distinct issue even on a new 2970 with much more capable procs and 12GB+ of ram (or more, if I wanted or could afford to build such a box).

In a centralized solution, you should be able to support an incredibly large number of domains with relative ease, on a box that is not necessarily fast. The solution provided is not built for such a situation. DNS itself is low-overhead, and most stand-alone dns servers can easily do multiple times more than what an average cpanel-dns server can do. My goal, is to reduce the # of DNS servers we have to have, for both customer support and our own support tasks. To easily put it, building a virtual DNS cluster that can theoretically grow as large as my DB server can handle, is my goal. I've done this before without cpanel being involved, now I do not want to remove the ease of use to the client that cpanel provides.

Make sense?

I'll be honest, I've looked at that script (which is in Perl), in the thoughts of taking it apart and possibly altering it or rewriting it to my own desires.

Unfortunately this is like decrypting ancient languages. I'm not sure in a reasonable amount of time I could do that, with the codebase that just doesn't seem it was managed very well (and lacks a significant amount of comments, and screams inefficient... oy.)

In any case, there doesn't appear to be any documentation of what is SENT to this tool when you make changes inside of cpanel. That's what I'd like to see.

Its been a while since I've looked at that scripts, I'll see if I can pull it apart any easier since I know cpanel updates frequently.

Thanks for the help,

Adam

plumsauce
10-12-2009, 04:46 PM
search the term:

dns "hidden master"

use the cpanel dns as the hidden master

everything else is a slave/secondary depending on preferred terminology

OffbeatAdam
10-12-2009, 06:03 PM
search the term:

dns "hidden master"

use the cpanel dns as the hidden master

everything else is a slave/secondary depending on preferred terminology


I'm not sure how this really assists the capacity problem. The only difference from a hidden master and a master is that one is not registered. Ultimately it will still be inefficiently handled by cPanel, and while I may be able to make the slaves far more efficient, customers will still be unable to update DNS should the hidden master go down - which it will. Thanks though, I had forgotten about that and I'll probably employ it in my final result here. We have been seeing a few DNS attack attempts that would have been fixed by this.

plumsauce
10-12-2009, 07:13 PM
So, then use your cpanel *cluster* as the hidden master(s).

And let the slaves axfr from them.

I admit that my knowledge and experience with hosting control panels is exactly zero :D

OffbeatAdam
10-13-2009, 11:47 AM
So, then use your cpanel *cluster* as the hidden master(s).

And let the slaves axfr from them.

I admit that my knowledge and experience with hosting control panels is exactly zero :D

In a nutshell, I'm primarily trying to remove the point of failure that is cpanel DNS :)