1 (edited by potato 2013-04-08 04:28:18)

Topic: Avamis doesn't trigger Spamassassin

==== Required information ====
- iRedMail version: 0.8.3
- Store mail accounts in which backend (LDAP/MySQL/PGSQL): MySQL
- Linux/BSD distribution name and version: Ubuntu 12.10
- Related log if you're reporting an issue: http://pastebin.com/D2qXrkmr
====

Hey there

I have a mail server running at the moment, set up with iRedMail. It's been working perfectly well for a few months, but my users do get an awful lot of spam. Apparently SpamAssassin wasn't configured or running. This is what I did so far to try and make it work:

  1. Edited /etc/default/spamassassin: changed ENABLED to 1. (Otherwise SpamAssassin wouldn't start)

  2. Edited /etc/amavis/conf.d/05-domain_id. Added the local domains so it would trigger tags, as such:
    @local_domains_acl = ( [".$mydomain", ".maildomain.com", ".maildomain2.com", ".maildomain3.com" ] );

  3. Edited /etc/amavis/conf.d/20-debian_defaults so it would add spam tags to every mail for testing purposes:
    $sa_tag_level_deflt = -1000;

  4. Restarted both Amavis and SpamAssassin, to no avail.

Here is the mail.log that shows up when I restart Amavis. It does seem to load the SpamAssassin module.
http://pastebin.com/D2qXrkmr

This is the only Amavis log entry that I get when I received a mail:

Apr  7 17:27:40 mail amavis[15836]: (15836-01) Passed CLEAN {RelayedOutbound}, LOCAL [***.***.***.***]:56878 [***.***.***.***] <testsender@mail.com> -> <testreceived@mail.com>, Queue-ID: 95BD92CD, Message-ID: <CAL3sA7gWvZbZC_baQjaYSCdDY6vNn$

----

Spider Email Archiver: On-Premises, lightweight email archiving software developed by iRedMail team. Supports Amazon S3 compatible storage and custom branding.

2

Re: Avamis doesn't trigger Spamassassin

potato wrote:

* Edited /etc/default/spamassassin: changed ENABLED to 1. (Otherwise SpamAssassin wouldn't start)

Wrong. SpamAssassin is configured to be invoked by Amavisd, not running as a standalone deamon/service.

potato wrote:

* Edited /etc/amavis/conf.d/05-domain_id. Added the local domains so it would trigger tags, as such:
@local_domains_acl = ( [".$mydomain", ".maildomain.com", ".maildomain2.com", ".maildomain3.com" ] );

Wrong, please list your local domains in @local_domains_maps in /etc/amavis/conf.d/50-user instead. And reverse above change.

potato wrote:

Edited /etc/amavis/conf.d/20-debian_defaults so it would add spam tags to every mail for testing purposes:
$sa_tag_level_deflt = -1000;

It's always a good idea to add your custom settings in 50-user, or override default settings.

3

Re: Avamis doesn't trigger Spamassassin

Perfect, works now. Thanks a lot.