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

How to solve the error problem of mysql master-slave replication

2025-03-31 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >

Share

Shulou(Shulou.com)05/31 Report--

This article mainly introduces "how to solve the problem of mysql master-slave copy error report". In daily operation, I believe many people have doubts about how to solve the problem of mysql master-slave copy error report. The editor consulted all kinds of materials and sorted out simple and easy-to-use operation methods. I hope it will be helpful for you to answer the doubt of "how to solve the problem of mysql master-slave replication error report". Next, please follow the editor to study!

Master-slave copy error message:

Mysql > show slave status\ G

* * 1. Row *

Slave_IO_State: Waiting for master to send event

Relay_Master_Log_File: log-bin.000006

Slave_IO_Running: Yes

Slave_SQL_Running: No

Last_Errno: 1206

Last_Error: Could not execute Delete_rows event on table my_learn.test4; The total number of locks exceeds the lock table size, Error_code: 1206; handler error HA_ERR_LOCK_TABLE_FULL; the event's master log log-bin.000006, end_log_pos 1387576763

Exec_Master_Log_Pos: 120

View the mysql error code:

Error: 1206 SQLSTATE: HY000 (ER_LOCK_TABLE_FULL)

Message: the total number of locks exceeds the size of the locking table.

This type of solution:

1. Check the values of max_write_lock_count and innodb_buffer_pool_size parameters, and modify the value of innodb_buffer_pool_size to meet the requirements.

two。 For large quantities of DML statements, they should be submitted in batches.

Processing of the master-slave replication process:

Mysql > stop slave

Mysql > change master to master_log_file='log-bin.000006',master_log_pos=120

Query OK, 0 rows affected, 2 warnings (0.34 sec)

-- Note in this step, the binlog and POS points that execute the write shall prevail.

Relay_Master_Log_File: log-bin.000006

Exec_Master_Log_Pos: 120

Mysql > start slave

At this point, the study on "how to solve the problem of mysql master-slave replication error report" is over. I hope to be able to solve everyone's doubts. The collocation of theory and practice can better help you learn, go and try it! If you want to continue to learn more related knowledge, please continue to follow the website, the editor will continue to work hard to bring you more practical articles!

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: 227

*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