MySQL双主 [英] MySQL dual master
问题描述
对于我当前的项目,我们正在考虑为地理上分开的设置设置双主复制拓扑;美国东海岸的一个分贝,日本的另一个分贝. 我很好奇是否有人尝试过这种方法,并且有什么经验.
For my current project we are thinking of setting up a dual master replication topology for a geographically separated setup; one db on the us east coast and the other db in japan. I am curious if anyone has tried this and what there experience has been.
此外,我很好奇我要解决这个问题的其他选择.我们正在考虑消息队列.
Also, I am curious what my other options are for solving this problem; we are considering message queues.
谢谢!
推荐答案
Just a note on the technical aspects of your plan: You have to know that MySQL does not officially support multi-master replication (only MySQL Cluster provides support for synchronous replication).
但是,即使使用普通的MySQL复制设置,也至少有一个"hack"使得多主复制成为可能.请参阅Patrick Galbraith的"MySQL多主复制" ,以获取可能的解决方案.我没有这种设置的经验,所以我不敢判断这种方法的可行性.
But there is at least one "hack" that makes multi-master-replication possible even with a normal MySQL replication setup. Please see Patrick Galbraith's "MySQL Multi-Master Replication" for a possible solution. I don't have any experience with this setup, so I don't dare to judge on how feasible this approach would be.
这篇关于MySQL双主的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!