Die DynDNS-Domain im eigenen Bind9.
apt-get install bind9
options { directory "/var/cache/bind"; forwarders { ns1.provider.de; ns2.provider.de; ns3.provider.de; }; forward only; listen-on port 53 { 127.0.0.1; 192.168.57.2; }; listen-on-v6 { none; }; allow-query { 127.0.0.1; 192.168.57.0/24; }; allow-recursion { 127.0.0.1; 192.168.57.0/24; }; allow-transfer { none; }; cleaning-interval 720; notify no; };In diesem Beispiel stellt bind alle Anfragen, die der Dienst nicht selbst beantworten kann, an die forwarder, also die DNS-Server des eigenen Providers. Das macht man, um die DNS-Root-Server zu entlasten.
zone "my.dyndns.domain" { type master; file "/etc/bind/my.dyndns.domain.zone"; }; zone "57.168.192.in-addr.arpa" { type master; file "/etc/bind/192.168.57.rev"; };
$TTL 2D @ IN SOA ns.my.dyndns.domain. root.my.dyndns.domain. ( 2005012001 ; serial 1D ; refresh 2H ; retry 1W ; expiry 2D) ; minimum IN NS ns.my.dyndns.domain. IN MX 10 my.dyndns.domain. IN A 192.168.57.2 ns IN A 192.168.57.2 hostname IN A 192.168.57.2 mail IN CNAME hostname www IN CNAME hostname ftp IN CNAME hostname client1 IN A 192.168.57.111 client2 IN A 192.168.57.112
$TTL 2D @ IN SOA ns.my.dyndns.domain. root.my.dyndns.domain. ( 0511292000 ; serial (d. adams) 1D ; refresh 2H ; retry 1W ; expiry 2D ) ; minimum IN NS ns IN NS ns.my.dyndns.domain. IN MX 10 my.dyndns.domain. 2 IN PTR my.dyndns.domain. 111 IN PTR client1.my.dyndns.domain. 112 IN PTR client2.my.dyndns.domain.