Re: [Dovecot] Different but probably related issue
Hi Marc,
[+list since I'm unlikely to be able to solve this problem myself]
I am trying to setup a debian testing (wheeze) mail server using postfix, dovecot and amavisd-new with spamassassin. I have everything working fine, using mdbox mailboxes and system users. As a final touch for this setup, I wanted to be able to train the (global) bayes database directly through IMAP.
Hence, I installed your plugin (directly from the official debian repositories) and set it up to report mails to spamassassin. I am using the "pipe" backend to call a wrapper script, that stores the mail into a temporary file and launches sa-learn to learn it. My tests indicate that this is working properly.
Ok, nice.
However, when the dovecot-antispam plugin is enabled, I have a weird problem sending emails. This is, whenever my MUA tries to save the just sent message to the "Sent" folder, dovecot shows the following error:
Hmm, ok, let's see
Dovecot's error log:
Jun 4 22:35:14 aiur dovecot: imap(user): Error: mdbox /home/user/.mdbox/mailboxes/Sent/dbox-Mails: map uid lost for uid 0 Jun 4 22:36:06 aiur dovecot: imap(user): Error: /home/user/.mdbox/mailboxes/Spam/dbox-Mails/dovecot.index reset, view is now inconsistent Jun 4 22:36:09 aiur dovecot: imap(user): Error: Log synchronization error at seq=8,offset=27592 for /home/user/.mdbox/storage/dovecot.map.index: Append with UID 56056, but next_uid = 56057 Jun 4 22:36:09 aiur dovecot: lda(user): Error: Log synchronization error at seq=8,offset=27592 for /home/user/.mdbox/storage/dovecot.map.index: Append with UID 56056, but next_uid = 56057 Jun 4 22:36:10 aiur dovecot: imap(user): Error: /home/user/.mdbox/mailboxes/INBOX/dbox-Mails/dovecot.index reset, view is now inconsistent
As a result, the MUA hangs for a while (some minute and a half). After that it closes the IMAP session properly, but I am left with two copies of the sent email in the "Sent" folder: one that is marked as unread and one that is not.
Curious. I think the problem is likely the mdbox storage... There have always been some issues with it and the antispam plugin when combined. The first issue was that we couldn't access the raw text or something ... not sure what's up now.
IMAP Conversation (as logged by roundcube webmail)
[04-Jun-2012 22:35:14 +0200]: [4A68] C: A0005 APPEND INBOX.Sent (\Seen) {519+} [04-Jun-2012 22:35:14 +0200]: [4A68] C: Received: from cpe-76-169-183-245.socal.res.rr.com ([76.169.183.245]) by server.domain.tld with HTTP (HTTP/1.1 POST); Mon, 04 Jun 2012 22:35:14 +0200 MIME-Version: 1.0 ... [04-Jun-2012 22:36:10 +0200]: [4A68] S: A0005 OK [APPENDUID 1338488996 4274] Append completed.
That looks ... pretty normal.
At this point, I do not know what else to try or how to fix this problem. Thus, I have had to disable your plugin for now. Do you have any ideas on how to proceed? I can give you access to this machine if need be (it's a personal server).
Unfortunately, I don't. I can only suggest, as a test, trying with some other storage format -- I only use Maildir -- to see if the problem is really in the interaction with mdbox. I'm fairly sure that's likely the problem, maybe the plugin doesn't pass something through append that is needed by mdbox, but I've never even attempted to understand mdbox.
Maybe Timo can comment. Timo, you can find the latest code here: http://git.sipsolutions.net/?p=dovecot-antispam.git;a=summary
johannes
On 5.6.2012, at 11.09, Johannes Berg wrote:
Unfortunately, I don't. I can only suggest, as a test, trying with some other storage format -- I only use Maildir -- to see if the problem is really in the interaction with mdbox. I'm fairly sure that's likely the problem, maybe the plugin doesn't pass something through append that is needed by mdbox, but I've never even attempted to understand mdbox.
Maybe Timo can comment. Timo, you can find the latest code here: http://git.sipsolutions.net/?p=dovecot-antispam.git;a=summary
I don't see anything obviously wrong in there.. Perhaps antispam_save_finish() returns failure for some reason and dbox doesn't handle that properly?
participants (2)
-
Johannes Berg
-
Timo Sirainen