Secondary DNS feature

I just don't want to re-invent the wheel when there are perfectly good (proven) programs that can be used with some really simple scripts :)

I'll be interested to hear how your script works out :)

John
 
What I have not figured out from all these posts is I personally don't care about entering the new zones manually. Its great if it did it automatically but I want to make sure that you don't need to enter a primary zone to make this work.

The other question to Jeff would be how does it reload the zone file if the master is down. Does it assume that the server is down and does not destroy the existing zone file?

My only thought from this entire thread is that we are worried about how to make this interact with other control panels and other DA servers. Screw it, currently we don't do anything else between two servers so why start now? When a version of DA comes out that can admin multiple DA servers then we can worry about this but lets keep it simple.

All we need to do is have a place to enter the domain, and the ip of the master servers. That would make it easy for everyone.
 
Well, at least we're finally seeing some interest.

My only responses to thoroughfare would be that I'd appreciate it if he'd show me the security holes rather than just allude to them, and also that I don't leave any ports open at all, contrary to his suggestion that I did.

To everyone else, I point out that there's nothing wrong with scripts, and there's nothing wrong with programs written in C.

The reason we (here) write scripts is severalfold:

(1) They're easier to write than C, and there's a larger base of people who know how to write them.

(2) It's easier for people to accept them, as most people can read through and understand a script a bit more easily than a C program, and many admins don't want to run 3rd party C programs unless they understand them well, so it's easier to get scripts accepted in the general community.

(3) Modern scripting languages work well, and work quickly, with little system load.

You'd be surprised how much of your linux/unix systems are implemented as various scripts in various scripting languages. For example, Majordomo is written entirely in perl scripts. Mailman is written entirely in Python scripts.

I apprceciate all the work John and Mark do for us, but I know they have a limited number of hours available every day, just as we do. I'm willing to take some of that load off them by creating Open Source solutions they, you and I can all use.

It may sometimes sound as if I'm arrogant; I often am, but I don't mean to be, and I don't mind being taken to task for it.

But please, when doing so, give me concrete examples of what you think is wrong with my ideas as well as my presentation, so we can all learn from them.
existenz said:
What I have not figured out from all these posts is I personally don't care about entering the new zones manually. Its great if it did it automatically but I want to make sure that you don't need to enter a primary zone to make this work.
Of course you (or DA) must create a primary zone on the master server.

Thousands of BIND admins currently use scripts to replicate the information to the slave server so they don't have to create new zones on the slave server; all my small project is, is an attempt to create a small Open Source solution anyone can use.
The other question to Jeff would be how does it reload the zone file if the master is down. Does it assume that the server is down and does not destroy the existing zone file?
My sripts don't touch existing zone files at all; BIND updates them automatically according to the times in the SOA record in the master zone, and that's set up automatically by DA using values which are generally reasonable.

My scripts will create a new include file for /etc/named.conf, and that new include file will contain a list of all the domains mastered on all the servers it's set up (once) to slave.

If during any one of the update cycles it can't get a copy of the list from a server that's down, it uses the last list it has. It will do that forever, until you, as admin, remove the server from the list of servers it's set up to slave.
My only thought from this entire thread is that we are worried about how to make this interact with other control panels and other DA servers. Screw it, currently we don't do anything else between two servers so why start now? When a version of DA comes out that can admin multiple DA servers then we can worry about this but lets keep it simple.
I still think my solution is simple. The fact that it works with all nameservers, not just DA servers, is just icing on the cake, considering many of us have multiple servers and not all of them are DA servers.
All we need to do is have a place to enter the domain, and the ip of the master servers. That would make it easy for everyone.
Note quite, for several reasons:

1) If your resellers or clients set up new domains or if you have automatic domain setup (Whois.Cart, ModernBill) then you may not know when a domain is set up.

2) If you do know, then do you really want to have to go to your slave server and set up domains manually?

