How to clear a zone from a broken Bind/Named server

Posted by Cerin on Server Fault See other posts from Server Fault or by Cerin
Published on 2013-11-11T15:23:32Z Indexed on 2013/11/11 15:57 UTC
Read the original article Hit count: 287

Filed under:
|

I tried adding a new zone for "mydomain4.com" to my Named DNS server. However, when I went to restart it, I received the unhelpful error message:

Error in named configuration:
zone mydomain4.com/IN: loaded serial 3
zone mydomain3.com/IN: loaded serial 2
zone mydomain2.com/IN: loaded serial 2
zone mydomain1.com/IN: loaded serial 2
zone mydomain0.com/IN: loaded serial 6
zone localhost.localdomain/IN: loaded serial 0
zone localhost/IN: loaded serial 0
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
zone 1.0.0.127.in-addr.arpa/IN: loaded serial 0
zone 0.in-addr.arpa/IN: loaded serial 0
zone mydomain/IN: loaded serial 2010092201
dns_rdata_fromtext: db.10.157.10:27: near '*.mydomain4.com.': bad name (check-names)
zone 10.157.10.in-addr.arpa/IN: loading from master file db.10.157.10 failed: bad name (check-names)
zone 10.157.10.in-addr.arpa/IN: not loaded due to errors.
_default/10.157.10.in-addr.arpa/IN: bad name (check-names)

I'm confused by this, since I thought I created the new zone identically to how I created the other 4 zones. However, since I need this DNS server up, I tried deleting the new zone file at /var/named/chroot/var/named/mydomain4.com.db. However, upon trying to restart again, I received a new unhelpful error:

Error in named configuration:
zone mydomain4.com/IN: loading from master file mydomain4.com.db failed: file not found
zone mydomain4.com/IN: not loaded due to errors.
_default/mydomain4.com./IN: file not found
zone mydomain3.com/IN: loaded serial 2
zone mydomain2.com/IN: loaded serial 2
zone mydomain1.com/IN: loaded serial 2
zone mydomain0.com/IN: loaded serial 6
zone localhost.localdomain/IN: loaded serial 0
zone localhost/IN: loaded serial 0
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
zone 1.0.0.127.in-addr.arpa/IN: loaded serial 0
zone 0.in-addr.arpa/IN: loaded serial 0
zone mydomain/IN: loaded serial 2010092201
dns_rdata_fromtext: db.10.157.10:27: near '*.mydomain4.com.': bad name (check-names)
zone 10.157.10.in-addr.arpa/IN: loading from master file db.10.157.10 failed: bad name (check-names)
zone 10.157.10.in-addr.arpa/IN: not loaded due to errors.
_default/10.157.10.in-addr.arpa/IN: bad name (check-names)

Obviously, named still thinks the zone file is being used, but I can't find where. I've tried doing:

grep -lir "mydomain4" /

but it doesn't find any files containing that text. How do I purge this domain from named's configs? Also, how do I figure out what caused the original error?

© Server Fault or respective owner

Related posts about bind

Related posts about named-conf