[Dovecot] Recieving e-mail is not updating quota
Hello again.
When I send e-mail locally from userX@mydomain to userY@mydomain the quota in userY@mydomain isn't updated with the new message, but the message arrives fine. It's not a userX problem, because it's equal if it's userY sending userX. When I save an message, the quota is updated. Or when the userX sends the e-mail, his quota is updated too. The problem is that the quota don't update when a new message arrives. What could it be?
Now I empty the mailbox of the userY, and the maildirsize is like this:
16777216S 0 0 1151862 1 2837616 1 2838683 1 5674797 2 -5674797 -2 -5674797 -2 1151862 1 -1151862 -1 -1151862 -1
The user quota from ldap is 16MB. In the user dir, the size is 452K
# du -kh . --max-depth=0 452K .
Now, I send an e-mail about 900k from userX to userY, and the quota display still 0M, but the user dir is 1,6M
# du -kh . --max-depth=0 1,6M .
My confs/logs
# /usr/local/dovecot/sbin/dovecot -n # 1.1.1: /usr/local/dovecot/etc/dovecot.conf log_path: /var/log/dovecot.log info_log_path: /var/log/dovecot-info.log ssl_disable: yes disable_plaintext_auth: no login_dir: /usr/local/dovecot/var/run/dovecot/login login_executable: /usr/local/dovecot/libexec/dovecot/imap-login valid_chroot_dirs: /home/vmail/domains verbose_proctitle: yes first_valid_uid: 200 last_valid_uid: 200 first_valid_gid: 200 last_valid_gid: 200 mail_privileged_group: vmail mail_uid: 200 mail_gid: 200 mail_location: maildir:/home/vmail/domains/%d/%n mail_debug: yes mail_plugins: quota imap_quota auth default: user: dovecot-auth passdb: driver: ldap args: /usr/local/dovecot/etc/dovecot-ldap.conf userdb: driver: ldap args: /usr/local/dovecot/etc/dovecot-ldap.conf plugin: quota_rule: *:storage=1G quota_rule2: Trash:storage=10%% quota_rule3: Lixeira:storage=10%% quota_rule4: Spam:storage=10%% quota: maildir
# grep -v '^ *\(#.*\)\?$' /usr/local/dovecot/etc/dovecot-ldap.conf hosts = localhost dn = cn=dovecot,dc=xxxxxx,dc=ce,dc=gov,dc=br dnpass = xxxxx ldap_version = 3 base = o=mail, dc=xxxxxx, dc=ce, dc=gov, dc=br deref = never scope = subtree user_attrs = homeDirectory=home,quota=quota_rule=*:storage=%$M user_filter = (&(objectClass=JammMailAccount)(mail=%u)(accountActive=TRUE)(delete=FALSE)) pass_attrs = userPassword=password pass_filter = (&(objectClass=JammMailAccount)(mail=%u)(accountActive=TRUE)(delete=FALSE))
# tail /var/log/mail.log dovecot: Jul 25 14:05:00 Info: IMAP(userY@xxxxxx.ce.gov.br): Loading modules from directory: /usr/local/dovecot/lib/dovecot/imap dovecot: Jul 25 14:05:00 Info: IMAP(userY@xxxxxx.ce.gov.br): Module loaded: /usr/local/dovecot/lib/dovecot/imap/lib10_quota_plugin.so dovecot: Jul 25 14:05:00 Info: IMAP(userY@xxxxxx.ce.gov.br): Module loaded: /usr/local/dovecot/lib/dovecot/imap/lib11_imap_quota_plugin.so dovecot: Jul 25 14:05:00 Info: IMAP(userY@xxxxxx.ce.gov.br): Effective uid=200, gid=200, home=/home/vmail/domains dovecot: Jul 25 14:05:00 Info: IMAP(userY@xxxxxx.ce.gov.br): Quota root: name= backend=maildir args= dovecot: Jul 25 14:05:00 Info: IMAP(userY@xxxxxx.ce.gov.br): Quota rule: root= mailbox=* bytes=16777216 (0%) messages=0 (0%) dovecot: Jul 25 14:05:00 Info: IMAP(userY@xxxxxx.ce.gov.br): Quota rule: root= mailbox=Trash bytes=1677721 (10%) messages=0 (0%) dovecot: Jul 25 14:05:00 Info: IMAP(userY@xxxxxx.ce.gov.br): Quota rule: root= mailbox=Lixeira bytes=1677721 (10%) messages=0 (0%) dovecot: Jul 25 14:05:00 Info: IMAP(userY@xxxxxx.ce.gov.br): Quota rule: root= mailbox=Spam bytes=1677721 (10%) messages=0 (0%) dovecot: Jul 25 14:05:00 Info: IMAP(userY@xxxxxx.ce.gov.br): maildir: data=/home/vmail/domains/xxxxxx.ce.gov.br/rodrigo dovecot: Jul 25 14:05:00 Info: IMAP(userY@xxxxxx.ce.gov.br): maildir++: root=/home/vmail/domains/xxxxxx.ce.gov.br/rodrigo, index=, control=, inbox=/home/vmail/domains/xxxxxx.ce.gov.br/rodrigo
Regards, Rodrigo.
-- M. Rodrigo Monteiro falecom@rodrigomonteiro.net "Free as in Freedom, not free as in free beer" Linux User # 403730
2008/7/25 M. Rodrigo Monteiro falecom@rodrigomonteiro.net:
Now I empty the mailbox of the userY, and the maildirsize is like this:
16777216S 0 0 1151862 1 2837616 1 2838683 1 5674797 2 -5674797 -2 -5674797 -2 1151862 1 -1151862 -1 -1151862 -1
The user quota from ldap is 16MB. In the user dir, the size is 452K
# du -kh . --max-depth=0 452K .
Now, I send an e-mail about 900k from userX to userY, and the quota display still 0M, but the user dir is 1,6M
# cat maildirsize 16777216S 0 0
# du -kh . --max-depth=0 1,6M .
-- M. Rodrigo Monteiro falecom@rodrigomonteiro.net "Free as in Freedom, not free as in free beer" Linux User # 403730
On Jul 25, 2008, at 1:27 PM, M. Rodrigo Monteiro wrote:
When I send e-mail locally from userX@mydomain to userY@mydomain the quota in userY@mydomain isn't updated with the new message, but the message arrives fine. It's not a userX problem, because it's equal if it's userY sending userX. When I save an message, the quota is updated. Or when the userX sends the e-mail, his quota is updated too. The problem is that the quota don't update when a new message arrives. What could it be?
How do you deliver the new messages? Are you using Dovecot's deliver
or your MTA's delivery agent? Sounds like the problem is with that
configuration.
participants (2)
-
M. Rodrigo Monteiro
-
Timo Sirainen