On 10 Jan 2002 08:50:43 +0800, William wrote:

> Has anyone noticed problems with fetchmail going to sleep after a week
> or so?  Running fetchmail gives the "woken up" message, but no mail. 
> Stopping and restarting it and the next poll (its on a dialup with mail
> queued at the ISP, but is not consistant with link avaiability) picks up
> a **LOT** of mail.  I also suspect that prior to stopping altogether it
> picks up less and less mail each poll until nothing is collected.
> 
> BillK

I seem to recall fetchmail not being totally reliable when issuing the
command again when it's already running...  I solved this with the
following, avoiding issuing "fetchmail" altogether...

One of my remote users is on a dial-up and I set her up with this in her
crontab: 
* * * * * if [ -z "`/bin/ps --no-headers -j -C fetchmail`" ]; then
/usr/bin/fetchmail --fetchmailrc /home/<user>/.fetchmailrc; fi

Everything on one line... and it doesn't hurt to put these in the crontab
too:

SHELL=/bin/sh
MAILTO=""

And in the /home/<user>/.fetchmailrc:
# Configuration created Tue Aug 28 13:50:13 2001 by fetchmailconf
set syslog
set postmaster "<user>"
set bouncemail
set properties ""
set daemon 300

poll <mail_server>
 with proto POP3
       user '<user>' there with password '<passwd>' is <user> here
warnings 3600

Note the quotation marks (and lack of) around user/passwd fields.  The
"set daemon 300" polls every 5 minutes; adjust to taste (in seconds).

HTH,
Pierre

Want to buy your Pack or Services from MandrakeSoft? 
Go to http://www.mandrakestore.com

Reply via email to