Home > Database > Mysql Tutorial > body text

MySQL-MMM切换演示

WBOY
Release: 2016-06-07 17:40:59
Original
1799 people have browsed it

MMM(Multi-MasterReplicationManagerforMySQL)是基于双Master结构,后面接N台Slave安装很简单,官网提供了很详细的安装文档:http://mysql-mmm.org/mmm2:guide

安装很简单,香港虚拟主机,官网提供了很详细的安装文档:

:guide 

3台环境做测试

 

服务都起来后,状态如下:

[root@M1 mysql-mmm]# mmm_control show

  M2(192.168.8.26) master/ONLINE. Roles:

  slave1(192.168.8.27) slave/ONLINE. Roles: reader(192.168.8.52)

 

 

 

[root@M1 mysql-mmm]# mmm_control show     

  M1(192.168.8.25) master/HARD_OFFLINE. Roles:

  M2(192.168.8.26) master/ONLINE. Roles: writer(192.168.8.51)

  slave1(192.168.8.27) slave/ONLINE. Roles: reader(192.168.8.52)

======================================================

 

[root@M1 mysql-mmm]# mmm_control show      

  M1(192.168.8.25) master/ONLINE. Roles:

  M2(192.168.8.26) master/ONLINE. Roles: writer(192.168.8.51)

  slave1(192.168.8.27) slave/ONLINE. Roles: reader(192.168.8.52)

 

======================================================

             Slave_IO_Running: Yes

            Slave_SQL_Running: Yes

 

 

[root@M1 mysql-mmm]# mmm_control show

  M1(192.168.8.25) master/ONLINE. Roles: reader(192.168.8.52)

  M2(192.168.8.26) master/ONLINE. Roles: writer(192.168.8.51)

  slave1(192.168.8.27) slave/REPLICATION_FAIL. Roles:

 

======================================================


[root@M1 mysql-mmm]# mmm_control show

  M1(192.168.8.25) master/REPLICATION_FAIL. Roles:

  M2(192.168.8.26) master/ONLINE. Roles: reader(192.168.8.52), writer(192.168.8.51)

  slave1(192.168.8.27) slave/REPLICATION_FAIL. Roles:

=========================================================


[root@M1 mysql-mmm]# mmm_control show

  M1(192.168.8.25) master/REPLICATION_FAIL. Roles:

  M2(192.168.8.26) master/ONLINE. Roles: writer(192.168.8.51)

  slave1(192.168.8.27) slave/ONLINE. Roles: reader(192.168.8.52)

 

本文出自 “贺春旸的技术专栏” 博客,香港服务器,请务必保留此出处

,香港虚拟主机
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!