[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: running a script at startup
> > If you want to get fancy, you could create it's own start/stop script
> > like all the major services have, but the easiest thing is to add it
> > to /etc/rc.d/rc.local.
> This would allow me to have it start and stop with startup and shutdown,
> correct?
Not if you add it to /etc/rc.d/rc.local.
Yes, if you create it's own start/stop script.
> > Exactly? vi, pico, emacs, xemacs, xedit, nedit, gnome-edit, kedit, ...
> > (add it to the end of /etc/rc.d/rc.local ;)
> Hehe, I should have said, how do I write the script. But I dont think it
> would shutdown. I am attempting to get it to work like a network, ie. it
> starts at startup and ends at shutdown.
Personally I wouldn't write it from scratch, I'd copy one of the existing
start/stop scripts to a new name and modify it for the new service.
Once you have the script created (and tested by running it manually),
then you can add it to start at whatever runlevel(s) you like. See the
"chkconfig" command to list, add, delete, and change the runlevels it
gets started and stopped at.
--------------------------------------------
Bruce Smith bruce@armintl.com
System Administrator / Network Administrator
Armstrong International, Inc.
Three Rivers, Michigan 49093 USA
http://www.armstrong-intl.com/
--------------------------------------------