| 1 |
call mtr.add_suppression("mariadbd.*: File "); |
| 2 |
call mtr.add_suppression("Plugin 'file_key_management' "); |
| 3 |
call mtr.add_suppression("InnoDB: Recovery cannot access file"); |
| 4 |
call mtr.add_suppression("InnoDB: Plugin initialization aborted"); |
| 5 |
call mtr.add_suppression("Plugin 'InnoDB' init function returned error\\."); |
| 6 |
call mtr.add_suppression("Plugin 'InnoDB' registration as a STORAGE ENGINE failed."); |
| 7 |
call mtr.add_suppression("Fewer engines are enabled now than were before the crash"); |
| 8 |
call mtr.add_suppression("InnoDB: (Unable to apply log to|Discarding log for) corrupted page "); |
| 9 |
call mtr.add_suppression("InnoDB: Cannot apply log to \\[page id: space=[1-9][0-9]*, page number=0\\] of corrupted file '.*test.t[1-5]\\.ibd'"); |
| 10 |
call mtr.add_suppression("InnoDB: Failed to read page .* from file '.*'"); |
| 11 |
call mtr.add_suppression("InnoDB: OPT_PAGE_CHECKSUM mismatch"); |
| 12 |
call mtr.add_suppression("InnoDB: Missing FILE_CHECKPOINT"); |
| 13 |
call mtr.add_suppression("InnoDB: Log scan aborted at LSN"); |
| 14 |
call mtr.add_suppression("InnoDB: Set innodb_force_recovery=1 to ignore corruption"); |
| 15 |
call mtr.add_suppression("InnoDB: Encryption key is not found for"); |
| 16 |
# restart: --file-key-management-filename=MYSQL_TEST_DIR/std_data/keys2.txt |
| 17 |
create table t1(a int not null primary key auto_increment, c char(200), b blob, index(b(10))) engine=innodb row_format=compressed encrypted=yes encryption_key_id=20; |
| 18 |
create table t2(a int not null primary key auto_increment, c char(200), b blob, index(b(10))) engine=innodb row_format=compressed encrypted=yes; |
| 19 |
create table t3(a int not null primary key auto_increment, c char(200), b blob, index(b(10))) engine=innodb encrypted=yes encryption_key_id=20; |
| 20 |
create table t4(a int not null primary key auto_increment, c char(200), b blob, index(b(10))) engine=innodb encrypted=yes; |
| 21 |
begin; |
| 22 |
insert into t2 select * from t1; |
| 23 |
insert into t3 select * from t1; |
| 24 |
insert into t4 select * from t1; |
| 25 |
commit; |
| 26 |
|
| 27 |
# Flush all dirty pages from buffer pool |
| 28 |
SET @no_checkpoint_save_pct= @@GLOBAL.innodb_max_dirty_pages_pct; |
| 29 |
SET @no_checkpoint_save_pct_lwm= @@GLOBAL.innodb_max_dirty_pages_pct_lwm; |
| 30 |
SET GLOBAL innodb_max_dirty_pages_pct_lwm=0.0; |
| 31 |
SET GLOBAL innodb_max_dirty_pages_pct=0.0; |
| 32 |
SET GLOBAL innodb_max_dirty_pages_pct= @no_checkpoint_save_pct; |
| 33 |
SET GLOBAL innodb_max_dirty_pages_pct_lwm= @no_checkpoint_save_pct_lwm; |
| 34 |
|
| 35 |
CREATE TABLE t5 (a VARCHAR(8)) ENGINE=InnoDB ENCRYPTED=YES; |
| 36 |
SET GLOBAL innodb_flush_log_at_trx_commit=1; |
| 37 |
begin; |
| 38 |
update t1 set c = repeat('secret3', 20); |
| 39 |
update t2 set c = repeat('secret4', 20); |
| 40 |
update t3 set c = repeat('secret4', 20); |
| 41 |
update t4 set c = repeat('secret4', 20); |
| 42 |
insert into t1 (c,b) values (repeat('secret5',20), repeat('secret6',6000)); |
| 43 |
insert into t2 (c,b) values (repeat('secret7',20), repeat('secret8',6000)); |
| 44 |
insert into t3 (c,b) values (repeat('secret9',20), repeat('secre10',6000)); |
| 45 |
insert into t4 (c,b) values (repeat('secre11',20), repeat('secre12',6000)); |
| 46 |
INSERT INTO t5 VALUES ('foo'),('bar'); |
| 47 |
COMMIT; |
| 48 |
# Kill the server |
| 49 |
# restart: --file-key-management-filename=MYSQL_TEST_DIR/std_data/keys-not-found.txt |
| 50 |
SELECT * FROM INFORMATION_SCHEMA.ENGINES |
| 51 |
WHERE engine = 'innodb' |
| 52 |
AND support IN ('YES', 'DEFAULT', 'ENABLED'); |
| 53 |
ENGINE SUPPORT COMMENT TRANSACTIONS XA SAVEPOINTS |
| 54 |
FOUND 1 /\[ERROR\] InnoDB: Encryption key is not found for .*test.t[1-5].ibd/ in mysqld.1.err |
| 55 |
# restart: --file-key-management-filename=MYSQL_TEST_DIR/std_data/keys2.txt |
| 56 |
drop table t1,t2,t3,t4,t5; |