If both of these conditions work for you, then yes, and if your slave server runs DA, then yes, a simple addition to the DA DNS screens would suffice for you.

And frankly, I do hope they set up such an addition.

And may I offer another suggestion if these conditions work: You can probably buy a Cobalt RaQ3 or a RaQ4 for in the neighborhood of us$250 - us$300, rebuild it with a RaQ4 restore CDROM, and do exactly what you want.

But for those of us who don't want to have to manually enter anything, my solutions appears to me to be quite simple, and elegant.

if you disagree, please give me some constructive criticism.

Thanks.

Jeff
 
jlasman said:
My only responses to thoroughfare would be that I'd appreciate it if he'd show me the security holes rather than just allude to them, and also that I don't leave any ports open at all, contrary to his suggestion that I did.

Isn't running an FTP server on your secondary DNS box an open port?

I was thinking about your script last night. Perhaps you could use scp rather than FTP? I still don't think it'd be the best solution for DA's implementation of secondary DNS but it will definetly be of use to many bind users I'm sure.

John, I was also thinking about my PHP script - it could be even simpler. It could be run as a cronjob on the secondary DNS box and simply access the DA API and retrieve the list of domains and add/remove them to the named.conf accordingly. That way, there'd be no daemon or open socket, and it removes the need to use some kind of authentication system, since we could use DA's HTTPS.

Matt :)
 
jlasman said:
To everyone else, I point out that there's nothing wrong with scripts, and there's nothing wrong with programs written in C.

PS Jeff, I wasn't saying there's anything wrong with scripts. I'm a PHP developer - PHP is a scripting language. My contention was that DA should implement a daemon to make it secure and 'less messy' if you like. The scripts idea is growing on me however, and I agree a daemon is probably over the top.

I felt you were being arrogant because it seemed as though you were trying to get the developers to use your scripts in an almost demanding way. Consider my point of view, having never heard of your scripts before, and then reading 'I strongly suggest [that DA waits for my scripts]'. Can you see that? I understand now how you meant it, and that you probably didn't intend it to sound like that.

My points before about your script system were:
a) I felt that it should be developed by DA themselves
b) I think using FTP to transfer the files is a bad idea because it requires:
i) an FTP daemon to be added to the secondary DNS box
ii) FTP accounts and cronjobs to be setup
iii) FTP is an insecure protocol

For me personally, I think I'm going to develop a PHP script that uses the DA API and updates named.conf accordingly (see my above post).

Sorry for any misunderstandings.

Matt :)
 
Just remember that no decisions have been made yet. :)
We'll try to have plenty of discussions to determine the best method for the majority.

John
 
Originally posted by thoroughfare Isn't running an FTP server on your secondary DNS box an open port?
Read my scenario again carefully and you'll see that the Slave DNS server doesn't use an FTP daemon; it does the FTPing to the DA box and then runs the "get" command. Maybe I didn't make that clear enough :( . My guess is that most webhosting systems already use an FTP daemon, and the purpose of my proposed system is to allow users of hosting control panels to to do slave DNS "automagically". I believe most hosting panels also run FTP daemons.

The insecurity is that if someone is sniffing your data they can find out your password.

That's true, but all they can get if they log into your master DNS server and "get" the contents, is your list of zones. Nothing else. And if the system properly sets up permissions (and it will) they won't be able to poison the system by adding or changing anything.
I was thinking about your script last night. Perhaps you could use scp rather than FTP?
I could, but I'm not guaranteed that everyone who uses a control panel has scp installed. Nevertheless it's a good idea; thanks. I think I'll offer it as an option.
I still don't think it'd be the best solution for DA's implementation of secondary DNS but it will definetly be of use to many bind users I'm sure.
It'll work for me :) . And probably for anyone else running multiple control panels.
John, I was also thinking about my PHP script - it could be even simpler. It could be run as a cronjob on the secondary DNS box and simply access the DA API and retrieve the list of domains and add/remove them to the named.conf accordingly. That way, there'd be no daemon or open socket, and it removes the need to use some kind of authentication system, since we could use DA's HTTPS.
From where would the DA API (on the slave DNS box) get the list of domains on the master box? That's the part of your plan I don't get yet. Is there a way to get it without (a) running a daemon on one of the boxes or (b) adding a program to the inetd or xinetd list?

