[pkg-fetchmail-maint] Bug#230615: discussion of pidfile writing incorrect

Jeremy S Bygott jeremy at jsbygott.fsnet.co.uk
Wed Oct 5 01:58:10 UTC 2005


On Tue, 9 Mar 2004 Graham Wilson <bob at decoy.wox.org> wrote

> I have learned the hard way now why fetchmail uses a non-standard
> pidfile format. It writes out only the PID if the process is running
> in the foreground, but writes out two if the process is running in
> the background.


This is not the whole story, so I'm contributing in the hope that it
will help anyone searching these bug reports.  (It would have helped
me, for instance!)

The second number is not a PID at all; it is the polling interval
specified in the config file fetchmail was started with, typically
/etc/fetchmailrc.  The line will look like this:
       set daemon 300

You can verify this (without reading source code!) by changing the
number and starting fetchmail again.

If you comment out that line, fetchmail will poll its mailboxes only
once (without becoming a daemon) and will write only its PID to the
pidfile.





More information about the pkg-fetchmail-maint mailing list