I wanted to add a zone to my bind9 configuration (BIND 9.16.1). I have about 20 domains serviced by this name server, most of which have worked for > 10 years.
named-checkconf is throwing errors on the new conf file, but also all the old conf files, even though they still work. I'm not brave enough to reload bind9 in case I am missing something.
I get the following error:
root@ns:/var/cache/bind# named-checkconf test
test:1: unknown option '$ORIGIN'
test:18: unexpected token near end of file
root@ns:/var/cache/bind# cat test
$ORIGIN test.au.
$TTL 3h
@ IN SOA ns1.example.com.au. david.example.com.au. (
23042601 # serial
3h # refresh
15m # retry
14d # expire
12h # default_ttl
)
@ IN NS ns1.example.com.au.
@ IN NS ns2.example.com.au.
@ IN MX 50 mail.test.au.
@ IN MX 100 ns.example.com.au.
@ IN A 123.456.789.1
mail IN A 123.456.789.9
www IN A 123.456.789.1
root@ns:/var/cache/bind#
If I put a comment at the beginning, i get a different error thus:
root@ns:/var/cache/bind# named-checkconf test
test:1: syntax error near ';'
root@ns:/var/cache/bind# cat test
; 230426 original
;
$ORIGIN test.au.
$TTL 3h
@ IN SOA ns.example.com.au. david.example.com.au. (
etc......
I feel like I'm missing something obvious.