mysql-Learning -8-20170522-Preliminary copy

Source: Internet
Author: User
Tags mixed

mysql-Learning -8-20170522-mysql Replication

5.1 Row

5.6.10 GTID

Master-Slave Row+gtid + mysqlbinlog (smei-sync)

Binary log mode: SBR, rbr,mixed

Row format

The main library notifies me of the changed data from the library, and then pulls the changed parts from the library from the main library.

5.7 of the replication has a significant increase, mainly to improve the multi-notification aspect, such as 3 slave library, there will be 3 to make separate notification

If no delay mode, the library pulls data from the main library's memory

Statement format:

Master-Slave consistency Check tool,

The row format, which is fixed using the statement format, is relatively secure relative to the statement format, that is, the delete from Pt-table-checksum/pt-table-sync where the data is not dropped from the TB where ID <10000; The row format is recorded and statement only records one, which is the difference between row and statement.

Copy flow in row format:

Innodb No PK case there is a rowid mixed is a transitional form, it is not recommended to use the

Each transaction has a global number, divided into two parts:

Live MySQL replication, here are 7 videos to watch and practice the operation:

Create a master-slave rule: same set of Master/slave port numbers as long as you use mysqldump for backup, be sure to bring the following two parameters: Master-data
Single-transaction, why are you talking back?

Master-Slave construction environment carding:

Gtid Change to Off

Remember the change master statement

Help Change Master to To give a copy of Gtid, Binglog must be in row format

SET @ @GLOBAL. Gtid_purged= ' 61beeb3d-2a88-11e7-9db9-080027f7e774:1-2 ';
"Admin" Wu Bingxi (82565387) 22:21:06



"Admin" Wu Bingxi (82565387) 22:21:29



"Admin" Wu Bingxi (82565387) 22:22:51

"Admin" Wu Bingxi (82565387) 22:23:25
#mysql-S/tmp/mysql3307.sock-p </data/backup/db20170522.sql
Enter Password:
ERROR 1840 (HY000) at line: @ @GLOBAL. Gtid_purged can only is set when @ @GLOBAL. Gtid_executed is empty.
"Admin" Wu Bingxi (82565387) 22:23:35
Reset Master;

  

mysql-Learning -8-20170522-Preliminary copy

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.