Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to realize Cluster High availability Architecture in MySQL

2025-01-18 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >

Share

Shulou(Shulou.com)05/31 Report--

Today, I will talk to you about how to achieve a highly available cluster architecture in MySQL. Many people may not know much about it. In order to make you understand better, the editor has summarized the following for you. I hope you can get something according to this article.

MySQL+DRDB architecture

Through the DRBD replication mode based on block block, the double master failover can be carried out quickly, and the problem of single point of failure of the main database can be solved to a great extent.

This architecture features:

1. High-availability software can use Heartbeat, which is fully responsible for the management of VIP, data and DRBD services.

2. After the master failure, the slave database can be switched automatically and quickly, and the slave library can still synchronize with the new master database through VIP.

3. Separation of read and write is also supported from the library, which can be implemented by middleware or program.

MySQL+MHA architecture

At present, MHA should also be a relatively mature and common scheme in the high availability scheme of Mysql. It was developed by the Japanese. In the process of mysql failover, MHA can switch quickly and automatically, and maintain the consistency of data to a great extent.

This architecture features:

1. Installation and deployment is simple and does not affect the existing architecture.

2. Automatic monitoring and failover

3. Ensure data consistency

4. Failover mode can be manual or automatic multi-directional selection

5. Wide range of adaptation (applicable to any storage engine)

MySQL+MMM architecture

MMM, or Master-Master Replication Manager for MySQL (mysql Master replication Manager), is a scalable suite of scripts for monitoring, failover, and management of mysql master replication configurations (only one node can be written at any time). This suite can also read load balancing from any number of slave servers based on the standard master-slave configuration, so you can use it to launch virtual ip on a group of servers that reside in replication In addition, it has scripts that implement data backup and resynchronization between nodes.

MySQL itself does not provide a replication failover solution, through the MMM scheme to achieve server failover, so as to achieve the high availability of mysql.

The features of this scheme are:

1. High security, high stability and good scalability

2. At least three or more servers are required

3. For double masters (higher requirements for master-slave reproduction)

4. The separation of reading and writing can also be realized.

MySQL Cluster architecture

The cluster high availability scheme officially launched by Mysql is difficult to evaluate because I have not used it.

An explanation taken from the Internet

MySQL Cluster consists of a group of computers, each running a variety of processes, including MySQL servers, NDB Cluster data nodes, management servers, and (possibly) specialized data access programs.

Due to the complexity of the MySQL Cluster architecture, deployment is time-consuming (it usually takes several hours for DBA to complete the build), while relying on MySQL Cluster Manager can be done with only one command, but MySQL Cluster Manager is paid for. And industry veterans believe that NDB is not suitable for most business scenarios and has security problems. Therefore, the number of users is relatively small.

After reading the above, do you have any further understanding of how to implement the cluster high availability architecture in MySQL? If you want to know more knowledge or related content, please follow the industry information channel, thank you for your support.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Database

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report