Records of MySQL's highly available design scenarios

Source: Internet
Author: User

First, look at the high-availability scenarios for common MySQL:

Description of the pair:

1) heartbeat through the serial line or Ethernet network cable directly connected to the end of the service to do health checks, and is responsible for the implementation of DRBD,MYSQL,VIP and other resources automatic switching.

2) Data-1-2 as a data-1-1 high-usable hot sub, under normal circumstances data-1-1 provide a partition SDB1 for MySQL to use.

3) physical disks are RAID10 or RAID0, and are selected based on performance and redundancy requirements.

4) between servers, the server and the switch are dual gigabit NIC bindings

5) The application server (including not limited to the web, etc.) accesses the MySQL Main library via VIP. Load-balanced slave pools are accessed through different VIPs.

6) MySQL data in DRBD partition 1

7) Mysqlslave1,mysqlslave2 is synchronized via VIP and main library MySQL.

The above high can be used as MySQL multi-slave mode, this example belongs to a primary two from.

Two. mysql Main library outage switching process architecture topology:

Description of the pair:

1) Data-1-2 heartbeat through the serial line or a separate cable connection to Data-1-1 do health checks, found that Data-1-1 hung, automatically start data-1-2 on the Drbd,mysql and other services and responsible for the VIP dynamic switch, Ensure that the main library business is properly taken over and the service is automatically provided externally.

2) the application server (including not limited to the web, etc.) accesses the MySQL main library through the VIP and accesses the load balanced slave pool through the different VIP.

3) physical disks are RAID10 or RAID0, and are selected based on performance and redundancy requirements.

4) between servers, the server and the switch are gigabit NIC bindings.

5) MySQL on the data-1-1 in Data-1-1 partition 1, after the failure of the data-1-2 on the simultaneous implementation of high-availability switching.

6) After the failure of the Data-1-2 mysqlslave1,mysqlslave2 through the VIP and data-1-2 on the MySQL master library resynchronization.

Three. Main library outage switch to the new post-Primary schema topology:

Tip: After the high-availability scheme switch database schema, it becomes a regular master-slave architecture, at this time, the new main library from the hot Standby library into a single point of service. Therefore, we need to fix the original main library or add a new hot standby library to the main library as soon as possible to avoid the impact on the business of the new main library outage after switching.

Records of MySQL's highly available design scenarios

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.