[imp] Can I enable "Quota" function with my imap server ?

Ken Weaverling weave@hopi.dtcc.edu
Wed Nov 27 14:19:40 2002


Quoting EdwardSPL@ita.org.mo:

> I want to enable "Quota" function, but my imap server come from
> Redhat...

> So, is there a good solution for me to fix this problem ?

The imap server that comes with Redhat is uw-imap, which doesn't support imap
quotas and doesn't work well with hard disk quotas. 

If your mail server sits on a box where users have access to store files via
other non-imap means (example, via shell access or samba), then quotas become
more problematic. 

Redhat supports disk quotas but that introduces another problem, in that imap
won't report what the usage is.  Even if it did, file system quotas present
numerous problems for the imap client user. For example, if you hit your quota
limit, your first reaction is to delete messages. But once you delete, it either
moves the message to Trash (which fails, no space) or expunge it (which fails
since it copies the folder without deleted messages, and then deletes original
folder).

With all that in mind, I'm trying to think of a best way around this. Since my
horde server, imap server, and disk storage is all on one system, I don't need
to use imap to find a quota. So I was hoping to write an imp quota hook that
queried the file system quota for the user, then subtract some margin of safety,
then report that usage.  I was thinking more like 50% less than disk quota.

Still doesn't solve all the issues though. So you report 100% used, but it's
really 50% to allow for stuff to be shuffled around to get deleted. Then what?
People could ignore it, so there has to be a way to force user to manage quota.
Possibilities include hook into the send message routine and deny sending until
under quota, or force maintenance on logon to get messages down, etc, etc...

Not an easy issue! If you have a closed-box imap/mail system, it would probably
be easier to switch to courier imap.

The father of imap and author of uw-imap, Mark Crispin, has a lot to say about
this issue. Just use groups.google.com to search the comp.mail.imap group for
his name and the keyword quota and you should find those arguments easily!



More information about the imp mailing list