日期:2014-05-16  浏览次数:20669 次

设置mysql5的master-master同步复制机制

Setting Up Master-Master Replication With MySQL 5 On Debian Etch

Do you like HowtoForge? Please consider supporting us by?becoming a subscriber.
?
Submitted by?falko?(Contact Author) (Forums) on Tue, 2007-10-23 17:03.?::?Debian?|?High-Availability?|?MySQL

Setting Up Master-Master Replication With MySQL 5 On Debian Etch

?

Version 1.0?
Author: Falko Timme <ft [at] falkotimme [dot] com>?
Last edited 10/15/2007

Since version 5, MySQL comes with built-in support for master-master replication, solving the problem that can happen with self-generated keys. In former MySQL versions, the problem with master-master replication was that conflicts arose immediately if node A and node B both inserted an auto-incrementing key on the same table. The advantages of master-master replication over the traditional master-slave replication are that you don't have to modify your applications to make write accesses only to the master, and that it is easier to provide high-availability because if the master fails, you still have the other master.

I do not issue any guarantee that this will work for you!

?

1 Preliminary Note

In this tutorial