Originally posted by: tech100
in /etc/rc.d/rc2.d
create links:
ln -s /path/to/your/script/yourappstartstopscript /etc/rc.d/rc2.d/S99theapp
ln -s /path/to/your/script/yourappstartstopscript /etc/rc.d/rc2.d/K99theapp
where the /path/to/your/script/yourappstartstopscript is construct as follows:
#--------------------------BEGIN---------------
{code}
case "$1" in
start)
here put your app startup commands /script ;;
stop)
here put your app stoping commands /script ;;
*)
$ECHO "Usage: $0 {start|stop}"
exit 1
;;
esac
#--------------------------END---------------