- Copy the script from link [3] to your HDD and call it isostar_server
- Change line:
/path/to/command/to/start/new-service
to:/opt/csd/isostar/APACHE/bin/ccdc_apache start
and line:/path/to/command/to/stop/new-service
to:/opt/csd/isostar/APACHE/bin/ccdc_apache stop
- Remove following lines (from both start and stop subsection):
#Or to run it as some other user: /bin/su - username -c /path/to/command/to/start/new-service echo "."
- Change 'new-service' in 'echo -n' lines to 'isostar_server'.
- Now as a root copy isostar_server file into /etc/init.d/
- Again as a root invoke chkconfig and add isostar_server: /sbin/chkconfig --add isostar_server
Links
[1] http://linux.die.net/man/8/chkconfig[2] http://spiralbound.net/2006/11/15/controlling-services-with-chkconfig
[3] http://spiralbound.net/2007/07/23/example-linux-init-script
[4] http://wiki.linuxquestions.org/wiki/Update-rc.d
[5] http://www.annodex.net/cgi-bin/man/man2html?update-rc.d+8
No comments:
Post a Comment