- initscript LSB related fixes (#523435)

This commit is contained in:
Adam Tkac 2010-01-27 17:12:19 +00:00
parent b51a1f40e4
commit 13e55cd35c
2 changed files with 14 additions and 8 deletions

View File

@ -20,7 +20,7 @@ Summary: The Berkeley Internet Name Domain (BIND) DNS (Domain Name System) serv
Name: bind Name: bind
License: ISC License: ISC
Version: 9.7.0 Version: 9.7.0
Release: 0.11.%{PREVER}%{?dist} Release: 0.12.%{PREVER}%{?dist}
Epoch: 32 Epoch: 32
Url: http://www.isc.org/products/BIND/ Url: http://www.isc.org/products/BIND/
Buildroot:%{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) Buildroot:%{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
@ -621,6 +621,9 @@ rm -rf ${RPM_BUILD_ROOT}
%endif %endif
%changelog %changelog
* Wed Jan 27 2010 Adam Tkac <atkac redhat com> 32:9.7.0-0.12.rc1
- initscript LSB related fixes (#523435)
* Wed Jan 27 2010 Adam Tkac <atkac redhat com> 32:9.7.0-0.11.rc1 * Wed Jan 27 2010 Adam Tkac <atkac redhat com> 32:9.7.0-0.11.rc1
- revert the "DEBUG" feature (#510283), it causes too many problems (#545128) - revert the "DEBUG" feature (#510283), it causes too many problems (#545128)

View File

@ -92,6 +92,8 @@ umount_chroot_conf()
# Check if all what named needs running # Check if all what named needs running
start() start()
{ {
[ "$EUID" != "0" ] && exit 4
# Source networking configuration. # Source networking configuration.
[ -r /etc/sysconfig/network ] && . /etc/sysconfig/network [ -r /etc/sysconfig/network ] && . /etc/sysconfig/network
@ -123,9 +125,9 @@ start()
echo -n $"Starting named: " echo -n $"Starting named: "
if [ -n "`/sbin/pidof -o %PPID "$named"`" ]; then if [ -n "`/sbin/pidof -o %PPID "$named"`" ]; then
echo -n $"named: already running" echo -n $"named: already running"
failure success
echo echo
exit 1; exit 0;
fi; fi;
ckcf_options='-z'; # enable named-checkzone for each zone (9.3.1+) ! ckcf_options='-z'; # enable named-checkzone for each zone (9.3.1+) !
@ -175,6 +177,8 @@ start()
} }
stop() { stop() {
[ "$EUID" != "0" ] && exit 4
# Stop daemons. # Stop daemons.
echo -n $"Stopping named: " echo -n $"Stopping named: "
[ -x /usr/sbin/rndc ] && /usr/sbin/rndc stop >/dev/null 2>&1; [ -x /usr/sbin/rndc ] && /usr/sbin/rndc stop >/dev/null 2>&1;
@ -223,6 +227,8 @@ restart() {
start start
} }
reload() { reload() {
[ "$EUID" != "0" ] && exit
echo -n $"Reloading "$named": " echo -n $"Reloading "$named": "
p=`/sbin/pidof -o %PPID "$named"` p=`/sbin/pidof -o %PPID "$named"`
RETVAL=$? RETVAL=$?
@ -250,11 +256,7 @@ case "$1" in
restart) restart)
restart restart
;; ;;
condrestart) condrestart|try-restart)
echo "condrestart option is obsolete. Use try-restart instead"
if [ -e /var/lock/subsys/named ]; then restart; fi
;;
try-restart)
if [ -e /var/lock/subsys/named ]; then restart; fi if [ -e /var/lock/subsys/named ]; then restart; fi
;; ;;
reload) reload)
@ -265,6 +267,7 @@ case "$1" in
;; ;;
*) *)
echo $"Usage: $0 {start|stop|status|restart|try-restart|reload|force-reload}" echo $"Usage: $0 {start|stop|status|restart|try-restart|reload|force-reload}"
[ "x$1" = "x" ] && exit 0
exit 3 exit 3
esac esac