A simple nameserver-in-a-can configuration for people who have had enough
trying to edit several dozen HOSTS files on multiple systems.

Please note that because I didn't want to wreck my internal nameservers, I
have not actually run the results of this stuff fully.  It looks ok, but if
you get errors, the source of the error should be obvious if you look at
wherever named is configured to throw log messages on your system.

This is free software, supplied under the terms of the GNU General Public
License, version 2, or at your option, any later version.  Not that I really
care;  do what you like with it, just don't blame me if it all goes the way
of the pear.

It is supplied with no warranty of any kind.  If you break it, you get to
keep all of the pieces.  If it breaks you, you need to restore yourself from
a backup.

While I am happy to receive bug reports at jimhowes  at  jimhowes.org.uk,
this does not mean you will get any form of support, and does not even
guarantee an answer.  The software is supplied 'as is', and any bugs are
included free of charge.  If you want me to create a proper DNS configuration
for you, I charge by the hour.

----------------------------------------------------------------------------

This stuff creates a basic nameserver for a private (non-internet-connected)
network.  For internet connected networks, read up on forwarders and put
appropriate lines in named.conf

BEFORE YOU START - BACK UP ANYTHING YOUR DISTRIBUTION HAS PUT IN /var/named
IF YOUR SYSTEM HAS INTERNET CONNECTIVITY YOU ALMOST CERTAINLY DO NOT WANT MY
GENERATED rndc.key FILE AND SHOULD USE YOUR OWN.

192.168.0.db is your basic hosts-style database.
Syntax is similar to /etc/hosts
The OFFICIAL host name should be listed first, aliases afterwards, no dots
Blank entries will have no forward DNS, but will resolve as no-dns-yet.domain

If your network is not at 192.168.0.0/24, and your domain name is not foobar.net
then you need to edit the definitions at the top of named.generate.rc
Note that named.generate.rc is run with it's standard input being the host-style
file, usually 192.168.0.db

Create the chroot environment in /var/named by running make-chroot.rc
You only need to do that once.

Run named.recreate.rc to regenerate the named database and restart named
Depending on your distribution, the named service may or may not run in a
chroot environment in /var/named/chroot, this script _should_ take care
of that, but your milage may vary.  


