SOURCES: dhcdbd.init - add try-restart/force-reload
glen
glen at pld-linux.org
Sun Apr 27 03:42:18 CEST 2008
Author: glen Date: Sun Apr 27 01:42:18 2008 GMT
Module: SOURCES Tag: HEAD
---- Log message:
- add try-restart/force-reload
---- Files affected:
SOURCES:
dhcdbd.init (1.5 -> 1.6)
---- Diffs:
================================================================
Index: SOURCES/dhcdbd.init
diff -u SOURCES/dhcdbd.init:1.5 SOURCES/dhcdbd.init:1.6
--- SOURCES/dhcdbd.init:1.5 Sun Apr 27 03:40:38 2008
+++ SOURCES/dhcdbd.init Sun Apr 27 03:42:13 2008
@@ -78,6 +78,16 @@
fi
}
+condrestart() {
+ if [ -f /var/lock/subsys/dhcdbd ]; then
+ stop
+ start
+ else
+ msg_not_running dhcdbd
+ RETVAL=$1
+ fi
+}
+
RETVAL=0
# See how we were called.
case "$1" in
@@ -91,6 +101,12 @@
stop
start
;;
+ try-restart)
+ condrestart 0
+ ;;
+ force-reload)
+ condrestart 7
+ ;;
status)
status dhcdbd
if [ $? -eq 0 ]; then
@@ -112,7 +128,7 @@
fi
;;
*)
- msg_usage "$0 {start|stop|restart|status}"
+ msg_usage "$0 {start|stop|restart|try-restart|force-reload|status}"
exit 3
;;
esac
================================================================
---- CVS-web:
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/SOURCES/dhcdbd.init?r1=1.5&r2=1.6&f=u
More information about the pld-cvs-commit
mailing list