procmail
[Top] [All Lists]

Re: corrupted mboxes

2002-05-06 16:44:05
Hi

On Tuesday, 7. May 2002 00:21, Professional Software Engineering 
wrote:
At 00:06 2002-05-07 +0200, Axel Heinrici did say:
It is me again. For some reason procmail produces corrupted
mboxes.

Yea, that sort of happens when the author of the script ignores
the need to LOCK mailboxes.  Procmail does what you tell it to,
and in this case, you're saying "write to this file, whenever, I
don't care".

It took this from the examples delivered with procmail. And i did 
not thought of this beeing buggy in this way. 

 From 'man procmailrc':
By using any number of recipes you can presort your mail
extremely straightforward into several mailfolders.   Bear  in
 mind  though that  the  mail  can  arrive concurrently in
these mailfolders (if several procmail programs happen to run 
at  the  same  time,  not unlikely  if  a  lot of mail
arrives).  To make sure this does not result in a mess, proper
use of lockfiles is highly recommended.

and:
Local lockfile
  If  you put a second (trailing) ':' on the first recipe
line, then procmail will use a locallockfile (for this recipe
only).  You can optionally specify the locallockfile to use;
if you don't however, procmail will use the destination
filename (or the  filename  fol- lowing the first '>>') and
will append $LOCKEXT to it.

I tried to change it in the following way:

---------.procmailrc----------------------
PATH=$HOME/bin:/usr/bin:/usr/ucb:/bin:/usr/local/bin:.
MAILDIR=$HOME/Mail      # You'd better make sure it exists
DEFAULT=$MAILDIR/mbox
LOGFILE=$MAILDIR/from
#LOCKFILE=$HOME/.lockmail

:0 :                            # Anything from thf
* ^To.*physik*
institutsmail                   # Institusmails einsortieren
--------------------------------------------

If I understand right this should cause procmail to use 
$MAILDIR/institutsmail.lock as local lockfile for this mbox. I 
already tried this recently and I tried it again a minute ago. But 
~/Mail/institutsmail still messes up (of course I deleted it 
before).
Can you give a little more precise hint how to set this up? I am 
not reluctant in reading manpages. But at the moment I do not 
understand why this doesn't work or how to set up the locking 
correctly.

greetings 
        Axel
_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail

<Prev in Thread] Current Thread [Next in Thread>