I've been toying with bind (a DNS server, if you're unaware), and I've pretty much never run it until today. I got a couple of the zone files set up and wanted to test them. I did the following, and was successful:
# service named start
Starting named: [ OK ]
After a few failed DNS lookups, I checked to see if the process was running. It wasn't. I tried starting it again. It claimed success again, but the process was not running. I tried setting it to debug logging and checked the logs... I found no problems.
So, in an act of desparation, I decided to start the service manually by simply issuing the following command:
# /usr/sbin/named
It ran. I did a few DNS lookups, and it was working. I tried to stop the service afterward and got the following output:
# service named stop
Stopping named: [ OK ]
I checked, and it was still running. How strange! So, I started looking in the /etc/rc.d/init.d/named file and snooping. I found that the service was called with the following command:
daemon /usr/sbin/named -u named ${OPTIONS}
I added an echo in there to see what ${OPTIONS} evaluated to, and it was null. So, I checked the man page for named to find out what the -u switch was for. It sets the username. So, I tried starting it manually with named -u named since it had worked before when started manually. I checked, and it was not running. I tried issuing named -u root. It ran fine.
My next thought was that maybe I had a permission issue with the configuration files. Therefore, I changed all the zone files, the log file, and the named.conf file to 777. I get the same problem.
What should I try at this point?