Bug#380459: [pkg-fetchmail-maint] Bug#380459: /etc/init.d/fetchmail awaken really doesn't anything

Héctor García hector at debian.org
Mon Jul 31 14:42:57 UTC 2006


El lun, 31-07-2006 a las 14:24 +0200, Riccardo Stagni escribió:
> On Mon, Jul 31, 2006 at 01:30:40PM +0200, Nico Golde wrote:
> > I thought about your solutions but here comes mine :)
> > From fetchmail(1):
> > Normally,  calling fetchmail with a daemon in the background sends a wake-up signal to the dae-
> > mon, forcing it to poll mailservers immediately.  (The wake-up signal is SIGHUP if fetchmail is
> > running  as  root, SIGUSR1 otherwise.)  The wake-up action also clears any 'wedged' flags indi-
> > cating that connections have wedged due to failed authentication or multiple timeouts.
> > 
> > So my fix here is to get the pid from the pid-file and send SIGUP (kill -1) to the
> > process. Works pretty well and imho is the sanest solution here.
> > What do you think?
> Very smarter! :)
> 
> I read the manpage a lot of times, but I ever found nothing, perhaps
> because I was looking for awake:
>  man fetchmail
>  /awake
>  Pattern not found  (press RETURN)
>  "mmmh... It isn't awakenable by hand??? queer..."
> :)
> 
> Just another question: why there are two pid in the pidfile? If I stop the
> daemon it correctly removes /var/run/fetchmail/fetchmail.pid, but when I
> restart it writes two numbers: the right pid (first row) and 300 (second
> row, that doesn't correspond to any process).
> 

The second number is not a pid number. Is another number that upstream
needs (don't remember at this moment what it is, sleep time?), and that
places it there.
That is the reason of why we use head -n1 on the init.d script.

Regards,

Héctor
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Esta parte del mensaje =?ISO-8859-1?Q?est=E1?= firmada
	digitalmente
Url : http://lists.alioth.debian.org/pipermail/pkg-fetchmail-maint/attachments/20060731/8d1c70b4/attachment.pgp


More information about the pkg-fetchmail-maint mailing list