1. Add Maria source vi /etc/yum.repos.d/MariaDB.repo Paste the latest mariadb image from Alibaba Cloud: [mariadb] name = MariaDB baseurl = https://mirrors.aliyun.com/mariadb/yum/10.5/centos7-amd64/ gpgkey=https://mirrors.aliyun.com/mariadb/yum/RPM-GPG-KEY-MariaDB gpgcheck=1 Install the new version of MariaDB yum install mariadb mariadb-server Enable binlog vim /etc/my.cnf.d/server.cnf Add the following under mysqld server_id = 1 log_bin = mysql-bin systemctl restart mariadb 2. Master-Slave Replication 1. Authorize on the master grant replication slave on *.* to 'slave'@'192.168.59.%' identified by '123'; 2. Add a host and perform synchronization master operation Stop slave, stop synchronization, and start modifying information stop slave; Write the master information CHANGE MASTER TO -> MASTER_HOST='192.168.59.143', -> MASTER_USER='slave', -> MASTER_PASSWORD = '123', -> MASTER_PORT=3306, ->MASTER_USE_GTID = current_pos; Start slave and start synchronization start slave; Verify whether show slave status \G; At this point, GTID master-slave replication is completed! ! This is the end of this article about MYSQL database GTID master-slave replication implementation (super convenient). For more relevant MYSQL GTID master-slave replication content, please search 123WORDPRESS.COM's previous articles or continue to browse the following related articles. I hope everyone will support 123WORDPRESS.COM in the future! You may also be interested in:
|
<<: A complete list of meta tag settings for mobile devices
>>: Detailed explanation of the watch listener example in vue3.0
Table of contents Listener 1.watchEffect 2.watch ...
The following two errors were encountered when co...
Using provide+inject combination in Vue First you...
Web page WB.ExecWB control printing method Copy c...
Comprehensive understanding of html.css overflow ...
1. Download the repository image docker pull regi...
Overview The project was created successfully and...
This article shares the specific code of js to im...
This article mainly introduces the case of Vue en...
Preface In our daily work, we often need to renam...
Table of contents 1. Vue life cycle 2. Hook funct...
Based on past experience, taking notes after comp...
How to implement the paging function of MyBatis i...
Definition and Use Using @media queries, you can ...
This article example shares the specific code of ...