0

i'm playing around with a DNS on localhost and i'm trying to add a subdomain but syslog reports it as a lame server.

i've defined my subdomain in my .db file while as follows

domain. IN SOA ns1.domain mail.domain (
      ....

 )

 IN NS ns1.domain
 ns1.domain. IN A 192.168.0.1

 subdomain IN NS ns1.subdomain.domain.
 ns1.subdomain.domain. IN A 192.168.0.1

doing dig @localhost ns1.subdomain.domain returns no answers and syslog shows it as a lame server.

or is this correct behaviour from a subdomain?

/etc/bind/named.conf.local

consist of the following lines

zone "domain"{
   type master;
   file "/etc/bind/dnstest.db";
};

1 Answers1

0

You need to have both:

zone "domain"{
   type master;
   file "/etc/bind/dnstest.db";
};
zone "subdomain.domain"{
   type master;
   file "/etc/bind/subdomain.dnstest.db";
};

To be authoritative for the subdomain, you need a full set of SOA records, not just NS records in the parent zone.

guzzijason
  • 1,370
  • 7
  • 18