setup daemontools, ucspi-tcp, tinydns, dnscache, axfrdns

1) instalace zakladního sw pro kompilaci (install packages needed for compilation)

apt-get install build-essential

2a) instalace daemontools z repozitare (installation from repository)

apt-get install daemontools daemontools-run

2b) nebo kompilace daemontools podle (or compilation from source according to)

mkdir /downloads && cd /downloads
tar zxvf djbdnsrocks.tar.gz && cd djbdnsrocks 
tar xvzf daemontools-0.76.tar.gz
cd /downloads/djbdnsrocks/admin/daemontools-0.76/src/
patch < /downloads/djbdnsrocks/daemontools_errnopatch
cd /downloads/djbdnsrocks/admin/daemontools-0.76

3a) instalace ucspi-tcp z repozitare (installation from repository)

apt-get install ucspi-tcp

3b) nebo kompilace ucspi-tcp podle (or compilation from source according to)

cd /downloads/djbdnsrocks
patch < /downloads/djbdnsrocks/ucspi-tcp_errnopatch
make setup check

4) instalace djbdns (setup djbdns)

cd /downloads/djbdnsrocks
tar zxvf djbdns-1.05.tar.gz && cd djbdns-1.05
patch < /downloads/djbdnsrocks/djbdns_errnopatch
make setup check

přidat uživatele pro dnscache, tinydns, axfrdns
(add users for dnscache, tinydns, axfrdns)

/usr/sbin/useradd -s /sbin/nologin -d /dev/null dnslog
/usr/sbin/useradd -s /sbin/nologin -d /dev/null dnscache
/usr/sbin/useradd -s /sbin/nologin -d /dev/null tinydns
/usr/sbin/useradd -s /sbin/nologin -d /dev/null axfrdns

5) konfigurace dnscache (dnscache configuration)

priklad pro lokalni sit (example for local network):
dnscache-conf dnscache dnslog /etc/dnscache

ln -s /etc/dnscache /service

zkontrolovat, jestli běží (check if is running):

ps -aux | grep dnscache

v /etc/dnscache/root/ip nastavit jakym IP/sitim ma odpovidat - napr. pro sit
in /etc/dnscache/root/ip set which IP/networks should response - eg. for network

cd /etc/dnscache/root/ip

touch 192.168.1

restart dnscache:

svc -t /service/dnscache

zajistit, aby /etc/resolv.conf neprepisoval dhclient:
v /etc/dhcp3/dhclient.conf v radku zacinajicim "request ..." smazat nebo zakomentovat "domain-name-servers"

nastavit do /etc/resolv.conf IP adresu dnscache
(insert IP address of dnscache into /etc/resolv.conf):

echo "nameserver" > /etc/resolv.conf

pripadne nastavit do konfigurace dhcp serveru, aby klientum nabizel jako DNS server dnscache:
do /etc/dhcp3/dhcpd.conf přidat nebo upravit řádek:

option domain-name-servers;

6) konfigurace tinydns (tinydns configuration)

/usr/local/bin/tinydns-conf tinydns dnslog /etc/tinydns

přidat záznam(y) do (add lines to) /etc/tinydns/root/data:

# authoritative ns
# sekundarni ns
# mail
# reverzni zaznam
# aliasy

potom v /etc/tinydns/root spustit make (then in /etc/tinydns/root run make)

rict dnscache, aby se na nase domeny ptala primo naseho dns serveru:

echo "" > /service/dnscache/root/servers/

restart dnscache:

svc -t /service/dnscache

7) konfigurace axfrdns (axfrdns configuration)

axfrdns-conf axfrdns dnslog /etc/axfrdns /etc/tinydns

pridat zaznamy do ( add lines to) /etc/axfrdns/tcp

potom v /etc/axfrdns spustit make (then in /etc/axfrdns run make)

otestovat prenos zony z vyse povolenych IP (test zone transfer from allowed IPs):

cd /tmp
tcpclient 53 axfr-get data data.tmp
cat data

Attached files: djbdnsrocks.tar.gz

Tags: daemontools djbdns tinydns dnscache
Last update:
2010-11-11 14:21
Average rating:0 (0 Votes)

You can comment this FAQ

Chuck Norris has counted to infinity. Twice.