LFS Bootscripts

DJ Lucas dj at linuxfromscratch.org
Sun Aug 7 22:29:12 PDT 2005

DJ Lucas wrote:
> Archaic wrote:
>>Of course it increments. 
> $$ increments 3 times while running the script only once.   Maybe I've
> just lost myself again.
> BTW.  My recolection of -x was incorrect.  After reading the manpage of
> pidof, I realized my error. :-)  Reverse what I said.  -x is required to
> pick up the scripts, it was removed at one time and found to be broken
> so then '-o $$ -o $PPID' was added to getpids().
> -- DJ Lucas

Never mind.  $$ is not actually incrementing, but I don't know what
processes pidof is finding when running that script.  Creating a second
functions script with only statusproc and getpids using the same 'pidof
-o $$ -o $PPID -x "${1}"' gives the proper result.  It looks as if pidof
it's finding it's own PID but that can't be either because it does not
find itself in the second example.  I'm at a loss.  Will revisit after
some sleep.

-- DJ Lucas

More information about the lfs-dev mailing list