Subject: Re: delivery when disk nearly full

From: Jason Haar <[email-masked]>
Date: Wed, 21 Sep 1994 16:16:31 GMT

Procmail is nice :-)

First off, if someone sent a 1M file to a /var/spool partition that was 0.5M
- procmail wouldn't even see it - sendmail wouldn't be able to write the
whole thing into /var/spool/mqueue - so the SMTP session would fail; sendmail
would delete the file, and the sending site would try again latter.

Assuming you had 1.5M free, then sendmail could receive the whole file into
mqueue, and THEN would pipe into procmail - which would try to write to
/var/spool/mail/usercode.

Procmail would fail, backtrack out the stuff it had done, and would tell
sendmail it failed - so sendmail wouldn't delete the file from mqueue - and
would try again latter.

I'm amazed to see that a lot of Unices still come with broken local mailers
that can't recover under these conditions - procmail can, and is another good
reason to use it instead of the default local mailer. It's a good test to do
on your system - I've known about this issue for years - but only noticed on
these systems at work last month!! [obviously a rare problem here - but
that's no excuse ;-) ]

Of course I'm assuming a BSD-ish type system here (i.e. /var/spool) - but the
general rule applies.

That's all a bit poorly written - but I hope you get the point! :-)

Cheers,

Jason
+------------------------------+------------------------------------------+
| Jason Haar, European SysAdmin   Phone: + 44 (256) 790111                |
| Motorola Cellular Subscriber      Fax: + 44 (256) 790519                |
| Basingstoke, Hampshire                                                  |
| RG21 1PL,  ENGLAND           Internet: [email-masked] |
+------------------------------+------------------------------------------+

---

From: [email-masked] (Stephen R. van den Berg)
Date: Wed, 21 Sep 1994 20:41:54 +0200

>sendmail it failed - so sendmail wouldn't delete the file from mqueue - and

That would be the case if procmail was started with the -t option and
if it falls off the end of the .procmailrc *and* it couldn't deliver to
$DEFAULT or $ORGMAIL.

Procmail never checks the amount of free space beforehand, it simply writes
until it gets an error.
Since v3.04, procmail also truncates the mailfile back to its former size
if an error occurred.

-- 
Sincerely,                                  [email-masked]
           Stephen R. van den Berg (AKA BuGless).

"Listen very carefully, I shall only say this once."