From: Wietse Venema (no email)
Date: Thu Aug 16 2007 - 16:58:13 EDT
Gregory K. Ruiz-Ade:
> This may seem like an odd request, but would there be a way for me to
> have postfix automatically do the equivalent of a "postsuper -h
> <queue_id>" on any message that's larger than a certain size?
>
> I'm trying to debug a mail server problem (the ltmp daemon is
> crashing on large messages), but I don't want to stop up other mail
> in the process.
>
> This is a very temporary problem, but it's a pain to keep looking
> through mailq output and picking out queue ids of large messages to
> manually hold. :)
Use the example Postfix greylist script, and instead of
greylisting, modify it to reply with HOLD for mail with
a size value > 15MB.
sub smtpd_access_policy {
if ($attr{"size"} > 15728640) {
return "hold";
} else {
return "dunno";
}
}
http://www.postfix.org/SMTPD_POLICY_README.html
Wietse
|
|
|