Differences between revisions 1 and 2
Revision 1 as of 2017-12-10 19:38:00
Size: 15
Comment:
Revision 2 as of 2017-12-10 19:40:39
Size: 1694
Comment:
Deletions are marked like this. Additions are marked like this.
Line 2: Line 2:

= DNS Slave =


== Network ==

Since looking up the DNS servers IP-address does not make any sense, we will give the DNS server a statc IP-address. Edit `/etc/networking/interfaces` and make the following changes.

{{{
# The primary network interface
#allow-hotplug eth0
#iface eth0 inet dhcp

auto eth0
iface eth0 inet static
        address 192.168.1.35
        network 192.168.1.0
        netmask 255.255.255.0
        broadcast 192.168.1.255
        gateway 192.168.1.1
}}}

== Install BIND ==

{{{
apt-get install bind9
}}}

== Configure BIND ==

=== Make BIND listen ===

edit `/etc/bind/named.conf.options` and add

{{{
listen-on { any; };
allow-notify { 192.168.1.35; };
}}}
=== Get the DDNS update key ===

Get the key from the master and save it in `/etc/bind/ddns-update.dnskey`.

{{{
key "ddns-update" {
        algorithm hmac-sha512;
        secret "yYFzfibvlpS33+vsngV2jF5tGkTiVSjhYoFuV0T7bnCVfFGx3Mu05SW+LakImdofkNM00LxHCLuvD1W1vSWMmA==";
};
}}}

=== Create a new zone ===
`/etc/bind/named.conf.kallenberg.dk`
{{{
# Key used by DHCP servers for dynamic DNS updates
include "/etc/bind/ddns-update.dnskey";

zone "kallenberg.dk" {
        type slave;
        file "/var/lib/bind/kallenberg.dk.zone";
        allow-transfer { 192.168.1.34; };
        allow-update { key "ddns-update"; };
};

zone "1.168.192.in-addr.arpa" {
        type slave;
        file "/var/lib/bind/1.168.192.zone";
        allow-transfer { 192.168.1.34; };
        allow-update { key "ddns-update"; };
};
}}}

Add the new zone file to `/etc/bind/named.conf.local`
{{{
include "/etc/bind/named.conf.kallenberg.dk";
}}}

DNS Slave

DNS Slave

Network

Since looking up the DNS servers IP-address does not make any sense, we will give the DNS server a statc IP-address. Edit /etc/networking/interfaces and make the following changes.

# The primary network interface
#allow-hotplug eth0
#iface eth0 inet dhcp

auto eth0
iface eth0 inet static
        address 192.168.1.35
        network 192.168.1.0
        netmask 255.255.255.0
        broadcast 192.168.1.255
        gateway 192.168.1.1

Install BIND

apt-get install bind9

Configure BIND

Make BIND listen

edit /etc/bind/named.conf.options and add

listen-on { any; };
allow-notify { 192.168.1.35; };

Get the DDNS update key

Get the key from the master and save it in /etc/bind/ddns-update.dnskey.

key "ddns-update" {
        algorithm hmac-sha512;
        secret "yYFzfibvlpS33+vsngV2jF5tGkTiVSjhYoFuV0T7bnCVfFGx3Mu05SW+LakImdofkNM00LxHCLuvD1W1vSWMmA==";
};

Create a new zone

/etc/bind/named.conf.kallenberg.dk

# Key used by DHCP servers for dynamic DNS updates
include "/etc/bind/ddns-update.dnskey";

zone "kallenberg.dk" {
        type slave;
        file "/var/lib/bind/kallenberg.dk.zone";
        allow-transfer { 192.168.1.34; };
        allow-update { key "ddns-update"; };
};

zone "1.168.192.in-addr.arpa" {
        type slave;
        file "/var/lib/bind/1.168.192.zone";
        allow-transfer { 192.168.1.34; };
        allow-update { key "ddns-update"; };
};

Add the new zone file to /etc/bind/named.conf.local

include "/etc/bind/named.conf.kallenberg.dk";

None: DNS Slave (last edited 2021-01-22 16:16:09 by Kristian Kallenberg)