I
I
Ivan2020-06-24 16:20:36
linux
Ivan, 2020-06-24 16:20:36

DNS does not work in the configured bind9, how to fix it?

There are virtual machines with Linux in VirtualBox 2, on one DNS (210.210.10.1), and on the other WEB server (210.210.10.2). It is necessary that the WEB server be located at the server.site.lan domain name, but my setting does not work (

Here are my configs:

named.conf.local

acl mynetwork {210.210.10.0/24; 127.0.0.1; };
options {
directory "/var/cache/bind";
auth-nxdomain no;
listen-on-v6 { none; };
allow-query { mynetwork; };
};


named.conf.default-zones
zone "site.lan" {
type master;
file "/etc/bind/db.site.lan";
};

zone "10.210.210.in-addr.arpa" {
type master;
file "/etc/bind/10.210.210.in-addr.arpa";
};


db.site.lan
$TTL 30
$ORIGIN site.lan.

@ IN SOA ns.site.lan. root.site.lan. (
2011100902 ;Serial
1d ;Refresh
1h ;Retry
1w ;Expire
2h ) ;Negative Cache TTL
;
@ IN NS ns.site.lan.
@ IN A 210.210.10.1

server IN A 210.210.10.2


10.210.210.in-addr.arpa
$TTL 30
$ORIGIN 10.210.210.in-addr.arpa.

@ IN SOA ns.site.lan. root.site.lan. (
2011100907 ;Serial
1d ;Refresh
1h ;Retry
1w ;Expire
2h) ;Negative Cache TTL
;
NS ns.site.lan.

2 PTR server.site.lan.


resolv.conf
domain site.lan
search site.lan
nameserver 210.210.10.1


And at the command
named-checkconf -z

Outputs this:

zone site.lan/IN: NS 'ns.site.lan' has no address records (A or AAAA)
zone site.lan/IN: not loaded due to errors.
_default/site.lan/IN: bad zone
zone 10.210.210.in-addr.arpa/IN: loaded serial 2011100907


What is misconfigured?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
W
Wexter, 2020-06-24
@ivan_minin

zone site.lan/IN: NS 'ns.site.lan' has no address records (A or AAAA)

you are explicitly told that there is no A or AAAA record for the ns.site.lan domain, either specify another existing one as the NS server, or add a record

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question