[Dovecot] expire plugin no delete 1.2.1 / 1.2.2

Robert Schetterer robert at schetterer.org
Tue Aug 4 11:22:15 EEST 2009


Robert Schetterer schrieb:
> Timo Sirainen schrieb:
>> On Aug 3, 2009, at 3:52 AM, Robert Schetterer wrote:
>>
>>> /etc/crontab
>>> 45 9   * * *   root /usr/sbin/dovecot -c /etc/dovecot/dovecot.conf
>>> --exec-mail ext /usr/lib/dovecot/expire-tool.sh
>> Disable this for now and tomorrow just run the --test first manually,
>> save its output, then if it seemed ok run without --test.
>>
> 
> ok i will do
> /usr/sbin/dovecot -c /etc/dovecot/dovecot.conf
> --exec-mail ext /usr/lib/dovecot/expire-tool.sh --test tommorow
> and then
> /usr/sbin/dovecot -c /etc/dovecot/dovecot.conf --exec-mail ext
> /usr/lib/dovecot/expire-tool.sh
> 
> savin the outputs
> and additional looking in sql and imap savedate
> 
> manually after deletetion time
> 

Hi Timo, did that exactly in that row
as you see the mail didnt get deleted ( stays in filesystem, and is
shown to thunderbird )
but it expired in sql dict rightly but was not deleted

/usr/sbin/dovecot -c /etc/dovecot/dovecot.conf --exec-mail ext
/usr/lib/dovecot/expire-tool.sh --test
Info: Loading modules from directory: /usr/lib/dovecot/modules/imap
Info: Module loaded: /usr/lib/dovecot/modules/imap/lib01_acl_plugin.so
Info: Module loaded: /usr/lib/dovecot/modules/imap/lib10_quota_plugin.so
Info: Module loaded:
/usr/lib/dovecot/modules/imap/lib20_autocreate_plugin.so
Info: Module loaded: /usr/lib/dovecot/modules/imap/lib20_expire_plugin.so
Info: Module loaded: /usr/lib/dovecot/modules/imap/lib20_fts_plugin.so
Info: Module loaded: /usr/lib/dovecot/modules/imap/lib20_virtual_plugin.so
Info: Module loaded: /usr/lib/dovecot/modules/imap/lib21_fts_squat_plugin.so
Info: Quota root: name= backend=dict args=:proxy::quotadict
Info: Quota warning: bytes=0 (95%) messages=0
command=/usr/local/bin/quota-warning.sh 95
Info: Quota warning: bytes=0 (80%) messages=0
command=/usr/local/bin/quota-warning.sh 80
Info: expire: pattern=Trash type=expunge secs=86400
Info: auth input:
home=/usr/local/virtual/schetterer.com/robert at schetterer.com/
Info: auth input: quota_rule=*:bytes=10240000
Info: auth input: quota_rule2=Trash:storage=50240
Info: auth input: quota_rule3=Sent:storage=50240
Info: auth input: quota_rule4=Drafts:storage=50240
Info: auth input: quota_rule5=Templates:storage=50240
Info: auth input: quota_rule6=Junk:storage=50240
Info: auth input:
mail=maildir:/usr/local/virtual/schetterer.com/robert at schetterer.com/
Info: auth input: namespace_1_inbox=yes
Info: auth input: uid=1001
Info: auth input: gid=1001
Info: dict quota: user=robert at schetterer.com, uri=proxy::quotadict,
noenforcing=0
Info: Namespace: type=private, prefix=, sep=/, inbox=yes, hidden=no,
list=yes, subscriptions=yes
Info: maildir:
data=/usr/local/virtual//root/:CONTROL=/usr/local/virtual//root/:INDEX=/usr/local/virtual//root/:INBOX=/usr/local/virtual//root/
Info: maildir++: root=/usr/local/virtual//root, index=, control=,
inbox=/usr/local/virtual//root
Info: acl: initializing backend with data: vfile
Info: acl: acl username = robert at schetterer.com
Info: acl: owner = 1
Info: acl vfile: Global ACL directory: (null)
Info: Namespace: type=private, prefix=virtual/, sep=/, inbox=no,
hidden=yes, list=no, subscriptions=no
Info: virtual: data=/etc/dovecot/virtual:LAYOUT=maildir++
Info: maildir++: root=/etc/dovecot/virtual, index=, control=, inbox=
Info: acl: initializing backend with data: vfile
Info: acl: acl username = robert at schetterer.com
Info: acl: owner = 1
Info: acl vfile: Global ACL directory: (null)
Info: Namespace: type=private, prefix=RealMails/, sep=/, inbox=no,
hidden=yes, list=no, subscriptions=yes
Info: maildir:
data=/usr/local/virtual//root/:CONTROL=/usr/local/virtual//root/:INDEX=/usr/local/virtual//root/:INBOX=/usr/local/virtual//root/
Info: maildir++: root=/usr/local/virtual//root, index=, control=,
inbox=/usr/local/virtual//root
Info: acl: initializing backend with data: vfile
Info: acl: acl username = robert at schetterer.com
Info: acl: owner = 1
Info: acl vfile: Global ACL directory: (null)
Info: Namespace: type=shared, prefix=shared/%u/, sep=/, inbox=no,
hidden=no, list=children, subscriptions=no
Info: shared: root=, index=, control=, inbox=
Info: Namespace : Using permissions from /usr/local/virtual//root:
mode=0700 gid=-1
Info: acl vfile: file /usr/local/virtual//root/.Trash/dovecot-acl not found
Info: robert at schetterer.com/Trash: no messages left

select mailbox, from_unixtime(expire_stamp), username from expireplugin;
+---------+-----------------------------+-----------------------+
| mailbox | from_unixtime(expire_stamp) | username              |
+---------+-----------------------------+-----------------------+
| Trash   | 2009-08-04 09:40:21         | robert at schetterer.com |
+---------+-----------------------------+-----------------------+
1 row in set (0.00 sec)

3 select Trash
* OK [CLOSED]
* FLAGS (\Answered \Flagged \Deleted \Seen \Draft nonjunk Junk)
* OK [PERMANENTFLAGS (\Answered \Flagged \Deleted \Seen \Draft nonjunk
Junk \*)] Flags permitted.
* 1 EXISTS
* 0 RECENT
* OK [UIDVALIDITY 1240758078] UIDs valid
* OK [UIDNEXT 89] Predicted next UID
* OK [HIGHESTMODSEQ 123]
3 OK [READ-WRITE] Select completed.
4 fetch 1:* (internaldate x-savedate)
* 1 FETCH (INTERNALDATE "03-Aug-2009 09:40:16 +0200" X-SAVEDATE
"03-Aug-2009 09:40:21 +0200")
4 OK Fetch completed.

/usr/local/virtual/schetterer.com/robert at schetterer.com/.Trash/cur# ls -la
total 12
drwx------ 2 vmail vmail 4096 2009-08-03 09:40 .
drwx------ 5 vmail vmail 4096 2009-08-04 10:10 ..
-rw------- 2 vmail vmail  832 2009-08-03 09:40
1249285221.M317685P16433.master,W=853,S=832:2,S


/usr/sbin/dovecot -c /etc/dovecot/dovecot.conf --exec-mail ext
/usr/lib/dovecot/expire-tool.sh
Info: Loading modules from directory: /usr/lib/dovecot/modules/imap
Info: Module loaded: /usr/lib/dovecot/modules/imap/lib01_acl_plugin.so
Info: Module loaded: /usr/lib/dovecot/modules/imap/lib10_quota_plugin.so
Info: Module loaded:
/usr/lib/dovecot/modules/imap/lib20_autocreate_plugin.so
Info: Module loaded: /usr/lib/dovecot/modules/imap/lib20_expire_plugin.so
Info: Module loaded: /usr/lib/dovecot/modules/imap/lib20_fts_plugin.so
Info: Module loaded: /usr/lib/dovecot/modules/imap/lib20_virtual_plugin.so
Info: Module loaded: /usr/lib/dovecot/modules/imap/lib21_fts_squat_plugin.so
Info: Quota root: name= backend=dict args=:proxy::quotadict
Info: Quota warning: bytes=0 (95%) messages=0
command=/usr/local/bin/quota-warning.sh 95
Info: Quota warning: bytes=0 (80%) messages=0
command=/usr/local/bin/quota-warning.sh 80
Info: expire: pattern=Trash type=expunge secs=86400
Info: auth input:
home=/usr/local/virtual/schetterer.com/robert at schetterer.com/
Info: auth input: quota_rule=*:bytes=10240000
Info: auth input: quota_rule2=Trash:storage=50240
Info: auth input: quota_rule3=Sent:storage=50240
Info: auth input: quota_rule4=Drafts:storage=50240
Info: auth input: quota_rule5=Templates:storage=50240
Info: auth input: quota_rule6=Junk:storage=50240
Info: auth input:
mail=maildir:/usr/local/virtual/schetterer.com/robert at schetterer.com/
Info: auth input: namespace_1_inbox=yes
Info: auth input: uid=1001
Info: auth input: gid=1001
Info: dict quota: user=robert at schetterer.com, uri=proxy::quotadict,
noenforcing=0
Info: Namespace: type=private, prefix=, sep=/, inbox=yes, hidden=no,
list=yes, subscriptions=yes
Info: maildir:
data=/usr/local/virtual//root/:CONTROL=/usr/local/virtual//root/:INDEX=/usr/local/virtual//root/:INBOX=/usr/local/virtual//root/
Info: maildir++: root=/usr/local/virtual//root, index=, control=,
inbox=/usr/local/virtual//root
Info: acl: initializing backend with data: vfile
Info: acl: acl username = robert at schetterer.com
Info: acl: owner = 1
Info: acl vfile: Global ACL directory: (null)
Info: Namespace: type=private, prefix=virtual/, sep=/, inbox=no,
hidden=yes, list=no, subscriptions=no
Info: virtual: data=/etc/dovecot/virtual:LAYOUT=maildir++
Info: maildir++: root=/etc/dovecot/virtual, index=, control=, inbox=
Info: acl: initializing backend with data: vfile
Info: acl: acl username = robert at schetterer.com
Info: acl: owner = 1
Info: acl vfile: Global ACL directory: (null)
Info: Namespace: type=private, prefix=RealMails/, sep=/, inbox=no,
hidden=yes, list=no, subscriptions=yes
Info: maildir:
data=/usr/local/virtual//root/:CONTROL=/usr/local/virtual//root/:INDEX=/usr/local/virtual//root/:INBOX=/usr/local/virtual//root/
Info: maildir++: root=/usr/local/virtual//root, index=, control=,
inbox=/usr/local/virtual//root
Info: acl: initializing backend with data: vfile
Info: acl: acl username = robert at schetterer.com
Info: acl: owner = 1
Info: acl vfile: Global ACL directory: (null)
Info: Namespace: type=shared, prefix=shared/%u/, sep=/, inbox=no,
hidden=no, list=children, subscriptions=no
Info: shared: root=, index=, control=, inbox=
Info: Namespace : Using permissions from /usr/local/virtual//root:
mode=0700 gid=-1
Info: acl vfile: file /usr/local/virtual//root/.Trash/dovecot-acl not found

ls -la
total 12
drwx------ 2 vmail vmail 4096 2009-08-03 09:40 .
drwx------ 5 vmail vmail 4096 2009-08-04 10:10 ..
-rw------- 2 vmail vmail  832 2009-08-03 09:40
1249285221.M317685P16433.master,W=853,S=832:2,S
root at master:/usr/local/virtual/schetterer.com/robert at schetterer.com/.Trash/cur#

select Trash
* FLAGS (\Answered \Flagged \Deleted \Seen \Draft nonjunk Junk)
* OK [PERMANENTFLAGS (\Answered \Flagged \Deleted \Seen \Draft nonjunk
Junk \*)] Flags permitted.
* 1 EXISTS
* 0 RECENT
* OK [UIDVALIDITY 1240758078] UIDs valid
* OK [UIDNEXT 89] Predicted next UID
* OK [HIGHESTMODSEQ 123]
2 OK [READ-WRITE] Select completed.
3 fetch 1:* (internaldate x-savedate)
* 1 FETCH (INTERNALDATE "03-Aug-2009 09:40:16 +0200" X-SAVEDATE
"03-Aug-2009 09:40:21 +0200")
3 OK Fetch completed.

mysql> select mailbox, from_unixtime(expire_stamp), username from
expireplugin;
Empty set (0.01 sec)






-- 
Best Regards

MfG Robert Schetterer

Germany/Munich/Bavaria


More information about the dovecot mailing list