Univention Bugzilla – Bug 38474
Mail quota feature with Dovecot
Last modified: 2015-07-09 18:13:30 CEST
Use extended attributes in users/user. Can be read by Dovecot directly from LDAP.
*** Bug 38406 has been marked as a duplicate of this bug. ***
Commit: 60853 * Per-user quota configurable in UDM. * Stores quota as (int) MB in LDAP attribute univentionMailUserQuota from univentionMail, which is attached to all users. * Dovecot reads it directly from LDAP upon mailbox access. * Dovecot uses maildir++ backend: writes stats into ~/Maildir/maildirsize * Adds UCRVs mail/dovecot/quota/warning/subject and mail/dovecot/quota/warning/text/.* to configure warning mails if user gets over quota. Read/list quotas on the command line with: # doveadm quota get [-u <user>|-A]
(In reply to Daniel Tröder from comment #0) > Use extended attributes in users/user. Can be read by Dovecot directly from > LDAP. → made small text changes: r61754 | Bug #38474: updated translation in extended attribute → extended attribute is not removed if last dovecot app in UCS domain has been uninstalled → unjoin script should check that and remove ext attr if the last dovecot app is uninstalled → see ucs_isServiceUnused in developer guide → REOPEN root@slave22b:~# univention-ldapsearch -LLL uid=user1 univentionMailUserQuota mailPrimaryAddress dn: uid=user1,cn=users,dc=nstx,dc=local mailPrimaryAddress: mail1@nstx.local univentionMailUserQuota: 1234 root@slave22b:~# doveadm quota get -u mail1@nstx.local Quota name Type Value Limit % User quota STORAGE 0 1263616 0 User quota MESSAGE 0 - 0 1263616 == 1234 * 1024 → OK Functionality tested by ./40_dovecot_quota and ./41_dovecot_quota-status from ucs-test (and manually). → OK 4
(In reply to Daniel Tröder from comment Bug 38406 #0) > Trash folders should get a 110% quota, for clients that do move-to-trash > before deleting, so user don't get the dreaded "cannot delete message, > mailbox full" message. > > Currently we have Dovecot 2.1 in UCS 4.0. With Dovecot 2.2 we'd get the > "quota-status" policy service, that can tell Postfix that the users mailbox > is full. Currently it will produce backscatter. → works as described
> → extended attribute is not removed if last dovecot app in UCS domain has > been > uninstalled → unjoin script should check that and remove ext attr if the > last > dovecot app is uninstalled > → see ucs_isServiceUnused in developer guide > → REOPEN fixed in commit 61765
(In reply to Daniel Tröder from comment #5) > > → extended attribute is not removed if last dovecot app in UCS domain has > > been > > uninstalled → unjoin script should check that and remove ext attr if the > > last > > dovecot app is uninstalled > > → see ucs_isServiceUnused in developer guide > > → REOPEN > fixed in commit 61765 → OK, join script is executed and extended attribute is removed. → VERIFIED
<http://errata.univention.de/ucs/4.0/237.html>