OT: bayes in MySQL with replication

Jason Ede J.Ede at birchenallhowden.co.uk
Fri Feb 22 11:25:06 GMT 2008

I know this is way off topic, but I'm guessing others have had this and have solved it...

Since our 2 mail servers are on different sites and the VPN between them hasn't been overly reliable I've been trialling the bayes in MySQL with Master - Master replication. (MySQL 5.0)

This seems to work fine for a few hours and I then get...

080222 10:38:07 [ERROR] Slave: Error 'Duplicate entry '1-èõÒûc' for key 1' on query. Default database: 'sa_bayes'. Query: 'INSERT INTO bayes_token
                   (id, token, spam_count, ham_count, atime)
                   VALUES ('1','èõÒûc','0','1','1203675610')', Error_code: 1062
080222 10:38:07 [ERROR] Error running query, slave SQL thread aborted. Fix the problem, and restart the slave SQL thread with "SLAVE START". We stopped at log 'mysql-bin.000006' position 8791360

and SQL replication stops. Is there any way of avoiding this or of specifying a default action in case of a clash like this?

Currently each mailserver connects to the local copy of the database.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.mailscanner.info/pipermail/mailscanner/attachments/20080222/e6676811/attachment.html

More information about the MailScanner mailing list