Я установил BIND9 на моей виртуальной машине Debian Stretch, это часть моей виртуальной сетевой лаборатории - я хочу, чтобы машина с установленным BIND выполняла роль брандмауэра, nat, dns и dhcp для других (сейчас я устанавливаю статические IP-адреса везде, просто для простоты). Он имеет один интерфейс (eth1) для взаимодействия с частной сетью и другой (eth0) для доступа в Интернет.
Пинг с определенными IP-адресами работает нормально, поэтому nat part настроен правильно.
Проблема заключается в настройке BIND в качестве службы кэширования DNS. Служба BIND работает без ошибок, но я получаю следующую ошибку (nslookup с той же машины, на которой установлен BIND):
nslookup google.com
Server: 127.0.0.1
Address: 127.0.0.1#53
** server can't find google.com: SERVFAIL
/ и т.д. / привязывать / named.conf.options
options {
directory "/var/cache/bind";
dnssec-validation auto;
listen-on port 53 {10.0.0.1; 127.0.0.1; };
recursion yes;
allow-query { 127.0.0.1; any; };
allow-query-cache { 127.0.0.1; any;};
allow-recursion { 127.0.0.1; any; };
auth-nxdomain no; # conform to RFC1035
};
/ и т.д. / BIND / named.conf.default-зона
// prime the server with knowledge of the root servers
zone "." {
type hint;
file "/etc/bind/db.root";
};
// be authoritative for the localhost forward and reverse zones, and for
// broadcast zones as per RFC 1912
zone "localhost" {
type master;
file "/etc/bind/db.local";
};
zone "127.in-addr.arpa" {
type master;
file "/etc/bind/db.127";
};
zone "0.in-addr.arpa" {
type master;
file "/etc/bind/db.0";
};
zone "255.in-addr.arpa" {
type master;
file "/etc/bind/db.255";
};
/ и т.д. / привязывать / db.local
;
; BIND data file for local loopback interface
;
$TTL 604800
@ IN SOA localhost. root.localhost. (
2 ; Serial
604800 ; Refresh
86400 ; Retry
2419200 ; Expire
604800 ) ; Negative Cache TTL
;
@ IN NS localhost.
@ IN A 127.0.0.1
@ IN AAAA ::1
/ и т.д. / привязывать / db.127
;
; BIND reverse data file for local loopback interface
;
$TTL 604800
@ IN SOA localhost. root.localhost. (
1 ; Serial
604800 ; Refresh
86400 ; Retry
2419200 ; Expire
604800 ) ; Negative Cache TTL
;
@ IN NS localhost.
1.0.0 IN PTR localhost.
/ и т.д. / привязывать / named.conf
// This is the primary configuration file for the BIND DNS server named.
//
// Please read /usr/share/doc/bind9/README.Debian.gz for information on the
// structure of BIND configuration files in Debian, *BEFORE* you customize
// this configuration file.
//
// If you are just adding zones, please do that in /etc/bind/named.conf.local
include "/etc/bind/named.conf.options";
include "/etc/bind/named.conf.local";
include "/etc/bind/named.conf.default-zones";
/ и т.д. / привязка / named.conf.local
// Do any local configuration here
//
// Consider adding the 1918 zones here, if they are not used in your
// organization
//include "/etc/bind/zones.rfc1918";
Поскольку я новичок в сети, я был бы признателен за любые подсказки. Спасибо