Thanks.

Jeff
 
thoroughfare said:
PS Jeff, I wasn't saying there's anything wrong with scripts. I'm a PHP developer - PHP is a scripting language. My contention was that DA should implement a daemon to make it secure and 'less messy' if you like. The scripts idea is growing on me however, and I agree a daemon is probably over the top.
Sorry; I should have read your second post before replying; now I understand you were considering a separate daemon.

I think that's a great idea, when DA (the company) has the chance to to implement a multi-server solution.

But I certainly don't want to see them creating so many interim solutions that the final end product gets delayed, and that's what I'm afraid of.

I used to market a really great Windows-based email server.

It was a first version, written in Delphi.

The eventual plan was to completely rewrite it in C++.

Never happened, because the company got so involved in adding features to the first version.

I don't want to see that happen to DA; I want to see them be able to move along.
I felt you were being arrogant because it seemed as though you were trying to get the developers to use your scripts in an almost demanding way.
You're right; reading it over now, I see what you mean.
Consider my point of view, having never heard of your scripts before, and then reading 'I strongly suggest [that DA waits for my scripts]'. Can you see that? I understand now how you meant it, and that you probably didn't intend it to sound like that.
No, I certainly didn't.

Okay, let me introduce myself:

I'm Jeff and here's where I come from:

I founded my first (and one of the first, no one around now seems to be sure of the exact numbers) webhosting company back in late 1994, when you could only get one IP# per machine and only one domain per IP#.

(Sold it in '95, but that's another story.)

Before that I've been on the 'net since long before it was the 'net, been using and creating software since Unix ran on TRS-80s, and was President of an international guild of database programmers for three terms running.

Developed business programs for the TRS-80 Model I and was for a time VP of Software Development for the LOBO, the TRS-80 workalike. We developed the version of CP/M Plus that Gary Kildall (the owner of Digital Research, inventors of CPM (see here), called the best implementation ever done.

Long after that Cobalt Systems (before Sun bought them) considered us the largest of the independent support companies supporting the RaQ and Qube line; they even gave us hardware so we could continue to supporl their new models. (Okay, I'll stop now :) ).
My points before about your script system were:
a) I felt that it should be developed by DA themselves
DA is not a large company with endless resources. I'm happy to be able to help them as I am able, and I'm happy to put my work into the Open Source community so they and others may benefit from it.
b) I think using FTP to transfer the files is a bad idea because it requires:
i) an FTP daemon to be added to the secondary DNS box
As I mentioned above, it doesn't.
ii) FTP accounts and cronjobs to be setup
iii) FTP is an insecure protocol
I agree with both of the above but don't see the issue as strongly as you do. Nevertheless I like the idea of using scp as an option.
For me personally, I think I'm going to develop a PHP script that uses the DA API and updates named.conf accordingly (see my above post).
Works for me :) . If you put it into Open Source I'll probably want to try it.
Sorry for any misunderstandings.
I'm happy for the opportunity to clear the air.

Jeff
 
Thanks Jeff, I'm glad we worked that out :)

I'm 18 in 6 days, been working with PCs since a young age (I was coding in QBasic at the age of 8). I run a webhosting business but also work as a freelance graphic designer and applications developer.

I'm quite new to *nix (although I run RH9 on my desktop now, and OpenBSD on a dev server for my designs), so my knowledge often has holes, which I'll be the first to admit :D

Thanks Jeff,
Matt :)
 
Last edited:
My oldest kid is 38, so that makes me old enough to be your grandfather :) .

