On Tue, Aug 08, 2000 at 01:24:48AM -0400, Todd Finney wrote:
! Couldn't you just do something like this in the rc script
! to get the correct pid every time?
!
! `ps -C qmail-send | sed 's/^.\([0-9]*\).*/\1/' | tr -d
! [:space:]`
I think you probably meant ``^.*'' instead of ``^.''.
! [Note: There is probably a better way to do
! this. Suggestions are welcome.]
If I remember correctly, this does pretty much the same thing as
``pidof'', except I think the latter is faster.
Even faster, I believe, is to simply write qmail-send's pid to
/var/run/qmail.pid, as suggested in my previous post; then you don't
even have to search through all the processes, as ``ps'' and ``pidof''
have to.
---Chris K.
--
Chris, the Young One |_ If you can't afford a backup system, you can't
Auckland, New Zealand |_ afford to have important data on your computer.
http://cloud9.hedgee.com/ |_ ---Tracy R. Reed