This commit is contained in:
2025-05-19 12:13:52 +02:00
parent 16a1b05506
commit 28a3871cdf
9 changed files with 287 additions and 0 deletions

View File

@@ -0,0 +1,40 @@
Configuration Schema:
--------------------
The Debian BIND package ships with a config that will work for the majority
of leaf servers with no user input required.
The named configuration file named.conf is located in /etc/bind, so that all
static configuration files relating to bind are in one place. If you really
don't want named.conf in /etc/bind, then the best way to handle it is probably
to replace /etc/bind/named.conf with a symlink to the location you want to use.
You could also use an option to named in the init.d script, but that only works
for named, not for things like ndc.
Zone data files for the root servers, and the forward and reverse localhost
zones are also provided in /etc/bind.
The working directory for named is now /var/cache/bind. Thus, any transient
files generated by named, such as database files for zones the daemon is
secondary for, will be written to the /var filesystem, where they belong.
To make this work, the named.conf provided uses explicitly fully-qualified
pathnames to reference the files in /etc/bind.
Unlike previous BIND packages for Debian, the named.conf and provided db.*
files are tagged as conffiles. Thus, if you just want a "caching mostly"
server configuration for a server that does not need to be authoritative for
anything else, you can run the provided configuration as-is. If you want to
hack on named.conf, or even the init.d fragment, you can feel free to. Future
package upgrades will treat your configuration changes sanely, as all Debian
packages should.
While you are free to craft whatever structure you wish for servers which need
to be authoritative for additional zones, what we suggest is that you put the
db files for any zones you are master for in /etc/bind (perhaps even in a
subdirectory structure depending on complexity), using full pathnames in the
named.conf file. Any zones you are secondary for should be configured in
named.conf with simple filenames (relative to /var/cache/bind), so the data
files will be stored in BIND's working directory (defaults to /var/cache/bind).
Zones subject to automatic updates (such as via DHCP and/or nsupdate) should be
stored in /var/lib/bind, and specified with full pathnames.

164
SCR2.2/TP22/dns1.imn Normal file
View File

@@ -0,0 +1,164 @@
node n0 {
type lanswitch
network-config {
hostname switch1
!
}
canvas c0
iconcoords {408 96}
labelcoords {408 119}
interface-peer {e0 n1}
interface-peer {e1 n2}
interface-peer {e2 n3}
interface-peer {e3 n5}
interface-peer {e4 n4}
}
node n1 {
type host
network-config {
hostname osiris
!
interface eth0
ip address 192.168.1.158/24
mac address 42:00:aa:00:00:00
!
interface lo0
type lo
ip address 127.0.0.1/8
ipv6 address ::1/128
!
}
canvas c0
iconcoords {96 240}
labelcoords {96 276}
interface-peer {eth0 n0}
}
node n2 {
type pc
network-config {
hostname eno
!
interface eth0
ip address 192.168.1.1/24
mac address 42:00:aa:00:00:01
!
interface lo0
type lo
ip address 127.0.0.1/8
ipv6 address ::1/128
!
}
canvas c0
iconcoords {240 360}
labelcoords {240 391}
interface-peer {eth0 n0}
}
node n3 {
type pc
network-config {
hostname owt
!
interface eth0
ip address 192.168.1.2/24
mac address 42:00:aa:00:00:02
!
interface lo0
type lo
ip address 127.0.0.1/8
ipv6 address ::1/128
!
}
canvas c0
iconcoords {480 360}
labelcoords {480 391}
interface-peer {eth0 n0}
}
node n4 {
type pc
network-config {
hostname eerht
!
interface eth0
ip address 192.168.1.3/24
mac address 42:00:aa:00:00:03
!
interface lo0
type lo
ip address 127.0.0.1/8
ipv6 address ::1/128
!
}
canvas c0
iconcoords {672 336}
labelcoords {672 367}
interface-peer {eth0 n0}
}
node n5 {
type pc
network-config {
hostname ruof
!
interface eth0
ip address 192.168.1.4/24
mac address 42:00:aa:00:00:04
!
interface lo0
type lo
ip address 127.0.0.1/8
ipv6 address ::1/128
!
}
canvas c0
iconcoords {720 168}
labelcoords {720 199}
interface-peer {eth0 n0}
}
link l0 {
nodes {n0 n1}
bandwidth 0
}
link l1 {
nodes {n0 n2}
bandwidth 0
}
link l2 {
nodes {n3 n0}
bandwidth 0
}
link l3 {
nodes {n5 n0}
bandwidth 0
}
link l4 {
nodes {n0 n4}
bandwidth 0
}
canvas c0 {
name {Canvas0}
}
option show {
interface_names yes
ip_addresses yes
ipv6_addresses yes
node_labels yes
link_labels yes
background_images no
annotations yes
hostsAutoAssign no
grid yes
iconSize normal
zoom 1.0
}

