Re: Linux Startup

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



tony.chamberlain@xxxxxxxxx wrote:
> 
> I have a program I want started at system startup time, and also
> monitored so if it dies it will be restarted.
> I see two options but problems with both:
> 
> 
> 1) Put it into /etc/inittab
> 
>      This would work, EXCEPT I need to do some stuff first.  I need to
> do a cd, and add some stuff to the
>       PATH and LD_LIBRARY_PATH.  And I can't do (as far as I can tell,
> as I tried):
> 
>         x:respawn:cd /root/inittab;
> LD_LIBRARY_PATH="$LD_LIBRARY_PATH:$PWD";./Vms
> 
>       I think you have to run from root
> 
> 
> 
> 2) Put into /etc/rc*.d
> 
>      Then I could do all the path setup, etc, but how do I get it to
> respawn if it somehow dies?
> 
> 
Try putting the entire sequence in quotes. I am not sure it will
work, but I know that if you don't, everything after the space is
passed to the first command as parameters. If that does not work,
put it in a script, and run the script. As long as the script does
not exit, it will be fine.

Mikkel
-- 

  Do not meddle in the affairs of dragons,
for thou art crunchy and taste good with Ketchup!

Attachment: signature.asc
Description: OpenPGP digital signature


[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux