MySQL複製錯誤]Last_Errno: 1666 Last_Error: Error executing row event: 'Cannot execute statement: impossmysql
收到email報警, Last_Error: Error executing row event: 'Cannot execute statement: impossible to write to binary log since statement is in row format and BINLOG_FORMAT = STATEMENT.'sql
mysql> show slave status;orm
看到貌似是statement模式不足以應付應用,換成mixed試試看吧:
mysql> STOP SLAVE;
Query OK, 0 rows affected (0.02 sec)
mysql> SET GLOBAL binlog_format=MIXED;
Query OK, 0 rows affected (0.00 sec)
mysql> START SLAVE;
Query OK, 0 rows affected (0.00 sec)it
可是這樣只會一次性io
爲了永久生效,須要修改my.inievent
# Remove leading ast
# to turn on a very important data integrity option: logging form
# changes to the binary log between backups. email
log_bin = E:/mysql56/log_bin/log_bin.log import
#relay_log = E:/mysql56/log_bin/relay_log.log
#read_only = 1
# binary logging format - mixed recommended
binlog_format=mixed