Konfiguration von bind9
von suleiman- SNIPPET_TEXT:
-
- #
- # Nun kann ich bind9 neu installieren
- #
- apt install bind9
- # Kopie der Original Dateien
- cp -r /etc/bind /etc/bind-org
- # erstellen einer Zonen-Datei
- cp /etc/bind/db.local /etc/bind/db.home-network
- nano /etc/bind/db.home-network
- cat /etc/bind/db.home-network
- ;
- ; BIND data file for home-network
- ;
- $TTL 604800
- @ IN SOA mysrv.home-network. root.home-network. (
- 2 ; Serial
- 604800 ; Refresh
- 86400 ; Retry
- 2419200 ; Expire
- 604800 ) ; Negative Cache TTL
- ;
- @ IN NS mysrv.home-network.
- @ IN MX 10 mysrv.home-network.
- mysrv IN A 192.168.147.1
- bak IN CNAME mysrv.
- nfs IN CNAME mysrv.
- sftp IN CNAME mysrv.
- smb IN CNAME mysrv.
- # erstellen einer umgekehrten Zonen-Datei
- cp /etc/bind/db.127 /etc/bind/db.home-network.inv
- nano /etc/bind/db.home-network.inv
- cat /etc/bind/db.home-network.inv
- ;
- ; BIND reverse data file for home-network
- ;
- $TTL 604800
- @ IN SOA mysrv.home-network. root.home-network. (
- 1 ; Serial
- 604800 ; Refresh
- 86400 ; Retry
- 2419200 ; Expire
- 604800 ) ; Negative Cache TTL
- ;
- @ IN NS mysrv.home-network.
- 1 IN PTR mysrv.home-network.
- # Die Zonen-Dateien müssen nun eingebunden werden
- nano /etc/bind/named.conf.local
- cat /etc/bind/named.conf.local
- //
- // Do any local configuration here
- //
- zone "home-network" {
- type master;
- file "/etc/bind/db.home-network";
- allow-update { key rndc-key; };
- };
- zone "147.168.192.in-addr.arpa" {
- type master;
- file "/etc/bind/db.home-network.inv";
- allow-update { key rndc-key; };
- };
- // Consider adding the 1918 zones here, if they are not used in your
- // organization
- //include "/etc/bind/zones.rfc1918";
Quellcode
Hier kannst du den Code kopieren und ihn in deinen bevorzugten Editor einfügen. PASTEBIN_DOWNLOAD_SNIPPET_EXPLAIN