Hi all,

I have two fedora15 boxes that process mail for a few domains, and
recently set up bayes in mysql for each of them. The servers are in
geographically different locations, a few hops from each other. Since
they both process mail for the same domains, I thought it made sense
to share the database between them.

What's the best way to do this? Set one as a master and the other as a
slave, or perhaps replication between them?

easy:
set master on mx1, slave on mx2.
master is in charge of adding to db, and expiring, and slave can read it.
problem: mx2 will get mostly spam, since spammers hit mx2 first, you 'spam' hits will be lower then you thought.

hard:
master/master.
you have replication issues, especially when the sam spammer sends 500 emails to the mx1, and the same 500 to mx2.
only run manual expire via cronjob on master.

try this patch: (changes insert into bayes_seen to insert ignore into, ymmv, use at own risk, your HP printer sets on fire because of it, its not my fault)

cd /usr/local/lib/perl5/site_perl/${pv}/Mail/SpamAssassin/BayesStore


   sed -i '' -e '/INSERT INTO bayes_seen/s/INTO/IGNORE INTO/' MySQL.pm

(hey SA folks.. any reason not to just put that into 3.4.0? won't hurt anything, will it?)


--
Michael Scheidell, CTO
o: 561-999-5000
d: 561-948-2259
>*| *SECNAP Network Security Corporation

   * Best Mobile Solutions Product of 2011
   * Best Intrusion Prevention Product
   * Hot Company Finalist 2011
   * Best Email Security Product
   * Certified SNORT Integrator

______________________________________________________________________
This email has been scanned and certified safe by SpammerTrap(r). For Information please see http://www.spammertrap.com/ ______________________________________________________________________

Reply via email to