summaryrefslogtreecommitdiffstats
path: root/mysql-test/suite/innodb/t/innodb_scrub.test
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-04 18:00:34 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-04 18:00:34 +0000
commit3f619478f796eddbba6e39502fe941b285dd97b1 (patch)
treee2c7b5777f728320e5b5542b6213fd3591ba51e2 /mysql-test/suite/innodb/t/innodb_scrub.test
parentInitial commit. (diff)
downloadmariadb-upstream.tar.xz
mariadb-upstream.zip
Adding upstream version 1:10.11.6.upstream/1%10.11.6upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'mysql-test/suite/innodb/t/innodb_scrub.test')
-rw-r--r--mysql-test/suite/innodb/t/innodb_scrub.test45
1 files changed, 45 insertions, 0 deletions
diff --git a/mysql-test/suite/innodb/t/innodb_scrub.test b/mysql-test/suite/innodb/t/innodb_scrub.test
new file mode 100644
index 00000000..8fe460da
--- /dev/null
+++ b/mysql-test/suite/innodb/t/innodb_scrub.test
@@ -0,0 +1,45 @@
+-- source include/have_innodb.inc
+-- source include/no_valgrind_without_big.inc
+
+let $MYSQLD_DATADIR=`select @@datadir`;
+CREATE TABLE t1(f1 int auto_increment primary key,
+ f2 varchar(256),
+ f3 text) engine = innodb;
+let $numinserts = 500;
+--disable_query_log
+begin;
+while ($numinserts)
+{
+ dec $numinserts;
+ eval INSERT INTO t1(f2,f3) VALUES ('repairman', repeat('unicycle', 1000));
+}
+commit;
+--enable_query_log
+FLUSH TABLE t1 FOR EXPORT;
+UNLOCK TABLES;
+
+let SEARCH_PATTERN= unicycle|repairman;
+let SEARCH_FILE= $MYSQLD_DATADIR/test/t1.ibd;
+-- source include/search_pattern_in_file.inc
+DELETE FROM t1;
+-- source include/wait_all_purged.inc
+FLUSH TABLE t1 FOR EXPORT;
+UNLOCK TABLES;
+-- source include/search_pattern_in_file.inc
+DROP TABLE t1;
+
+--echo #
+--echo # MDEV-30527 Assertion !m_freed_pages in mtr_t::start()
+--echo # on DROP TEMPORARY TABLE
+--echo #
+SET @scrub= @@GLOBAL.innodb_immediate_scrub_data_uncompressed;
+SET GLOBAL innodb_immediate_scrub_data_uncompressed= 1;
+SET @fpt=@@GLOBAL.innodb_file_per_table;
+SET GLOBAL innodb_file_per_table=0;
+CREATE TABLE t ENGINE=InnoDB AS SELECT 1;
+DROP TABLE t;
+SET GLOBAL innodb_file_per_table=@fpt;
+CREATE TEMPORARY TABLE tmp ENGINE=InnoDB AS SELECT 1;
+DROP TABLE tmp;
+SET GLOBAL INNODB_IMMEDIATE_SCRUB_DATA_UNCOMPRESSED= @scrub;
+--echo # End of 10.6 tests