Changed files:
dhcp.init -> 1.16
exit 0
fi
+checkconfig() {
+ show "Checking %s configuration" DHCPD
+ out=`/usr/sbin/dhcpd -t 2>&1`; rc=$?
+ if [ $rc -gt 0 ]; then
+ fail
+ echo >&2 "$out"
+ else
+ ok
+ fi
+ return $rc
+}
+
start() {
# Check if the service is already running?
if [ ! -f /var/lock/subsys/dhcpd ]; then
# See how we were called.
case "$1" in
start)
+ checkconfig || exit 1
start
;;
stop)
stop
;;
restart)
+ checkconfig || exit 1
stop
start
;;
+ checkconfig)
+ checkconfig
+ ;;
status)
status dhcpd
exit $?
;;
*)
- msg_usage "$0 {start|stop|restart|status}"
+ msg_usage "$0 {start|stop|restart|checkconfig|status}"
exit 3
esac