:: Re: [DNG] What not to back up
Top Pagina
Delete this message
Reply to this message
Auteur: Bob Proulx
Datum:  
Aan: dng
Onderwerp: Re: [DNG] What not to back up
Mike Tubby wrote:
> ... but if you run a nameserver you may well need:
>
>     /var/cache/bind

>
> as that's where your zonefiles are ;-)


Sorry. No. I am curious what led you to that conclusion?

By default in the Debian packaged configuration only the cached zone
files downloaded on secondaries are located there. (The upstream BIND
does not specify a default location. This is a distro package default
location.) Since it is a package default the local admin may also
change it to any other location they wish. But /var/cache is as good
of a location as any for cached files.

And therefore by all means delete that directory any time you feel
like doing so and recreate it empty. It's not important and does not
require being backed up. It only needs to exist so the named has a
location to store and cache files (that have a TTL too) downloaded
from the primary.

If that directory is empty then upon start the BIND named will request
a fresh download of all of the zones it is configured for as a
secondary nameserver and will cache them in that directory again. If
the named is not configured as a secondary then that directory will be
empty of zone files.

For DNS primaries one specifies the source zone file using the
named.conf "file" directive. Put that file anywhere you wish to put
it. But putting that in /var/cache/bind would be a very poor choice
in my opinion.

Example of actually doing this.

    file "/etc/bind/db.proulx.com";


Since this is an option that must be configured when setting up a
primary zone then you can put those source zone files anywhere you
decide is the place to keep the source of them. I highly recommend
etckeeper for all of /etc and therefore I prefer to keep source there
where etckeeper can track them.

Bob