LFS Bootscripts

DJ Lucas dj at linuxfromscratch.org
Sun Aug 7 21:05:01 PDT 2005


Randy McMurchy wrote:

> 
> It reports that the daemon is running with such-and-such PID, but
> that PID really doesn't exist except at the moment the status was
> checked.

IIRC, in the past, we had used the -x switch to pidof and that was
removed in favor of '-o $PPID -o $$'.  The -x should definately be
removed as this would be broken with backround scripts (popbeforesmtp is
the only example I can come up with right off the top of my head.  It's
written in perl and would fail to show with -x).  Now both are used with
the LSB style pidofproc function.  Will test with all shells and get
back in a few moments regarding $$ and $PPID to see if that is possibly
the issue.  Randy what shell is linked to /bin/sh on your system?

Anyway, there is definately a bug if it's returning the PID of the
running script, but there is also a problem in your script as you should
be passing the full path of the binary to statusproc; Well, unless that
is a symlink in which case pidof will find the PIDs of the target.

-- DJ Lucas



More information about the lfs-dev mailing list