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

MySQL master-slave synchronous error report, server-id consistency leads to error report

2025-02-23 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >

Share

Shulou(Shulou.com)06/01 Report--

Today, a new slave library is added to synchronize master data, but the my.cnf configuration file is copied directly without modifying server-id, resulting in an error:

2017-04-01 14:57:16 140661325472512 [Note] Slave: received end packet from server, apparent master shutdown: 2017-04-01 14:57:16 140661325472512 [Note] Slave Slave O thread: Failed reading log event, reconnecting to retry, log 'mysql-bin.000037' at position 3556801602017-04-01 14:57:16 140661325472512 [Note] Slave: received end packet from server, apparent master shutdown: 2017-04-01 14:57:16 140661325472512 [Note] Slave I hand O thread: Failed reading log event, reconnecting to retry Log 'mysql-bin.000037' at position 355687180 2017-04-01 14:57:17 140661325472512 [Note] Slave, apparent master shutdown: 2017-04-01 14:57:17 140661325472512 [Note] Slave Slave O thread: Failed reading log event, reconnecting to retry, log' mysql-bin.000037' at position 3557012742017-04-01 14:57:18 140661325472512 [Note] Slave, apparent master shutdown: 2017-04-01 14:57:18 140661325472512 [Note] Slave I thread: Failed reading log event, reconnecting to retry Log 'mysql-bin.000037' at position 355723904 2017-04-01 14:57:18 140661325472512 [Note] Slave, apparent master shutdown: 2017-04-01 14:57:18 140661325472512 [Note] Slave Slave O thread: Failed reading log event, reconnecting to retry, log' mysql-bin.000037' at position 3557345362017-04-01 14:57:19 140661325472512 [Note] Slave: received end packet from server, apparent master shutdown: 2017-04-01 14:57:19 140661325472512 [Note] Slave I thread: Failed reading log event, reconnecting to retry Log 'mysql-bin.000037' at position 3557368492017-04-01 14:57:19 140661325472512 [Note] Slave, apparent master shutdown: 2017-04-01 14:57:19 140661325472512 [Note] Slave Slave O thread: Failed reading log event, reconnecting to retry, log' mysql-bin.000037' at position 3557409782017-04-01 14:57:20 140661325472512 [Note] Slave: received end packet from server, apparent master shutdown: 2017-04-01 14:57:20 140661325472512 [Note] Slave I thread: Failed reading log event, reconnecting to retry Log 'mysql-bin.000037' at position 355740978

View master-slave synchronization status

> show slave status\ G Relay_Master_Log_File: mysql-bin.000037 Slave_IO_Running: Preparing Slave_SQL_Running: Yes Replicate_Do_DB: Replicate_Ignore_DB: Replicate_Do_Table: Replicate_Ignore_Table: Replicate_Wild_Do_Table: Replicate_Wild_Ignore_Table: Last_Errno : 0 Last_Error: Skip_Counter: 0 Exec_Master_Log_Pos: 354949769 Relay_Log_Space: 30906 Until_Condition: None Until_Log_File: Until_Log_Pos: 0 Master_SSL_Allowed: No Master_SSL_CA_File: Master_SSL_CA_Path: Master_SSL_Cert: Master_SSL_Cipher: Master_SSL_Key: Seconds_Behind_Master: NULL

Encountered the error message:

Find out if the server-id settings on the master and slave master and slave are the same

Finding whether the server-id settings between slave1 and slave2 slave and slave are the same can also cause this problem

The server-id of each master and slave master-slave library must be unique, identifying the unique identity of the master-slave library.

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