CREATE TABLE t1(a INT PRIMARY KEY, b INT, c LONGBLOB) ENGINE=InnoDB;
*** Test restarting the server on an existing binlog
include/reset_master.inc
SET SESSION binlog_annotate_row_events= 0;
INSERT INTO t1 VALUES (1, 0, REPEAT('@', 31760));
INSERT INTO t1 VALUES (2, 0, REPEAT('@', 100));
RESET MASTER;
INSERT INTO t1 VALUES (3, 0, REPEAT('&', 31760));
INSERT INTO t1 VALUES (4, 0, REPEAT('&', $length));
# restart
SELECT @@GLOBAL.max_binlog_size;
@@GLOBAL.max_binlog_size
262144
RESET MASTER;
INSERT INTO t1 VALUES (5, 0, REPEAT('@', 243700));
INSERT INTO t1 VALUES (6, 0, REPEAT('@', 100));
RESET MASTER;
INSERT INTO t1 VALUES (7, 0, REPEAT('&', 243700));
INSERT INTO t1 VALUES (8, 0, REPEAT('&', $length));
# restart
DROP TABLE t1;
*** Test restarting on malicious binlog file with invalid chunk_len
RESET MASTER;
# restart
SHOW BINLOG EVENTS IN 'binlog-000000.ibb';
ERROR HY000: Error when executing command SHOW BINLOG EVENTS: error reading event data
CALL mtr.add_suppression("InnoDB: Corrupt binlog found on page 1 in binlog number 0: Invalid chunk length");
¤ Dauer der Verarbeitung: 0.1 Sekunden
(vorverarbeitet am 2026-11-24)
¤
*© Formatika GbR, Deutschland