View File

@@ -0,0 +1,17 @@
;
; BIND data file for tp.scr
;
$TTL 604800
@ IN SOA osiris.tp.scr. root.tp.scr. (
2 ; Serial
604800 ; Refresh
86400 ; Retry
2419200 ; Expire
604800 ) ; Negative Cache TTL
;
@ IN NS osiris.tp.scr.
osiris.tp.scr. IN A 192.168.1.158
eno.tp.scr. IN A 192.168.1.1
owt.tp.scr. IN A 192.168.1.2
eerht.tp.scr. IN A 192.168.1.3
ruof.tp.scr. IN A 192.168.1.4

View File

@@ -0,0 +1,17 @@
;
; BIND reverse data file for tp.scr
;
$TTL 604800
@ IN SOA osiris.tp.scr. root.tp.scr. (
1 ; Serial
604800 ; Refresh
86400 ; Retry
2419200 ; Expire
604800 ) ; Negative Cache TTL
;
@ IN NS osiris.tp.scr.
158.1.168.192.in-addr.arpa IN PTR osiris.tp.scr.
1.1.168.192.in-addr.arpa IN PTR eno.tp.scr.
2.1.168.192.in-addr.arpa IN PTR owt.tp.scr.
3.1.168.192.in-addr.arpa IN PTR eerht.tp.scr.
4.1.168.192.in-addr.arpa IN PTR ruof.tp.scr.

View File

@@ -0,0 +1,13 @@
;
; BIND reverse data file for local loopback tp.scr
;
$TTL 604800
@ IN SOA osiris.tp.scr. root.. (
1 ; Serial
604800 ; Refresh
86400 ; Retry
2419200 ; Expire
604800 ) ; Negative Cache TTL
;
@ IN NS localhost.
1.0.0 IN PTR localhost.

View File

@@ -0,0 +1,17 @@
;
; BIND data file for local loopback tp.scr
;
$TTL 604800
@ IN SOA osiris.tp.scr. root.tp.scr. (
2 ; Serial
604800 ; Refresh
86400 ; Retry
2419200 ; Expire
604800 ) ; Negative Cache TTL
;
@ IN NS osiris.tp.scr.
osiris.tp.scr. IN A 192.168.1.158
eno.tp.scr. IN A 192.168.1.1
owt.tp.scr. IN A 192.168.1.2
eerht.tp.scr. IN A 192.168.1.3
ruof.tp.scr. IN A 192.168.1.4

View File

@@ -0,0 +1,19 @@
//
// Do any local configuration here
//
// Consider adding the 1918 zones here, if they are not used in your
// organization
//include "/etc/bind/zones.rfc1918";
zone "tp.scr"
{
type master;
file "/etc/bind/db.tp.scr";
};
zone "1.168.192.in-addr.arpa"
{
type master;
file "/etc/bind/db.tp.scr.inv";
};

Binary file not shown.