# bind 8.4.7
# ==========
# bind 9.x is the current version of bind and should be used in all cases
# where possible. If you don't have a specific reason for using bind 8.x,
# go to the bind 9.x howto.
# I think the latest version of Slackware to include bind 8.x was Slackware
# 7.1 All versions since include bind 9.x, though several include 8.x in
# 'pasture'.
# I haven't used bind 8.x in several years, so if any of this is no longer
# accurate, let me know and I'll fix it.
# Below, the examples include commandline options and such for running the
# named daemon chrooted under the /var/named directory. For details about
# setting up named under a chroot jail, see the Chroot-BIND8 HOWTO
cd
test -f installed/bind-8.4.7.tar.gz && mv installed/bind-8.4.7.tar.gz .
test ! -f bind-8.4.7.tar.gz -a ! -f bind-src.tar.gz &&
wget http://ftp.isc.org/isc/bind/src/8.4.7/bind-src.tar.gz
mv -f bind-src.tar.gz bind-8.4.7.tar.gz
mkdir -p -m 0700 src
cd src
find -maxdepth 1 -type d -name "bind-*" -exec rm -r {} \;
mkdir -p -m 0700 bind-8.4.7
cd bind-8.4.7
tar xzvf ~/bind-8.4.7.tar.gz
test $UID = 0 && chown -R root:root .
cd src
make depend
make all
# Check port/linux/Makefile.set to make sure everything is ok (it should
# already be). If you change anything, remove the .settings file
# Back up /var/named (if it exists):
test -d /var/named &&
( mkdir -p -m 0700 ~/backup
tar czvf ~/backup/named-`date +%m%d%Y`.tgz /var/named (
# If you're running the named daemon, stop it. This is how to stop it if
# you're running it chroot'ed into /var/named. If it's not chrooted, I'd
# guess that 'ndc stop' would do the trick.
# /usr/sbin/ndc -c /var/named/var/run/ndc stop
test -x /sbin/removepkg && /sbin/removepkg bind
make install
## I don't know if this is still necessary, but I used to have to copy the
## binaries into /var/named/usr/sbin/ when I was running named chrooted under
## /var/named. You don't need to do this if you're just installing bind for
## the resolver and utilities.
# cp /usr/sbin/named /usr/sbin/named-xfer /usr/sbin/ndc /var/named/usr/sbin/
# Also if you're running the named daemon, create a 'named' user and group
# to run the daemon as:
getent group | grep "^named:" > /dev/null 2>&1 || groupadd named
id named > /dev/null 2>&1 || useradd -g named named
## Start up named again. This example runs it as user 'named', group 'named',
## chrooted under /var/named.
# /usr/sbin/named -u named -g named -t /var/named