#!/bin/sh # cups # Source functions library source /etc/rc.d/init.d/functions log_script_name "$0 $*" # See how we were called case "$1" in start) cmd_run_log_box_warn "CUPS start" loadproc cupsd ;; stop) cmd_run_log_box_warn "CUPS stop" killproc cupsd ;; reload) cmd_run_log_box_warn "CUPS reload" reloadproc cupsd ;; restart) $0 stop sleep 1 $0 start ;; status) statusproc cupsd ;; *) echo "Usage: $0 {reload|restart|start|status|stop}" exit ${EXIT_CODE_FAILURE} ;; esac exit $?