All:

This is my first attempt at maildirquota (maildirsize) support for 
vdelivermail.  It's not recommended for production at all, so just test..

Rather than rewrite vdelivermail to observe Mr. Sam's maildirquota 
mechanism (which is a better solution, but a LOT more work), I decided 
fork deliver_mail() and pass the message, the user's quota, and the path 
to the Maildir to deliverquota.  I don't know how much of an impact this 
will have on higher volume servers, but this seemed like a reasonable 
place to start.

Anyway, the patch is here: http://shupp.org/patches/deliverquota-
patch-1.gz
And here's an easy way to apply:

cd vpopmail-5.0
lynx --source http://shupp.org/patches/deliverquota-patch-1.gz | patch 
-p0
./configure --enable-deliverquota=y <options>
make ; make install-strip

After applying the patch, you'll find README.deliverquota.  It has 
details on what I did, and important info about it.  Buf for starters, 
you MUST have deliverquota installed in /usr/local/bin.  configure will 
fail otherwise.  More info in the readme...

The good news is that it uses quotas from vpopmail, and no .qmail file 
is necessary since it's called from vdelivermail.  Also, most of 
vdelivermail's functionality (exept quota usage) is intact.

CAVEAT:  In my tests with a 200KB (unreasonably small) quota, deleting 
mail manually (with rm) or via qmail-pop3d doesn't get me back under 
quota.  This is because the maildirsize only gets recalculated when it's 
either missing, or its file size is over 5k.  But if you are using a 
maildirquota aware pop program, like Sam's that ships with courier-imap 
(or courie-imap itself), this shouldn't be an issue.

Please report any experiences you have either to this list, or to me 
directly.

Enjoy!

Bill Shupp

Reply via email to