Bind/named won't start

modem

Verified User
Joined
Apr 7, 2004
Messages
396
I made an IP change to the server this weekend and followed the standard instructions on the DA website for doing this. All is well and the DA control panel reflects the new IP addresses and changes.

But when I was checking everything over, I noticed Bind/named was not running. I tried starting it in the DA panel but it wouldn't start. So I tried going to console and doing a "service named stop" and then a "service named start" but those didn't work either. The process list does not show named running. When I checked the system log file... this is what it showed.

Any Ideas???

Oct 26 12:52:34 stargatesg1 named[23992]: starting BIND 9.2.1 -u named
Oct 26 12:52:34 stargatesg1 named[23992]: using 1 CPU
Oct 26 12:52:34 stargatesg1 named: named startup succeeded
Oct 26 12:53:00 stargatesg1 named[24052]: starting BIND 9.2.1 -u named
Oct 26 12:53:00 stargatesg1 named[24052]: using 1 CPU
Oct 26 12:53:00 stargatesg1 named: named startup succeeded
Oct 26 12:53:14 stargatesg1 named: named shutdown failed
Oct 26 12:53:16 stargatesg1 named[24077]: starting BIND 9.2.1 -u named
Oct 26 12:53:16 stargatesg1 named[24077]: using 1 CPU
Oct 26 12:53:16 stargatesg1 named: named startup succeeded
Oct 26 12:54:01 stargatesg1 named[24101]: starting BIND 9.2.1 -u named
Oct 26 12:54:01 stargatesg1 named[24101]: using 1 CPU
Oct 26 12:54:01 stargatesg1 named: named startup succeeded
Oct 26 12:54:14 stargatesg1 named: named shutdown failed
Oct 26 12:54:16 stargatesg1 named[24131]: starting BIND 9.2.1 -u named
Oct 26 12:54:16 stargatesg1 named[24131]: using 1 CPU
Oct 26 12:54:16 stargatesg1 named: named startup succeeded
 
BIND is shutting down without writing a message just after it's starting.

Try starting BIND from the command line (you can read /etc/rc.d/init.d/named to figure out the correct syntax) to see what error messages you get.

Jeff
 
This is the following from the named startup file. I manually tried to start bind as this does as well as services named start. But nothing it still starts and stops. I've been checking log files to see if there is an error but I don't see anything other than bind starting and stopping.

Any ideas??

Mind you this worked fully before the IP change.



#!/bin/bash
#
# named This shell script takes care of starting and stopping
# named (BIND DNS server).
#
# chkconfig: - 55 45
# description: named (BIND) is a Domain Name Server (DNS) \
# that is used to resolve host names to IP addresses.
# probe: true

# Source function library.
. /etc/rc.d/init.d/functions

# Source networking configuration.
. /etc/sysconfig/network

RETVAL=0
prog="named"

# Check that networking is up.
[ "${NETWORKING}" = "no" ] && exit 0

[ -r /etc/sysconfig/named ] && . /etc/sysconfig/named

[ -x /usr/sbin/named ] || exit 0

[ -r ${ROOTDIR}/etc/named.conf ] || exit 0


start() {
# Start daemons.
if [ -n "`/sbin/pidof named`" ]; then
echo -n $"$prog: already running"
return 1
fi
echo -n $"Starting $prog: "
if [ -n "${ROOTDIR}" -a "x${ROOTDIR}" != "x/" ]; then
OPTIONS="${OPTIONS} -t ${ROOTDIR}"
fi
daemon /usr/sbin/named -u named ${OPTIONS}
RETVAL=$?
[ $RETVAL -eq 0 ] && touch /var/lock/subsys/named
return $RETVAL
}
stop() {
# Stop daemons.
echo -n $"Stopping $prog: "
/usr/sbin/rndc stop
RETVAL=$?
[ $RETVAL -eq 0 ] && rm -f /var/lock/subsys/named || {
killproc named
RETVAL=$?
[ $RETVAL -eq 0 ] && rm -f /var/lock/subsys/named
}
echo
return $RETVAL
}
rhstatus() {
/usr/sbin/rndc status
return $?
}
restart() {
stop
# wait a couple of seconds for the named to finish closing down
sleep 2
start
}
reload() {
echo -n $"Reloading $prog: "
/usr/sbin/rndc reload >/dev/null 2>&1 || /usr/bin/killall -HUP `/sbin/pidof -o %PPID named`
[ "$?" -eq 0 ] && success $"$prog reload" || failure $"$prog reload"
echo
return $?
}
probe() {
# named knows how to reload intelligently; we don't want linuxconf
# to offer to restart every time
/usr/sbin/rndc reload >/dev/null 2>&1 || echo start
return $?
}

