Commit 30df297c authored by Marko Mäkelä's avatar Marko Mäkelä

Merge 10.0 into 10.1

Rewrite the test encryption.innodb-checksum-algorithm not to
require any restarts or re-bootstrapping, and to cover all
innodb_page_size combinations.

Test innodb.101_compatibility with all innodb_page_size combinations.
parents da61107f d8d39721
[64k]
innodb-page-size=64K
innodb-buffer-pool-size=24M
[32k]
innodb-page-size=32K
innodb-buffer-pool-size=24M
[16k]
innodb-page-size=16K
[8k]
innodb-page-size=8K
[4k]
innodb-page-size=4K
# The goal of including this file is to enable innodb_page_size combinations
# (see include/innodb_page_size.combinations)
--source include/have_innodb.inc
[16k]
innodb-page-size=16K
[8k]
innodb-page-size=8K
[4k]
innodb-page-size=4K
# The goal of including this file is to enable innodb_page_size combinations
# (see include/innodb_page_size.combinations)
--source include/have_innodb.inc
...@@ -2812,10 +2812,20 @@ sub mysql_server_start($) { ...@@ -2812,10 +2812,20 @@ sub mysql_server_start($) {
} }
my $mysqld_basedir= $mysqld->value('basedir'); my $mysqld_basedir= $mysqld->value('basedir');
my $extra_opts= get_extra_opts($mysqld, $tinfo);
if ( $basedir eq $mysqld_basedir ) if ( $basedir eq $mysqld_basedir )
{ {
if (! $opt_start_dirty) # If dirty, keep possibly grown system db if (! $opt_start_dirty) # If dirty, keep possibly grown system db
{ {
# Some InnoDB options are incompatible with the default bootstrap.
# If they are used, re-bootstrap
if ( $extra_opts and
"@$extra_opts" =~ /--innodb[-_](?:page[-_]size|checksum[-_]algorithm|undo[-_]tablespaces|log[-_]group[-_]home[-_]dir|data[-_]home[-_]dir)/ )
{
mysql_install_db($mysqld, undef, $extra_opts);
}
else {
# Copy datadir from installed system db # Copy datadir from installed system db
my $path= ($opt_parallel == 1) ? "$opt_vardir" : "$opt_vardir/.."; my $path= ($opt_parallel == 1) ? "$opt_vardir" : "$opt_vardir/..";
my $install_db= "$path/install.db"; my $install_db= "$path/install.db";
...@@ -2823,6 +2833,7 @@ sub mysql_server_start($) { ...@@ -2823,6 +2833,7 @@ sub mysql_server_start($) {
mtr_error("Failed to copy system db to '$datadir'") unless -d $datadir; mtr_error("Failed to copy system db to '$datadir'") unless -d $datadir;
} }
} }
}
else else
{ {
mysql_install_db($mysqld); # For versional testing mysql_install_db($mysqld); # For versional testing
...@@ -2859,7 +2870,6 @@ sub mysql_server_start($) { ...@@ -2859,7 +2870,6 @@ sub mysql_server_start($) {
if (!$opt_embedded_server) if (!$opt_embedded_server)
{ {
my $extra_opts= get_extra_opts($mysqld, $tinfo);
mysqld_start($mysqld,$extra_opts); mysqld_start($mysqld,$extra_opts);
# Save this test case information, so next can examine it # Save this test case information, so next can examine it
...@@ -3083,7 +3093,7 @@ sub default_mysqld { ...@@ -3083,7 +3093,7 @@ sub default_mysqld {
sub mysql_install_db { sub mysql_install_db {
my ($mysqld, $datadir)= @_; my ($mysqld, $datadir, $extra_opts)= @_;
my $install_datadir= $datadir || $mysqld->value('datadir'); my $install_datadir= $datadir || $mysqld->value('datadir');
my $install_basedir= $mysqld->value('basedir'); my $install_basedir= $mysqld->value('basedir');
...@@ -3124,6 +3134,13 @@ sub mysql_install_db { ...@@ -3124,6 +3134,13 @@ sub mysql_install_db {
mtr_add_arg($args, $extra_opt); mtr_add_arg($args, $extra_opt);
} }
} }
# InnoDB options can come not only from the command line, but also
# from option files or combinations
foreach my $extra_opt ( @$extra_opts ) {
if ($extra_opt =~ /--innodb/) {
mtr_add_arg($args, $extra_opt);
}
}
# If DISABLE_GRANT_OPTIONS is defined when the server is compiled (e.g., # If DISABLE_GRANT_OPTIONS is defined when the server is compiled (e.g.,
# configure --disable-grant-options), mysqld will not recognize the # configure --disable-grant-options), mysqld will not recognize the
......
...@@ -2339,4 +2339,99 @@ id select_type table type possible_keys key key_len ref rows filtered Extra ...@@ -2339,4 +2339,99 @@ id select_type table type possible_keys key key_len ref rows filtered Extra
Warnings: Warnings:
Note 1003 select `test`.`t1`.`i1` AS `i1`,`test`.`t1`.`v1` AS `v1`,`test`.`t2`.`i2` AS `i2`,`test`.`t2`.`v2` AS `v2`,`test`.`t3`.`i3` AS `i3`,`test`.`t3`.`v3` AS `v3` from `test`.`t1` join `test`.`t2` join `test`.`t3` where ((`test`.`t3`.`v3` = 4) and (`test`.`t1`.`i1` = `test`.`t3`.`i3`) and (`test`.`t2`.`i2` = `test`.`t3`.`i3`)) Note 1003 select `test`.`t1`.`i1` AS `i1`,`test`.`t1`.`v1` AS `v1`,`test`.`t2`.`i2` AS `i2`,`test`.`t2`.`v2` AS `v2`,`test`.`t3`.`i3` AS `i3`,`test`.`t3`.`v3` AS `v3` from `test`.`t1` join `test`.`t2` join `test`.`t3` where ((`test`.`t3`.`v3` = 4) and (`test`.`t1`.`i1` = `test`.`t3`.`i3`) and (`test`.`t2`.`i2` = `test`.`t3`.`i3`))
drop table t1,t2,t3; drop table t1,t2,t3;
#
# MDEV-11958: LEFT JOIN with stored routine produces incorrect result
#
CREATE TABLE t (x INT);
INSERT INTO t VALUES(1),(NULL);
CREATE FUNCTION f (val INT, ret INT) RETURNS INT DETERMINISTIC RETURN IFNULL(val, ret);
SELECT t1.x, t2.x, IFNULL(t2.x,0), f(t2.x,0)
FROM t t1 LEFT JOIN t t2
ON t1.x = t2.x
WHERE IFNULL(t2.x,0)=0;
x x IFNULL(t2.x,0) f(t2.x,0)
NULL NULL 0 0
explain extended
SELECT t1.x, t2.x, IFNULL(t2.x,0), f(t2.x,0)
FROM t t1 LEFT JOIN t t2
ON t1.x = t2.x
WHERE IFNULL(t2.x,0)=0;
id select_type table type possible_keys key key_len ref rows filtered Extra
1 SIMPLE t1 ALL NULL NULL NULL NULL 2 100.00
1 SIMPLE t2 ALL NULL NULL NULL NULL 2 100.00 Using where
Warnings:
Note 1003 select `test`.`t1`.`x` AS `x`,`test`.`t2`.`x` AS `x`,ifnull(`test`.`t2`.`x`,0) AS `IFNULL(t2.x,0)`,`f`(`test`.`t2`.`x`,0) AS `f(t2.x,0)` from `test`.`t` `t1` left join `test`.`t` `t2` on((`test`.`t2`.`x` = `test`.`t1`.`x`)) where (ifnull(`test`.`t2`.`x`,0) = 0)
SELECT t1.x, t2.x, IFNULL(t2.x,0), f(t2.x,0)
FROM t t1 LEFT JOIN t t2
ON t1.x = t2.x
WHERE f(t2.x,0)=0;
x x IFNULL(t2.x,0) f(t2.x,0)
NULL NULL 0 0
explain extended
SELECT t1.x, t2.x, IFNULL(t2.x,0), f(t2.x,0)
FROM t t1 LEFT JOIN t t2
ON t1.x = t2.x
WHERE f(t2.x,0)=0;
id select_type table type possible_keys key key_len ref rows filtered Extra
1 SIMPLE t1 ALL NULL NULL NULL NULL 2 100.00
1 SIMPLE t2 ALL NULL NULL NULL NULL 2 100.00 Using where
Warnings:
Note 1003 select `test`.`t1`.`x` AS `x`,`test`.`t2`.`x` AS `x`,ifnull(`test`.`t2`.`x`,0) AS `IFNULL(t2.x,0)`,`f`(`test`.`t2`.`x`,0) AS `f(t2.x,0)` from `test`.`t` `t1` left join `test`.`t` `t2` on((`test`.`t2`.`x` = `test`.`t1`.`x`)) where (`f`(`test`.`t2`.`x`,0) = 0)
drop function f;
drop table t;
CREATE TABLE t1 (
col1 DECIMAL(33,5) NULL DEFAULT NULL,
col2 DECIMAL(33,5) NULL DEFAULT NULL
);
CREATE TABLE t2 (
col1 DECIMAL(33,5) NULL DEFAULT NULL,
col2 DECIMAL(33,5) NULL DEFAULT NULL,
col3 DECIMAL(33,5) NULL DEFAULT NULL
);
INSERT INTO t1 VALUES (2, 1.1), (2, 2.1);
INSERT INTO t2 VALUES (3, 3.1, 4), (1, 1, NULL);
CREATE FUNCTION f1 ( p_num DECIMAL(45,15), p_return DECIMAL(45,15))
RETURNS decimal(33,5)
LANGUAGE SQL
DETERMINISTIC
CONTAINS SQL
SQL SECURITY INVOKER
BEGIN
IF p_num IS NULL THEN
RETURN p_return;
ELSE
RETURN p_num;
END IF;
END |
SELECT t1.col1, t2.col1, t2.col3
FROM t1 LEFT OUTER JOIN t2 ON t1.col1 = t2.col2
WHERE IFNULL(t2.col3,0) = 0;
col1 col1 col3
2.00000 NULL NULL
2.00000 NULL NULL
EXPLAIN EXTENDED SELECT t1.col1, t2.col1, t2.col3
FROM t1 LEFT OUTER JOIN t2 ON t1.col1 = t2.col2
WHERE IFNULL(t2.col3,0) = 0;
id select_type table type possible_keys key key_len ref rows filtered Extra
1 SIMPLE t1 ALL NULL NULL NULL NULL 2 100.00
1 SIMPLE t2 ALL NULL NULL NULL NULL 2 100.00 Using where
Warnings:
Note 1003 select `test`.`t1`.`col1` AS `col1`,`test`.`t2`.`col1` AS `col1`,`test`.`t2`.`col3` AS `col3` from `test`.`t1` left join `test`.`t2` on((`test`.`t2`.`col2` = `test`.`t1`.`col1`)) where (ifnull(`test`.`t2`.`col3`,0) = 0)
SELECT t1.col1, t2.col1, t2.col3
FROM t1 LEFT OUTER JOIN t2 ON t1.col1 = t2.col2
WHERE f1(t2.col3,0) = 0;
col1 col1 col3
2.00000 NULL NULL
2.00000 NULL NULL
EXPLAIN EXTENDED SELECT t1.col1, t2.col1, t2.col3
FROM t1 LEFT OUTER JOIN t2 ON t1.col1 = t2.col2
WHERE f1(t2.col3,0) = 0;
id select_type table type possible_keys key key_len ref rows filtered Extra
1 SIMPLE t1 ALL NULL NULL NULL NULL 2 100.00
1 SIMPLE t2 ALL NULL NULL NULL NULL 2 100.00 Using where
Warnings:
Note 1003 select `test`.`t1`.`col1` AS `col1`,`test`.`t2`.`col1` AS `col1`,`test`.`t2`.`col3` AS `col3` from `test`.`t1` left join `test`.`t2` on((`test`.`t2`.`col2` = `test`.`t1`.`col1`)) where (`f1`(`test`.`t2`.`col3`,0) = 0)
DROP FUNCTION f1;
DROP TABLE t1,t2;
# end of 5.5 tests
SET optimizer_switch=@save_optimizer_switch; SET optimizer_switch=@save_optimizer_switch;
...@@ -2350,6 +2350,101 @@ id select_type table type possible_keys key key_len ref rows filtered Extra ...@@ -2350,6 +2350,101 @@ id select_type table type possible_keys key key_len ref rows filtered Extra
Warnings: Warnings:
Note 1003 select `test`.`t1`.`i1` AS `i1`,`test`.`t1`.`v1` AS `v1`,`test`.`t2`.`i2` AS `i2`,`test`.`t2`.`v2` AS `v2`,`test`.`t3`.`i3` AS `i3`,`test`.`t3`.`v3` AS `v3` from `test`.`t1` join `test`.`t2` join `test`.`t3` where ((`test`.`t3`.`v3` = 4) and (`test`.`t1`.`i1` = `test`.`t3`.`i3`) and (`test`.`t2`.`i2` = `test`.`t3`.`i3`)) Note 1003 select `test`.`t1`.`i1` AS `i1`,`test`.`t1`.`v1` AS `v1`,`test`.`t2`.`i2` AS `i2`,`test`.`t2`.`v2` AS `v2`,`test`.`t3`.`i3` AS `i3`,`test`.`t3`.`v3` AS `v3` from `test`.`t1` join `test`.`t2` join `test`.`t3` where ((`test`.`t3`.`v3` = 4) and (`test`.`t1`.`i1` = `test`.`t3`.`i3`) and (`test`.`t2`.`i2` = `test`.`t3`.`i3`))
drop table t1,t2,t3; drop table t1,t2,t3;
#
# MDEV-11958: LEFT JOIN with stored routine produces incorrect result
#
CREATE TABLE t (x INT);
INSERT INTO t VALUES(1),(NULL);
CREATE FUNCTION f (val INT, ret INT) RETURNS INT DETERMINISTIC RETURN IFNULL(val, ret);
SELECT t1.x, t2.x, IFNULL(t2.x,0), f(t2.x,0)
FROM t t1 LEFT JOIN t t2
ON t1.x = t2.x
WHERE IFNULL(t2.x,0)=0;
x x IFNULL(t2.x,0) f(t2.x,0)
NULL NULL 0 0
explain extended
SELECT t1.x, t2.x, IFNULL(t2.x,0), f(t2.x,0)
FROM t t1 LEFT JOIN t t2
ON t1.x = t2.x
WHERE IFNULL(t2.x,0)=0;
id select_type table type possible_keys key key_len ref rows filtered Extra
1 SIMPLE t1 ALL NULL NULL NULL NULL 2 100.00
1 SIMPLE t2 ALL NULL NULL NULL NULL 2 100.00 Using where; Using join buffer (flat, BNL join)
Warnings:
Note 1003 select `test`.`t1`.`x` AS `x`,`test`.`t2`.`x` AS `x`,ifnull(`test`.`t2`.`x`,0) AS `IFNULL(t2.x,0)`,`f`(`test`.`t2`.`x`,0) AS `f(t2.x,0)` from `test`.`t` `t1` left join `test`.`t` `t2` on((`test`.`t2`.`x` = `test`.`t1`.`x`)) where (ifnull(`test`.`t2`.`x`,0) = 0)
SELECT t1.x, t2.x, IFNULL(t2.x,0), f(t2.x,0)
FROM t t1 LEFT JOIN t t2
ON t1.x = t2.x
WHERE f(t2.x,0)=0;
x x IFNULL(t2.x,0) f(t2.x,0)
NULL NULL 0 0
explain extended
SELECT t1.x, t2.x, IFNULL(t2.x,0), f(t2.x,0)
FROM t t1 LEFT JOIN t t2
ON t1.x = t2.x
WHERE f(t2.x,0)=0;
id select_type table type possible_keys key key_len ref rows filtered Extra
1 SIMPLE t1 ALL NULL NULL NULL NULL 2 100.00
1 SIMPLE t2 ALL NULL NULL NULL NULL 2 100.00 Using where; Using join buffer (flat, BNL join)
Warnings:
Note 1003 select `test`.`t1`.`x` AS `x`,`test`.`t2`.`x` AS `x`,ifnull(`test`.`t2`.`x`,0) AS `IFNULL(t2.x,0)`,`f`(`test`.`t2`.`x`,0) AS `f(t2.x,0)` from `test`.`t` `t1` left join `test`.`t` `t2` on((`test`.`t2`.`x` = `test`.`t1`.`x`)) where (`f`(`test`.`t2`.`x`,0) = 0)
drop function f;
drop table t;
CREATE TABLE t1 (
col1 DECIMAL(33,5) NULL DEFAULT NULL,
col2 DECIMAL(33,5) NULL DEFAULT NULL
);
CREATE TABLE t2 (
col1 DECIMAL(33,5) NULL DEFAULT NULL,
col2 DECIMAL(33,5) NULL DEFAULT NULL,
col3 DECIMAL(33,5) NULL DEFAULT NULL
);
INSERT INTO t1 VALUES (2, 1.1), (2, 2.1);
INSERT INTO t2 VALUES (3, 3.1, 4), (1, 1, NULL);
CREATE FUNCTION f1 ( p_num DECIMAL(45,15), p_return DECIMAL(45,15))
RETURNS decimal(33,5)
LANGUAGE SQL
DETERMINISTIC
CONTAINS SQL
SQL SECURITY INVOKER
BEGIN
IF p_num IS NULL THEN
RETURN p_return;
ELSE
RETURN p_num;
END IF;
END |
SELECT t1.col1, t2.col1, t2.col3
FROM t1 LEFT OUTER JOIN t2 ON t1.col1 = t2.col2
WHERE IFNULL(t2.col3,0) = 0;
col1 col1 col3
2.00000 NULL NULL
2.00000 NULL NULL
EXPLAIN EXTENDED SELECT t1.col1, t2.col1, t2.col3
FROM t1 LEFT OUTER JOIN t2 ON t1.col1 = t2.col2
WHERE IFNULL(t2.col3,0) = 0;
id select_type table type possible_keys key key_len ref rows filtered Extra
1 SIMPLE t1 ALL NULL NULL NULL NULL 2 100.00
1 SIMPLE t2 ALL NULL NULL NULL NULL 2 100.00 Using where; Using join buffer (flat, BNL join)
Warnings:
Note 1003 select `test`.`t1`.`col1` AS `col1`,`test`.`t2`.`col1` AS `col1`,`test`.`t2`.`col3` AS `col3` from `test`.`t1` left join `test`.`t2` on((`test`.`t2`.`col2` = `test`.`t1`.`col1`)) where (ifnull(`test`.`t2`.`col3`,0) = 0)
SELECT t1.col1, t2.col1, t2.col3
FROM t1 LEFT OUTER JOIN t2 ON t1.col1 = t2.col2
WHERE f1(t2.col3,0) = 0;
col1 col1 col3
2.00000 NULL NULL
2.00000 NULL NULL
EXPLAIN EXTENDED SELECT t1.col1, t2.col1, t2.col3
FROM t1 LEFT OUTER JOIN t2 ON t1.col1 = t2.col2
WHERE f1(t2.col3,0) = 0;
id select_type table type possible_keys key key_len ref rows filtered Extra
1 SIMPLE t1 ALL NULL NULL NULL NULL 2 100.00
1 SIMPLE t2 ALL NULL NULL NULL NULL 2 100.00 Using where; Using join buffer (flat, BNL join)
Warnings:
Note 1003 select `test`.`t1`.`col1` AS `col1`,`test`.`t2`.`col1` AS `col1`,`test`.`t2`.`col3` AS `col3` from `test`.`t1` left join `test`.`t2` on((`test`.`t2`.`col2` = `test`.`t1`.`col1`)) where (`f1`(`test`.`t2`.`col3`,0) = 0)
DROP FUNCTION f1;
DROP TABLE t1,t2;
# end of 5.5 tests
SET optimizer_switch=@save_optimizer_switch; SET optimizer_switch=@save_optimizer_switch;
set join_cache_level=default; set join_cache_level=default;
show variables like 'join_cache_level'; show variables like 'join_cache_level';
......
--- suite/encryption/r/innodb-checksum-algorithm.result
+++ suite/encryption/r/innodb-checksum-algorithm,32k.reject
@@ -13,9 +13,9 @@
SET GLOBAL innodb_default_encryption_key_id=4;
SET GLOBAL innodb_checksum_algorithm=crc32;
create table tce_crc32(a serial, b blob, index(b(10))) engine=innodb
-ROW_FORMAT=COMPRESSED encrypted=yes;
+ROW_FORMAT=DYNAMIC encrypted=yes;
create table tc_crc32(a serial, b blob, index(b(10))) engine=innodb
-ROW_FORMAT=COMPRESSED encrypted=no;
+ROW_FORMAT=DYNAMIC encrypted=no;
create table te_crc32(a serial, b blob, index(b(10))) engine=innodb
encrypted=yes;
create table t_crc32(a serial, b blob, index(b(10))) engine=innodb
@@ -222,9 +222,9 @@
t_crc32, tpe_crc32, tp_crc32;
SET GLOBAL innodb_checksum_algorithm=innodb;
create table tce_innodb(a serial, b blob, index(b(10))) engine=innodb
-ROW_FORMAT=COMPRESSED encrypted=yes;
+ROW_FORMAT=DYNAMIC encrypted=yes;
create table tc_innodb(a serial, b blob, index(b(10))) engine=innodb
-ROW_FORMAT=COMPRESSED encrypted=no;
+ROW_FORMAT=DYNAMIC encrypted=no;
create table te_innodb(a serial, b blob, index(b(10))) engine=innodb
encrypted=yes;
create table t_innodb(a serial, b blob, index(b(10))) engine=innodb
@@ -431,9 +431,9 @@
t_innodb, tpe_innodb, tp_innodb;
SET GLOBAL innodb_checksum_algorithm=none;
create table tce_none(a serial, b blob, index(b(10))) engine=innodb
-ROW_FORMAT=COMPRESSED encrypted=yes;
+ROW_FORMAT=DYNAMIC encrypted=yes;
create table tc_none(a serial, b blob, index(b(10))) engine=innodb
-ROW_FORMAT=COMPRESSED encrypted=no;
+ROW_FORMAT=DYNAMIC encrypted=no;
create table te_none(a serial, b blob, index(b(10))) engine=innodb
encrypted=yes;
create table t_none(a serial, b blob, index(b(10))) engine=innodb
--- suite/encryption/r/innodb-checksum-algorithm.result
+++ suite/encryption/r/innodb-checksum-algorithm,64k.reject
@@ -13,9 +13,9 @@
SET GLOBAL innodb_default_encryption_key_id=4;
SET GLOBAL innodb_checksum_algorithm=crc32;
create table tce_crc32(a serial, b blob, index(b(10))) engine=innodb
-ROW_FORMAT=COMPRESSED encrypted=yes;
+ROW_FORMAT=DYNAMIC encrypted=yes;
create table tc_crc32(a serial, b blob, index(b(10))) engine=innodb
-ROW_FORMAT=COMPRESSED encrypted=no;
+ROW_FORMAT=DYNAMIC encrypted=no;
create table te_crc32(a serial, b blob, index(b(10))) engine=innodb
encrypted=yes;
create table t_crc32(a serial, b blob, index(b(10))) engine=innodb
@@ -222,9 +222,9 @@
t_crc32, tpe_crc32, tp_crc32;
SET GLOBAL innodb_checksum_algorithm=innodb;
create table tce_innodb(a serial, b blob, index(b(10))) engine=innodb
-ROW_FORMAT=COMPRESSED encrypted=yes;
+ROW_FORMAT=DYNAMIC encrypted=yes;
create table tc_innodb(a serial, b blob, index(b(10))) engine=innodb
-ROW_FORMAT=COMPRESSED encrypted=no;
+ROW_FORMAT=DYNAMIC encrypted=no;
create table te_innodb(a serial, b blob, index(b(10))) engine=innodb
encrypted=yes;
create table t_innodb(a serial, b blob, index(b(10))) engine=innodb
@@ -431,9 +431,9 @@
t_innodb, tpe_innodb, tp_innodb;
SET GLOBAL innodb_checksum_algorithm=none;
create table tce_none(a serial, b blob, index(b(10))) engine=innodb
-ROW_FORMAT=COMPRESSED encrypted=yes;
+ROW_FORMAT=DYNAMIC encrypted=yes;
create table tc_none(a serial, b blob, index(b(10))) engine=innodb
-ROW_FORMAT=COMPRESSED encrypted=no;
+ROW_FORMAT=DYNAMIC encrypted=no;
create table te_none(a serial, b blob, index(b(10))) engine=innodb
encrypted=yes;
create table t_none(a serial, b blob, index(b(10))) engine=innodb
SET @saved_file_format = @@global.innodb_file_format;
SET @saved_file_per_table = @@global.innodb_file_per_table;
SET @saved_checksum_algorithm = @@global.innodb_checksum_algorithm;
SET @saved_encrypt_tables = @@global.innodb_encrypt_tables;
SET @saved_encryption_threads = @@global.innodb_encryption_threads;
SET @saved_encryption_key_id = @@global.innodb_default_encryption_key_id;
SET GLOBAL innodb_file_format = `Barracuda`; SET GLOBAL innodb_file_format = `Barracuda`;
SET GLOBAL innodb_file_per_table = ON; SET GLOBAL innodb_file_per_table = ON;
call mtr.add_suppression("InnoDB: innodb_checksum_algorithm is set to \"strict_crc32\" but the page \\[page id: space=[0-9]+, page number=[0-9]+\\] contains a valid checksum \"innodb\". Accepting the page as valid. Change innodb_checksum_algorithm to \"crc32\" to silently accept such pages or rewrite all pages so that they contain \"crc32\" checksum."); SET GLOBAL innodb_encrypt_tables = ON;
call mtr.add_suppression("InnoDB: innodb_checksum_algorithm is set to \"strict_none\" but the page \\[page id: space=[0-9]+, page number=[0-9]+\\] contains a valid checksum \"innodb\". Accepting the page as valid. Change innodb_checksum_algorithm to \"none\" to silently accept such pages or rewrite all pages so that they contain \"none\" checksum."); SET GLOBAL innodb_encryption_threads = 4;
call mtr.add_suppression("InnoDB: innodb_checksum_algorithm is set to \"strict_crc32\" but the page \\[page id: space=[0-9]+, page number=[0-9]+\\] contains a valid checksum \"none\". Accepting the page as valid. Change innodb_checksum_algorithm to \"crc32\" to silently accept such pages or rewrite all pages so that they contain \"crc32\" checksum."); call mtr.add_suppression("InnoDB: innodb_checksum_algorithm is set to \"strict_(crc32|none|innodb)\" but the page \\[page id: space=[0-9]+, page number=[0-9]+\\] contains a valid checksum \"(innodb|none|crc32)\"");
call mtr.add_suppression("InnoDB: innodb_checksum_algorithm is set to \"strict_innodb\" but the page \\[page id: space=[0-9]+, page number=[0-9]+\\] contains a valid checksum \"none\". Accepting the page as valid. Change innodb_checksum_algorithm to \"innodb\" to silently accept such pages or rewrite all pages so that they contain \"innodb\" checksum."); SET GLOBAL innodb_checksum_algorithm = innodb;
call mtr.add_suppression("InnoDB: innodb_checksum_algorithm is set to \"strict_innodb\" but the page \\[page id: space=[0-9]+, page number=[0-9]+\\] contains a valid checksum \"crc32\". Accepting the page as valid. Change innodb_checksum_algorithm to \"innodb\" to silently accept such pages or rewrite all pages so that they contain \"innodb\" checksum."); SET GLOBAL innodb_default_encryption_key_id=4;
call mtr.add_suppression("InnoDB: innodb_checksum_algorithm is set to \"strict_none\" but the page \\[page id: space=[0-9]+, page number=[0-9]+\\] contains a valid checksum \"crc32\". Accepting the page as valid. Change innodb_checksum_algorithm to \"none\" to silently accept such pages or rewrite all pages so that they contain \"none\" checksum."); SET GLOBAL innodb_checksum_algorithm=crc32;
set GLOBAL innodb_default_encryption_key_id=4; create table tce_crc32(a serial, b blob, index(b(10))) engine=innodb
create table t1(a int not null auto_increment primary key, b blob, index(b(10))) engine=innodb row_format=compressed encrypted=yes; ROW_FORMAT=COMPRESSED encrypted=yes;
create table t2(a int not null auto_increment primary key, b blob, index(b(10))) engine=innodb encrypted=yes; create table tc_crc32(a serial, b blob, index(b(10))) engine=innodb
create table t3(a int not null auto_increment primary key, b blob, index(b(10))) engine=innodb row_format=compressed encrypted=no; ROW_FORMAT=COMPRESSED encrypted=no;
create table t4(a int not null auto_increment primary key, b blob, index(b(10))) engine=innodb encrypted=no; create table te_crc32(a serial, b blob, index(b(10))) engine=innodb
create table t5(a int not null auto_increment primary key, b blob, index(b(10))) engine=innodb encrypted=yes page_compressed=yes; encrypted=yes;
create table t_crc32(a serial, b blob, index(b(10))) engine=innodb
encrypted=no;
create table tpe_crc32(a serial, b blob, index(b(10))) engine=innodb
page_compressed=yes encrypted=yes;
create table tp_crc32(a serial, b blob, index(b(10))) engine=innodb
page_compressed=yes encrypted=no;
begin; begin;
insert into t1(b) values (repeat('secret',20)); insert into tce_crc32(b) values (repeat('secret',20));
insert into t1(b) select b from t1; insert into tc_crc32(b) values (repeat('secret',20));
insert into t1(b) select b from t1; insert into te_crc32(b) values (repeat('secret',20));
insert into t1(b) select b from t1; insert into t_crc32(b) values (repeat('secret',20));
insert into t1(b) select b from t1; insert into tpe_crc32(b) values (repeat('secret',20));
insert into t1(b) select b from t1; insert into tp_crc32(b) values (repeat('secret',20));
insert into t2(b) select b from t1;
insert into t3(b) select b from t1;
insert into t4(b) select b from t1;
insert into t5(b) select b from t1;
commit; commit;
# 1 Restart mysqld --innodb-checksum-algorithm=crc32 FLUSH TABLES tce_crc32, tc_crc32, te_crc32,
select count(*) from t1; t_crc32, tpe_crc32, tp_crc32 FOR EXPORT;
count(*) backup: tce_crc32
32 backup: tc_crc32
select count(*) from t2; backup: te_crc32
count(*) backup: t_crc32
32 backup: tpe_crc32
select count(*) from t3; backup: tp_crc32
count(*) t_crc32.cfg
32 t_crc32.frm
select count(*) from t4; t_crc32.ibd
count(*) tc_crc32.cfg
32 tc_crc32.frm
select count(*) from t5; tc_crc32.ibd
count(*) tce_crc32.cfg
32 tce_crc32.frm
insert into t1(b) select b from t1; tce_crc32.ibd
insert into t2(b) select b from t1; te_crc32.cfg
insert into t3(b) select b from t1; te_crc32.frm
insert into t4(b) select b from t1; te_crc32.ibd
insert into t5(b) select b from t1; tp_crc32.cfg
# 2 Restart mysqld --innodb-checksum-algorithm=innodb tp_crc32.frm
select count(*) from t1; tp_crc32.ibd
count(*) tpe_crc32.cfg
64 tpe_crc32.frm
select count(*) from t2; tpe_crc32.ibd
count(*) UNLOCK TABLES;
96 SET GLOBAL innodb_checksum_algorithm=strict_crc32;
select count(*) from t3; ALTER TABLE tce_crc32 DISCARD TABLESPACE;
count(*) ALTER TABLE tc_crc32 DISCARD TABLESPACE;
96 ALTER TABLE te_crc32 DISCARD TABLESPACE;
select count(*) from t4; ALTER TABLE t_crc32 DISCARD TABLESPACE;
count(*) ALTER TABLE tpe_crc32 DISCARD TABLESPACE;
96 ALTER TABLE tp_crc32 DISCARD TABLESPACE;
select count(*) from t5; restore: tce_crc32 .ibd and .cfg files
count(*) restore: tc_crc32 .ibd and .cfg files
96 restore: te_crc32 .ibd and .cfg files
insert into t1(b) select b from t1 limit 100; restore: t_crc32 .ibd and .cfg files
insert into t2(b) select b from t1 limit 100; restore: tpe_crc32 .ibd and .cfg files
insert into t3(b) select b from t1 limit 100; restore: tp_crc32 .ibd and .cfg files
insert into t4(b) select b from t1 limit 100; ALTER TABLE tce_crc32 IMPORT TABLESPACE;
insert into t5(b) select b from t1 limit 100; update tce_crc32 set b=substr(b,1);
# 3 Restart mysqld --innodb-checksum-algorithm=none ALTER TABLE tc_crc32 IMPORT TABLESPACE;
select count(*) from t1; update tc_crc32 set b=substr(b,1);
count(*) ALTER TABLE te_crc32 IMPORT TABLESPACE;
128 update te_crc32 set b=substr(b,1);
select count(*) from t2; ALTER TABLE t_crc32 IMPORT TABLESPACE;
count(*) update t_crc32 set b=substr(b,1);
196 ALTER TABLE tpe_crc32 IMPORT TABLESPACE;
select count(*) from t3; update tpe_crc32 set b=substr(b,1);
count(*) ALTER TABLE tp_crc32 IMPORT TABLESPACE;
196 update tp_crc32 set b=substr(b,1);
select count(*) from t4; SET GLOBAL innodb_checksum_algorithm=crc32;
count(*) ALTER TABLE tce_crc32 DISCARD TABLESPACE;
196 ALTER TABLE tc_crc32 DISCARD TABLESPACE;
select count(*) from t5; ALTER TABLE te_crc32 DISCARD TABLESPACE;
count(*) ALTER TABLE t_crc32 DISCARD TABLESPACE;
196 ALTER TABLE tpe_crc32 DISCARD TABLESPACE;
insert into t1(b) select b from t1 limit 100; ALTER TABLE tp_crc32 DISCARD TABLESPACE;
insert into t2(b) select b from t1 limit 100; restore: tce_crc32 .ibd and .cfg files
insert into t3(b) select b from t1 limit 100; restore: tc_crc32 .ibd and .cfg files
insert into t4(b) select b from t1 limit 100; restore: te_crc32 .ibd and .cfg files
insert into t5(b) select b from t1 limit 100; restore: t_crc32 .ibd and .cfg files
# 4 Restart mysqld --innodb-checksum-algorithm=innodb restore: tpe_crc32 .ibd and .cfg files
select count(*) from t1; restore: tp_crc32 .ibd and .cfg files
count(*) ALTER TABLE tce_crc32 IMPORT TABLESPACE;
228 update tce_crc32 set b=substr(b,1);
select count(*) from t2; ALTER TABLE tc_crc32 IMPORT TABLESPACE;
count(*) update tc_crc32 set b=substr(b,1);
296 ALTER TABLE te_crc32 IMPORT TABLESPACE;
select count(*) from t3; update te_crc32 set b=substr(b,1);
count(*) ALTER TABLE t_crc32 IMPORT TABLESPACE;
296 update t_crc32 set b=substr(b,1);
select count(*) from t4; ALTER TABLE tpe_crc32 IMPORT TABLESPACE;
count(*) update tpe_crc32 set b=substr(b,1);
296 ALTER TABLE tp_crc32 IMPORT TABLESPACE;
select count(*) from t5; update tp_crc32 set b=substr(b,1);
count(*) SET GLOBAL innodb_checksum_algorithm=strict_innodb;
296 ALTER TABLE tce_crc32 DISCARD TABLESPACE;
insert into t1(b) select b from t1 limit 100; ALTER TABLE tc_crc32 DISCARD TABLESPACE;
insert into t2(b) select b from t1 limit 100; ALTER TABLE te_crc32 DISCARD TABLESPACE;
insert into t3(b) select b from t1 limit 100; ALTER TABLE t_crc32 DISCARD TABLESPACE;
insert into t4(b) select b from t1 limit 100; ALTER TABLE tpe_crc32 DISCARD TABLESPACE;
insert into t5(b) select b from t1 limit 100; ALTER TABLE tp_crc32 DISCARD TABLESPACE;
# 5 Restart mysqld --innodb-checksum-algorithm=strict_innodb restore: tce_crc32 .ibd and .cfg files
select count(*) from t1; restore: tc_crc32 .ibd and .cfg files
count(*) restore: te_crc32 .ibd and .cfg files
328 restore: t_crc32 .ibd and .cfg files
select count(*) from t2; restore: tpe_crc32 .ibd and .cfg files
count(*) restore: tp_crc32 .ibd and .cfg files
396 ALTER TABLE tce_crc32 IMPORT TABLESPACE;
select count(*) from t3; update tce_crc32 set b=substr(b,1);
count(*) ALTER TABLE tc_crc32 IMPORT TABLESPACE;
396 update tc_crc32 set b=substr(b,1);
select count(*) from t4; ALTER TABLE te_crc32 IMPORT TABLESPACE;
count(*) update te_crc32 set b=substr(b,1);
396 ALTER TABLE t_crc32 IMPORT TABLESPACE;
select count(*) from t5; update t_crc32 set b=substr(b,1);
count(*) ALTER TABLE tpe_crc32 IMPORT TABLESPACE;
396 update tpe_crc32 set b=substr(b,1);
insert into t1(b) select b from t1 limit 100; ALTER TABLE tp_crc32 IMPORT TABLESPACE;
insert into t2(b) select b from t1 limit 100; update tp_crc32 set b=substr(b,1);
insert into t3(b) select b from t1 limit 100; SET GLOBAL innodb_checksum_algorithm=innodb;
insert into t4(b) select b from t1 limit 100; ALTER TABLE tce_crc32 DISCARD TABLESPACE;
insert into t5(b) select b from t1 limit 100; ALTER TABLE tc_crc32 DISCARD TABLESPACE;
# 6 Restart mysqld --innodb-checksum-algorithm=innodb ALTER TABLE te_crc32 DISCARD TABLESPACE;
select count(*) from t1; ALTER TABLE t_crc32 DISCARD TABLESPACE;
count(*) ALTER TABLE tpe_crc32 DISCARD TABLESPACE;
428 ALTER TABLE tp_crc32 DISCARD TABLESPACE;
select count(*) from t2; restore: tce_crc32 .ibd and .cfg files
count(*) restore: tc_crc32 .ibd and .cfg files
496 restore: te_crc32 .ibd and .cfg files
select count(*) from t3; restore: t_crc32 .ibd and .cfg files
count(*) restore: tpe_crc32 .ibd and .cfg files
496 restore: tp_crc32 .ibd and .cfg files
select count(*) from t4; ALTER TABLE tce_crc32 IMPORT TABLESPACE;
count(*) update tce_crc32 set b=substr(b,1);
496 ALTER TABLE tc_crc32 IMPORT TABLESPACE;
select count(*) from t5; update tc_crc32 set b=substr(b,1);
count(*) ALTER TABLE te_crc32 IMPORT TABLESPACE;
496 update te_crc32 set b=substr(b,1);
insert into t1(b) select b from t1 limit 100; ALTER TABLE t_crc32 IMPORT TABLESPACE;
insert into t2(b) select b from t1 limit 100; update t_crc32 set b=substr(b,1);
insert into t3(b) select b from t1 limit 100; ALTER TABLE tpe_crc32 IMPORT TABLESPACE;
insert into t4(b) select b from t1 limit 100; update tpe_crc32 set b=substr(b,1);
insert into t5(b) select b from t1 limit 100; ALTER TABLE tp_crc32 IMPORT TABLESPACE;
# 7 Restart mysqld --innodb-checksum-algorithm=strict_none update tp_crc32 set b=substr(b,1);
select count(*) from t1; SET GLOBAL innodb_checksum_algorithm=strict_none;
count(*) ALTER TABLE tce_crc32 DISCARD TABLESPACE;
528 ALTER TABLE tc_crc32 DISCARD TABLESPACE;
select count(*) from t2; ALTER TABLE te_crc32 DISCARD TABLESPACE;
count(*) ALTER TABLE t_crc32 DISCARD TABLESPACE;
596 ALTER TABLE tpe_crc32 DISCARD TABLESPACE;
select count(*) from t3; ALTER TABLE tp_crc32 DISCARD TABLESPACE;
count(*) restore: tce_crc32 .ibd and .cfg files
596 restore: tc_crc32 .ibd and .cfg files
select count(*) from t4; restore: te_crc32 .ibd and .cfg files
count(*) restore: t_crc32 .ibd and .cfg files
596 restore: tpe_crc32 .ibd and .cfg files
select count(*) from t5; restore: tp_crc32 .ibd and .cfg files
count(*) ALTER TABLE tce_crc32 IMPORT TABLESPACE;
596 update tce_crc32 set b=substr(b,1);
insert into t1(b) select b from t1 limit 100; ALTER TABLE tc_crc32 IMPORT TABLESPACE;
insert into t2(b) select b from t1 limit 100; update tc_crc32 set b=substr(b,1);
insert into t3(b) select b from t1 limit 100; ALTER TABLE te_crc32 IMPORT TABLESPACE;
insert into t4(b) select b from t1 limit 100; update te_crc32 set b=substr(b,1);
insert into t5(b) select b from t1 limit 100; ALTER TABLE t_crc32 IMPORT TABLESPACE;
# 8 Restart mysqld --innodb-checksum-algorithm=innodb update t_crc32 set b=substr(b,1);
select count(*) from t1; ALTER TABLE tpe_crc32 IMPORT TABLESPACE;
count(*) update tpe_crc32 set b=substr(b,1);
628 ALTER TABLE tp_crc32 IMPORT TABLESPACE;
select count(*) from t2; update tp_crc32 set b=substr(b,1);
count(*) SET GLOBAL innodb_checksum_algorithm=none;
696 ALTER TABLE tce_crc32 DISCARD TABLESPACE;
select count(*) from t3; ALTER TABLE tc_crc32 DISCARD TABLESPACE;
count(*) ALTER TABLE te_crc32 DISCARD TABLESPACE;
696 ALTER TABLE t_crc32 DISCARD TABLESPACE;
select count(*) from t4; ALTER TABLE tpe_crc32 DISCARD TABLESPACE;
count(*) ALTER TABLE tp_crc32 DISCARD TABLESPACE;
696 restore: tce_crc32 .ibd and .cfg files
select count(*) from t5; restore: tc_crc32 .ibd and .cfg files
count(*) restore: te_crc32 .ibd and .cfg files
696 restore: t_crc32 .ibd and .cfg files
insert into t1(b) select b from t1 limit 100; restore: tpe_crc32 .ibd and .cfg files
insert into t2(b) select b from t1 limit 100; restore: tp_crc32 .ibd and .cfg files
insert into t3(b) select b from t1 limit 100; ALTER TABLE tce_crc32 IMPORT TABLESPACE;
insert into t4(b) select b from t1 limit 100; update tce_crc32 set b=substr(b,1);
insert into t5(b) select b from t1 limit 100; ALTER TABLE tc_crc32 IMPORT TABLESPACE;
# 9 Restart mysqld --innodb-checksum-algorithm=strict_crc32 update tc_crc32 set b=substr(b,1);
select count(*) from t1; ALTER TABLE te_crc32 IMPORT TABLESPACE;
count(*) update te_crc32 set b=substr(b,1);
728 ALTER TABLE t_crc32 IMPORT TABLESPACE;
select count(*) from t2; update t_crc32 set b=substr(b,1);
count(*) ALTER TABLE tpe_crc32 IMPORT TABLESPACE;
796 update tpe_crc32 set b=substr(b,1);
select count(*) from t3; ALTER TABLE tp_crc32 IMPORT TABLESPACE;
count(*) update tp_crc32 set b=substr(b,1);
796 CHECK TABLE tce_crc32, tc_crc32, te_crc32,
select count(*) from t4; t_crc32, tpe_crc32, tp_crc32;
count(*) Table Op Msg_type Msg_text
796 test.tce_crc32 check status OK
select count(*) from t5; test.tc_crc32 check status OK
count(*) test.te_crc32 check status OK
796 test.t_crc32 check status OK
insert into t1(b) select b from t1 limit 100; test.tpe_crc32 check status OK
insert into t2(b) select b from t1 limit 100; test.tp_crc32 check status OK
insert into t3(b) select b from t1 limit 100; DROP TABLE tce_crc32, tc_crc32, te_crc32,
insert into t4(b) select b from t1 limit 100; t_crc32, tpe_crc32, tp_crc32;
insert into t5(b) select b from t1 limit 100; SET GLOBAL innodb_checksum_algorithm=innodb;
# 10 Restart mysqld --innodb-checksum-algorithm=innodb create table tce_innodb(a serial, b blob, index(b(10))) engine=innodb
select count(*) from t1; ROW_FORMAT=COMPRESSED encrypted=yes;
count(*) create table tc_innodb(a serial, b blob, index(b(10))) engine=innodb
828 ROW_FORMAT=COMPRESSED encrypted=no;
select count(*) from t2; create table te_innodb(a serial, b blob, index(b(10))) engine=innodb
count(*) encrypted=yes;
896 create table t_innodb(a serial, b blob, index(b(10))) engine=innodb
select count(*) from t3; encrypted=no;
count(*) create table tpe_innodb(a serial, b blob, index(b(10))) engine=innodb
896 page_compressed=yes encrypted=yes;
select count(*) from t4; create table tp_innodb(a serial, b blob, index(b(10))) engine=innodb
count(*) page_compressed=yes encrypted=no;
896 begin;
select count(*) from t5; insert into tce_innodb(b) values (repeat('secret',20));
count(*) insert into tc_innodb(b) values (repeat('secret',20));
896 insert into te_innodb(b) values (repeat('secret',20));
insert into t1(b) select b from t1 limit 100; insert into t_innodb(b) values (repeat('secret',20));
insert into t2(b) select b from t1 limit 100; insert into tpe_innodb(b) values (repeat('secret',20));
insert into t3(b) select b from t1 limit 100; insert into tp_innodb(b) values (repeat('secret',20));
insert into t4(b) select b from t1 limit 100; commit;
insert into t5(b) select b from t1 limit 100; FLUSH TABLES tce_innodb, tc_innodb, te_innodb,
# Restart mysqld --innodb-checksum-algorithm=crc32 t_innodb, tpe_innodb, tp_innodb FOR EXPORT;
select count(*) from t1; backup: tce_innodb
count(*) backup: tc_innodb
928 backup: te_innodb
select count(*) from t2; backup: t_innodb
count(*) backup: tpe_innodb
996 backup: tp_innodb
select count(*) from t3; t_innodb.cfg
count(*) t_innodb.frm
996 t_innodb.ibd
select count(*) from t4; tc_innodb.cfg
count(*) tc_innodb.frm
996 tc_innodb.ibd
select count(*) from t5; tce_innodb.cfg
count(*) tce_innodb.frm
996 tce_innodb.ibd
insert into t1(b) select b from t1 limit 100; te_innodb.cfg
insert into t2(b) select b from t1 limit 100; te_innodb.frm
insert into t3(b) select b from t1 limit 100; te_innodb.ibd
insert into t4(b) select b from t1 limit 100; tp_innodb.cfg
insert into t5(b) select b from t1 limit 100; tp_innodb.frm
# 11 Restart mysqld --innodb-checksum-algorithm=strict_crc32 tp_innodb.ibd
select count(*) from t1; tpe_innodb.cfg
count(*) tpe_innodb.frm
1028 tpe_innodb.ibd
select count(*) from t2; UNLOCK TABLES;
count(*) SET GLOBAL innodb_checksum_algorithm=strict_crc32;
1096 ALTER TABLE tce_innodb DISCARD TABLESPACE;
select count(*) from t3; ALTER TABLE tc_innodb DISCARD TABLESPACE;
count(*) ALTER TABLE te_innodb DISCARD TABLESPACE;
1096 ALTER TABLE t_innodb DISCARD TABLESPACE;
select count(*) from t4; ALTER TABLE tpe_innodb DISCARD TABLESPACE;
count(*) ALTER TABLE tp_innodb DISCARD TABLESPACE;
1096 restore: tce_innodb .ibd and .cfg files
select count(*) from t5; restore: tc_innodb .ibd and .cfg files
count(*) restore: te_innodb .ibd and .cfg files
1096 restore: t_innodb .ibd and .cfg files
insert into t1(b) select b from t1 limit 100; restore: tpe_innodb .ibd and .cfg files
insert into t2(b) select b from t1 limit 100; restore: tp_innodb .ibd and .cfg files
insert into t3(b) select b from t1 limit 100; ALTER TABLE tce_innodb IMPORT TABLESPACE;
insert into t4(b) select b from t1 limit 100; update tce_innodb set b=substr(b,1);
insert into t5(b) select b from t1 limit 100; ALTER TABLE tc_innodb IMPORT TABLESPACE;
# 12 Restart mysqld --innodb-checksum-algorithm=crc32 update tc_innodb set b=substr(b,1);
select count(*) from t1; ALTER TABLE te_innodb IMPORT TABLESPACE;
count(*) update te_innodb set b=substr(b,1);
1128 ALTER TABLE t_innodb IMPORT TABLESPACE;
select count(*) from t2; update t_innodb set b=substr(b,1);
count(*) ALTER TABLE tpe_innodb IMPORT TABLESPACE;
1196 update tpe_innodb set b=substr(b,1);
select count(*) from t3; ALTER TABLE tp_innodb IMPORT TABLESPACE;
count(*) update tp_innodb set b=substr(b,1);
1196 SET GLOBAL innodb_checksum_algorithm=crc32;
select count(*) from t4; ALTER TABLE tce_innodb DISCARD TABLESPACE;
count(*) ALTER TABLE tc_innodb DISCARD TABLESPACE;
1196 ALTER TABLE te_innodb DISCARD TABLESPACE;
select count(*) from t5; ALTER TABLE t_innodb DISCARD TABLESPACE;
count(*) ALTER TABLE tpe_innodb DISCARD TABLESPACE;
1196 ALTER TABLE tp_innodb DISCARD TABLESPACE;
insert into t1(b) select b from t1 limit 100; restore: tce_innodb .ibd and .cfg files
insert into t2(b) select b from t1 limit 100; restore: tc_innodb .ibd and .cfg files
insert into t3(b) select b from t1 limit 100; restore: te_innodb .ibd and .cfg files
insert into t4(b) select b from t1 limit 100; restore: t_innodb .ibd and .cfg files
insert into t5(b) select b from t1 limit 100; restore: tpe_innodb .ibd and .cfg files
# 13 Restart mysqld --innodb-checksum-algorithm=strict_none restore: tp_innodb .ibd and .cfg files
select count(*) from t1; ALTER TABLE tce_innodb IMPORT TABLESPACE;
count(*) update tce_innodb set b=substr(b,1);
1228 ALTER TABLE tc_innodb IMPORT TABLESPACE;
select count(*) from t2; update tc_innodb set b=substr(b,1);
count(*) ALTER TABLE te_innodb IMPORT TABLESPACE;
1296 update te_innodb set b=substr(b,1);
select count(*) from t3; ALTER TABLE t_innodb IMPORT TABLESPACE;
count(*) update t_innodb set b=substr(b,1);
1296 ALTER TABLE tpe_innodb IMPORT TABLESPACE;
select count(*) from t4; update tpe_innodb set b=substr(b,1);
count(*) ALTER TABLE tp_innodb IMPORT TABLESPACE;
1296 update tp_innodb set b=substr(b,1);
select count(*) from t5; SET GLOBAL innodb_checksum_algorithm=strict_innodb;
count(*) ALTER TABLE tce_innodb DISCARD TABLESPACE;
1296 ALTER TABLE tc_innodb DISCARD TABLESPACE;
insert into t1(b) select b from t1 limit 100; ALTER TABLE te_innodb DISCARD TABLESPACE;
insert into t2(b) select b from t1 limit 100; ALTER TABLE t_innodb DISCARD TABLESPACE;
insert into t3(b) select b from t1 limit 100; ALTER TABLE tpe_innodb DISCARD TABLESPACE;
insert into t4(b) select b from t1 limit 100; ALTER TABLE tp_innodb DISCARD TABLESPACE;
insert into t5(b) select b from t1 limit 100; restore: tce_innodb .ibd and .cfg files
# 14 Restart mysqld --innodb-checksum-algorithm=crc32 restore: tc_innodb .ibd and .cfg files
select count(*) from t1; restore: te_innodb .ibd and .cfg files
count(*) restore: t_innodb .ibd and .cfg files
1328 restore: tpe_innodb .ibd and .cfg files
select count(*) from t2; restore: tp_innodb .ibd and .cfg files
count(*) ALTER TABLE tce_innodb IMPORT TABLESPACE;
1396 update tce_innodb set b=substr(b,1);
select count(*) from t3; ALTER TABLE tc_innodb IMPORT TABLESPACE;
count(*) update tc_innodb set b=substr(b,1);
1396 ALTER TABLE te_innodb IMPORT TABLESPACE;
select count(*) from t4; update te_innodb set b=substr(b,1);
count(*) ALTER TABLE t_innodb IMPORT TABLESPACE;
1396 update t_innodb set b=substr(b,1);
select count(*) from t5; ALTER TABLE tpe_innodb IMPORT TABLESPACE;
count(*) update tpe_innodb set b=substr(b,1);
1396 ALTER TABLE tp_innodb IMPORT TABLESPACE;
insert into t1(b) select b from t1 limit 100; update tp_innodb set b=substr(b,1);
insert into t2(b) select b from t1 limit 100; SET GLOBAL innodb_checksum_algorithm=innodb;
insert into t3(b) select b from t1 limit 100; ALTER TABLE tce_innodb DISCARD TABLESPACE;
insert into t4(b) select b from t1 limit 100; ALTER TABLE tc_innodb DISCARD TABLESPACE;
insert into t5(b) select b from t1 limit 100; ALTER TABLE te_innodb DISCARD TABLESPACE;
# 15 Restart mysqld --innodb-checksum-algorithm=strict_innodb ALTER TABLE t_innodb DISCARD TABLESPACE;
select count(*) from t1; ALTER TABLE tpe_innodb DISCARD TABLESPACE;
count(*) ALTER TABLE tp_innodb DISCARD TABLESPACE;
1428 restore: tce_innodb .ibd and .cfg files
select count(*) from t2; restore: tc_innodb .ibd and .cfg files
count(*) restore: te_innodb .ibd and .cfg files
1496 restore: t_innodb .ibd and .cfg files
select count(*) from t3; restore: tpe_innodb .ibd and .cfg files
count(*) restore: tp_innodb .ibd and .cfg files
1496 ALTER TABLE tce_innodb IMPORT TABLESPACE;
select count(*) from t4; update tce_innodb set b=substr(b,1);
count(*) ALTER TABLE tc_innodb IMPORT TABLESPACE;
1496 update tc_innodb set b=substr(b,1);
select count(*) from t5; ALTER TABLE te_innodb IMPORT TABLESPACE;
count(*) update te_innodb set b=substr(b,1);
1496 ALTER TABLE t_innodb IMPORT TABLESPACE;
insert into t1(b) select b from t1 limit 100; update t_innodb set b=substr(b,1);
insert into t2(b) select b from t1 limit 100; ALTER TABLE tpe_innodb IMPORT TABLESPACE;
insert into t3(b) select b from t1 limit 100; update tpe_innodb set b=substr(b,1);
insert into t4(b) select b from t1 limit 100; ALTER TABLE tp_innodb IMPORT TABLESPACE;
insert into t5(b) select b from t1 limit 100; update tp_innodb set b=substr(b,1);
# 16 Restart mysqld --innodb-checksum-algorithm=crc32 SET GLOBAL innodb_checksum_algorithm=strict_none;
select count(*) from t1; ALTER TABLE tce_innodb DISCARD TABLESPACE;
count(*) ALTER TABLE tc_innodb DISCARD TABLESPACE;
1528 ALTER TABLE te_innodb DISCARD TABLESPACE;
select count(*) from t2; ALTER TABLE t_innodb DISCARD TABLESPACE;
count(*) ALTER TABLE tpe_innodb DISCARD TABLESPACE;
1596 ALTER TABLE tp_innodb DISCARD TABLESPACE;
select count(*) from t3; restore: tce_innodb .ibd and .cfg files
count(*) restore: tc_innodb .ibd and .cfg files
1596 restore: te_innodb .ibd and .cfg files
select count(*) from t4; restore: t_innodb .ibd and .cfg files
count(*) restore: tpe_innodb .ibd and .cfg files
1596 restore: tp_innodb .ibd and .cfg files
select count(*) from t5; ALTER TABLE tce_innodb IMPORT TABLESPACE;
count(*) update tce_innodb set b=substr(b,1);
1596 ALTER TABLE tc_innodb IMPORT TABLESPACE;
insert into t1(b) select b from t1 limit 100; update tc_innodb set b=substr(b,1);
insert into t2(b) select b from t1 limit 100; ALTER TABLE te_innodb IMPORT TABLESPACE;
insert into t3(b) select b from t1 limit 100; update te_innodb set b=substr(b,1);
insert into t4(b) select b from t1 limit 100; ALTER TABLE t_innodb IMPORT TABLESPACE;
insert into t5(b) select b from t1 limit 100; update t_innodb set b=substr(b,1);
# 17 Restart mysqld --innodb-checksum-algorithm=none ALTER TABLE tpe_innodb IMPORT TABLESPACE;
select count(*) from t1; update tpe_innodb set b=substr(b,1);
count(*) ALTER TABLE tp_innodb IMPORT TABLESPACE;
1628 update tp_innodb set b=substr(b,1);
select count(*) from t2; SET GLOBAL innodb_checksum_algorithm=none;
count(*) ALTER TABLE tce_innodb DISCARD TABLESPACE;
1696 ALTER TABLE tc_innodb DISCARD TABLESPACE;
select count(*) from t3; ALTER TABLE te_innodb DISCARD TABLESPACE;
count(*) ALTER TABLE t_innodb DISCARD TABLESPACE;
1696 ALTER TABLE tpe_innodb DISCARD TABLESPACE;
select count(*) from t4; ALTER TABLE tp_innodb DISCARD TABLESPACE;
count(*) restore: tce_innodb .ibd and .cfg files
1696 restore: tc_innodb .ibd and .cfg files
select count(*) from t5; restore: te_innodb .ibd and .cfg files
count(*) restore: t_innodb .ibd and .cfg files
1696 restore: tpe_innodb .ibd and .cfg files
insert into t1(b) select b from t1 limit 100; restore: tp_innodb .ibd and .cfg files
insert into t2(b) select b from t1 limit 100; ALTER TABLE tce_innodb IMPORT TABLESPACE;
insert into t3(b) select b from t1 limit 100; update tce_innodb set b=substr(b,1);
insert into t4(b) select b from t1 limit 100; ALTER TABLE tc_innodb IMPORT TABLESPACE;
insert into t5(b) select b from t1 limit 100; update tc_innodb set b=substr(b,1);
# 18 Restart mysqld --innodb-checksum-algorithm=crc32 ALTER TABLE te_innodb IMPORT TABLESPACE;
select count(*) from t1; update te_innodb set b=substr(b,1);
count(*) ALTER TABLE t_innodb IMPORT TABLESPACE;
1728 update t_innodb set b=substr(b,1);
select count(*) from t2; ALTER TABLE tpe_innodb IMPORT TABLESPACE;
count(*) update tpe_innodb set b=substr(b,1);
1796 ALTER TABLE tp_innodb IMPORT TABLESPACE;
select count(*) from t3; update tp_innodb set b=substr(b,1);
count(*) CHECK TABLE tce_innodb, tc_innodb, te_innodb,
1796 t_innodb, tpe_innodb, tp_innodb;
select count(*) from t4; Table Op Msg_type Msg_text
count(*) test.tce_innodb check status OK
1796 test.tc_innodb check status OK
select count(*) from t5; test.te_innodb check status OK
count(*) test.t_innodb check status OK
1796 test.tpe_innodb check status OK
insert into t1(b) select b from t1 limit 100; test.tp_innodb check status OK
insert into t2(b) select b from t1 limit 100; DROP TABLE tce_innodb, tc_innodb, te_innodb,
insert into t3(b) select b from t1 limit 100; t_innodb, tpe_innodb, tp_innodb;
insert into t4(b) select b from t1 limit 100; SET GLOBAL innodb_checksum_algorithm=none;
insert into t5(b) select b from t1 limit 100; create table tce_none(a serial, b blob, index(b(10))) engine=innodb
# Restart mysqld --innodb-checksum-algorithm=strict_crc32 ROW_FORMAT=COMPRESSED encrypted=yes;
select count(*) from t1; create table tc_none(a serial, b blob, index(b(10))) engine=innodb
count(*) ROW_FORMAT=COMPRESSED encrypted=no;
1828 create table te_none(a serial, b blob, index(b(10))) engine=innodb
select count(*) from t2; encrypted=yes;
count(*) create table t_none(a serial, b blob, index(b(10))) engine=innodb
1896 encrypted=no;
select count(*) from t3; create table tpe_none(a serial, b blob, index(b(10))) engine=innodb
count(*) page_compressed=yes encrypted=yes;
1896 create table tp_none(a serial, b blob, index(b(10))) engine=innodb
select count(*) from t4; page_compressed=yes encrypted=no;
count(*) begin;
1896 insert into tce_none(b) values (repeat('secret',20));
select count(*) from t5; insert into tc_none(b) values (repeat('secret',20));
count(*) insert into te_none(b) values (repeat('secret',20));
1896 insert into t_none(b) values (repeat('secret',20));
insert into t1(b) select b from t1 limit 100; insert into tpe_none(b) values (repeat('secret',20));
insert into t2(b) select b from t1 limit 100; insert into tp_none(b) values (repeat('secret',20));
insert into t3(b) select b from t1 limit 100; commit;
insert into t4(b) select b from t1 limit 100; FLUSH TABLES tce_none, tc_none, te_none,
insert into t5(b) select b from t1 limit 100; t_none, tpe_none, tp_none FOR EXPORT;
# 19 Restart mysqld --innodb-checksum-algorithm=strict_none backup: tce_none
select count(*) from t1; backup: tc_none
count(*) backup: te_none
1928 backup: t_none
select count(*) from t2; backup: tpe_none
count(*) backup: tp_none
1996 t_none.cfg
select count(*) from t3; t_none.frm
count(*) t_none.ibd
1996 tc_none.cfg
select count(*) from t4; tc_none.frm
count(*) tc_none.ibd
1996 tce_none.cfg
select count(*) from t5; tce_none.frm
count(*) tce_none.ibd
1996 te_none.cfg
insert into t1(b) select b from t1 limit 100; te_none.frm
insert into t2(b) select b from t1 limit 100; te_none.ibd
insert into t3(b) select b from t1 limit 100; tp_none.cfg
insert into t4(b) select b from t1 limit 100; tp_none.frm
insert into t5(b) select b from t1 limit 100; tp_none.ibd
# 20 Restart mysqld --innodb-checksum-algorithm=strict_crc32 tpe_none.cfg
select count(*) from t1; tpe_none.frm
count(*) tpe_none.ibd
2028 UNLOCK TABLES;
select count(*) from t2; SET GLOBAL innodb_checksum_algorithm=strict_crc32;
count(*) ALTER TABLE tce_none DISCARD TABLESPACE;
2096 ALTER TABLE tc_none DISCARD TABLESPACE;
select count(*) from t3; ALTER TABLE te_none DISCARD TABLESPACE;
count(*) ALTER TABLE t_none DISCARD TABLESPACE;
2096 ALTER TABLE tpe_none DISCARD TABLESPACE;
select count(*) from t4; ALTER TABLE tp_none DISCARD TABLESPACE;
count(*) restore: tce_none .ibd and .cfg files
2096 restore: tc_none .ibd and .cfg files
select count(*) from t5; restore: te_none .ibd and .cfg files
count(*) restore: t_none .ibd and .cfg files
2096 restore: tpe_none .ibd and .cfg files
insert into t1(b) select b from t1 limit 100; restore: tp_none .ibd and .cfg files
insert into t2(b) select b from t1 limit 100; ALTER TABLE tce_none IMPORT TABLESPACE;
insert into t3(b) select b from t1 limit 100; update tce_none set b=substr(b,1);
insert into t4(b) select b from t1 limit 100; ALTER TABLE tc_none IMPORT TABLESPACE;
insert into t5(b) select b from t1 limit 100; update tc_none set b=substr(b,1);
# 21 Restart mysqld --innodb-checksum-algorithm=strict_innodb ALTER TABLE te_none IMPORT TABLESPACE;
select count(*) from t1; update te_none set b=substr(b,1);
count(*) ALTER TABLE t_none IMPORT TABLESPACE;
2128 update t_none set b=substr(b,1);
select count(*) from t2; ALTER TABLE tpe_none IMPORT TABLESPACE;
count(*) update tpe_none set b=substr(b,1);
2196 ALTER TABLE tp_none IMPORT TABLESPACE;
select count(*) from t3; update tp_none set b=substr(b,1);
count(*) SET GLOBAL innodb_checksum_algorithm=crc32;
2196 ALTER TABLE tce_none DISCARD TABLESPACE;
select count(*) from t4; ALTER TABLE tc_none DISCARD TABLESPACE;
count(*) ALTER TABLE te_none DISCARD TABLESPACE;
2196 ALTER TABLE t_none DISCARD TABLESPACE;
select count(*) from t5; ALTER TABLE tpe_none DISCARD TABLESPACE;
count(*) ALTER TABLE tp_none DISCARD TABLESPACE;
2196 restore: tce_none .ibd and .cfg files
insert into t1(b) select b from t1 limit 100; restore: tc_none .ibd and .cfg files
insert into t2(b) select b from t1 limit 100; restore: te_none .ibd and .cfg files
insert into t3(b) select b from t1 limit 100; restore: t_none .ibd and .cfg files
insert into t4(b) select b from t1 limit 100; restore: tpe_none .ibd and .cfg files
insert into t5(b) select b from t1 limit 100; restore: tp_none .ibd and .cfg files
# 22 Restart mysqld --innodb-checksum-algorithm=strict_crc32 ALTER TABLE tce_none IMPORT TABLESPACE;
select count(*) from t1; update tce_none set b=substr(b,1);
count(*) ALTER TABLE tc_none IMPORT TABLESPACE;
2228 update tc_none set b=substr(b,1);
select count(*) from t2; ALTER TABLE te_none IMPORT TABLESPACE;
count(*) update te_none set b=substr(b,1);
2296 ALTER TABLE t_none IMPORT TABLESPACE;
select count(*) from t3; update t_none set b=substr(b,1);
count(*) ALTER TABLE tpe_none IMPORT TABLESPACE;
2296 update tpe_none set b=substr(b,1);
select count(*) from t4; ALTER TABLE tp_none IMPORT TABLESPACE;
count(*) update tp_none set b=substr(b,1);
2296 SET GLOBAL innodb_checksum_algorithm=strict_innodb;
select count(*) from t5; ALTER TABLE tce_none DISCARD TABLESPACE;
count(*) ALTER TABLE tc_none DISCARD TABLESPACE;
2296 ALTER TABLE te_none DISCARD TABLESPACE;
insert into t1(b) select b from t1 limit 100; ALTER TABLE t_none DISCARD TABLESPACE;
insert into t2(b) select b from t1 limit 100; ALTER TABLE tpe_none DISCARD TABLESPACE;
insert into t3(b) select b from t1 limit 100; ALTER TABLE tp_none DISCARD TABLESPACE;
insert into t4(b) select b from t1 limit 100; restore: tce_none .ibd and .cfg files
insert into t5(b) select b from t1 limit 100; restore: tc_none .ibd and .cfg files
# 23 Restart mysqld --innodb-checksum-algorithm=none restore: te_none .ibd and .cfg files
select count(*) from t1; restore: t_none .ibd and .cfg files
count(*) restore: tpe_none .ibd and .cfg files
2328 restore: tp_none .ibd and .cfg files
select count(*) from t2; ALTER TABLE tce_none IMPORT TABLESPACE;
count(*) update tce_none set b=substr(b,1);
2396 ALTER TABLE tc_none IMPORT TABLESPACE;
select count(*) from t3; update tc_none set b=substr(b,1);
count(*) ALTER TABLE te_none IMPORT TABLESPACE;
2396 update te_none set b=substr(b,1);
select count(*) from t4; ALTER TABLE t_none IMPORT TABLESPACE;
count(*) update t_none set b=substr(b,1);
2396 ALTER TABLE tpe_none IMPORT TABLESPACE;
select count(*) from t5; update tpe_none set b=substr(b,1);
count(*) ALTER TABLE tp_none IMPORT TABLESPACE;
2396 update tp_none set b=substr(b,1);
insert into t1(b) select b from t1 limit 100; SET GLOBAL innodb_checksum_algorithm=innodb;
insert into t2(b) select b from t1 limit 100; ALTER TABLE tce_none DISCARD TABLESPACE;
insert into t3(b) select b from t1 limit 100; ALTER TABLE tc_none DISCARD TABLESPACE;
insert into t4(b) select b from t1 limit 100; ALTER TABLE te_none DISCARD TABLESPACE;
insert into t5(b) select b from t1 limit 100; ALTER TABLE t_none DISCARD TABLESPACE;
# 24 Restart mysqld --innodb-checksum-algorithm=strict_crc32 ALTER TABLE tpe_none DISCARD TABLESPACE;
select count(*) from t1; ALTER TABLE tp_none DISCARD TABLESPACE;
count(*) restore: tce_none .ibd and .cfg files
2428 restore: tc_none .ibd and .cfg files
select count(*) from t2; restore: te_none .ibd and .cfg files
count(*) restore: t_none .ibd and .cfg files
2496 restore: tpe_none .ibd and .cfg files
select count(*) from t3; restore: tp_none .ibd and .cfg files
count(*) ALTER TABLE tce_none IMPORT TABLESPACE;
2496 update tce_none set b=substr(b,1);
select count(*) from t4; ALTER TABLE tc_none IMPORT TABLESPACE;
count(*) update tc_none set b=substr(b,1);
2496 ALTER TABLE te_none IMPORT TABLESPACE;
select count(*) from t5; update te_none set b=substr(b,1);
count(*) ALTER TABLE t_none IMPORT TABLESPACE;
2496 update t_none set b=substr(b,1);
insert into t1(b) select b from t1 limit 100; ALTER TABLE tpe_none IMPORT TABLESPACE;
insert into t2(b) select b from t1 limit 100; update tpe_none set b=substr(b,1);
insert into t3(b) select b from t1 limit 100; ALTER TABLE tp_none IMPORT TABLESPACE;
insert into t4(b) select b from t1 limit 100; update tp_none set b=substr(b,1);
insert into t5(b) select b from t1 limit 100; SET GLOBAL innodb_checksum_algorithm=strict_none;
# Restart mysqld --innodb-checksum-algorithm=strict_none ALTER TABLE tce_none DISCARD TABLESPACE;
select count(*) from t1; ALTER TABLE tc_none DISCARD TABLESPACE;
count(*) ALTER TABLE te_none DISCARD TABLESPACE;
2528 ALTER TABLE t_none DISCARD TABLESPACE;
select count(*) from t2; ALTER TABLE tpe_none DISCARD TABLESPACE;
count(*) ALTER TABLE tp_none DISCARD TABLESPACE;
2596 restore: tce_none .ibd and .cfg files
select count(*) from t3; restore: tc_none .ibd and .cfg files
count(*) restore: te_none .ibd and .cfg files
2596 restore: t_none .ibd and .cfg files
select count(*) from t4; restore: tpe_none .ibd and .cfg files
count(*) restore: tp_none .ibd and .cfg files
2596 ALTER TABLE tce_none IMPORT TABLESPACE;
select count(*) from t5; update tce_none set b=substr(b,1);
count(*) ALTER TABLE tc_none IMPORT TABLESPACE;
2596 update tc_none set b=substr(b,1);
insert into t1(b) select b from t1 limit 100; ALTER TABLE te_none IMPORT TABLESPACE;
insert into t2(b) select b from t1 limit 100; update te_none set b=substr(b,1);
insert into t3(b) select b from t1 limit 100; ALTER TABLE t_none IMPORT TABLESPACE;
insert into t4(b) select b from t1 limit 100; update t_none set b=substr(b,1);
insert into t5(b) select b from t1 limit 100; ALTER TABLE tpe_none IMPORT TABLESPACE;
# 25 Restart mysqld --innodb-checksum-algorithm=none update tpe_none set b=substr(b,1);
select count(*) from t1; ALTER TABLE tp_none IMPORT TABLESPACE;
count(*) update tp_none set b=substr(b,1);
2628 SET GLOBAL innodb_checksum_algorithm=none;
select count(*) from t2; ALTER TABLE tce_none DISCARD TABLESPACE;
count(*) ALTER TABLE tc_none DISCARD TABLESPACE;
2696 ALTER TABLE te_none DISCARD TABLESPACE;
select count(*) from t3; ALTER TABLE t_none DISCARD TABLESPACE;
count(*) ALTER TABLE tpe_none DISCARD TABLESPACE;
2696 ALTER TABLE tp_none DISCARD TABLESPACE;
select count(*) from t4; restore: tce_none .ibd and .cfg files
count(*) restore: tc_none .ibd and .cfg files
2696 restore: te_none .ibd and .cfg files
select count(*) from t5; restore: t_none .ibd and .cfg files
count(*) restore: tpe_none .ibd and .cfg files
2696 restore: tp_none .ibd and .cfg files
insert into t1(b) select b from t1 limit 100; ALTER TABLE tce_none IMPORT TABLESPACE;
insert into t2(b) select b from t1 limit 100; update tce_none set b=substr(b,1);
insert into t3(b) select b from t1 limit 100; ALTER TABLE tc_none IMPORT TABLESPACE;
insert into t4(b) select b from t1 limit 100; update tc_none set b=substr(b,1);
insert into t5(b) select b from t1 limit 100; ALTER TABLE te_none IMPORT TABLESPACE;
# 26 Restart mysqld --innodb-checksum-algorithm=strict_none update te_none set b=substr(b,1);
select count(*) from t1; ALTER TABLE t_none IMPORT TABLESPACE;
count(*) update t_none set b=substr(b,1);
2728 ALTER TABLE tpe_none IMPORT TABLESPACE;
select count(*) from t2; update tpe_none set b=substr(b,1);
count(*) ALTER TABLE tp_none IMPORT TABLESPACE;
2796 update tp_none set b=substr(b,1);
select count(*) from t3; CHECK TABLE tce_none, tc_none, te_none,
count(*) t_none, tpe_none, tp_none;
2796 Table Op Msg_type Msg_text
select count(*) from t4; test.tce_none check status OK
count(*) test.tc_none check status OK
2796 test.te_none check status OK
select count(*) from t5; test.t_none check status OK
count(*) test.tpe_none check status OK
2796 test.tp_none check status OK
insert into t1(b) select b from t1 limit 100; DROP TABLE tce_none, tc_none, te_none,
insert into t2(b) select b from t1 limit 100; t_none, tpe_none, tp_none;
insert into t3(b) select b from t1 limit 100; SET GLOBAL innodb_file_format = @saved_file_format;
insert into t4(b) select b from t1 limit 100; SET GLOBAL innodb_file_per_table = @saved_file_per_table;
insert into t5(b) select b from t1 limit 100; SET GLOBAL innodb_checksum_algorithm = @saved_checksum_algorithm;
# 27 Restart mysqld --innodb-checksum-algorithm=strict_innodb SET GLOBAL innodb_encrypt_tables = @saved_encrypt_tables;
select count(*) from t1; SET GLOBAL innodb_encryption_threads = @saved_encryption_threads;
count(*) SET GLOBAL innodb_default_encryption_key_id = @saved_encryption_key_id;
2828
select count(*) from t2;
count(*)
2896
select count(*) from t3;
count(*)
2896
select count(*) from t4;
count(*)
2896
select count(*) from t5;
count(*)
2896
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
# 28 Restart mysqld --innodb-checksum-algorithm=strict_none
select count(*) from t1;
count(*)
2928
select count(*) from t2;
count(*)
2996
select count(*) from t3;
count(*)
2996
select count(*) from t4;
count(*)
2996
select count(*) from t5;
count(*)
2996
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
# Restart mysqld --innodb-checksum-algorithm=none
select count(*) from t1;
count(*)
3028
select count(*) from t2;
count(*)
3096
select count(*) from t3;
count(*)
3096
select count(*) from t4;
count(*)
3096
select count(*) from t5;
count(*)
3096
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
# 29 Restart mysqld --innodb-checksum-algorithm=strict_innodb
select count(*) from t1;
count(*)
3128
select count(*) from t2;
count(*)
3196
select count(*) from t3;
count(*)
3196
select count(*) from t4;
count(*)
3196
select count(*) from t5;
count(*)
3196
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
# 30 Restart mysqld --innodb-checksum-algorithm=none
select count(*) from t1;
count(*)
3228
select count(*) from t2;
count(*)
3296
select count(*) from t3;
count(*)
3296
select count(*) from t4;
count(*)
3296
select count(*) from t5;
count(*)
3296
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
drop table t1,t2,t3,t4,t5;
--innodb_checksum_algorithm=innodb
--innodb-tablespaces-encryption
--innodb-encrypt-tables=on
--innodb-encryption-threads=4
-- source include/have_innodb.inc -- source include/innodb_page_size.inc
-- source include/have_file_key_management_plugin.inc -- source include/have_file_key_management_plugin.inc
# embedded does not support restart SET @saved_file_format = @@global.innodb_file_format;
-- source include/not_embedded.inc SET @saved_file_per_table = @@global.innodb_file_per_table;
SET @saved_checksum_algorithm = @@global.innodb_checksum_algorithm;
SET @saved_encrypt_tables = @@global.innodb_encrypt_tables;
SET @saved_encryption_threads = @@global.innodb_encryption_threads;
SET @saved_encryption_key_id = @@global.innodb_default_encryption_key_id;
#
# Tests:
#
# innodb
# 1) innodb => crc32
# 2) crc32 => innodb
# 3) innodb => none
# 4) none => innodb
# 5) innodb => strict_innodb
# 6) strict_innodb => innodb
# 7) innodb => strict_none
# 8) strict_none => innodb
# 9) innodb => strict_crc32
# 10) strict_crc32 => innodb
#
# crc32
# 11) crc32 => strict_crc32
# 12) strict_crc32 => crc32
# 13) crc32 => strict_none
# 14) strict_none => crc32
# 15) crc32 => strict_innodb
# 16) strict_innodb => crc32
# 17) crc32 => none
# 18) none => crc32
# (note that innodb is handled on 1 and 2)
#
# strict_crc32
# 19) strict_crc32 => strict_none
# 20) strict_none => strict_crc32
# 21) strict_crc32 => strict_innodb
# 22) strict_innodb => strict_crc32
# 23) strict_crc32 => none
# 24) none => strict_crc32
# (note that innodb is handled on 9 and 10)
# (note that crc32 is handled on 11 and 12)
#
# strict_none
# 25) strict_none => none
# 26) none => strict_none
# 27) strict_none = strict_innodb
# 28) strict_innodb => strict_none
# (note that innodb is handled on 7 and 8)
# (note that crc32 is handled on 13 and 14)
# (note that strict_crc32 is handled 19 and 20)
#
# none
# 29) none => strict_innodb
# 30) strict_innodb => none
# (note that innodb is handled on 3 and 4)
# (note that crc32 is handled on 17 and 18)
# (note that strict_crc32 is handled on 23 and 24)
# (note that strict_none is handled on 25 and 26)
#
# strict_innodb
# (note that innodb is handled on 5 and 6)
# (note that crc32 is handled on 15 and 16)
# (note that strict_crc32 is handled on 21 and 22)
# (note that strict_none is handled on 27 and 28)
# (note that none is handled on 29 and 30)
#
--disable_warnings
SET GLOBAL innodb_file_format = `Barracuda`; SET GLOBAL innodb_file_format = `Barracuda`;
SET GLOBAL innodb_file_per_table = ON; SET GLOBAL innodb_file_per_table = ON;
SET GLOBAL innodb_encrypt_tables = ON;
call mtr.add_suppression("InnoDB: innodb_checksum_algorithm is set to \"strict_crc32\" but the page \\[page id: space=[0-9]+, page number=[0-9]+\\] contains a valid checksum \"innodb\". Accepting the page as valid. Change innodb_checksum_algorithm to \"crc32\" to silently accept such pages or rewrite all pages so that they contain \"crc32\" checksum."); SET GLOBAL innodb_encryption_threads = 4;
call mtr.add_suppression("InnoDB: innodb_checksum_algorithm is set to \"strict_none\" but the page \\[page id: space=[0-9]+, page number=[0-9]+\\] contains a valid checksum \"innodb\". Accepting the page as valid. Change innodb_checksum_algorithm to \"none\" to silently accept such pages or rewrite all pages so that they contain \"none\" checksum."); call mtr.add_suppression("InnoDB: innodb_checksum_algorithm is set to \"strict_(crc32|none|innodb)\" but the page \\[page id: space=[0-9]+, page number=[0-9]+\\] contains a valid checksum \"(innodb|none|crc32)\"");
call mtr.add_suppression("InnoDB: innodb_checksum_algorithm is set to \"strict_crc32\" but the page \\[page id: space=[0-9]+, page number=[0-9]+\\] contains a valid checksum \"none\". Accepting the page as valid. Change innodb_checksum_algorithm to \"crc32\" to silently accept such pages or rewrite all pages so that they contain \"crc32\" checksum."); SET GLOBAL innodb_checksum_algorithm = innodb;
SET GLOBAL innodb_default_encryption_key_id=4;
call mtr.add_suppression("InnoDB: innodb_checksum_algorithm is set to \"strict_innodb\" but the page \\[page id: space=[0-9]+, page number=[0-9]+\\] contains a valid checksum \"none\". Accepting the page as valid. Change innodb_checksum_algorithm to \"innodb\" to silently accept such pages or rewrite all pages so that they contain \"innodb\" checksum.");
let MYSQLD_DATADIR =`SELECT @@datadir`;
call mtr.add_suppression("InnoDB: innodb_checksum_algorithm is set to \"strict_innodb\" but the page \\[page id: space=[0-9]+, page number=[0-9]+\\] contains a valid checksum \"crc32\". Accepting the page as valid. Change innodb_checksum_algorithm to \"innodb\" to silently accept such pages or rewrite all pages so that they contain \"innodb\" checksum.");
# ROW_FORMAT=COMPRESSED is unavailable with innodb_page_size=32k or 64k
call mtr.add_suppression("InnoDB: innodb_checksum_algorithm is set to \"strict_none\" but the page \\[page id: space=[0-9]+, page number=[0-9]+\\] contains a valid checksum \"crc32\". Accepting the page as valid. Change innodb_checksum_algorithm to \"none\" to silently accept such pages or rewrite all pages so that they contain \"none\" checksum."); let $row_format_compressed= `select case when @@global.innodb_page_size>16384
then 'ROW_FORMAT=DYNAMIC' else 'ROW_FORMAT=COMPRESSED' end`;
--enable_warnings
let $from = 3;
set GLOBAL innodb_default_encryption_key_id=4; while ($from)
create table t1(a int not null auto_increment primary key, b blob, index(b(10))) engine=innodb row_format=compressed encrypted=yes; {
create table t2(a int not null auto_increment primary key, b blob, index(b(10))) engine=innodb encrypted=yes; dec $from;
create table t3(a int not null auto_increment primary key, b blob, index(b(10))) engine=innodb row_format=compressed encrypted=no; let checksum = `select case $from
create table t4(a int not null auto_increment primary key, b blob, index(b(10))) engine=innodb encrypted=no; when 0 then 'none'
create table t5(a int not null auto_increment primary key, b blob, index(b(10))) engine=innodb encrypted=yes page_compressed=yes; when 1 then 'innodb'
when 2 then 'crc32'
end`;
eval SET GLOBAL innodb_checksum_algorithm=$checksum;
eval create table tce_$checksum(a serial, b blob, index(b(10))) engine=innodb
$row_format_compressed encrypted=yes;
eval create table tc_$checksum(a serial, b blob, index(b(10))) engine=innodb
$row_format_compressed encrypted=no;
eval create table te_$checksum(a serial, b blob, index(b(10))) engine=innodb
encrypted=yes;
eval create table t_$checksum(a serial, b blob, index(b(10))) engine=innodb
encrypted=no;
eval create table tpe_$checksum(a serial, b blob, index(b(10))) engine=innodb
page_compressed=yes encrypted=yes;
eval create table tp_$checksum(a serial, b blob, index(b(10))) engine=innodb
page_compressed=yes encrypted=no;
begin; begin;
insert into t1(b) values (repeat('secret',20)); eval insert into tce_$checksum(b) values (repeat('secret',20));
insert into t1(b) select b from t1; eval insert into tc_$checksum(b) values (repeat('secret',20));
insert into t1(b) select b from t1; eval insert into te_$checksum(b) values (repeat('secret',20));
insert into t1(b) select b from t1; eval insert into t_$checksum(b) values (repeat('secret',20));
insert into t1(b) select b from t1; eval insert into tpe_$checksum(b) values (repeat('secret',20));
insert into t1(b) select b from t1; eval insert into tp_$checksum(b) values (repeat('secret',20));
insert into t2(b) select b from t1;
insert into t3(b) select b from t1;
insert into t4(b) select b from t1;
insert into t5(b) select b from t1;
commit; commit;
--echo # 1 Restart mysqld --innodb-checksum-algorithm=crc32 eval FLUSH TABLES tce_$checksum, tc_$checksum, te_$checksum,
-- let $restart_parameters=--innodb-checksum-algorithm=crc32 t_$checksum, tpe_$checksum, tp_$checksum FOR EXPORT;
-- source include/restart_mysqld.inc perl;
do "$ENV{MTR_SUITE_DIR}/include/innodb-util.pl";
select count(*) from t1; my @tables = ("tce_", "tc_", "te_", "t_", "tpe_", "tp_");
select count(*) from t2; ib_backup_tablespaces("test", map{ $_ . $ENV{checksum} } @tables);
select count(*) from t3; EOF
select count(*) from t4; --list_files $MYSQLD_DATADIR/test
select count(*) from t5; UNLOCK TABLES;
insert into t1(b) select b from t1; let $to = 6;
insert into t2(b) select b from t1; while ($to)
insert into t3(b) select b from t1; {
insert into t4(b) select b from t1; dec $to;
insert into t5(b) select b from t1; let $tocksum = `select case $to
when 0 then 'none'
--echo # 2 Restart mysqld --innodb-checksum-algorithm=innodb when 1 then 'strict_none'
-- let $restart_parameters=--innodb-checksum-algorithm=innodb when 2 then 'innodb'
-- source include/restart_mysqld.inc when 3 then 'strict_innodb'
when 4 then 'crc32'
select count(*) from t1; when 5 then 'strict_crc32'
select count(*) from t2; end`;
select count(*) from t3;
select count(*) from t4; eval SET GLOBAL innodb_checksum_algorithm=$tocksum;
select count(*) from t5;
eval ALTER TABLE tce_$checksum DISCARD TABLESPACE;
insert into t1(b) select b from t1 limit 100; eval ALTER TABLE tc_$checksum DISCARD TABLESPACE;
insert into t2(b) select b from t1 limit 100; eval ALTER TABLE te_$checksum DISCARD TABLESPACE;
insert into t3(b) select b from t1 limit 100; eval ALTER TABLE t_$checksum DISCARD TABLESPACE;
insert into t4(b) select b from t1 limit 100; eval ALTER TABLE tpe_$checksum DISCARD TABLESPACE;
insert into t5(b) select b from t1 limit 100; eval ALTER TABLE tp_$checksum DISCARD TABLESPACE;
--echo # 3 Restart mysqld --innodb-checksum-algorithm=none perl;
-- let $restart_parameters=--innodb-checksum-algorithm=none do "$ENV{MTR_SUITE_DIR}/include/innodb-util.pl";
-- source include/restart_mysqld.inc my @tables = ("tce_", "tc_", "te_", "t_", "tpe_", "tp_");
ib_restore_tablespaces("test", map{ $_ . $ENV{checksum} } @tables);
select count(*) from t1; EOF
select count(*) from t2;
select count(*) from t3; eval ALTER TABLE tce_$checksum IMPORT TABLESPACE;
select count(*) from t4; eval update tce_$checksum set b=substr(b,1);
select count(*) from t5; eval ALTER TABLE tc_$checksum IMPORT TABLESPACE;
eval update tc_$checksum set b=substr(b,1);
insert into t1(b) select b from t1 limit 100; eval ALTER TABLE te_$checksum IMPORT TABLESPACE;
insert into t2(b) select b from t1 limit 100; eval update te_$checksum set b=substr(b,1);
insert into t3(b) select b from t1 limit 100; eval ALTER TABLE t_$checksum IMPORT TABLESPACE;
insert into t4(b) select b from t1 limit 100; eval update t_$checksum set b=substr(b,1);
insert into t5(b) select b from t1 limit 100; eval ALTER TABLE tpe_$checksum IMPORT TABLESPACE;
eval update tpe_$checksum set b=substr(b,1);
--echo # 4 Restart mysqld --innodb-checksum-algorithm=innodb eval ALTER TABLE tp_$checksum IMPORT TABLESPACE;
-- let $restart_parameters=--innodb-checksum-algorithm=innodb eval update tp_$checksum set b=substr(b,1);
-- source include/restart_mysqld.inc }
select count(*) from t1; eval CHECK TABLE tce_$checksum, tc_$checksum, te_$checksum,
select count(*) from t2; t_$checksum, tpe_$checksum, tp_$checksum;
select count(*) from t3; eval DROP TABLE tce_$checksum, tc_$checksum, te_$checksum,
select count(*) from t4; t_$checksum, tpe_$checksum, tp_$checksum;
select count(*) from t5; }
insert into t1(b) select b from t1 limit 100; SET GLOBAL innodb_file_format = @saved_file_format;
insert into t2(b) select b from t1 limit 100; SET GLOBAL innodb_file_per_table = @saved_file_per_table;
insert into t3(b) select b from t1 limit 100; SET GLOBAL innodb_checksum_algorithm = @saved_checksum_algorithm;
insert into t4(b) select b from t1 limit 100; SET GLOBAL innodb_encrypt_tables = @saved_encrypt_tables;
insert into t5(b) select b from t1 limit 100; SET GLOBAL innodb_encryption_threads = @saved_encryption_threads;
SET GLOBAL innodb_default_encryption_key_id = @saved_encryption_key_id;
--echo # 5 Restart mysqld --innodb-checksum-algorithm=strict_innodb
-- let $restart_parameters=--innodb-checksum-algorithm=strict_innodb
-- source include/restart_mysqld.inc
select count(*) from t1;
select count(*) from t2;
select count(*) from t3;
select count(*) from t4;
select count(*) from t5;
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
--echo # 6 Restart mysqld --innodb-checksum-algorithm=innodb
-- let $restart_parameters=--innodb-checksum-algorithm=innodb
-- source include/restart_mysqld.inc
select count(*) from t1;
select count(*) from t2;
select count(*) from t3;
select count(*) from t4;
select count(*) from t5;
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
--echo # 7 Restart mysqld --innodb-checksum-algorithm=strict_none
-- let $restart_parameters=--innodb-checksum-algorithm=strict_none
-- source include/restart_mysqld.inc
select count(*) from t1;
select count(*) from t2;
select count(*) from t3;
select count(*) from t4;
select count(*) from t5;
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
--echo # 8 Restart mysqld --innodb-checksum-algorithm=innodb
-- let $restart_parameters=--innodb-checksum-algorithm=innodb
-- source include/restart_mysqld.inc
select count(*) from t1;
select count(*) from t2;
select count(*) from t3;
select count(*) from t4;
select count(*) from t5;
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
--echo # 9 Restart mysqld --innodb-checksum-algorithm=strict_crc32
-- let $restart_parameters=--innodb-checksum-algorithm=strict_crc32
-- source include/restart_mysqld.inc
select count(*) from t1;
select count(*) from t2;
select count(*) from t3;
select count(*) from t4;
select count(*) from t5;
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
--echo # 10 Restart mysqld --innodb-checksum-algorithm=innodb
-- let $restart_parameters=--innodb-checksum-algorithm=innodb
-- source include/restart_mysqld.inc
select count(*) from t1;
select count(*) from t2;
select count(*) from t3;
select count(*) from t4;
select count(*) from t5;
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
--echo # Restart mysqld --innodb-checksum-algorithm=crc32
-- let $restart_parameters=--innodb-checksum-algorithm=crc32
-- source include/restart_mysqld.inc
select count(*) from t1;
select count(*) from t2;
select count(*) from t3;
select count(*) from t4;
select count(*) from t5;
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
--echo # 11 Restart mysqld --innodb-checksum-algorithm=strict_crc32
-- let $restart_parameters=--innodb-checksum-algorithm=strict_crc32
-- source include/restart_mysqld.inc
select count(*) from t1;
select count(*) from t2;
select count(*) from t3;
select count(*) from t4;
select count(*) from t5;
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
--echo # 12 Restart mysqld --innodb-checksum-algorithm=crc32
-- let $restart_parameters=--innodb-checksum-algorithm=crc32
-- source include/restart_mysqld.inc
select count(*) from t1;
select count(*) from t2;
select count(*) from t3;
select count(*) from t4;
select count(*) from t5;
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
--echo # 13 Restart mysqld --innodb-checksum-algorithm=strict_none
-- let $restart_parameters=--innodb-checksum-algorithm=strict_none
-- source include/restart_mysqld.inc
select count(*) from t1;
select count(*) from t2;
select count(*) from t3;
select count(*) from t4;
select count(*) from t5;
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
--echo # 14 Restart mysqld --innodb-checksum-algorithm=crc32
-- let $restart_parameters=--innodb-checksum-algorithm=crc32
-- source include/restart_mysqld.inc
select count(*) from t1;
select count(*) from t2;
select count(*) from t3;
select count(*) from t4;
select count(*) from t5;
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
--echo # 15 Restart mysqld --innodb-checksum-algorithm=strict_innodb
-- let $restart_parameters=--innodb-checksum-algorithm=strict_innodb
-- source include/restart_mysqld.inc
select count(*) from t1;
select count(*) from t2;
select count(*) from t3;
select count(*) from t4;
select count(*) from t5;
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
--echo # 16 Restart mysqld --innodb-checksum-algorithm=crc32
-- let $restart_parameters=--innodb-checksum-algorithm=crc32
-- source include/restart_mysqld.inc
select count(*) from t1;
select count(*) from t2;
select count(*) from t3;
select count(*) from t4;
select count(*) from t5;
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
--echo # 17 Restart mysqld --innodb-checksum-algorithm=none
-- let $restart_parameters=--innodb-checksum-algorithm=none
-- source include/restart_mysqld.inc
select count(*) from t1;
select count(*) from t2;
select count(*) from t3;
select count(*) from t4;
select count(*) from t5;
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
--echo # 18 Restart mysqld --innodb-checksum-algorithm=crc32
-- let $restart_parameters=--innodb-checksum-algorithm=crc32
-- source include/restart_mysqld.inc
select count(*) from t1;
select count(*) from t2;
select count(*) from t3;
select count(*) from t4;
select count(*) from t5;
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
--echo # Restart mysqld --innodb-checksum-algorithm=strict_crc32
-- let $restart_parameters=--innodb-checksum-algorithm=strict_crc32
-- source include/restart_mysqld.inc
select count(*) from t1;
select count(*) from t2;
select count(*) from t3;
select count(*) from t4;
select count(*) from t5;
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
--echo # 19 Restart mysqld --innodb-checksum-algorithm=strict_none
-- let $restart_parameters=--innodb-checksum-algorithm=strict_none
-- source include/restart_mysqld.inc
select count(*) from t1;
select count(*) from t2;
select count(*) from t3;
select count(*) from t4;
select count(*) from t5;
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
--echo # 20 Restart mysqld --innodb-checksum-algorithm=strict_crc32
-- let $restart_parameters=--innodb-checksum-algorithm=strict_crc32
-- source include/restart_mysqld.inc
select count(*) from t1;
select count(*) from t2;
select count(*) from t3;
select count(*) from t4;
select count(*) from t5;
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
--echo # 21 Restart mysqld --innodb-checksum-algorithm=strict_innodb
-- let $restart_parameters=--innodb-checksum-algorithm=strict_innodb
-- source include/restart_mysqld.inc
select count(*) from t1;
select count(*) from t2;
select count(*) from t3;
select count(*) from t4;
select count(*) from t5;
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
--echo # 22 Restart mysqld --innodb-checksum-algorithm=strict_crc32
-- let $restart_parameters=--innodb-checksum-algorithm=strict_crc32
-- source include/restart_mysqld.inc
select count(*) from t1;
select count(*) from t2;
select count(*) from t3;
select count(*) from t4;
select count(*) from t5;
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
--echo # 23 Restart mysqld --innodb-checksum-algorithm=none
-- let $restart_parameters=--innodb-checksum-algorithm=none
-- source include/restart_mysqld.inc
select count(*) from t1;
select count(*) from t2;
select count(*) from t3;
select count(*) from t4;
select count(*) from t5;
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
--echo # 24 Restart mysqld --innodb-checksum-algorithm=strict_crc32
-- let $restart_parameters=--innodb-checksum-algorithm=strict_crc32
-- source include/restart_mysqld.inc
select count(*) from t1;
select count(*) from t2;
select count(*) from t3;
select count(*) from t4;
select count(*) from t5;
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
--echo # Restart mysqld --innodb-checksum-algorithm=strict_none
-- let $restart_parameters=--innodb-checksum-algorithm=strict_none
-- source include/restart_mysqld.inc
select count(*) from t1;
select count(*) from t2;
select count(*) from t3;
select count(*) from t4;
select count(*) from t5;
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
--echo # 25 Restart mysqld --innodb-checksum-algorithm=none
-- let $restart_parameters=--innodb-checksum-algorithm=none
-- source include/restart_mysqld.inc
select count(*) from t1;
select count(*) from t2;
select count(*) from t3;
select count(*) from t4;
select count(*) from t5;
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
--echo # 26 Restart mysqld --innodb-checksum-algorithm=strict_none
-- let $restart_parameters=--innodb-checksum-algorithm=strict_none
-- source include/restart_mysqld.inc
select count(*) from t1;
select count(*) from t2;
select count(*) from t3;
select count(*) from t4;
select count(*) from t5;
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
--echo # 27 Restart mysqld --innodb-checksum-algorithm=strict_innodb
-- let $restart_parameters=--innodb-checksum-algorithm=strict_innodb
-- source include/restart_mysqld.inc
select count(*) from t1;
select count(*) from t2;
select count(*) from t3;
select count(*) from t4;
select count(*) from t5;
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
--echo # 28 Restart mysqld --innodb-checksum-algorithm=strict_none
-- let $restart_parameters=--innodb-checksum-algorithm=strict_none
-- source include/restart_mysqld.inc
select count(*) from t1;
select count(*) from t2;
select count(*) from t3;
select count(*) from t4;
select count(*) from t5;
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
--echo # Restart mysqld --innodb-checksum-algorithm=none
-- let $restart_parameters=--innodb-checksum-algorithm=none
-- source include/restart_mysqld.inc
select count(*) from t1;
select count(*) from t2;
select count(*) from t3;
select count(*) from t4;
select count(*) from t5;
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
--echo # 29 Restart mysqld --innodb-checksum-algorithm=strict_innodb
-- let $restart_parameters=--innodb-checksum-algorithm=strict_innodb
-- source include/restart_mysqld.inc
select count(*) from t1;
select count(*) from t2;
select count(*) from t3;
select count(*) from t4;
select count(*) from t5;
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
--echo # 30 Restart mysqld --innodb-checksum-algorithm=none
-- let $restart_parameters=--innodb-checksum-algorithm=none
-- source include/restart_mysqld.inc
select count(*) from t1;
select count(*) from t2;
select count(*) from t3;
select count(*) from t4;
select count(*) from t5;
insert into t1(b) select b from t1 limit 100;
insert into t2(b) select b from t1 limit 100;
insert into t3(b) select b from t1 limit 100;
insert into t4(b) select b from t1 limit 100;
insert into t5(b) select b from t1 limit 100;
drop table t1,t2,t3,t4,t5;
--source include/have_innodb.inc --source include/innodb_page_size.inc
--source include/not_embedded.inc --source include/not_embedded.inc
-- echo # -- echo #
......
--source include/have_innodb.inc --source include/innodb_page_size.inc
--source include/have_debug.inc --source include/have_debug.inc
--source include/have_debug_sync.inc --source include/have_debug_sync.inc
......
#Bug#13955083 ALLOW IN-PLACE DDL OPERATIONS ON MISSING OR DISCARDED TABLESPACES #Bug#13955083 ALLOW IN-PLACE DDL OPERATIONS ON MISSING OR DISCARDED TABLESPACES
--source include/not_embedded.inc --source include/not_embedded.inc
--source include/have_innodb.inc --source include/innodb_page_size.inc
let $MYSQLD_DATADIR=`select @@datadir`; let $MYSQLD_DATADIR=`select @@datadir`;
SET GLOBAL innodb_file_per_table=1; SET GLOBAL innodb_file_per_table=1;
......
--source include/have_innodb.inc --source include/innodb_page_size.inc
# Save the initial number of concurrent sessions. # Save the initial number of concurrent sessions.
--source include/count_sessions.inc --source include/count_sessions.inc
......
--source include/have_innodb.inc --source include/innodb_page_size.inc
# #
# MMDEV-8386: MariaDB creates very big tmp file and hangs on xtradb # MMDEV-8386: MariaDB creates very big tmp file and hangs on xtradb
......
...@@ -10,8 +10,7 @@ ...@@ -10,8 +10,7 @@
# Avoid CrashReporter popup on Mac # Avoid CrashReporter popup on Mac
--source include/not_crashrep.inc --source include/not_crashrep.inc
# InnoDB is required --source include/innodb_page_size.inc
--source include/have_innodb.inc
--echo # --echo #
--echo # Bug #18734396 INNODB IN-PLACE ALTER FAILURES BLOCK FUTURE ALTERS --echo # Bug #18734396 INNODB IN-PLACE ALTER FAILURES BLOCK FUTURE ALTERS
......
DROP DATABASE IF EXISTS mysqltest_innodb_zip;
CREATE DATABASE mysqltest_innodb_zip; CREATE DATABASE mysqltest_innodb_zip;
USE mysqltest_innodb_zip; USE mysqltest_innodb_zip;
SELECT table_name, row_format, data_length, index_length SELECT table_name, row_format, data_length, index_length
...@@ -379,5 +378,4 @@ select @@innodb_file_format_max; ...@@ -379,5 +378,4 @@ select @@innodb_file_format_max;
@@innodb_file_format_max @@innodb_file_format_max
Barracuda Barracuda
drop table normal_table, zip_table; drop table normal_table, zip_table;
USE test;
DROP DATABASE mysqltest_innodb_zip; DROP DATABASE mysqltest_innodb_zip;
--source include/have_innodb.inc --source include/innodb_page_size_small.inc
# Tests for various combinations of ROW_FORMAT and KEY_BLOCK_SIZE # Tests for various combinations of ROW_FORMAT and KEY_BLOCK_SIZE
# Related bugs; # Related bugs;
# Bug#54679: ALTER TABLE causes compressed row_format to revert to compact # Bug#54679: ALTER TABLE causes compressed row_format to revert to compact
......
-- source include/have_innodb.inc --source include/innodb_page_size_small.inc
--disable_warnings
DROP DATABASE IF EXISTS mysqltest_innodb_zip;
--enable_warnings
CREATE DATABASE mysqltest_innodb_zip; CREATE DATABASE mysqltest_innodb_zip;
USE mysqltest_innodb_zip; USE mysqltest_innodb_zip;
...@@ -13,7 +8,6 @@ SELECT table_name, row_format, data_length, index_length ...@@ -13,7 +8,6 @@ SELECT table_name, row_format, data_length, index_length
let $per_table=`select @@innodb_file_per_table`; let $per_table=`select @@innodb_file_per_table`;
let $format=`select @@innodb_file_format`; let $format=`select @@innodb_file_format`;
let $innodb_strict_mode_orig=`select @@session.innodb_strict_mode`;
let $innodb_file_format_orig=`select @@innodb_file_format`; let $innodb_file_format_orig=`select @@innodb_file_format`;
let $innodb_file_format_max_orig=`select @@innodb_file_format_max`; let $innodb_file_format_max_orig=`select @@innodb_file_format_max`;
SET @save_innodb_stats_on_metadata=@@global.innodb_stats_on_metadata; SET @save_innodb_stats_on_metadata=@@global.innodb_stats_on_metadata;
...@@ -363,12 +357,9 @@ drop table normal_table, zip_table; ...@@ -363,12 +357,9 @@ drop table normal_table, zip_table;
-- disable_query_log -- disable_query_log
eval set global innodb_file_format=$format; eval set global innodb_file_format=$format;
eval set global innodb_file_per_table=$per_table; eval set global innodb_file_per_table=$per_table;
eval set session innodb_strict_mode=$innodb_strict_mode_orig;
eval SET GLOBAL innodb_file_format=$innodb_file_format_orig; eval SET GLOBAL innodb_file_format=$innodb_file_format_orig;
eval SET GLOBAL innodb_file_format_max=$innodb_file_format_max_orig; eval SET GLOBAL innodb_file_format_max=$innodb_file_format_max_orig;
SET @@global.innodb_stats_on_metadata=@save_innodb_stats_on_metadata; SET @@global.innodb_stats_on_metadata=@save_innodb_stats_on_metadata;
--enable_query_log --enable_query_log
USE test;
DROP DATABASE mysqltest_innodb_zip; DROP DATABASE mysqltest_innodb_zip;
--source include/have_innodb.inc --source include/innodb_page_size_small.inc
# #
# Bug#36169 create innodb compressed table with too large row size crashed # Bug#36169 create innodb compressed table with too large row size crashed
# http://bugs.mysql.com/36169 # http://bugs.mysql.com/36169
......
--source include/have_innodb.inc --source include/innodb_page_size_small.inc
# #
# Test case for bug 36172 # Test case for bug 36172
# #
......
-- source include/have_innodb.inc --source include/innodb_page_size_small.inc
let $file_format=`select @@innodb_file_format`; let $file_format=`select @@innodb_file_format`;
let $file_per_table=`select @@innodb_file_per_table`; let $file_per_table=`select @@innodb_file_per_table`;
......
-- source include/have_innodb.inc --source include/innodb_page_size_small.inc
let $file_format=`select @@innodb_file_format`; let $file_format=`select @@innodb_file_format`;
let $file_per_table=`select @@innodb_file_per_table`; let $file_per_table=`select @@innodb_file_per_table`;
......
--source include/have_innodb.inc --source include/innodb_page_size_small.inc
# #
# Bug #56680 InnoDB may return wrong results from a case-insensitive index # Bug #56680 InnoDB may return wrong results from a case-insensitive index
# #
......
...@@ -1882,4 +1882,86 @@ WHERE v3 = 4; ...@@ -1882,4 +1882,86 @@ WHERE v3 = 4;
drop table t1,t2,t3; drop table t1,t2,t3;
--echo #
--echo # MDEV-11958: LEFT JOIN with stored routine produces incorrect result
--echo #
CREATE TABLE t (x INT);
INSERT INTO t VALUES(1),(NULL);
CREATE FUNCTION f (val INT, ret INT) RETURNS INT DETERMINISTIC RETURN IFNULL(val, ret);
SELECT t1.x, t2.x, IFNULL(t2.x,0), f(t2.x,0)
FROM t t1 LEFT JOIN t t2
ON t1.x = t2.x
WHERE IFNULL(t2.x,0)=0;
explain extended
SELECT t1.x, t2.x, IFNULL(t2.x,0), f(t2.x,0)
FROM t t1 LEFT JOIN t t2
ON t1.x = t2.x
WHERE IFNULL(t2.x,0)=0;
SELECT t1.x, t2.x, IFNULL(t2.x,0), f(t2.x,0)
FROM t t1 LEFT JOIN t t2
ON t1.x = t2.x
WHERE f(t2.x,0)=0;
explain extended
SELECT t1.x, t2.x, IFNULL(t2.x,0), f(t2.x,0)
FROM t t1 LEFT JOIN t t2
ON t1.x = t2.x
WHERE f(t2.x,0)=0;
drop function f;
drop table t;
CREATE TABLE t1 (
col1 DECIMAL(33,5) NULL DEFAULT NULL,
col2 DECIMAL(33,5) NULL DEFAULT NULL
);
CREATE TABLE t2 (
col1 DECIMAL(33,5) NULL DEFAULT NULL,
col2 DECIMAL(33,5) NULL DEFAULT NULL,
col3 DECIMAL(33,5) NULL DEFAULT NULL
);
INSERT INTO t1 VALUES (2, 1.1), (2, 2.1);
INSERT INTO t2 VALUES (3, 3.1, 4), (1, 1, NULL);
DELIMITER |;
CREATE FUNCTION f1 ( p_num DECIMAL(45,15), p_return DECIMAL(45,15))
RETURNS decimal(33,5)
LANGUAGE SQL
DETERMINISTIC
CONTAINS SQL
SQL SECURITY INVOKER
BEGIN
IF p_num IS NULL THEN
RETURN p_return;
ELSE
RETURN p_num;
END IF;
END |
DELIMITER ;|
let $q1=
SELECT t1.col1, t2.col1, t2.col3
FROM t1 LEFT OUTER JOIN t2 ON t1.col1 = t2.col2
WHERE IFNULL(t2.col3,0) = 0;
eval $q1;
eval EXPLAIN EXTENDED $q1;
let $q2=
SELECT t1.col1, t2.col1, t2.col3
FROM t1 LEFT OUTER JOIN t2 ON t1.col1 = t2.col2
WHERE f1(t2.col3,0) = 0;
eval $q2;
eval EXPLAIN EXTENDED $q2;
DROP FUNCTION f1;
DROP TABLE t1,t2;
--echo # end of 5.5 tests
SET optimizer_switch=@save_optimizer_switch; SET optimizer_switch=@save_optimizer_switch;
...@@ -1162,7 +1162,11 @@ class Item_func_coercibility :public Item_int_func ...@@ -1162,7 +1162,11 @@ class Item_func_coercibility :public Item_int_func
longlong val_int(); longlong val_int();
const char *func_name() const { return "coercibility"; } const char *func_name() const { return "coercibility"; }
void fix_length_and_dec() { max_length=10; maybe_null= 0; } void fix_length_and_dec() { max_length=10; maybe_null= 0; }
table_map not_null_tables() const { return 0; } bool eval_not_null_tables(uchar *)
{
not_null_tables_cache= 0;
return false;
}
Item* propagate_equal_fields(THD *thd, const Context &ctx, COND_EQUAL *cond) Item* propagate_equal_fields(THD *thd, const Context &ctx, COND_EQUAL *cond)
{ return this; } { return this; }
bool const_item() const { return true; } bool const_item() const { return true; }
...@@ -1444,7 +1448,11 @@ class Item_udf_func :public Item_func ...@@ -1444,7 +1448,11 @@ class Item_udf_func :public Item_func
} }
void cleanup(); void cleanup();
Item_result result_type () const { return udf.result_type(); } Item_result result_type () const { return udf.result_type(); }
table_map not_null_tables() const { return 0; } bool eval_not_null_tables(uchar *opt_arg)
{
not_null_tables_cache= 0;
return 0;
}
bool is_expensive() { return 1; } bool is_expensive() { return 1; }
virtual void print(String *str, enum_query_type query_type); virtual void print(String *str, enum_query_type query_type);
}; };
...@@ -1940,7 +1948,11 @@ class Item_func_match :public Item_real_func ...@@ -1940,7 +1948,11 @@ class Item_func_match :public Item_real_func
bool is_expensive_processor(uchar *arg) { return TRUE; } bool is_expensive_processor(uchar *arg) { return TRUE; }
enum Functype functype() const { return FT_FUNC; } enum Functype functype() const { return FT_FUNC; }
const char *func_name() const { return "match"; } const char *func_name() const { return "match"; }
table_map not_null_tables() const { return 0; } bool eval_not_null_tables(uchar *opt_arg)
{
not_null_tables_cache= 0;
return 0;
}
bool fix_fields(THD *thd, Item **ref); bool fix_fields(THD *thd, Item **ref);
bool eq(const Item *, bool binary_cmp) const; bool eq(const Item *, bool binary_cmp) const;
/* The following should be safe, even if we compare doubles */ /* The following should be safe, even if we compare doubles */
...@@ -2181,6 +2193,11 @@ class Item_func_sp :public Item_func ...@@ -2181,6 +2193,11 @@ class Item_func_sp :public Item_func
{ {
return TRUE; return TRUE;
} }
bool eval_not_null_tables(uchar *opt_arg)
{
not_null_tables_cache= 0;
return 0;
}
}; };
...@@ -2228,7 +2245,11 @@ class Item_func_last_value :public Item_func ...@@ -2228,7 +2245,11 @@ class Item_func_last_value :public Item_func
void fix_length_and_dec(); void fix_length_and_dec();
enum Item_result result_type () const { return last_value->result_type(); } enum Item_result result_type () const { return last_value->result_type(); }
const char *func_name() const { return "last_value"; } const char *func_name() const { return "last_value"; }
table_map not_null_tables() const { return 0; } bool eval_not_null_tables(uchar *opt_arg)
{
not_null_tables_cache= 0;
return 0;
}
enum_field_types field_type() const { return last_value->field_type(); } enum_field_types field_type() const { return last_value->field_type(); }
bool const_item() const { return 0; } bool const_item() const { return 0; }
void evaluate_sideeffects(); void evaluate_sideeffects();
......
...@@ -3386,18 +3386,12 @@ buf_page_get_gen( ...@@ -3386,18 +3386,12 @@ buf_page_get_gen(
goto loop; goto loop;
} }
fprintf(stderr,
"innodb_change_buffering_debug evict %u %u\n",
(unsigned) space, (unsigned) offset);
return(NULL); return(NULL);
} }
mutex_enter(&fix_block->mutex); mutex_enter(&fix_block->mutex);
if (buf_flush_page_try(buf_pool, fix_block)) { if (buf_flush_page_try(buf_pool, fix_block)) {
fprintf(stderr,
"innodb_change_buffering_debug flush %u %u\n",
(unsigned) space, (unsigned) offset);
guess = fix_block; guess = fix_block;
goto loop; goto loop;
} }
......
...@@ -2507,7 +2507,7 @@ DECLARE_THREAD(srv_master_thread)( ...@@ -2507,7 +2507,7 @@ DECLARE_THREAD(srv_master_thread)(
case SRV_SHUTDOWN_CLEANUP: case SRV_SHUTDOWN_CLEANUP:
if (srv_shutdown_state == SRV_SHUTDOWN_CLEANUP if (srv_shutdown_state == SRV_SHUTDOWN_CLEANUP
&& srv_fast_shutdown < 2) { && srv_fast_shutdown < 2) {
srv_shutdown(srv_fast_shutdown == 1); srv_shutdown(srv_fast_shutdown == 0);
} }
srv_suspend_thread(slot); srv_suspend_thread(slot);
my_thread_end(); my_thread_end();
......
...@@ -3446,17 +3446,10 @@ buf_page_get_gen( ...@@ -3446,17 +3446,10 @@ buf_page_get_gen(
goto loop; goto loop;
} }
fprintf(stderr,
"innodb_change_buffering_debug evict %u %u\n",
(unsigned) space, (unsigned) offset);
return(NULL); return(NULL);
} }
if (buf_flush_page_try(buf_pool, fix_block)) { if (buf_flush_page_try(buf_pool, fix_block)) {
fprintf(stderr,
"innodb_change_buffering_debug flush %u %u\n",
(unsigned) space, (unsigned) offset);
guess = fix_block;
goto loop; goto loop;
} }
......
...@@ -3193,7 +3193,7 @@ DECLARE_THREAD(srv_master_thread)( ...@@ -3193,7 +3193,7 @@ DECLARE_THREAD(srv_master_thread)(
case SRV_SHUTDOWN_CLEANUP: case SRV_SHUTDOWN_CLEANUP:
if (srv_shutdown_state == SRV_SHUTDOWN_CLEANUP if (srv_shutdown_state == SRV_SHUTDOWN_CLEANUP
&& srv_fast_shutdown < 2) { && srv_fast_shutdown < 2) {
srv_shutdown(srv_fast_shutdown == 1); srv_shutdown(srv_fast_shutdown == 0);
} }
srv_suspend_thread(slot); srv_suspend_thread(slot);
my_thread_end(); my_thread_end();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment