Dynamically add zones

Alan Clegg aclegg at isc.org
Fri Jul 30 00:45:53 UTC 2010


On 7/29/2010 5:38 PM, Jack Tavares wrote:

> Will this functionality be available through an api?
> Or will it just be through rndc ?

Not sure what API we would use beyond rndc.  If you have
recommendations, please e-mail me directly or give me a phone call
(+1-919-355-885) and let's talk about it...

> What error checking and reporting will it give?

Error checking is about as good as editing named.conf by hand and then
running "named-checkconf".  The log on the server receiving the 'rndc'
command gets useful things like:

--SNIP--
30-Jul-2010 00:25:29.013 received control channel command 'addzone
clegg.com { type slave; file "slave/clegg.com"'
30-Jul-2010 00:25:29.014 none:1: missing ';' before end of file
30-Jul-2010 00:25:29.014 none:1: '}' expected near end of file
--SNIP--

and

--SNIP--
30-Jul-2010 00:42:26.717 received control channel command 'addzone
boo!bad.com { type master; file "master/boo!bad.com"; update-policy
local; auto-dnssec maintain; };'
30-Jul-2010 00:42:26.717 none:1: '{' expected near '!'
--SNIP--

Unfortunately, rndc isn't very talkative on error messages, but it does
complain if something goes wrong:

When adding a zone that is already in the named.conf:
--SNIP--
root at ubuntu:/etc/namedb# ./addslavezone clegg.com
rndc: 'addzone' failed: already exists
--SNIP--

And with a bad name:
--SNIP--
root at ubuntu:/etc/namedb# ./addzone boo\!bad.com
rndc: 'addzone' failed: unexpected token
--SNIP--

Once scripted to do "pre-rndc error checking", I'm sure that someone
will be able to write a heck of a frontend -- we expect nothing less.

:)

AlanC

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 260 bytes
Desc: OpenPGP digital signature
URL: <https://lists.isc.org/pipermail/bind-users/attachments/20100729/0ff6ec9d/attachment.bin>


More information about the bind-users mailing list