# See how we were called.
case "$1" in
start)
start
;;
stop)
stop
;;
status)
rhstatus
;;
restart)
restart
;;
condrestart)
[ -e /var/lock/subsys/named ] && restart
;;
reload)
reload
;;
probe)
probe
;;
*)
echo $"Usage: $0 {start|stop|status|restart|condrestart|reload|probe}"
exit 1
esac

exit $?
 
Have you tried (from the command line as root):
/usr/sbin/named -u named

If so, do you get any messages in return?

If not, when you posted the error messages, did you leave out any?

When I start named it gives me a lot of log lines, and I can often use those to see problems.

Which OS are you running?

Jeff
 
I'm running RedHat 9. It doesn't give me any errors, in fact here is a copy from the terminal session:


Last login: Tue Oct 26 13:19:12 2004 from 170-215-151-151.br1.rmn.wv.frontiernet.net
[root@stargatesg1 root]# /usr/sbin/named -u named
[root@stargatesg1 root]#

Doing a ps ux command does not show named in the services as running.
 
By chance... when I downloaded and ran ipswap.sh as root:root inside of /root... would that have impacted the file permissions of /etc/named.conf and the /var/named/*.db's?? Would that be the cause of BIND not starting?

Also when I try to stop the process, it tells me that it 'FAILED' in stopping the process which I assume because there is no process running.
 
modem said:
By chance... when I downloaded and ran ipswap.sh as root:root inside of /root... would that have impacted the file permissions of /etc/named.conf and the /var/named/*.db's??
Don't know.
Would that be the cause of BIND not starting?
Bind could exit immediately after starting if it couldn't read it's configuration. But it should leave something in /var/log/messages.

Likewise if it's suid root and then for some reason cant' change to the user it's supposed to run at, perhaps because the user doesn't exist.

This sounds like a good question for the bind users mailing list or the bind newsgroup.
Also when I try to stop the process, it tells me that it 'FAILED' in stopping the process which I assume because there is no process running.
That is correct.

Jeff
 
Does DA have a copy of the Bind 9.2.1-16 and BindUtils 9.2.1-16 because I'm tempted to reinstall BIND on this server and see if that fixes it. If I gotta redo a few zones, I'll live.
 
I found the original RedHat9 RPM's... used webmin to reinstall/overwriting binary files and viola... it worked.

*heartattack avoided*

Thanks for the help you did and always do provide. :)
 
You're welcome. Be sure to check for updates at the Fedora Legacy Project.

Jeff
 
Is it adviseable to use Fedora based RPM's for Redhat9? I.E. Bind updates, PHP updates, etc? I always thought that using Fedora updates were not compatible with RedHat... or is that just RedHat saying they won't support squat for RedHat?
 
Nope. Fedora Legacy Project offers updates for RHL9 RPMs which have security issues.

Find them here.

Jeff
 
Is that for files ONLY listed on the fedora legacy project or do newer RPM's found on fedora's main page also work as 'upgrades' for current RH9 rpms as well?
 
Fedora and the Fedora Legacy project are completely separate.

Fedora is a new OS and tring to use Fedora RPMs to update RHL9 could cause your system to break.

Jeff
 
Thanks for the clarification, thats what I thought they were but wasn't sure.
 
Back
Top