Service named failed to start (bad zone)
6,908
The records you do have in you zone file appear correct, but you don't have enough of them, your zone is incomplete. The error message you posted is quite clear about that:
NS 'centos7-test.innovisage.local' has no address records (A or AAAA)
and the solution is also as simple as that, you need add that A or AAAA record:
centos7-test.innovisage.local. IN A 198.51.100.1
or the equivalent in DNS shorthand
centos7-test IN A 198.51.100.1
Related videos on Youtube
Author by
supmethods
Updated on September 18, 2022Comments
-
supmethods over 1 year
I am trying to create a new master zone for the domain name innovisage.local but keeping getting errors.
I'm using WebMin to configure the new master zone, so it should be syntactically correct. I've also manually checked the zone file and config file and they both seem correct to me.
Here's the error log:
-- Unit named.service has begun starting up. Aug 09 22:07:58 centos7-test.innovisage.local bash[5496]: zone localhost.localdomain/IN: loaded serial 0 Aug 09 22:07:58 centos7-test.innovisage.local bash[5496]: zone localhost/IN: loaded serial 0 Aug 09 22:07:58 centos7-test.innovisage.local bash[5496]: zone 1.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.ip6.arpa/IN: loaded serial 0 Aug 09 22:07:58 centos7-test.innovisage.local bash[5496]: zone 1.0.0.127.in-addr.arpa/IN: loaded serial 0 Aug 09 22:07:58 centos7-test.innovisage.local bash[5496]: zone 0.in-addr.arpa/IN: loaded serial 0 Aug 09 22:07:58 centos7-test.innovisage.local bash[5496]: zone innovisage.local/IN: NS 'centos7-test.innovisage.local' has no address records (A or AAAA) Aug 09 22:07:58 centos7-test.innovisage.local bash[5496]: zone innovisage.local/IN: not loaded due to errors. Aug 09 22:07:58 centos7-test.innovisage.local bash[5496]: _default/innovisage.local/IN: bad zone Aug 09 22:07:58 centos7-test.innovisage.local systemd[1]: named.service: control process exited, code=exited status=1 Aug 09 22:07:58 centos7-test.innovisage.local systemd[1]: Failed to start Berkeley Internet Name Domain (DNS). -- Subject: Unit named.service has failed -- Defined-By: systemd -- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel -- -- Unit named.service has failed. -- -- The result is failed. Aug 09 22:07:58 centos7-test.innovisage.local systemd[1]: Unit named.service entered failed state. Aug 09 22:07:58 centos7-test.innovisage.local systemd[1]: named.service failed.
Here's config file.
options { listen-on port 53 { 192.168.1.7; }; directory "/var/named"; dump-file "/var/named/data/cache_dump.db"; statistics-file "/var/named/data/named_stats.txt"; memstatistics-file "/var/named/data/named_mem_stats.txt"; recursion yes; dnssec-enable yes; dnssec-validation yes; /* Path to ISC DLV key */ bindkeys-file "/etc/named.iscdlv.key"; managed-keys-directory "/var/named/dynamic"; pid-file "/run/named/named.pid"; session-keyfile "/run/named/session.key"; forwarders { 203.12.160.35; 203.12.160.36; 8.8.8.8; }; }; logging { channel default_debug { file "data/named.run"; severity dynamic; }; }; zone "." IN { type hint; file "named.ca"; }; include "/etc/named.rfc1912.zones"; include "/etc/named.root.key"; zone "innovisage.local" { type master; file "/var/named/innovisage.local.hosts"; };
Here's my zone file:
$ttl 38400 innovisage.local. IN SOA centos7-test.innovisage.local. sophal.lee.live.com ( 1470744461 10800 3600 604800 38400 ) innovisage.local. IN NS centos7-test.innovisage.local.
-
supmethods almost 8 yearsI've tried adding the A record prior to removing it. In either case, they generate the same error message of "bad zone"
-
HBruijn almost 8 yearsCheck the zone file with
named-checkzone innovisage.local /var/named/innovisage.local.hosts
for syntax errors after editing -
supmethods almost 8 yearsYes, you were right with the previously entry. I misread before and thought it was for the A record of the domain name. Added the A record for the NS server and it fixed the problem. Thanks.
-
supmethods almost 8 yearsI've got it working by adding the A record as suggested but it intermittently stops working. Names always resolve on the server itself but it intermittently drops out on external clients. The DNS server is a CentOS VM and the client is a Windows machine hosting the VM. I've checked all the config file but can't see anything wrong with it. What could be causing this issue?