spamassassin-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From David Jones <>
Subject Re: Spamassassin // replicate configuration on multiple servers
Date Mon, 23 Oct 2017 12:37:21 GMT
On 10/19/2017 11:35 AM, Emanuel wrote:
> Hello,
> Is it possible to replicate the configuration, ie modify the 
> configuration file to replicate on the other servers that share the 
> cloud, or generate a shared database?
> Thanks for your help.
> Regards,
> Emanuel.

I will assume you meant the SA configuration in /etc/mail/spamassassin. 
Yes. I do this on 8 servers with rsync.  I have a master where I make 
changes and a cron'd script will sync it to all other servers.  This way 
I only have to do sa-update, updates, custom rules/plugins, 
freshclam, etc. on the master and it distributes to the other 7.

The rsync script uses SSH access from the master to the slaves with a 
passphraseless key so it's very simple to rsync and even run commands on 
the slaves to restart SA/MailScanner/Clamd when a change is detected on 
the slaves.  Disclaimer, a passphraseless SSH key can be risky so make 
sure you have proper firewall rules and other restrictions in place to 
keep security tight.

As far as sharing the Bayes DB, that is a different issue.  If you have 
your Bayes DB files on the filesystem, then you can rsync them too from 
a master but you need to train your ham and spam from the master.  If 
you want to be able to train your bayes from any server, then you need 
to use a shared storage like MySQL or Redis.  I have a 9th server that 
is used to collect ham and spam and do the Bayes training from there 
nightly into the Redis DB.

David Jones

View raw message