mirror of
https://github.com/MariaDB/server.git
synced 2025-08-08 11:22:35 +03:00
Merge 11.2 into 11.3
This commit is contained in:
@@ -59,7 +59,7 @@ SELECT * FROM t1;
|
||||
let $restart_parameters=--innodb_force_recovery=1;
|
||||
--source include/restart_mysqld.inc
|
||||
|
||||
--error ER_TABLE_CORRUPT
|
||||
--error ER_NO_SUCH_TABLE_IN_ENGINE,ER_TABLE_CORRUPT
|
||||
SELECT * FROM t1;
|
||||
SELECT * FROM t2;
|
||||
CHECK TABLE t2;
|
||||
|
@@ -1,9 +1,7 @@
|
||||
[strict_crc32]
|
||||
--innodb-checksum-algorithm=strict_crc32
|
||||
--innodb-use-atomic-writes=0
|
||||
--innodb-undo-tablespaces=0
|
||||
|
||||
[strict_full_crc32]
|
||||
--innodb-checksum-algorithm=strict_full_crc32
|
||||
--innodb-use-atomic-writes=0
|
||||
--innodb-undo-tablespaces=0
|
||||
|
@@ -28,7 +28,7 @@ show variables like 'innodb_doublewrite';
|
||||
show variables like 'innodb_fil_make_page_dirty_debug';
|
||||
show variables like 'innodb_saved_page_number_debug';
|
||||
|
||||
create table t1 (f1 int primary key, f2 blob) engine=innodb;
|
||||
create table t1 (f1 int primary key, f2 blob) engine=innodb stats_persistent=0;
|
||||
|
||||
start transaction;
|
||||
insert into t1 values(1, repeat('#',12));
|
||||
@@ -44,7 +44,9 @@ commit work;
|
||||
# Slow shutdown and restart to make sure ibuf merge is finished
|
||||
SET GLOBAL innodb_fast_shutdown = 0;
|
||||
let $shutdown_timeout=;
|
||||
let $restart_parameters="--debug_dbug=+d,ib_log_checkpoint_avoid_hard --innodb_flush_sync=0";
|
||||
--source include/restart_mysqld.inc
|
||||
--source ../include/no_checkpoint_start.inc
|
||||
begin;
|
||||
insert into t1 values (6, repeat('%', 400));
|
||||
|
||||
@@ -57,8 +59,20 @@ set global innodb_saved_page_number_debug = 1;
|
||||
set global innodb_fil_make_page_dirty_debug = 0;
|
||||
|
||||
set global innodb_buf_flush_list_now = 1;
|
||||
let $shutdown_timeout=0;
|
||||
--source include/shutdown_mysqld.inc
|
||||
|
||||
--let CLEANUP_IF_CHECKPOINT=drop table t1, unexpected_checkpoint;
|
||||
# Occasionally, a checkpoint would occur on the MSAN builder.
|
||||
# We do not know the reason, because the failure can only be reproduced if there is
|
||||
# enough load in that environment.
|
||||
# Therefore, we allow the test to be skipped when run on MSAN.
|
||||
# In other environments, we want the test to fail if a checkpoint occurs,
|
||||
# so that we would catch it if it starts to happen regularly.
|
||||
if (`select count(*) from information_schema.system_variables where variable_name='have_sanitizer' and global_value like "MSAN%"`)
|
||||
{
|
||||
--let CLEANUP_IF_CHECKPOINT=drop table t1;
|
||||
}
|
||||
|
||||
--source ../include/no_checkpoint_end.inc
|
||||
|
||||
--echo # Make the 1st page (page_no=0) and 2nd page (page_no=1)
|
||||
--echo # of the system tablespace all zeroes.
|
||||
@@ -74,6 +88,7 @@ print FILE chr(0) x ($ENV{'INNODB_PAGE_SIZE'});
|
||||
close FILE;
|
||||
EOF
|
||||
|
||||
let $restart_parameters=;
|
||||
--source include/start_mysqld.inc
|
||||
|
||||
let SEARCH_PATTERN=InnoDB: Restoring page \[page id: space=0, page number=0\] of datafile;
|
||||
@@ -90,7 +105,9 @@ select f1, f2 from t1;
|
||||
--echo # Test Begin: Test if recovery works if 1st page of
|
||||
--echo # system tablespace is corrupted and 2nd page as corrupted.
|
||||
|
||||
set global innodb_log_checkpoint_now = 1;
|
||||
let $restart_parameters="--debug_dbug=+d,ib_log_checkpoint_avoid_hard --innodb_flush_sync=0";
|
||||
--source include/restart_mysqld.inc
|
||||
--source ../include/no_checkpoint_start.inc
|
||||
begin;
|
||||
insert into t1 values (6, repeat('%', 400));
|
||||
|
||||
@@ -103,8 +120,8 @@ set global innodb_saved_page_number_debug = 1;
|
||||
set global innodb_fil_make_page_dirty_debug = 0;
|
||||
|
||||
set global innodb_buf_flush_list_now = 1;
|
||||
let $shutdown_timeout=0;
|
||||
--source include/shutdown_mysqld.inc
|
||||
|
||||
--source ../include/no_checkpoint_end.inc
|
||||
|
||||
--echo # Corrupt the 1st page (page_no=0) and 2nd page of the system tablespace.
|
||||
perl;
|
||||
@@ -119,6 +136,7 @@ print FILE chr(0) x ($ENV{'INNODB_PAGE_SIZE'}/2);
|
||||
close FILE;
|
||||
EOF
|
||||
|
||||
let $restart_parameters=;
|
||||
--source include/start_mysqld.inc
|
||||
|
||||
let SEARCH_PATTERN=InnoDB: Restoring page \[page id: space=0, page number=0\] of datafile;
|
||||
@@ -145,7 +163,7 @@ WHERE engine = 'innodb'
|
||||
AND support IN ('YES', 'DEFAULT', 'ENABLED');
|
||||
|
||||
--let $ibp=--innodb-log-group-home-dir=$bugdir --innodb-data-home-dir=$bugdir
|
||||
--let $ibd=$ibp --innodb-undo-tablespaces=0
|
||||
--let $ibp=$ibp --innodb-undo-tablespaces=0
|
||||
--let $ibp=$ibp --innodb-data-file-path=ibdata1:1M;ibdata2:1M:autoextend
|
||||
|
||||
--let $restart_parameters= $ibp
|
||||
|
@@ -19,8 +19,10 @@ SHOW INDEXES FROM t1;
|
||||
|
||||
INSERT INTO t1 VALUES ("col1_00001", "col2_00001"), ("col1_00002", "col2_00002");
|
||||
|
||||
SHOW INDEXES FROM t1;
|
||||
# Here, the cardinality would sometimes be 2 (already updated), sometimes 1.
|
||||
# SHOW INDEXES FROM t1;
|
||||
|
||||
SET STATEMENT use_stat_tables=never FOR
|
||||
ANALYZE TABLE t1;
|
||||
SHOW INDEXES FROM t1;
|
||||
|
||||
|
Reference in New Issue
Block a user