[Dovecot] Problem with quota warning
Hi again,
my test environment is working now and finally I tried to implement my quota warning but it is not working. LDA says the mailbox is full even it is not (only 81% and that is why the quota warning is executed). Further I used :noenforcing in my script.
Apr 9 15:08:21 backend01 dovecot: lda(test@k-team.info): Debug: Namespace INBOX.: Using permissions from /var/mail/k-team.info/test/mdbox: mode=0700 gid=-1 Apr 9 15:08:21 backend01 dovecot: lda(test@k-team.info): Debug: Quota root: name=User quota backend=dict args=:file://mdbox/dovecot-quota:noenforcing Apr 9 15:08:21 backend01 dovecot: lda(test@k-team.info): Debug: Quota warning: bytes=0 (90%) messages=0 reverse=no command=quota-warning 90 raw mail user Apr 9 15:08:21 backend01 dovecot: lda(test@k-team.info): Debug: Quota warning: bytes=0 (75%) messages=0 reverse=no command=quota-warning 75 raw mail user Apr 9 15:08:21 backend01 dovecot: lda(test@k-team.info): Debug: dict quota: user=raw mail user, uri=file://mdbox/dovecot-quota:noenforcing, noenforcing=0 Apr 9 15:08:21 backend01 dovecot: lda(test@k-team.info): Debug: none: root=, index=, control=, inbox=, alt= Apr 9 15:08:21 backend01 dovecot: lda(test@k-team.info): Debug: Destination address: test@k-team.info (source: user@hostname) Apr 9 15:08:21 backend01 dovecot: lda(test@k-team.info): msgid=unspecified: save failed to INBOX: Quota exceeded (mailbox for user is full) Apr 9 15:08:21 backend01 dovecot: lda(test@k-team.info): msgid=unspecified: rejected: Quota exceeded (mailbox for user is full) Apr 9 15:08:21 backend01 dovecot: lda(test@k-team.info): msgid=: Return-Path missing, rejection reason: Quota exceeded (mailbox for user is full)
# 2.1.3: /usr/local/etc/dovecot/dovecot.conf # OS: Linux 2.6.32-5-amd64 x86_64 Debian 6.0.4 auth_debug = yes auth_debug_passwords = yes auth_verbose = yes listen = 172.17.99.96 mail_debug = yes mail_gid = vmail mail_home = /var/mail/%d/%n mail_location = mdbox:~/mdbox:INDEX=/var/indexes/%d/%n mail_plugins = quota mail_uid = vmail managesieve_notify_capability = mailto managesieve_sieve_capability = fileinto reject envelope encoded-character vacation subaddress comparator-i;ascii-numeric relational regex imap4flags copy include variables body enotify environment mailbox date ihave namespace { inbox = yes location = prefix = INBOX. separator = . type = private } passdb { args = /usr/local/etc/dovecot/dovecot-sql.conf.ext driver = sql } plugin { autocreate = INBOX.Sent autocreate2 = INBOX.Trash autocreate3 = INBOX.Drafts autocreate4 = INBOX.Spamverdacht autosubscribe = INBOX.Sent autosubscribe2 = INBOX.Trash autosubscribe3 = INBOX.Drafts autosubscribe4 = INBOX.Spamverdacht quota = dict:User quota::file:%h/mdbox/dovecot-quota quota_rule2 = INBOX.Trash:storage=+100M quota_warning = storage=90%% quota-warning 90 %u quota_warning2 = storage=75%% quota-warning 75 %u sieve = ~/.dovecot.sieve sieve_dir = ~/sieve sieve_global_path = /usr/local/etc/dovecot/sieve/default.sieve } protocols = imap pop3 lmtp sieve service auth { unix_listener auth-userdb { user = vmail } } service imap-login { service_count = 1 } service lmtp { inet_listener lmtp { address = 172.17.99.96 port = 24 } } service managesieve-login { inet_listener sieve { port = 4190 } service_count = 1 } service quota-warning { executable = script /usr/local/etc/dovecot/quota-warning.sh unix_listener quota-warning { user = vmail } user = vmail } ssl = required ssl_cert =
#!/bin/sh PERCENT=$1 USER=$2 cat << EOF | /usr/local/libexec/dovecot/dovecot-lda -d $USER -o "plugin/quota=dict:User quota::file:%h/mdbox/dovecot-quota:noenforcing" From: support@example.com Reply-To: support@example.com Subject: Speicherplatz Ihrer Mailbox
...
Hi,
I switched from dovecot-lda to lmtp for my quota warnings but there is something wrong with the parameters:
/usr/local/libexec/dovecot/lmtp -d $USER -o "plugin/quota=dict:User quota::file:%h/mdbox/dovecot-quota:noenforcing"
/usr/local/libexec/dovecot/lmtp: invalid option -- 'd'
/usr/local/libexec/dovecot/lmtp -r $USER -o "plugin/quota=dict:User quota::file:%h/mdbox/dovecot-quota:noenforcing"
/usr/local/libexec/dovecot/lmtp: invalid option -- 'r'
Both parameters are listed on http://wiki2.dovecot.org/LMTP. So is this my fault or wrong information on the page?
Patrick
On 10.4.2012, at 13.44, Patrick Westenberg wrote:
I switched from dovecot-lda to lmtp for my quota warnings but there is something wrong with the parameters:
/usr/local/libexec/dovecot/lmtp -d $USER -o "plugin/quota=dict:User quota::file:%h/mdbox/dovecot-quota:noenforcing"
This is not how to use LMTP. You need to tell your MTA to connect to it via UNIX socket or via TCP. You don't execute the LMTP.
Both parameters are listed on http://wiki2.dovecot.org/LMTP. So is this my fault or wrong information on the page?
It says "Compared to dovecot-lda parameters", so it's describing where dovecot-lda parameters are taken with LMTP. I guess it could be said in some clearer way, but I don't really know how.
Timo Sirainen schrieb:
On 10.4.2012, at 13.44, Patrick Westenberg wrote:
I switched from dovecot-lda to lmtp for my quota warnings but there is something wrong with the parameters:
/usr/local/libexec/dovecot/lmtp -d $USER -o "plugin/quota=dict:User quota::file:%h/mdbox/dovecot-quota:noenforcing"
This is not how to use LMTP. You need to tell your MTA to connect to it via UNIX socket or via TCP. You don't execute the LMTP.
There is no MTA installed on this system. This is the backend server. dovecot-lda doesn't work too, look at my first post with this subject.
participants (2)
-
Patrick Westenberg
-
Timo Sirainen