From 55a7159f531dbd06449845ac2dd890aa51994088 Mon Sep 17 00:00:00 2001 From: unknown Date: Thu, 21 Nov 2013 14:42:25 +0100 Subject: MDEV-4982: GTID looses all binlog state after crash if InnoDB is disabled MDEV-4725: Incorrect binlog state recovery if crash while writing event group The binlog state was not recovered correctly if XA is not used (eg. InnoDB disabled), or if server crashed in the middle of writing an event group to the binlog. With this patch, we ensure that recovery of binlog state is done even if we do not do the full XA binlog recovery, and we ensure that we only recover fully written event groups into the binlog state. --- .../suite/rpl/r/rpl_gtid_crash_myisam.result | 24 ++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 mysql-test/suite/rpl/r/rpl_gtid_crash_myisam.result (limited to 'mysql-test/suite/rpl/r/rpl_gtid_crash_myisam.result') diff --git a/mysql-test/suite/rpl/r/rpl_gtid_crash_myisam.result b/mysql-test/suite/rpl/r/rpl_gtid_crash_myisam.result new file mode 100644 index 00000000000..55465d7e81b --- /dev/null +++ b/mysql-test/suite/rpl/r/rpl_gtid_crash_myisam.result @@ -0,0 +1,24 @@ +include/rpl_init.inc [topology=1->2] +*** Test crashing master with InnoDB disabled, the binlog gtid state should still be correctly recovered. *** +CREATE TABLE t1 (a INT PRIMARY KEY) ENGINE=MyISAM; +include/stop_slave.inc +CHANGE MASTER TO master_use_gtid=slave_pos; +include/start_slave.inc +INSERT INTO t1 VALUES (1); +INSERT INTO t1 VALUES (2); +SELECT * FROM t1 ORDER BY a; +a +1 +2 +FLUSH TABLES; +SET SESSION debug_dbug="+d,crash_dispatch_command_before"; +SELECT 1; +Got one of the listed errors +INSERT INTO t1 VALUES (3); +SELECT * FROM t1 ORDER BY a; +a +1 +2 +3 +DROP TABLE t1; +include/rpl_end.inc -- cgit v1.2.1