[lug] Locking mail spools

Tkil tkil at scrye.com
Wed Nov 14 19:49:18 MST 2001


>>>>> "Ken" == Ken Kinder <ken at kenkinder.com> writes:

Ken> Does anyone have some suggestions? The general thing I'm doing
Ken> here is writing a program that splits out mail from one spool
Ken> into many.

any particular reason why `procmail' won't do the trick?  unless
you're doing this for the fun of reinventing the wheel?

failing that, using `movemail' to copy the original file to a secure
temporary location might do the trick.

the problem is that there are at least three different locking
mechanisms used for this sort of thing; adding a (not-uncommon)
NFS-mounted mail spool on top of it just spreads the joy.

doing a quick search for "mail spool locking file" on google returns
lots of tricks.

it might also be advantageous to look at the source of all the
programs deliving to, and retrieving mail from, these files.  this
might explain which method they're using to do the locking.

t.



More information about the LUG mailing list