Click to See Complete Forum and Search --> : Writing a startup script


MPETNUCH
01-22-2001, 02:32 AM
I want to write a script that will load a program when the computer loads up. I think that I have to put it in /etc/init.d/. I am using Debian potato.

The programs is for uptimes.net called yaunc. It resides in /usr/sbin/yaunc and its config file in /etc/yaunc.conf

What would I need to put in /etc/init.d/ and where do I put a link to it in the rc.X stuff. Thanks in advance.

Strike
01-22-2001, 11:16 AM
Yes, it goes in /etc/init.d. Once you've got it written, go into /etc/rc2.d (unless you've changed the runlevel), and link it:

ln -s ../init.d/yaunc S99yaunc

That assumes you name your script yaunc, and you want to start it as one of the last things (chagne the number from 99 to put it earlier in the execution order)

Sterling
01-22-2001, 06:47 PM
The Linux System Administrator's Guide, I believe, explains how this kind of thing works. Grab it from http://www.linuxdoc.org and check it out. There's lots of useful information in both it and the Linux User's Guide.

------------------
-Sterling
"There is no Linuxnewbie.org cabal..."