I'm 60 years young; my youngest kids are my godkids, ranging in age from 4 to 27. I'm trying to encourage Jesse (he's just turned 14) to get interested in the business so I can retire :) .

As you might imagine, I've been doing this stuff since long before you were born :) .

I don't know if you followed the Gary Kildall link or not; I know most of the people mentioned, and even the author of the piece (and even, a long time ago in a universe very far away, knew Bill Gates, but we were both much younger then).

And I also know how Gary died; I wasn't there but a mutual friend confirmed it for me; it was the barroom brawl.

And I got a call this evening from an old friend who worked on the original OS for the DEC PDP-10 (he was written up in Who's Who for his work on it); he tells me there never was a VMS for the PDP-10. I didn't think so.

For those nostalgia buffs; the original Compuserve Information Systems forums (CIS / now Compuserve Interactive Services, a division of AOL/compuserve.com), the first forum services anywhere, were built on DEC PDP-10s.

(The guy who wrote the CIS forum software for them also wrote the same for the TRS-80 Model I, I modified it to avoid the TRS-80 string compression timeout problem, and used it to run "The fastest board in the West" in 1978-1980.)

Jeff
 
Of course you (or DA) must create a primary zone on the master server.

Thousands of BIND admins currently use scripts to replicate the information to the slave server so they don't have to create new zones on the slave server; all my small project is, is an attempt to create a small Open Source solution anyone can use.

How does your script know what server has a slave zone? In our example we 3 dedicated DNS boxes but each machine that does virtual hosting also has the secondary for the domains that server hosts. So how do I tell it what server to update or update from?
 
Your question confuses me a bit; sorry.

A slave server can update itself from either a master server or a slave server, since both are equally authoritative.

When setting up the slave server using my (still proposed only) script, you'll have a config file in which you'll put the name and ftp/scp login details of each master server you want to get master zones from.

What else am I missing in your question?

Thanks.

Jeff
 
suggestion for inter-server communication

Hello,

Just to throw a suggestion in, Webmin has the ability to create a bind slave zone on a second server - I do believe the second server must be running Webmin as well.

I only mention this as a suggestion to look at how another product does it. Not trying to get into the middle of a debate (I am not a php or C coder so I certainly wouldn't be writing such a tool).

Personally, I would like to see this ability without requiring that I be running DA on the second server. For me this is due to me most likely wanting to run a lower powered box to be a secondary DNS and backup mail server vs. a full fledged hosting box.
 
progress?

Any progress on this, because i'm running my server without slave :( and can't go into production, to riscy. I'm hoping that there will be an beta release to test with soon. :) :) :) :) ;)
 
What are your circumstances, Redeye?

Do you own two servers? Or do you need someone else to run slave DNS for you?

If you own two servers, are both running DA?

Jeff
 
I own a few servers (all linux), where one off them is a new webserver with da. I want to configure an other own server to be backup, but, that's my problem, i'm new to this, so a scripted solution would be great. I read you story, and thought, jippie :)

I'm about to step into commercial webhosting from virtual to a own dedicated webserver, so backup ns, would be smart i think ;).
 
We don't have anything ready yet :( .

But surely you can manage slave DNS manually in the meantime.

Or get someone to offer you slave DNS at no charge.

Or buy a commercial solution :) .

Jeff
 
jlasman said:
But surely you can manage slave DNS manually in the meantime.
Jeff

That's my problem I can't find any specific howto's on Bind slave dns with good examples, only general dns stuff.

Could some please post a working example? Please.
 
Books are wonderful teachers :) .

I highly recommend either the latest edition of "DNS and BIND", published by O'Reilly or "Linux DNS Server Administration" published by Sybex.

That said, look for the new How-To I've just written in "How-Tos".

I really don't have much time right now; I have a data center trip and a business trip to Los Angeles scheduled today), so if there's something in my "How-To" that doesn't look right to you, please bring it to my attention by a reply to the How-To, in the How-To thread; I might have made a typo.

Jeff
 
Back
Top