• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

Question Manual SpamAssassin Configuration / Bayes

SonjaP

New Pleskian
I've been searching for the right place to put manual/custom additions to the SpamAssassin configurations.

Usually I would have put something a file called local.cf in /etc/spamassassin but this seems to be ignored.

Also I would like to know where the actual configuration that plesk uses is stored there is a file in /etc/spamassassin/ named plesk.local.cf, but it seems that everything I add in that or any other cf file gets ignored.

I want to turn on bayes filtering for my server and cannot seem to find the right place to put the line
use_bayes 1

I'd be grateful for any pointers.
 
Global configurations can be placed in: /etc/mail/spamassassin/local.cf and they shouldn't be ignored. Any of the Plesk managed settings will also get written to that file. Plesk itself stores the configurations in the DB and writes them to disk.

Global enabled
Tools & Settings -> Spam Filter -> Switch on server-wide SpamAssassin spam filtering checked
Stored in plesk DB and written to /etc/mail/spamassassin/local.cf

Per mailbox configurations
Tools & Settings -> Spam Filter -> Apply individual settings to spam filtering checked
Stored in plesk DB and written to /var/qmail/mailnames/<domain>/<mailname>/user_prefs

I hope this helps.
 
Thanks for getting back quickly. So local.cf will not be completely overwritten everytime Plesk updates?
I'll check out the file and try that then.
 
So local.cf will not be completely overwritten everytime Plesk updates?

No it won't nor will any of the custom rules you create in the /etc/mail/spamassassin folder. You may need to create a cron job to automate updating spamassassin's default rules or manually by executing
# sa-update -D
# service spamassassin restart

Cheers
 
ou may need to create a cron job to automate updating spamassassin's default rules

Actually you don't need to run this manually. Plesk already has its own cron that does this: `/etc/cron.daily/60sa-update`
 
Back
Top