Spamassassin does not modify headers on Ispconfig/Centos 7.1

Discussion in 'Installation/Configuration' started by kephra, May 25, 2015.

  1. kephra

    kephra Member

    I noticed that the spam quarantined settings have no effect. None of the spam mails I receive have any spamassassin headers added, the SPAM subject tags are not added, and the quarantine levels apparently do not work. The configuration is from the Perfect Server Installation. Is there something not configured?
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    Please post the output of:

    ls -la /etc/amavis/


    ls -la /etc/amavisd.conf
  3. kephra

    kephra Member

    /etc/amavis does not exist
    [root@fire server]# ls -la /etc/amavisd.conf
    -rw-r--r-- 1 root root 34131 Apr 28 11:11 /etc/amavisd.conf
  4. till

    till Super Moderator Staff Member ISPConfig Developer

    Is there a directory /etc/amavisd ?
  5. kephra

    kephra Member

    Yes, /etc/amavisd/ exists and contains amavisd.conf
    /etc/amavisd.conf also exists
    The two files are different.
  6. till

    till Super Moderator Staff Member ISPConfig Developer

    The correct file is the one that contains these lines.

    $sql_select_policy =
       'SELECT *,'.
       ' FROM spamfilter_users LEFT JOIN spamfilter_policy ON'.
       ' WHERE IN (%k) ORDER BY spamfilter_users.priority DESC';
    $sql_select_white_black_list = 'SELECT wb FROM spamfilter_wblist'.
        ' WHERE (spamfilter_wblist.rid=?) AND ( IN (%k))' .
        ' ORDER BY spamfilter_wblist.priority DESC';
    Delete the other file and replace it with a symlink to the file that contains these lines. Then restart amavisd.
  7. kephra

    kephra Member

    Yes, the desired file on my system is /etc/amavisd.conf, NOT /etc/amavisd/amavisd.conf.
    I get a lot of spam, so it wont take long to see if that works, which I believe will
    Thanks for your help..... love your howtos :)
  8. kephra

    kephra Member

    This seems to have caused another problem. My systemd journal shows continual error messages like:
    ... amavis[23474]: (23474-06) (!)ClamAV-clamd av-scanner FAILED: run_av error: Too many retries to talk to /var/run/clamav/clamd.sock (All attempts (1) failed connecting to /var/run/clamav/clamd.sock) at (eval 98) line 608.\n
    ... amavis[24064]: (24064-06) (!)connect to /var/run/clamav/clamd.sock failed, attempt #1: Can't connect to a UNIX socket /var/run/clamav/clamd.sock: No such file or directory

    There is a /var/run/clamd.amavisd/clamd.sock

    In the /etc/amavisd.conf file there is:
    \&ask_daemon, ["CONTSCAN {}\n", "/var/run/clamav/clamd.sock"],
    qr/\bOK$/, qr/\bFOUND$/,
    qr/^.*?: (?!Infected Archive)(.*) FOUND$/ ],

    Should I change /var/run/clamav/clamd.sock to /var/run/clamd.amavisd/clamd.sock?
  9. till

    till Super Moderator Staff Member ISPConfig Developer

    Yes, please change that path to match the path on your system.
  10. paranoico

    paranoico New Member

    Hello Till,

    Since I cannot find how to create a new thread even when am a registered user, am going to post here too:

    I have exactly the same problem also after using the Perfect Server Guide but for Debian 7 box.

    ¿Could you shed some light about how to fix it? I know the files and locations you pointed at does not exist on Debian 7.

    Thanks in advance.
  11. till

    till Super Moderator Staff Member ISPConfig Developer

    Click on the "Post new thread button in a forum, e,g, here:

    This problem is centos specific, it does not exist on debian as debian does not change the locations of the amavis file for each version. Please check that you selected a spamfilter policy for the email domain or email addressin ispconfig. A good start is to use the normal policy.

Share This Page