Bind9 configured to start at boot, has to be started manually

Posted by antik on Super User See other posts from Super User or by antik
Published on 2009-12-16T23:56:42Z Indexed on 2010/04/12 2:53 UTC
Read the original article Hit count: 628

Filed under:
|
|

I've configured bind9 on my system and it works great when it runs.

It's currently configured to be run at runlevel 2 by setting:

$ sudo update-rc.d bind9 enable 2

This appears to have done its work:

$ tree -f /etc/rc?.d | grep -e ".*bind9$"
|-- /etc/rc0.d/K85bind9 -> ../init.d/bind9
|-- /etc/rc2.d/S15bind9 -> ../init.d/bind9
|-- /etc/rc3.d/S15bind9 -> ../init.d/bind9
|-- /etc/rc4.d/S15bind9 -> ../init.d/bind9
|-- /etc/rc5.d/S15bind9 -> ../init.d/bind9
|-- /etc/rc6.d/K85bind9 -> ../init.d/bind9

Booting the system, I believe I am at runlevel 2:

$ runlevel
N 2

Given the above configuration, when the system is rebooted, bind does not come up. Only on occasion, for some reason, can I resolve hostnames immediately after startup. Far more often than not however, I cannot.

I can interrogate the service's status:

$ sudo /etc/init.d/bind9 status
* could not access PID file for bind9

When the service doesn't start, I can start it successfully via a terminal by issuing

$ sudo /etc/init.d/bind9 start

And it works great from then on.

Loopback configuration:

$ ifconfig lo
lo        Link encap:Local Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:1872 errors:0 dropped:0 overruns:0 frame:0
          TX packets:1872 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0 
          RX bytes:220205 (220.2 KB)  TX bytes:220205 (220.2 KB)

Do I have my startup misconfigured? (I'm used to Gentoo so Ubuntu's model is still a little new to me) I'm not seeing any log indication of a failed attempt to start at boot in syslog. Is there someplace else I should be looking?

What else should I look into to get bind working at startup?

© Super User or respective owner

Related posts about ubuntu-9.10

Related posts about bind