Sign in with
Sign up | Sign in
Your question

DNS server won't resolve internal hostnames (bind9 on debian7)

Tags:
  • resolve
  • Networking
  • IP
  • DNS Server
  • DNS
  • bind9
Last response: in Networking
Share
October 10, 2014 9:34:45 AM

I have a small home network on which I have setup a DNS server using bind9 on debian 7.

Resolving external names like google.com works fine. But when trying to resolve hostnames within my local network, it fails.

Test setup:
Domain: test.local
DNS server IP: 10.0.0.9
Router IP: 10.0.0.8 (static)
Test pc 1 IP: 10.0.0.126 (dhcp)
Test pc 2 IP: 10.0.0.10 (static)
DNS server set for both test PCs: 10.0.0.9

nslookup tomshardware.com from test pc 1:
Spoiler

C:\>nslookup tomshardware.com
Server: UnKnown
Address: 10.0.0.9

Non-authoritative answer:
Name: tomshardware.com
Address: 50.112.149.71


nslookup internal hostname from test pc 1:
Spoiler
C:\>nslookup xen01.test.local
Server: UnKnown
Address: 10.0.0.9

*** UnKnown can't find xen01.test.local: Server failed

(note it says "Server failed". If trying to look up a non-existent hostname/domain, it will reply "Non-existent domain" instead)

My bind9 configs:
named.conf.local:
Spoiler
zone "test.local" {
type master;
file "/etc/bind/db.test.local";
};

zone "0.0.10.in-addr.arpa" {
type master;
notify no;
file "/etc/bind/db.10";
};


db.test.local:
Spoiler
$TTL 604800
@ IN SOA test.local. root.test.local. (
1010140; Serial
604800; Refresh
86400; Retry
2419200; Expire
604800 ); Negative Cache TTL
;
@ IN NS ns.test.local.
@ IN A 10.0.0.9
dns1 IN A 10.0.0.9
testpc1-pc IN A 10.0.0.126
wrt IN A 10.0.0.8
xen01 IN A 10.0.0.10


db.10:
Spoiler
$TTL 604800
@ IN SOA test.local. root.test.local. (
1010140; Serial
604800; Refresh
86400; Retry
2419200; Expire
604800 ); Negative Cache TTL
;
@ IN NS dns1.test.local.
8 IN PTR wrt.test.local
9 IN PTR dns1.test.local
10 IN PTR xen01.test.local
126 IN PTR testpc1-pc.test.local


The dns server have ofcourse been restarted prior to posting here.

What am I doing wrong?

More about : dns server resolve internal hostnames bind9 debian7

October 10, 2014 4:11:22 PM

This have been solved.
in db.test.local, I changed the NS A-record to dns.test.local.
m
0
l
Related resources
!