Skip to content

Instantly share code, notes, and snippets.

@micahlmartin
Created June 8, 2013 20:17
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save micahlmartin/5736429 to your computer and use it in GitHub Desktop.
Save micahlmartin/5736429 to your computer and use it in GitHub Desktop.
#!/bin/bash
#
# /etc/rc.d/init.d/
#
#
#
#
#
# Source function library.
. /etc/init.d/functions
start() {
echo -n "Starting : "
touch /var/lock/subsys/
return
}
stop() {
echo -n "Shutting down : "
rm -f /var/lock/subsys/
return
}
case "$1" in
start)
start
;;
stop)
stop
;;
status)
;;
restart)
stop
start
;;
reload)
tart)
[ -f /var/lock/subsys/ ] && restart || :
probe)
;;
*)
echo "Usage: {start|stop|status|reload|restart[|probe]"
exit 1
;;
esac
exit $?
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment