[Dovecot] sieve fileinto public shared mbox?

RParr RParr at TemporalArts.COM
Fri Nov 5 21:34:45 EET 2010


On 11/04/2010 06:51 PM, Timo Sirainen wrote:
> On 5.11.2010, at 1.35, RParr wrote:
>
>    
>> Could someone verify if 1) sieve can fileinto shared public mbox?
>>      
> I don't see any reason why it wouldn't.
>
>    
>> 2) if it can, what I might be doing wrong?
>>      
> Set mail_debug=yes and post logs. Also full dovecot -n output would be nice (and don't leave out the version number). I didn't see anything obviously wrong in your setup.
>    

root at n3:/etc/dovecot# dovecot -n
# 1.2.9: /etc/dovecot/dovecot.conf
# OS: Linux 2.6.32-25-generic x86_64 Ubuntu 10.04.1 LTS
log_timestamp: %Y-%m-%d %H:%M:%S
protocols: imap pop3 imaps pop3s managesieve
ssl_cert_file: /etc/ssl/certs/temporalarts.pem
ssl_key_file: /etc/ssl/private/temporalarts.key
ssl_cipher_list: 
ALL:!LOW:!SSLv2:ALL:!aNULL:!ADH:!eNULL:!EXP:RC4+RSA:+HIGH:+MEDIUM
login_dir: /var/run/dovecot/login
login_executable(default): /usr/lib/dovecot/imap-login
login_executable(imap): /usr/lib/dovecot/imap-login
login_executable(pop3): /usr/lib/dovecot/pop3-login
login_executable(managesieve): /usr/lib/dovecot/managesieve-login
mail_access_groups: tarts
mail_privileged_group: mail
mail_location: mbox:~/mail:INBOX=/var/mail/%u
mail_debug: yes
mbox_write_locks: fcntl dotlock
mail_executable(default): /usr/lib/dovecot/imap
mail_executable(imap): /usr/lib/dovecot/imap
mail_executable(pop3): /usr/lib/dovecot/pop3
mail_executable(managesieve): /usr/lib/dovecot/managesieve
mail_plugin_dir(default): /usr/lib/dovecot/modules/imap
mail_plugin_dir(imap): /usr/lib/dovecot/modules/imap
mail_plugin_dir(pop3): /usr/lib/dovecot/modules/pop3
mail_plugin_dir(managesieve): /usr/lib/dovecot/modules/managesieve
imap_client_workarounds(default): outlook-idle delay-newmail
imap_client_workarounds(imap): outlook-idle delay-newmail
imap_client_workarounds(pop3):
imap_client_workarounds(managesieve):
pop3_client_workarounds(default):
pop3_client_workarounds(imap):
pop3_client_workarounds(pop3): outlook-no-nuls oe-ns-eoh
pop3_client_workarounds(managesieve):
namespace:
   type: private
   separator: /
   inbox: yes
   list: yes
   subscriptions: yes
namespace:
   type: public
   separator: /
   prefix: public/
   location: mbox:/var/mail/public
   list: yes
lda:
   postmaster_address: postmaster
   mail_plugins: sieve
   quota_full_tempfail: yes
   deliver_log_format: msgid=%m: %$
   rejection_reason: Your message to <%t> was automatically rejected:%n%r
auth default:
   mechanisms: plain login
   passdb:
     driver: pam
   userdb:
     driver: passwd
   socket:
     type: listen
     client:
       path: /var/spool/postfix/private/dovecot-auth
       mode: 432
       user: postfix
       group: postfix
plugin:
   sieve: ~/.dovecot.sieve
   sieve_dir: ~/sieve
   sieve_global_path: /etc/dovecot/sieve/default.sieve
   sieve_global_dir: /etc/dovecot/sieve

I send an email containing the Spamassassin test GTUBE message from a 
remote host and the logs look like this
------------------------------------------------
11/05/10 12:23:12 pm    n3    postfix/smtpd    connect from 
jaysmith.com[74.164.202.187]
11/05/10 12:23:12 pm    n3    postfix/smtpd    connect from 
jaysmith.com[74.164.202.187]
11/05/10 12:23:13 pm    n3    postfix/smtpd    461FB601A9: 
client=jaysmith.com[74.164.202.187]
11/05/10 12:23:13 pm    n3    postfix/cleanup    461FB601A9: 
message-id=<201011051923.oA5JNBq3025002 at JaySmith.com>
11/05/10 12:23:13 pm    n3    postfix/qmgr    461FB601A9: 
from=<rparr at JaySmith.com>, size=875, nrcpt=1 (queue active)
11/05/10 12:23:13 pm    n3    postfix/smtpd    461FB601A9: 
client=jaysmith.com[74.164.202.187]
11/05/10 12:23:13 pm    n3    postfix/cleanup    461FB601A9: 
message-id=<201011051923.oA5JNBq3025002 at JaySmith.com>
11/05/10 12:23:13 pm    n3    postfix/qmgr    461FB601A9: 
from=<rparr at JaySmith.com>, size=875, nrcpt=1 (queue active)
11/05/10 12:23:13 pm    n3    postfix/smtpd    disconnect from 
jaysmith.com[74.164.202.187]
11/05/10 12:23:13 pm    n3    postfix/smtpd    disconnect from 
jaysmith.com[74.164.202.187]
11/05/10 12:23:16 pm    n3    dovecot    deliver(tarts): sieve: 
msgid=<201011051923.oA5JNBq3025002 at JaySmith.com>: failed to store into 
mailbox 'public/SPAM/SPAMMM': Mailbox doesn't exist: public/SPAM/SPAMMM
11/05/10 12:23:16 pm    n3    dovecot    deliver(tarts): sieve: 
execution of script /home/tarts/.dovecot.sieve failed, but implicit keep 
was successful
11/05/10 12:23:16 pm    n3    postfix/smtpd    connect from 
localhost[127.0.0.1]
11/05/10 12:23:16 pm    n3    postfix/smtpd    CADCC60482: 
client=localhost[127.0.0.1]
11/05/10 12:23:16 pm    n3    postfix/cleanup    CADCC60482: 
message-id=<201011051923.oA5JNBq3025002 at JaySmith.com>
11/05/10 12:23:16 pm    n3    postfix/smtpd    disconnect from 
localhost[127.0.0.1]
11/05/10 12:23:16 pm    n3    postfix/qmgr    CADCC60482: 
from=<rparr at JaySmith.com>, size=1723, nrcpt=1 (queue active)
11/05/10 12:23:16 pm    n3    amavis    (24998-07) Passed SPAM, 
[74.164.202.187] [74.164.202.187] <rparr at JaySmith.com> -> 
<tarts at n3.temporalarts.com>, quarantine: N/spam-NEY7tZkdXw4G.gz, 
Message-ID: <201011051923.oA5JNBq3025002 at JaySmith.com>, mail_id: 
NEY7tZkdXw4G, Hits: 1002.562, size: 875, queued_as: CADCC60482, 3200 ms
11/05/10 12:23:16 pm    n3    dovecot    deliver(tarts): sieve: 
msgid=<201011051923.oA5JNBq3025002 at JaySmith.com>: failed to store into 
mailbox 'public/SPAM/SPAMMM': Mailbox doesn't exist: public/SPAM/SPAMMM
11/05/10 12:23:16 pm    n3    postfix/smtp    461FB601A9: 
to=<tarts at n3.temporalarts.com>, relay=127.0.0.1[127.0.0.1]:10024, 
delay=3.8, delays=0.55/0.01/0/3.2, dsn=2.0.0, status=sent (250 2.0.0 Ok, 
id=24998-07, from MTA([127.0.0.1]:10025): 250 2.0.0 Ok: queued as 
CADCC60482)
11/05/10 12:23:16 pm    n3    dovecot    deliver(tarts): sieve: 
msgid=<201011051923.oA5JNBq3025002 at JaySmith.com>: stored mail into 
mailbox 'INBOX'
11/05/10 12:23:16 pm    n3    postfix/qmgr    461FB601A9: removed
11/05/10 12:23:16 pm    n3    dovecot    deliver(tarts): sieve: 
execution of script /home/tarts/.dovecot.sieve failed, but implicit keep 
was successful
11/05/10 12:23:16 pm    n3    postfix/local    CADCC60482: 
to=<tarts at n3.temporalarts.com>, relay=local, delay=0.01, 
delays=0/0.01/0/0.01, dsn=2.0.0, status=sent (delivered to command: 
/usr/lib/dovecot/deliver -c /etc/dovecot/conf.d/01-dovecot-postfix.conf 
-n -m "${EXTENSION}")
11/05/10 12:23:16 pm    n3    postfix/qmgr    CADCC60482: removed
11/05/10 12:23:16 pm    n3    postfix/smtpd    connect from 
localhost[127.0.0.1]
11/05/10 12:23:16 pm    n3    postfix/smtpd    CADCC60482: 
client=localhost[127.0.0.1]
11/05/10 12:23:16 pm    n3    postfix/cleanup    CADCC60482: 
message-id=<201011051923.oA5JNBq3025002 at JaySmith.com>
11/05/10 12:23:16 pm    n3    postfix/smtpd    disconnect from 
localhost[127.0.0.1]
11/05/10 12:23:16 pm    n3    postfix/qmgr    CADCC60482: 
from=<rparr at JaySmith.com>, size=1723, nrcpt=1 (queue active)
11/05/10 12:23:16 pm    n3    amavis    (24998-07) Passed SPAM, 
[74.164.202.187] [74.164.202.187] <rparr at JaySmith.com> -> 
<tarts at n3.temporalarts.com>, quarantine: N/spam-NEY7tZkdXw4G.gz, 
Message-ID: <201011051923.oA5JNBq3025002 at JaySmith.com>, mail_id: 
NEY7tZkdXw4G, Hits: 1002.562, size: 875, queued_as: CADCC60482, 3200 ms
11/05/10 12:23:16 pm    n3    dovecot    deliver(tarts): sieve: 
msgid=<201011051923.oA5JNBq3025002 at JaySmith.com>: failed to store into 
mailbox 'public/SPAM/SPAMMM': Mailbox doesn't exist: public/SPAM/SPAMMM
11/05/10 12:23:16 pm    n3    postfix/smtp    461FB601A9: 
to=<tarts at n3.temporalarts.com>, relay=127.0.0.1[127.0.0.1]:10024, 
delay=3.8, delays=0.55/0.01/0/3.2, dsn=2.0.0, status=sent (250 2.0.0 Ok, 
id=24998-07, from MTA([127.0.0.1]:10025): 250 2.0.0 Ok: queued as 
CADCC60482)
11/05/10 12:23:16 pm    n3    dovecot    deliver(tarts): sieve: 
msgid=<201011051923.oA5JNBq3025002 at JaySmith.com>: stored mail into 
mailbox 'INBOX'
11/05/10 12:23:16 pm    n3    postfix/qmgr    461FB601A9: removed
11/05/10 12:23:16 pm    n3    dovecot    deliver(tarts): sieve: 
execution of script /home/tarts/.dovecot.sieve failed, but implicit keep 
was successful
11/05/10 12:23:16 pm    n3    postfix/local    CADCC60482: 
to=<tarts at n3.temporalarts.com>, relay=local, delay=0.01, 
delays=0/0.01/0/0.01, dsn=2.0.0, status=sent (delivered to command: 
/usr/lib/dovecot/deliver -c /etc/dovecot/conf.d/01-dovecot-postfix.conf 
-n -m "${EXTENSION}")
11/05/10 12:23:16 pm    n3    postfix/qmgr    CADCC60482: removed
11/05/10 12:23:16 pm    n3    dovecot    deliver(tarts): sieve: 
msgid=<201011051923.oA5JNBq3025002 at JaySmith.com>: failed to store into 
mailbox 'public/SPAM/SPAMMM': Mailbox doesn't exist: public/SPAM/SPAMMM
11/05/10 12:23:16 pm    n3    dovecot    deliver(tarts): sieve: 
execution of script /home/tarts/.dovecot.sieve failed, but implicit keep 
was successful
--------------------------------------------------------

I then edit user tarts spam.sieve filter to post into one of user tarts 
mailboxes and send the same GTUBE message again
---------------------------------------------------------
11/05/10 12:28:34 pm    n3    postfix/smtpd    connect from 
jaysmith.com[74.164.202.187]
11/05/10 12:28:34 pm    n3    postfix/smtpd    connect from 
jaysmith.com[74.164.202.187]
11/05/10 12:28:36 pm    n3    postfix/smtpd    20BE160467: 
client=jaysmith.com[74.164.202.187]
11/05/10 12:28:36 pm    n3    postfix/cleanup    20BE160467: 
message-id=<201011051928.oA5JSYCn025245 at JaySmith.com>
11/05/10 12:28:36 pm    n3    postfix/qmgr    20BE160467: 
from=<rparr at JaySmith.com>, size=875, nrcpt=1 (queue active)
11/05/10 12:28:36 pm    n3    postfix/smtpd    20BE160467: 
client=jaysmith.com[74.164.202.187]
11/05/10 12:28:36 pm    n3    postfix/cleanup    20BE160467: 
message-id=<201011051928.oA5JSYCn025245 at JaySmith.com>
11/05/10 12:28:36 pm    n3    postfix/qmgr    20BE160467: 
from=<rparr at JaySmith.com>, size=875, nrcpt=1 (queue active)
11/05/10 12:28:36 pm    n3    postfix/smtpd    disconnect from 
jaysmith.com[74.164.202.187]
11/05/10 12:28:36 pm    n3    postfix/smtpd    disconnect from 
jaysmith.com[74.164.202.187]
11/05/10 12:28:39 pm    n3    postfix/smtpd    connect from 
localhost[127.0.0.1]
11/05/10 12:28:39 pm    n3    postfix/smtpd    55DAE60482: 
client=localhost[127.0.0.1]
11/05/10 12:28:39 pm    n3    postfix/cleanup    55DAE60482: 
message-id=<201011051928.oA5JSYCn025245 at JaySmith.com>
11/05/10 12:28:39 pm    n3    postfix/smtpd    disconnect from 
localhost[127.0.0.1]
11/05/10 12:28:39 pm    n3    postfix/qmgr    55DAE60482: 
from=<rparr at JaySmith.com>, size=1723, nrcpt=1 (queue active)
11/05/10 12:28:39 pm    n3    amavis    (24997-08) Passed SPAM, 
[74.164.202.187] [74.164.202.187] <rparr at JaySmith.com> -> 
<tarts at n3.temporalarts.com>, quarantine: e/spam-e26gavu3BMYL.gz, 
Message-ID: <201011051928.oA5JSYCn025245 at JaySmith.com>, mail_id: 
e26gavu3BMYL, Hits: 1002.562, size: 875, queued_as: 55DAE60482, 2869 ms
11/05/10 12:28:39 pm    n3    dovecot    deliver(tarts): sieve: 
msgid=<201011051928.oA5JSYCn025245 at JaySmith.com>: stored mail into 
mailbox 'SPAM/MySPAMMM'
11/05/10 12:28:39 pm    n3    postfix/local    55DAE60482: 
to=<tarts at n3.temporalarts.com>, relay=local, delay=0.01, 
delays=0/0.01/0/0.01, dsn=2.0.0, status=sent (delivered to command: 
/usr/lib/dovecot/deliver -c /etc/dovecot/conf.d/01-dovecot-postfix.conf 
-n -m "${EXTENSION}")
11/05/10 12:28:39 pm    n3    postfix/smtp    20BE160467: 
to=<tarts at n3.temporalarts.com>, relay=127.0.0.1[127.0.0.1]:10024, 
delay=3.4, delays=0.52/0.01/0/2.9, dsn=2.0.0, status=sent (250 2.0.0 Ok, 
id=24997-08, from MTA([127.0.0.1]:10025): 250 2.0.0 Ok: queued as 
55DAE60482)
11/05/10 12:28:39 pm    n3    postfix/qmgr    55DAE60482: removed
11/05/10 12:28:39 pm    n3    postfix/qmgr    20BE160467: removed
11/05/10 12:28:39 pm    n3    postfix/smtpd    connect from 
localhost[127.0.0.1]
11/05/10 12:28:39 pm    n3    postfix/smtpd    55DAE60482: 
client=localhost[127.0.0.1]
11/05/10 12:28:39 pm    n3    postfix/cleanup    55DAE60482: 
message-id=<201011051928.oA5JSYCn025245 at JaySmith.com>
11/05/10 12:28:39 pm    n3    postfix/smtpd    disconnect from 
localhost[127.0.0.1]
11/05/10 12:28:39 pm    n3    postfix/qmgr    55DAE60482: 
from=<rparr at JaySmith.com>, size=1723, nrcpt=1 (queue active)
11/05/10 12:28:39 pm    n3    amavis    (24997-08) Passed SPAM, 
[74.164.202.187] [74.164.202.187] <rparr at JaySmith.com> -> 
<tarts at n3.temporalarts.com>, quarantine: e/spam-e26gavu3BMYL.gz, 
Message-ID: <201011051928.oA5JSYCn025245 at JaySmith.com>, mail_id: 
e26gavu3BMYL, Hits: 1002.562, size: 875, queued_as: 55DAE60482, 2869 ms
11/05/10 12:28:39 pm    n3    dovecot    deliver(tarts): sieve: 
msgid=<201011051928.oA5JSYCn025245 at JaySmith.com>: stored mail into 
mailbox 'SPAM/MySPAMMM'
11/05/10 12:28:39 pm    n3    postfix/local    55DAE60482: 
to=<tarts at n3.temporalarts.com>, relay=local, delay=0.01, 
delays=0/0.01/0/0.01, dsn=2.0.0, status=sent (delivered to command: 
/usr/lib/dovecot/deliver -c /etc/dovecot/conf.d/01-dovecot-postfix.conf 
-n -m "${EXTENSION}")
11/05/10 12:28:39 pm    n3    postfix/smtp    20BE160467: 
to=<tarts at n3.temporalarts.com>, relay=127.0.0.1[127.0.0.1]:10024, 
delay=3.4, delays=0.52/0.01/0/2.9, dsn=2.0.0, status=sent (250 2.0.0 Ok, 
id=24997-08, from MTA([127.0.0.1]:10025): 250 2.0.0 Ok: queued as 
55DAE60482)
11/05/10 12:28:39 pm    n3    postfix/qmgr    55DAE60482: removed
11/05/10 12:28:39 pm    n3    postfix/qmgr    20BE160467: removed
11/05/10 12:28:42 pm    n3    dovecot    imap-login: Login: 
user=<tarts>, method=PLAIN, rip=63.227.222.66, lip=63.227.222.66, TLS
11/05/10 12:28:42 pm    n3    dovecot    IMAP(tarts): Effective 
uid=1091, gid=1091, home=/home/tarts
11/05/10 12:28:42 pm    n3    dovecot    IMAP(tarts): Namespace: 
type=private, prefix=, sep=/, inbox=yes, hidden=no, list=yes, 
subscriptions=yes
11/05/10 12:28:42 pm    n3    dovecot    IMAP(tarts): mbox: 
data=~/mail:INBOX=/var/mail/tarts
11/05/10 12:28:42 pm    n3    dovecot    IMAP(tarts): fs: 
root=/home/tarts/mail, index=, control=, inbox=/var/mail/tarts
11/05/10 12:28:42 pm    n3    dovecot    IMAP(tarts): Namespace: 
type=public, prefix=public/, sep=/, inbox=no, hidden=no, list=yes, 
subscriptions=no
11/05/10 12:28:42 pm    n3    dovecot    IMAP(tarts): mbox: 
data=/var/mail/public
11/05/10 12:28:42 pm    n3    dovecot    IMAP(tarts): mbox: INBOX 
defaulted to /var/mail/public/inbox
11/05/10 12:28:42 pm    n3    dovecot    IMAP(tarts): fs: 
root=/var/mail/public, index=, control=, inbox=/var/mail/public/inbox
11/05/10 12:28:42 pm    n3    dovecot    imap-login: Login: 
user=<tarts>, method=PLAIN, rip=63.227.222.66, lip=63.227.222.66, TLS
11/05/10 12:28:42 pm    n3    dovecot    IMAP(tarts): Effective 
uid=1091, gid=1091, home=/home/tarts
11/05/10 12:28:42 pm    n3    dovecot    IMAP(tarts): Namespace: 
type=private, prefix=, sep=/, inbox=yes, hidden=no, list=yes, 
subscriptions=yes
11/05/10 12:28:42 pm    n3    dovecot    IMAP(tarts): mbox: 
data=~/mail:INBOX=/var/mail/tarts
11/05/10 12:28:42 pm    n3    dovecot    IMAP(tarts): fs: 
root=/home/tarts/mail, index=, control=, inbox=/var/mail/tarts
11/05/10 12:28:42 pm    n3    dovecot    IMAP(tarts): Namespace: 
type=public, prefix=public/, sep=/, inbox=no, hidden=no, list=yes, 
subscriptions=no
11/05/10 12:28:42 pm    n3    dovecot    IMAP(tarts): mbox: 
data=/var/mail/public
11/05/10 12:28:42 pm    n3    dovecot    IMAP(tarts): mbox: INBOX 
defaulted to /var/mail/public/inbox
11/05/10 12:28:42 pm    n3    dovecot    IMAP(tarts): fs: 
root=/var/mail/public, index=, control=, inbox=/var/mail/public/inbox
-------------------------------------------------------------

I am a little confused by the references to inbox=/var/mail/tarts 
(correct per my understanding)
AND INBOX defaulted to /var/mail/public/inbox?  Does the definition of 
public namespace need to explicitly say inbox = no?




More information about the dovecot mailing list