ON DUPLICATE KEY UPDATE causing replication to fail
I ran into some problems while setting up replication between 2 version MySQL database. The following error was reported on the Slave site.
Last_Error: Error 'master may suffer from http://bugs.mysql.com/bug.php?id=24432 so slave stops; check error log on slave for more info' on query. Default database: 'wpdatabase'. Query: 'INSERT INTO `wp_2_options` (`option_name`, `option_value`, `autoload`) VALUES ('_transient_timeout_dirsize_cache', '1267703693', 'no') ON DUPLICATE KEY UPDATE `option_name` = VALUES(`option_name`), `option_value` = VALUES(`option_value`), `autoload` = VALUES(`autoload`)
As it seems “ON DUPLICATE KEY UPDATE” statement does not include auto increment values and therefor breaks the replication between a master and a slave.
This is mentioned as a bug (20188) in versions 5.0.24 up till 5.0.34.
As it seemed , I was running 5.0.26 which caused replication to break.
For now I’m looking at an upgrade of my mysql version to be higher as this should solve my problem.

Comments are closed.