Using rsync to configure a large number of MySQL, save a lot of compilation and configuration time, with the master and slave server to modify the MY.CNF, after the discovery of data can not be synchronized
Using rsync to configure a large number of MySQL, save a lot of compilation and configuration time, with the master and slave server to modify the MY.CNF, after the discovery of data can not be synchronized,
On slave server Show slave Status:
Fatal error:the slave I/O thread stops because master and slave have MySQL server equal; These uuids must are different for replication to work.
First check:
Mysql> Show variables like ' server_id ';
+ ————— + ——-+
| variable_name | Value |
+ ————— + ——-+
| server_id | 3 |
+ ————— + ——-+
The master and subordinate are not the same, excluding the problem.
Continue to troubleshoot, find the reason is, copy the entire data directory, the auto.cnf file is also copied over, which records the database UUID, each library UUID should be different.
[Auto]
Server-uuid=6dcee5be-8cdb-11e2-9408-90e2ba2e2ea6
Solution, according to this 16 into the format, casually changed, restart MySQL can be.