mysql 主从架构问题

徐xiaoxushuai 发布于 2012/07/26 14:38
阅读 580
收藏 0

120428 13:49:59 [Note] Slave I/O thread: connected to master 'repl@192.168.0.108:3306',  replication started in log 'log.000001' at position 98
120428 14:06:32 [Note] Slave I/O thread killed while reading event
120428 14:06:32 [Note] Slave I/O thread exiting, read up to log 'log.000001', position 314
120428 14:06:32 [Note] Error reading relay log event: slave SQL thread was killed
120428 14:06:37 [Note] Slave SQL thread initialized, starting replication in log 'log.000001' at position 314, relay log './mysqld-relay-bin.000010' position: 445
120428 14:06:37 [Note] Slave I/O thread: connected to master 'repl@192.168.0.108:3306',  replication started in log 'log.000001' at position 314

这是什么问题?

 

加载中
0
逝水fox
逝水fox

需要看的是[Error]的输出,贴出来的都是[Note]沒什么用的。一二行之间应该有输出什么被楼主你删掉了吧。

如果不方便复制给外人看的话,可以在有问题的时候show slave status\G;看下Last_IO_Errno、Last_IO_Error、Last_SQL_Errno以及Last_SQL_Error这四行的内容

0
徐xiaoxushuai
徐xiaoxushuai
[root@linux ~]# tail /var/log/mysqld.log
120428 16:47:24 [Note] Slave I/O thread killed while reading event
120428 16:47:24 [Note] Slave I/O thread exiting, read up to log 'log.000001', position 314
120428 16:47:24 [Note] Error reading relay log event: slave SQL thread was killed
120428 16:47:27 [Note] Slave SQL thread initialized, starting replication in log 'log.000001' at position 314, relay log './mysqld-relay-bin.000018' position: 229
120428 16:47:27 [Note] Slave I/O thread: connected to master 'repl@192.168.0.108:3306',  replication started in log 'log.000001' at position 314
120428 18:28:31 [Note] Slave I/O thread killed while reading event
120428 18:28:31 [Note] Slave I/O thread exiting, read up to log 'log.000001', position 314
120428 18:28:31 [Note] Error reading relay log event: slave SQL thread was killed
120428 18:28:36 [Note] Slave SQL thread initialized, starting replication in log 'log.000001' at position 314, relay log './mysqld-relay-bin.000020' position: 229
120428 18:28:36 [Note] Slave I/O thread: connected to master 'repl@192.168.0.108:3306',  replication started in log 'log.000001' at position 314
这是全部 内容了,没有[Error] 这个呀
0
kevin89
kevin89
正常的输出信息啊。
0
itsusony
itsusony

在slave里面打show slave status\G

我估计是你change master to的时候没写全信息或者pos,log file写错了。

返回顶部
顶部