[vox-tech] Strange server behavior

Jeff Newmiller vox-tech@lists.lugod.org
Wed, 23 Apr 2003 14:34:44 -0700 (PDT)


On Wed, 23 Apr 2003, Richard Crawford wrote:

> I have a script in /etc/init.d which starts up a service when the computer
> boots up.  It is also possible to start up the service manually by
> entering the appropriate command on the command line.
> 
> Now, when I start the service on the command line, it works just fine. 
> However, when I start up the computer (or try to start the services
> manually by running the init.d script from the command line), the services
> do not work. They show up as running when I do a ps -aux command, but they
> simply do not work.
> 
> How is this possible?

Different environments.  The most common environment variable that is
different between the command line and startup is PATH, but there are
other ones as well that depend on the commands you are invoking.
Always use full pathnames to your executables in init.d scripts.

---------------------------------------------------------------------------
Jeff Newmiller                        The     .....       .....  Go Live...
DCN:<jdnewmil@dcn.davis.ca.us>        Basics: ##.#.       ##.#.  Live Go...
                                      Live:   OO#.. Dead: OO#..  Playing
Research Engineer (Solar/Batteries            O.O#.       #.O#.  with
/Software/Embedded Controllers)               .OO#.       .OO#.  rocks...2k
---------------------------------------------------------------------------