When I try to restart / start the named
service, it keeps failing.
service named restart
Results in:-
Stopping named: [ OK ]
Starting named:
Error in named configuration:
/etc/named.conf:2: missing ';' before '}'
[FAILED]
service named start
Results in:-
Starting named:
Error in named configuration:
/etc/named.conf:2: missing ';' before '}'
[FAILED]
The thing is, even if named.conf
contains no syntax errors or even if the file doesn't exist at all, I'm still getting this error preventing me from starting the service.
Currently trying with a named.conf
containing the following:-
options {
listen-on port 53 { 127.0.0.1; };
};
And checking the syntax of named.conf
using
named-checkconf /etc/named.conf
Results in no errors. Yet when starting the service, I still get the above error.
I can't see any other errors in the logs relating to this and don't really know where to get to the bottom of this. Any ideas?
(Even reverting back to the named.conf
file that was in place before I stopped the service returns the same error now and this was previously running fine).
Contents on init.d/named
can be seen at this pastebin.
CentOS 6.4 - Linux version 2.6.32-358.6.2.el6.x86_64 (mockbuild@c6b8.bsys.dev.centos.org) (gcc version 4.4.7 20120313 (Red Hat 4.4.7-3) (GCC) ) #1 SMP Thu May 16 20:59:36 UTC 2013
Update
bash -x /etc/init.d/named start
Snippet from results possibly of relevance?
+ echo 'Error in named configuration:'
Error in named configuration:
+ echo '/etc/named.conf:2: missing '\'';'\'' before '\''}'\'''
/etc/named.conf:2: missing ';' before '}'
+ failure
+ local rc=0
+ '[' color '!=' verbose -a -z '' ']'
+ echo_failure
+ '[' color = color ']'
+ echo -en '\033[60G'
+ echo -n '['
[+ '[' color = color ']'
+ echo -en '\033[0;31m'
+ echo -n FAILED
FAILED+ '[' color = color ']'
+ echo -en '\033[0;39m'
+ echo -n ']'
]+ echo -ne '\r'
+ return 1
+ '[' -x /bin/plymouth ']'
+ /bin/plymouth --details
+ return 0
+ echo
/etc/init.d/named
? the errors probably come from there – Kiwy Mar 11 '14 at 11:19/etc/named.conf
file? (I've run anamed-checkconfig
on/etc/init.d/named
as well but nothing flagged that would prevent service from starting). Thanks. – zigojacko Mar 11 '14 at 11:24named-checkconf
as it is not anamed
config file. – Anthon Mar 11 '14 at 11:31/etc/init.d/named
please? – zigojacko Mar 11 '14 at 11:39