rt,今天发现了这个现象,
Slave_IO_Running 为 No ,同步也停止了
但 Slave_SQL_Running 依然为Yes,
start slave 后同步继续正常工作。大家遇见过这种现象吗? 什么样的情况会导致这种现象的出现?

解决方案 »

  1.   

    查到了:100720 15:32:55 [ERROR] Error reading packet from server: Got packet bigger than 'max_allowed_packet' bytes ( server_errno=2020)
    100720 15:32:55 [ERROR] Log entry on master is longer than max_allowed_packet (1049369) on slave. If the entry is correct, restart the server with a higher value of max_allowed_packet
    100720 15:32:55 [Note] Slave I/O thread exiting, read up to log 'mysql-bin.000028', position 766057638这个问题是 ?
      

  2.   

    而且我查了主从服务器中的max_allowed_packet值show global variables like 'max_allowed_packet';
    均为 +--------------------+---------+
    | Variable_name      | Value   |
    +--------------------+---------+
    | max_allowed_packet | 1048576 | 
    +--------------------+---------+
      

  3.   

             max_allowed_packet包或任何生成的/中间字符串的最大大小。包消息缓冲区初始化为net_buffer_length字节,但需要时可以增长到max_allowed_packet字节。该值默认很小,以捕获大的(可能是错误的)数据包。如果你使用大的BLOB 列或长字符串,你必须增加该值。应同你想要使用的最大的BLOB一样大。max_allowed_packet的协议限制为1GB。改大点吧 8M应该可以了
      

  4.   

    slave max_allowed_packet要和master的匹配(至少不能小于master的)推荐 64MB
      

  5.   

    我觉得MYSQL的ERR日志还是记录得挺全面的,甚至给出来解决方法。赞!