免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
123下一页
最近访问板块 发新帖
查看: 5198 | 回复: 20
打印 上一主题 下一主题

M-S出错 [复制链接]

论坛徽章:
3
CU大牛徽章
日期:2013-03-13 15:29:07CU大牛徽章
日期:2013-03-13 15:29:49CU大牛徽章
日期:2013-03-13 15:30:19
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2008-05-23 10:13 |只看该作者 |倒序浏览
我已经试过stop slave;start slave;了


  Slave_IO_Running: No
一直都是NO,下面是日志


  1. Error reading relay log event: slave SQL thread was killed
  2. May 23 09:30:08 webserver mysqld[16218]: 080523  9:30:08 [Note] Slave SQL thread initialized, starting replication in log 'mysql-bin.000138' at position 13810120, relay log '/var/run/mysqld/mysqld-relay-bin.000290' position: 98
  3. May 23 09:30:08 webserver mysqld[16218]: 080523  9:30:08 [Note] Slave I/O thread: connected to master 'backup@192.168.3.6:3306',  replication started in log 'mysql-bin.000138' at position 13810120
  4. May 23 09:30:08 webserver mysqld[16218]: 080523  9:30:08 [ERROR] Error reading packet from server: Client requested master to start replication from impossible position ( server_errno=1236)
  5. May 23 09:30:08 webserver mysqld[16218]: 080523  9:30:08 [ERROR] Got fatal error 1236: 'Client requested master to start replication from impossible position' from master when reading data from binary log
  6. May 23 09:30:08 webserver mysqld[16218]: 080523  9:30:08 [Note] Slave I/O thread exiting, read up to log 'mysql-bin.000138', position 13810120
  7. May 23 09:31:49 webserver mysqld[16218]: 080523  9:31:49 [Note] Error reading relay log event: slave SQL thread was killed
  8. May 23 09:31:51 webserver mysqld[16218]: 080523  9:31:51 [Note] Slave SQL thread initialized, starting replication in log 'mysql-bin.000138' at position 13810120, relay log '/var/run/mysqld/mysqld-relay-bin.000290' position: 98
  9. May 23 09:31:51 webserver mysqld[16218]: 080523  9:31:51 [Note] Slave I/O thread: connected to master 'backup@192.168.3.6:3306',  replication started in log 'mysql-bin.000138' at position 13810120
  10. May 23 09:31:51 webserver mysqld[16218]: 080523  9:31:51 [ERROR] Error reading packet from server: Client requested master to start replication from impossible position ( server_errno=1236)
  11. May 23 09:31:51 webserver mysqld[16218]: 080523  9:31:51 [ERROR] Got fatal error 1236: 'Client requested master to start replication from impossible position' from master when reading data from binary log
  12. May 23 09:31:51 webserver mysqld[16218]: 080523  9:31:51 [Note] Slave I/O thread exiting, read up to log 'mysql-bin.000138', position 13810120
复制代码

论坛徽章:
0
2 [报告]
发表于 2008-05-23 10:18 |只看该作者
Sounds like a power failure and the repl log was not flushed to disk.

Look at here.
http://lists.mysql.com/replication/789

论坛徽章:
0
3 [报告]
发表于 2008-05-23 10:20 |只看该作者
I think this is the best reply.
I read somewhere that you need to start at the beginning of the next
binary log because the slave is trying to read beyond the end of the
current file. Its worked for me so far.

论坛徽章:
0
4 [报告]
发表于 2008-05-23 10:30 |只看该作者
请问一下你这个错误日志是从那里看到的?
show slave status \G;
吗?

论坛徽章:
0
5 [报告]
发表于 2008-05-23 10:55 |只看该作者
I got the same error when I configurate the m-s a month ago.
Here is my error message.
080429 10:22:39 [ERROR] Slave I/O thread: error reconnecting to master 'rep1@192.168.2.111:3306': Error: 'Lost connection to MySQL server at 'reading initial communication packet', system error: 111'  errno: 2013  retry-time: 60  retrie
s: 86400

论坛徽章:
3
CU大牛徽章
日期:2013-03-13 15:29:07CU大牛徽章
日期:2013-03-13 15:29:49CU大牛徽章
日期:2013-03-13 15:30:19
6 [报告]
发表于 2008-05-23 11:07 |只看该作者
老兄你都说E文了啊,先回复再看,不过确实是M断电了

论坛徽章:
3
CU大牛徽章
日期:2013-03-13 15:29:07CU大牛徽章
日期:2013-03-13 15:29:49CU大牛徽章
日期:2013-03-13 15:30:19
7 [报告]
发表于 2008-05-23 11:32 |只看该作者
原帖由 yueliangdao0608 于 2008-5-23 10:20 发表
I think this is the best reply.




How should I do?Thanks.

论坛徽章:
0
8 [报告]
发表于 2008-05-23 12:19 |只看该作者
原帖由 MYSQLER 于 2008-5-23 11:07 发表
老兄你都说E文了啊,先回复再看,不过确实是M断电了



I have been practicing my speaking during these times.

论坛徽章:
3
CU大牛徽章
日期:2013-03-13 15:29:07CU大牛徽章
日期:2013-03-13 15:29:49CU大牛徽章
日期:2013-03-13 15:30:19
9 [报告]
发表于 2008-05-23 12:58 |只看该作者
俺这问题怎么办?看了一个文章

CHANGE MASTER TO MASTER_LOG_FILE=[NEXT FILE], MASTER_LOG_POS=4;
slave start;

NEXT FILE是的bin-log日志文件吧?
MASTER_LOG_POS指什么?

论坛徽章:
0
10 [报告]
发表于 2008-05-23 13:09 |只看该作者
原帖由 MYSQLER 于 2008-5-23 12:58 发表
俺这问题怎么办?看了一个文章

CHANGE MASTER TO MASTER_LOG_FILE=[NEXT FILE], MASTER_LOG_POS=4;
slave start;

NEXT FILE是的bin-log日志文件吧?
MASTER_LOG_POS指什么?



Flush logs,then you will got what you want.
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP