[Dovecot] Have problem with antispam plugin
I downloaded the source code plug-in version 1.3 from http://johannes.sipsolutions.net/download/dovecot-antispam/ Unpack and make from this .config file:
BACKEND=mailtrain
DOVECOT=/usr/include/dovecot
INSTALLDIR=/usr/lib/dovecot/modules/imap
USER=root
GROUP=root
DEBUG=syslog
DEBUG_VERBOSE=1
PLUGINNAME=antispam
Dovecot cofing file:
protocol imap {
login_executable = /usr/lib/dovecot/imap-login
mail_executable = /usr/lib/dovecot/imap
mail_plugins = quota imap_quota antispam
}
plugin {
antispam_mail_sendmail = /usr/bin/sa-learn
antispam_mail_spam = --spam
antispam_mail_notspam = --ham
antispam_mail_tmpdir = /tmp
antispam_trash_pattern_ignorecase = trash;Deleted *
antispam_spam_pattern_ignorecase = junk;spam
}
When move message into\from "Spam" folder get error:
[SERVERBUG] failed to send email
In syslog:
imap: antispam: plugin initialising (1.3-notgit)
dovecot: IMAP(test@u-kon.ru): Loading modules from directory:
/usr/lib/dovecot/modules/imap dovecot: IMAP(test@u-kon.ru): Module loaded: /usr/lib/dovecot/modules/imap/lib10_quota_plugin.so dovecot: IMAP(test@u-kon.ru): Module loaded: /usr/lib/dovecot/modules/imap/lib11_imap_quota_plugin.so dovecot: IMAP(test@u-kon.ru): Module loaded: /usr/lib/dovecot/modules/imap/lib90_antispam_plugin.so dovecot: IMAP(test@u-kon.ru): Effective uid=8, gid=12, home=(none) dovecot: IMAP(test@u-kon.ru): Quota root: name= backend=maildir args= dovecot: IMAP(test@u-kon.ru): Quota rule: root= mailbox=* bytes=2134810624 messages=0 dovecot: imap-login: Login: user=test@u-kon.ru, method=PLAIN, rip=192.168.10.59, lip=192.168.10.77, TLS imap: antispam: "trash" is case-insensitive wildcard match trash folder imap: antispam: "deleted *" is case-insensitive wildcard match trash folder imap: antispam: "SPAM" is exact match spam folder imap: antispam: "junk" is case-insensitive wildcard match spam folder imap: antispam: "spam" is case-insensitive wildcard match spam folder imap: antispam: no unsure folders imap: antispam: mail backend spam address --spam imap: antispam: mail backend not-spam address --ham imap: antispam: mail backend sendmail /usr/bin/sa-learn imap: antispam: mail backend sendmail arg --single imap: antispam: mail backend tmpdir /tmp dovecot: IMAP(test@u-kon.ru): maildir: data=/var/spool/mail/test@u-kon.ru dovecot: IMAP(test@u-kon.ru): maildir++: root=/var/spool/mail/test@u-kon.ru, index=, control=, inbox=/var/spool/mail/test@u-kon.ru dovecot: IMAP(test@u-kon.ru): Namespace : Using permissions from /var/spool/mail/test@u-kon.ru: mode=0700 gid=-1 imap: antispam: mailbox_is_unsure(Junk): 0 imap: antispam: mailbox_is_trash(INBOX): 0 imap: antispam: mailbox_is_trash(Junk): 0 imap: antispam: mail copy: from trash: 0, to trash: 0 imap: antispam: mailbox_is_spam(INBOX): 0 imap: antispam: mailbox_is_spam(Junk): 1 imap: antispam: mailbox_is_unsure(INBOX): 0 imap: antispam: mail copy: src spam: 0, dst spam: 1, src unsure: 0 imap: antispam: running mailtrain backend program /usr/bin/sa-learn imap: antispam: running mailtrain backend program /usr/bin/sa-learn imap: antispam: run program failed with exit code 9
Get sa-learn output from help this script:
#!/bin/bash
(
id -a
sa-learn
rc=$?
echo "exit code $rc"
exit $rc
) > /tmp/antispam.out.$$ 2> /tmp/antispam.err.$$
antispam.err - contains output as "sa-learn --help"
So this means that the call comes without any parameters or with incorrect parameters. I need this to work, please help.
On Thu, 2010-04-08 at 10:23 +0400, gerasew@gmail.com wrote:
I downloaded the source code plug-in version 1.3 from http://johannes.sipsolutions.net/download/dovecot-antispam/ Unpack and make from this .config file:
BACKEND=mailtrain DOVECOT=/usr/include/dovecot INSTALLDIR=/usr/lib/dovecot/modules/imap USER=root GROUP=root DEBUG=syslog DEBUG_VERBOSE=1 PLUGINNAME=antispam
Dovecot cofing file:
protocol imap { login_executable = /usr/lib/dovecot/imap-login mail_executable = /usr/lib/dovecot/imap mail_plugins = quota imap_quota antispam } plugin { antispam_mail_sendmail = /usr/bin/sa-learn antispam_mail_spam = --spam antispam_mail_notspam = --ham antispam_mail_tmpdir = /tmp antispam_trash_pattern_ignorecase = trash;Deleted * antispam_spam_pattern_ignorecase = junk;spam }
When move message into\from "Spam" folder get error:
[SERVERBUG] failed to send email
Are you using dovecot 1.2.11?
johannes
08.04.2010 10:35, Johannes Berg пишет:
On Thu, 2010-04-08 at 10:23 +0400, gerasew@gmail.com wrote:
I downloaded the source code plug-in version 1.3 from http://johannes.sipsolutions.net/download/dovecot-antispam/ Unpack and make from this .config file:
BACKEND=mailtrain DOVECOT=/usr/include/dovecot INSTALLDIR=/usr/lib/dovecot/modules/imap USER=root GROUP=root DEBUG=syslog DEBUG_VERBOSE=1 PLUGINNAME=antispam
Dovecot cofing file:
protocol imap { login_executable = /usr/lib/dovecot/imap-login mail_executable = /usr/lib/dovecot/imap mail_plugins = quota imap_quota antispam } plugin { antispam_mail_sendmail = /usr/bin/sa-learn antispam_mail_spam = --spam antispam_mail_notspam = --ham antispam_mail_tmpdir = /tmp antispam_trash_pattern_ignorecase = trash;Deleted * antispam_spam_pattern_ignorecase = junk;spam }
When move message into\from "Spam" folder get error:
[SERVERBUG] failed to send email
Are you using dovecot 1.2.11?
johannes
Yes.
# dovecot --version 1.2.11
# uname -a Linux test.ukon.local 2.6.26-2-xen-amd64 #1 SMP Fri Aug 14 10:19:53 UTC 2009 x86_64 GNU/Linux
# cat /etc/debian_version 5.0.4
Dovecot(dovecot-common, dovecot-imapd, dovecot-pop3d, dovecot-dev)
install from "testing" dist.
[please trim quotes, and keep the list copied]
On Thu, 2010-04-08 at 10:44 +0400, gerasew@gmail.com wrote:
When move message into\from "Spam" folder get error:
[SERVERBUG] failed to send email
Are you using dovecot 1.2.11?
Yes.
23 minutes before you asked, Ron told me it was broken. We don't know why yet :)
johannes
08.04.2010 10:52, Johannes Berg пишет:
When move message into\from "Spam" folder get error:
[SERVERBUG] failed to send email
Are you using dovecot 1.2.11?
Yes.
23 minutes before you asked, Ron told me it was broken. We don't know why yet :)
johannes
Dovecot 1.0.15(lenny stable) with the same error. What Dovecot version need to plugin works?
You own it works? :)
participants (2)
-
gerasew@gmail.com
-
Johannes Berg