Linux – Bind9 Slave not resolving clients queries

binddomain-name-systemlinuxmaster-slave

I have two VM's running OpenSUSE 15, one master and one slave.

Master is running well and transfer the zones file to the slave correctly but if I stop the bind on master server, slave should respond to clients but he doesn't. I configured two clients with only the slave server as DNS, not working.

What am I doing wrong ?
By the way, it is a test environment for my school project

Master conf file:

# Config dnslinux.lab

zone "dnslinux.lab" {
        type master;
        file "/var/lib/named/dnslinux.db";
        allow-transfer { 192.168.88.131; };
        #allow-update { 192.168.88.131 ; };
        notify yes;
        also-notify { 192.168.88.131; };
};

# Config zone inverse

zone "88.168.192.in-addr.arpa" {
        type master;
        file "/var/lib/named/reverse.dnslinux.db";
        allow-transfer { 192.168.88.131; };
        #allow-update { 192.168.88.131 ; };
        notify yes;
        also-notify { 192.168.88.131; };
};

SLAVE CONF FILE(can't share it other way)

SLAVE CONF FILE(can't share it other way)

Zones files
main file

$TTL 10800

@       IN      SOA     ns1.dnslinux.lab. root.dnslinux.lab. (
                        2020012301 ; Serial
                        30 ; Refresh
                        10 ; Retry
                        1w ; Expire
                        1h ) ; Negative Cache TTL

@       IN      NS      ns1.dnslinux.lab.
@       IN      NS      ns2.dnslinux.lab.

; DNS Servers
ns1     IN      A       192.168.88.130
ns2     IN      A       192.168.88.131

; Machines 
docker  IN      A       192.168.88.128

Reverse zone

$TTL 10800

@       IN      SOA     ns1.dnslinux.lab. root.dnslinux.lab. (
                        2020012301 ;
                        30 ;
                        10 ;
                        1w ;
                        1h ) ;

@       IN      NS      ns1.dnslinux.lab.
@       IN      NS      ns2.dnslinux.lab.


; DNS Servers
130     IN      PTR     ns1.dnslinux.lab.
131     IN      PTR     ns2.dnslinux.lab.

; Machines
128     IN      PTR     docker.dnslinux.lab.

This is the first time I posted here, please let me know if I'm not clear.

Best Answer

Result of dig command when i run it on my Docker VM

[root@docker sysadmin]# dig @192.168.88.131 docker.dnslinux.lab

; <<>> DiG 9.11.4-P2-RedHat-9.11.4-9.P2.el7 <<>> @192.168.88.131 docker.dnslinux.lab
; (1 server found)
;; global options: +cmd
;; connection timed out; no servers could be reached
[root@docker sysadmin]# ping 192.168.88.131
PING 192.168.88.131 (192.168.88.131) 56(84) bytes of data.
64 bytes from 192.168.88.131: icmp_seq=1 ttl=64 time=0.399 ms
64 bytes from 192.168.88.131: icmp_seq=2 ttl=64 time=0.811 ms
64 bytes from 192.168.88.131: icmp_seq=3 ttl=64 time=0.302 ms
^C
--- 192.168.88.131 ping statistics ---
3 packets transmitted, 3 received, 0% packet loss, time 2001ms
rtt min/avg/max/mdev = 0.302/0.504/0.811/0.220 ms

I also test a ping to ensure i can reach the slave.

Dig does work when i run it on the slave server himself. dig result . I configured slave's resolv.conf file as follow:

domain dnslinux.lab
search dnslinux.lab
nameserver 127.0.0.1
nameserver 192.168.88.130

Here are the logs i get when i restart named on slave:

EDIT: I solved the problem, it was the firewall blocking port 53 on public zone network (i don't know why my VMs network has been set to public), I went into yast > Security and Users > Firewall > Then i add DNS protocol on public. I noticed my mistake with dig @ip_slave_server client.name and by installing nmap nmap -v -p 53 192.168.X.X.