在Mysql的主从复制过程中,出现了1146错误。提示的错误原因是:在默认的数据中找不到指定的表。show slave status\G;现实的同步状态。Slave_io_Running: YESSlave
在Mysql的主从复制过程中,出现了1146错误。提示的错误原因是:在默认的数据中找不到指定的表。
show slave status\G;现实的同步状态。
Slave_io_Running: YES
Slave_sql_Running: No
Last_Errno: 1146
Last_Error: Error 'Table 'coop.Coop_Data' doesn't exist' on query. Default database: 'GCore'. Query: 'update coop.Coop_Data set State='2',NameLevel='2',CheckedTime=now(),Memo='' where DaiD='18601''
Skip_Counter: 0
Last_SQL_Errno: 1146
Last_SQL_Error: Error 'Table 'coop.Coop_Data' doesn't exist' on query. Default database: 'gcore'. Query: 'update coop.Coop_Data set State='2',NameLevel='2',CheckedTime=now(),Memo='' where DAID='18601''
原因是:
先使用的use db_name1,然后执行了 update db_name2.table set这种sql语句。
解决方法:
在从服务器上设置忽略该错,在my.cnf文件中添加“slave-skip-errors = 1146”,
如果少量的这种错误,直接在mysql client里面设置“set global sql_slave_skip_counter=1”;
--结束END--
本文标题: MySQL错误处理--1146错误
本文链接: https://www.lsjlt.com/news/42790.html(转载时请注明来源链接)
有问题或投稿请发送至: 邮箱/279061341@qq.com QQ/279061341
下载Word文档到电脑,方便收藏和打印~
2024-04-26
2024-04-26
2024-04-26
2024-04-26
2024-04-26
2024-04-26
2024-04-24
2024-04-24
2024-04-24
2024-04-24
回答
回答
回答
回答
回答
回答
回答
回答
回答
回答
0