I am using the 10.0.0.x scheme for my LAN. I have a Raspberry Pi that hosts certain services, including DNS. I am running into a problem with what I think is my reverse zone.
The RPI is on 10.0.0.21. My domain is example.tk. When a client requests for server.example.tk, it replys with 56.234.67.45 (redacted to random IP). This DNS server also answers DNS requests from the WAN. I want it to reply with 10.0.0.21 so clients on the LAN can have access to certain services that are not forwarded. The way I accomplish this is with reverse DNS, correct?
My configuration files for BIND9:
pi@raspberrypi /etc/bind $ cat named.conf.local
zone "example.tk" {
type master;
file "/etc/bind/zones/db.example.tk";
};
zone "0.0.10.in-addr.arpa" {
type master;
file "/etc/bind/zones/db.10";
allow-update { none; };
};
pi@raspberrypi /etc/bind $ cd zones
pi@raspberrypi /etc/bind/zones $ cat db.example.tk
$TTL 604800
@ IN SOA ns.example.tk. root.localhost. (
6 ; Serial
604800 ; Refresh
86400 ; Retry
2419200 ; Expire
604800 ) ; Negative Cache TTL
;
@ IN NS ns.example.tk.
ns IN A 50.161.83.76
server IN A 50.161.83.76
www IN CNAME server
play IN CNAME server
pi@raspberrypi /etc/bind/zones $ cat db.10
$TTL 604800
@ IN SOA ns.example.tk. root.localhost. (
99 ; Serial
604800 ; Refresh
86400 ; Retry
2419200 ; Expire
604800 ) ; Negative Cache TTL
;
0.0.10.in-addr.arpa. IN NS ns.example.tk.
21 IN PTR ns.example.tk.
21 IN PTR server.example.tk.
pi@raspberrypi /etc/bind/zones $
The problem is, it never replies with the reverse IP for clients on the LAN.
What am I doing wrong?
Edit: named-checkzone returns no errors.