Hello,
On Wed, Sep 03, 2003 at 05:19:10PM -0400, Bill Nottingham wrote:
> Tobias Burnus (tobias.burnus at physik.fu-berlin.de) said:
> > If there is no pidfile no further checks shall be done.
This is ment for the pidofproc script as defined in
/lib/lsb/init-functions.
> > If a script really has no pidfile then it can use pidof (part of LSB) or
> > pkill/pgrep (not part of LSB).
This is ment for those /etc/init.d/* init scripts that need it.
> Maybe I missed part of your discussion, but how do you
> programmatically determine this case; do you just specifying
> this when calling pidofproc?
I mean that if /opt/foo/sbin/mydaemon has no pidfile, then I can do this
in the init script /etc/init.d/foo-mydaemon:
status)
# I know there is no pid file and thus I cannot use pidofproc
# let's use pidof instead
pidof -o $$ -o $PPID -o %PPID /opt/foo/sbin/mydaemon
;;
Tobias