#!/bin/sh # fcron # Source functions library source /etc/rc.d/init.d/functions log_script_name "$0 $*" DAEMON=/usr/sbin/fcron DAEMON_DESC="fcron daemon" DAEMON_OPTS="-b -c /etc/fcron/fcron.conf" fcron_start() { /etc/fcron/configure loadproc ${DAEMON} ${DAEMON_OPTS} } # See how we were called. case "$1" in start) cmd_run_log_box_warn "${DAEMON_DESC} start" fcron_start ;; stop) cmd_run_log_box_warn "${DAEMON_DESC} stop" killproc ${DAEMON} ;; reload) cmd_run_log_box_warn "${DAEMON_DESC} reload" reloadproc ${DAEMON} ;; restart) $0 stop sleep 1 $0 start ;; status) statusproc ${DAEMON} ;; *) echo "Usage: $0 {start|stop|reload|restart|status}" exit ${EXIT_CODE_FAILURE} ;; esac exit $?