2017-06-13 16:20:21 +03:00
|
|
|
--source include/innodb_page_size.inc
|
|
|
|
# Embedded server tests do not support restarting
|
|
|
|
--source include/not_embedded.inc
|
2022-10-05 15:15:28 +03:00
|
|
|
# Slow shutdown may take more than 120 seconds under Valgrind,
|
|
|
|
# causing the server to be (silently) killed.
|
|
|
|
# Due to that, crash recovery could "heal" the damage that our
|
|
|
|
# Perl code is inflicting, and the SELECT statements could succeed
|
|
|
|
# instead of failing with ER_NO_SUCH_TABLE_IN_ENGINE.
|
|
|
|
--source include/not_valgrind.inc
|
2017-06-13 16:20:21 +03:00
|
|
|
|
|
|
|
--disable_query_log
|
2017-06-15 14:35:51 +03:00
|
|
|
call mtr.add_suppression("InnoDB: Table `mysql`\\.`innodb_table_stats` not found");
|
|
|
|
call mtr.add_suppression("InnoDB: incorrect flags in SYS_TABLES");
|
2021-05-20 14:58:25 +03:00
|
|
|
call mtr.add_suppression("InnoDB: Table test/t[cp] in InnoDB data dictionary contains invalid flags\\. SYS_TABLES\\.TYPE=(129|289|3873|1232[31]) SYS_TABLES\\.N_COLS=2147483649\\r?$");
|
|
|
|
call mtr.add_suppression("InnoDB: Table test/tr in InnoDB data dictionary contains invalid flags\\. SYS_TABLES\\.TYPE=65 SYS_TABLES\\.MIX_LEN=4294967295\\r?$");
|
2017-06-15 14:35:51 +03:00
|
|
|
call mtr.add_suppression("InnoDB: Refusing to load '\\..test.td\\.ibd' \\(id=3, flags=0x([2e]1)\\); dictionary contains id=3, flags=0x100\\1\\r?$");
|
|
|
|
call mtr.add_suppression("InnoDB: Refusing to load '\\..test.td\\.ibd' \\(id=3, flags=0x(1[2ae]1)\\); dictionary contains id=3, flags=0x10\\1\\r?$");
|
|
|
|
call mtr.add_suppression("InnoDB: Ignoring tablespace for `test`.`td` because it could not be opened\\.");
|
|
|
|
# FIXME: Remove the following spam due to invalid flags for test.td
|
|
|
|
call mtr.add_suppression("InnoDB: Operating system error number .* in a file operation");
|
|
|
|
call mtr.add_suppression("InnoDB: The error means the system cannot find the path specified");
|
2018-03-22 14:17:43 +02:00
|
|
|
call mtr.add_suppression("InnoDB: adjusting FSP_SPACE_FLAGS of file ");
|
2020-09-07 14:23:05 +05:30
|
|
|
call mtr.add_suppression("InnoDB: Parent table of FTS auxiliary table .* not found.");
|
2017-06-13 16:20:21 +03:00
|
|
|
FLUSH TABLES;
|
|
|
|
--enable_query_log
|
|
|
|
|
|
|
|
let INNODB_PAGE_SIZE=`select @@innodb_page_size`;
|
|
|
|
let MYSQLD_DATADIR=`select @@datadir`;
|
|
|
|
|
|
|
|
let bugdir= $MYSQLTEST_VARDIR/tmp/table_flags;
|
|
|
|
--mkdir $bugdir
|
2024-05-22 13:16:10 +05:30
|
|
|
let undodir= $MYSQLTEST_VARDIR/tmp/undo_dir;
|
|
|
|
--mkdir $undodir
|
|
|
|
|
2017-06-13 16:20:21 +03:00
|
|
|
--let SEARCH_FILE = $MYSQLTEST_VARDIR/log/mysqld.1.err
|
|
|
|
|
|
|
|
--let $d=--innodb-data-home-dir=$bugdir --innodb-log-group-home-dir=$bugdir
|
2017-06-15 14:35:51 +03:00
|
|
|
--let $d=$d --innodb-data-file-path=ibdata1:1M:autoextend
|
2017-06-13 16:20:21 +03:00
|
|
|
--let $d=$d --innodb-undo-tablespaces=0
|
2024-05-22 13:16:10 +05:30
|
|
|
--let $d=$d --skip-innodb-fast-shutdown --innodb_undo_directory=$undodir
|
2019-03-25 08:02:22 +02:00
|
|
|
--let $restart_noprint=1
|
2017-06-19 17:28:08 +03:00
|
|
|
--let $restart_parameters=$d --innodb-stats-persistent=0
|
2017-06-13 16:20:21 +03:00
|
|
|
--source include/restart_mysqld.inc
|
|
|
|
|
|
|
|
CREATE TABLE tr(a INT PRIMARY KEY)ENGINE=InnoDB ROW_FORMAT=REDUNDANT;
|
|
|
|
CREATE TABLE tc(a INT PRIMARY KEY)ENGINE=InnoDB ROW_FORMAT=COMPACT;
|
|
|
|
CREATE TABLE td(a INT PRIMARY KEY)ENGINE=InnoDB ROW_FORMAT=DYNAMIC;
|
2017-06-15 14:35:51 +03:00
|
|
|
SET innodb_strict_mode=OFF;
|
2017-06-13 16:20:21 +03:00
|
|
|
CREATE TABLE tz(a INT PRIMARY KEY)ENGINE=InnoDB ROW_FORMAT=COMPRESSED
|
|
|
|
KEY_BLOCK_SIZE=1;
|
2017-06-15 14:35:51 +03:00
|
|
|
SET innodb_strict_mode=ON;
|
2017-06-13 16:20:21 +03:00
|
|
|
# PAGE_COMPRESSED is supported starting with MariaDB 10.1.0
|
|
|
|
CREATE TABLE tp(a INT PRIMARY KEY)ENGINE=InnoDB ROW_FORMAT=DYNAMIC
|
|
|
|
PAGE_COMPRESSED=1 PAGE_COMPRESSION_LEVEL=9;
|
|
|
|
|
|
|
|
--source include/shutdown_mysqld.inc
|
|
|
|
--perl
|
|
|
|
use strict;
|
2019-02-16 12:06:52 +02:00
|
|
|
do "$ENV{MTR_SUITE_DIR}/include/crc32.pl";
|
2017-06-13 16:20:21 +03:00
|
|
|
my $ps= $ENV{INNODB_PAGE_SIZE};
|
|
|
|
my $file= "$ENV{bugdir}/ibdata1";
|
|
|
|
open(FILE, "+<", $file) || die "Unable to open $file\n";
|
MDEV-12026: Implement innodb_checksum_algorithm=full_crc32
MariaDB data-at-rest encryption (innodb_encrypt_tables)
had repurposed the same unused data field that was repurposed
in MySQL 5.7 (and MariaDB 10.2) for the Split Sequence Number (SSN)
field of SPATIAL INDEX. Because of this, MariaDB was unable to
support encryption on SPATIAL INDEX pages.
Furthermore, InnoDB page checksums skipped some bytes, and there
are multiple variations and checksum algorithms. By default,
InnoDB accepts all variations of all algorithms that ever existed.
This unnecessarily weakens the page checksums.
We hereby introduce two more innodb_checksum_algorithm variants
(full_crc32, strict_full_crc32) that are special in a way:
When either setting is active, newly created data files will
carry a flag (fil_space_t::full_crc32()) that indicates that
all pages of the file will use a full CRC-32C checksum over the
entire page contents (excluding the bytes where the checksum
is stored, at the very end of the page). Such files will always
use that checksum, no matter what the parameter
innodb_checksum_algorithm is assigned to.
For old files, the old checksum algorithms will continue to be
used. The value strict_full_crc32 will be equivalent to strict_crc32
and the value full_crc32 will be equivalent to crc32.
ROW_FORMAT=COMPRESSED tables will only use the old format.
These tables do not support new features, such as larger
innodb_page_size or instant ADD/DROP COLUMN. They may be
deprecated in the future. We do not want an unnecessary
file format change for them.
The new full_crc32() format also cleans up the MariaDB tablespace
flags. We will reserve flags to store the page_compressed
compression algorithm, and to store the compressed payload length,
so that checksum can be computed over the compressed (and
possibly encrypted) stream and can be validated without
decrypting or decompressing the page.
In the full_crc32 format, there no longer are separate before-encryption
and after-encryption checksums for pages. The single checksum is
computed on the page contents that is written to the file.
We do not make the new algorithm the default for two reasons.
First, MariaDB 10.4.2 was a beta release, and the default values
of parameters should not change after beta. Second, we did not
yet implement the full_crc32 format for page_compressed pages.
This will be fixed in MDEV-18644.
This is joint work with Marko Mäkelä.
2019-02-19 21:00:00 +02:00
|
|
|
die "Unable to read $file" unless sysread(FILE, $_, 58) == 58;
|
|
|
|
my $full_crc32 = unpack("N",substr($_,54,4)) & 0x10; # FIL_SPACE_FLAGS
|
2017-06-13 16:20:21 +03:00
|
|
|
# Read DICT_HDR_TABLES, the root page number of CLUST_IND (SYS_TABLES.NAME).
|
|
|
|
sysseek(FILE, 7*$ps+38+32, 0) || die "Unable to seek $file";
|
|
|
|
die "Unable to read $file" unless sysread(FILE, $_, 4) == 4;
|
|
|
|
my $sys_tables_root = unpack("N", $_);
|
|
|
|
my $page;
|
|
|
|
print "SYS_TABLES clustered index root page ($sys_tables_root):\n";
|
|
|
|
sysseek(FILE, $sys_tables_root*$ps, 0) || die "Unable to seek $file";
|
|
|
|
die "Unable to read $file" unless sysread(FILE, $page, $ps) == $ps;
|
|
|
|
open(BACKUP, ">$ENV{bugdir}/sys_tables.bin") || die "Unable to open backup\n";
|
|
|
|
syswrite(BACKUP, $page, $ps)==$ps || die "Unable to write backup\n";
|
|
|
|
close(BACKUP) || die "Unable to close backup\n";
|
|
|
|
print "N_RECS=", unpack("n", substr($page,38+16,2));
|
|
|
|
print "; LEVEL=", unpack("n", substr($page,38+26,2));
|
|
|
|
print "; INDEX_ID=0x", unpack("H*", substr($page,38+28,8)), "\n";
|
|
|
|
my @fields=("NAME","DB_TRX_ID","DB_ROLL_PTR",
|
|
|
|
"ID","N_COLS","TYPE","MIX_ID","MIX_LEN","CLUSTER_NAME","SPACE");
|
|
|
|
for (my $offset= 0x65; $offset;
|
|
|
|
$offset= unpack("n", substr($page,$offset-2,2)))
|
|
|
|
{
|
|
|
|
print "header=0x", unpack("H*",substr($page,$offset-6,6)), " (";
|
|
|
|
my $n_fields= unpack("n", substr($page,$offset-4,2)) >> 1 & 0x3ff;
|
|
|
|
my $start= 0;
|
|
|
|
my $name;
|
|
|
|
for (my $i= 0; $i < $n_fields; $i++) {
|
|
|
|
my $end= unpack("C", substr($page, $offset-7-$i, 1));
|
|
|
|
print ",\n " if $i;
|
|
|
|
print "$fields[$i]=";
|
|
|
|
if ($end & 0x80) {
|
|
|
|
print "NULL(", ($end & 0x7f) - $start, " bytes)"
|
|
|
|
} elsif ($n_fields > 1 && $i == 0) {
|
|
|
|
$name= substr($page,$offset+$start,$end-$start);
|
|
|
|
print "'$name'"
|
|
|
|
} else {
|
|
|
|
print "0x", unpack("H*", substr($page,$offset+$start,$end-$start))
|
|
|
|
}
|
|
|
|
# Corrupt SYS_TABLES.TYPE
|
|
|
|
if ($i == 5)
|
|
|
|
{
|
|
|
|
my $flags= 0;
|
|
|
|
if ($name eq 'test/tr') {
|
2017-06-13 18:29:40 +03:00
|
|
|
$flags= 0x40 # DATA_DIR (largely ignored by 10.1+)
|
2017-06-13 16:20:21 +03:00
|
|
|
} elsif ($name eq 'test/tc') {
|
|
|
|
$flags= 0x80 # 10.1 PAGE_COMPRESSED
|
|
|
|
} elsif ($name eq 'test/td') {
|
2017-06-15 14:35:51 +03:00
|
|
|
$flags= 0xf00 # PAGE_COMPRESSION_LEVEL=15 (0..9 is valid)
|
|
|
|
# As part of the MDEV-12873 fix, because the
|
|
|
|
# PAGE_COMPRESSED=YES flag was not set, we will assume that
|
|
|
|
# this table was actually created with 10.2.2..10.2.6
|
|
|
|
# using PAGE_COMPRESSED=YES PAGE_COMPRESSION_LEVEL=7.
|
2017-06-13 16:20:21 +03:00
|
|
|
} elsif ($name eq 'test/tz') {
|
|
|
|
$flags= 0x3000 # 10.1 ATOMIC_WRITES=3 (0..2 is valid)
|
|
|
|
} elsif ($name eq 'test/tp') {
|
|
|
|
$flags= 0x880 # 10.1 PAGE_COMPRESSED, PAGE_COMPRESSION_LEVEL=8
|
2017-06-15 14:35:51 +03:00
|
|
|
# (in 10.2.2 through 10.2.6, this is interpreted as
|
|
|
|
# PAGE_COMPRESSION_LEVEL=4 without PAGE_COMPRESSED
|
|
|
|
# but with SHARED_SPACE, which should be invalid)
|
2017-06-13 16:20:21 +03:00
|
|
|
}
|
|
|
|
|
|
|
|
substr($page,$offset+$start,$end-$start)= pack(
|
|
|
|
"N", $flags ^
|
|
|
|
unpack("N", substr($page,$offset+$start,$end-$start)))
|
|
|
|
if $flags;
|
|
|
|
}
|
|
|
|
# Corrupt SYS_TABLES.MIX_LEN (ignored for ROW_FORMAT=REDUNDANT)
|
|
|
|
if ($i == 7 && $name eq 'test/tr')
|
|
|
|
{
|
|
|
|
substr($page,$offset+$start,$end-$start)= chr(255) x 4;
|
|
|
|
}
|
|
|
|
$start= $end & 0x7f;
|
|
|
|
}
|
|
|
|
print ")\n";
|
|
|
|
}
|
2019-02-16 12:06:52 +02:00
|
|
|
my $polynomial = 0x82f63b78; # CRC-32C
|
MDEV-12026: Implement innodb_checksum_algorithm=full_crc32
MariaDB data-at-rest encryption (innodb_encrypt_tables)
had repurposed the same unused data field that was repurposed
in MySQL 5.7 (and MariaDB 10.2) for the Split Sequence Number (SSN)
field of SPATIAL INDEX. Because of this, MariaDB was unable to
support encryption on SPATIAL INDEX pages.
Furthermore, InnoDB page checksums skipped some bytes, and there
are multiple variations and checksum algorithms. By default,
InnoDB accepts all variations of all algorithms that ever existed.
This unnecessarily weakens the page checksums.
We hereby introduce two more innodb_checksum_algorithm variants
(full_crc32, strict_full_crc32) that are special in a way:
When either setting is active, newly created data files will
carry a flag (fil_space_t::full_crc32()) that indicates that
all pages of the file will use a full CRC-32C checksum over the
entire page contents (excluding the bytes where the checksum
is stored, at the very end of the page). Such files will always
use that checksum, no matter what the parameter
innodb_checksum_algorithm is assigned to.
For old files, the old checksum algorithms will continue to be
used. The value strict_full_crc32 will be equivalent to strict_crc32
and the value full_crc32 will be equivalent to crc32.
ROW_FORMAT=COMPRESSED tables will only use the old format.
These tables do not support new features, such as larger
innodb_page_size or instant ADD/DROP COLUMN. They may be
deprecated in the future. We do not want an unnecessary
file format change for them.
The new full_crc32() format also cleans up the MariaDB tablespace
flags. We will reserve flags to store the page_compressed
compression algorithm, and to store the compressed payload length,
so that checksum can be computed over the compressed (and
possibly encrypted) stream and can be validated without
decrypting or decompressing the page.
In the full_crc32 format, there no longer are separate before-encryption
and after-encryption checksums for pages. The single checksum is
computed on the page contents that is written to the file.
We do not make the new algorithm the default for two reasons.
First, MariaDB 10.4.2 was a beta release, and the default values
of parameters should not change after beta. Second, we did not
yet implement the full_crc32 format for page_compressed pages.
This will be fixed in MDEV-18644.
This is joint work with Marko Mäkelä.
2019-02-19 21:00:00 +02:00
|
|
|
if ($full_crc32)
|
|
|
|
{
|
|
|
|
my $ck = mycrc32(substr($page, 0, $ps-4), 0, $polynomial);
|
|
|
|
substr($page, $ps-4, 4) = pack("N", $ck);
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
my $ck= pack("N",mycrc32(substr($page, 4, 22), 0, $polynomial) ^
|
2019-02-16 12:06:52 +02:00
|
|
|
mycrc32(substr($page, 38, $ps - 38 - 8), 0, $polynomial));
|
MDEV-12026: Implement innodb_checksum_algorithm=full_crc32
MariaDB data-at-rest encryption (innodb_encrypt_tables)
had repurposed the same unused data field that was repurposed
in MySQL 5.7 (and MariaDB 10.2) for the Split Sequence Number (SSN)
field of SPATIAL INDEX. Because of this, MariaDB was unable to
support encryption on SPATIAL INDEX pages.
Furthermore, InnoDB page checksums skipped some bytes, and there
are multiple variations and checksum algorithms. By default,
InnoDB accepts all variations of all algorithms that ever existed.
This unnecessarily weakens the page checksums.
We hereby introduce two more innodb_checksum_algorithm variants
(full_crc32, strict_full_crc32) that are special in a way:
When either setting is active, newly created data files will
carry a flag (fil_space_t::full_crc32()) that indicates that
all pages of the file will use a full CRC-32C checksum over the
entire page contents (excluding the bytes where the checksum
is stored, at the very end of the page). Such files will always
use that checksum, no matter what the parameter
innodb_checksum_algorithm is assigned to.
For old files, the old checksum algorithms will continue to be
used. The value strict_full_crc32 will be equivalent to strict_crc32
and the value full_crc32 will be equivalent to crc32.
ROW_FORMAT=COMPRESSED tables will only use the old format.
These tables do not support new features, such as larger
innodb_page_size or instant ADD/DROP COLUMN. They may be
deprecated in the future. We do not want an unnecessary
file format change for them.
The new full_crc32() format also cleans up the MariaDB tablespace
flags. We will reserve flags to store the page_compressed
compression algorithm, and to store the compressed payload length,
so that checksum can be computed over the compressed (and
possibly encrypted) stream and can be validated without
decrypting or decompressing the page.
In the full_crc32 format, there no longer are separate before-encryption
and after-encryption checksums for pages. The single checksum is
computed on the page contents that is written to the file.
We do not make the new algorithm the default for two reasons.
First, MariaDB 10.4.2 was a beta release, and the default values
of parameters should not change after beta. Second, we did not
yet implement the full_crc32 format for page_compressed pages.
This will be fixed in MDEV-18644.
This is joint work with Marko Mäkelä.
2019-02-19 21:00:00 +02:00
|
|
|
substr($page,0,4)=$ck;
|
|
|
|
substr($page,$ps-8,4)=$ck;
|
|
|
|
}
|
2017-06-13 16:20:21 +03:00
|
|
|
sysseek(FILE, $sys_tables_root*$ps, 0) || die "Unable to seek $file";
|
|
|
|
syswrite(FILE, $page, $ps)==$ps || die "Unable to write $file\n";
|
|
|
|
close(FILE) || die "Unable to close $file\n";
|
|
|
|
EOF
|
|
|
|
--source include/start_mysqld.inc
|
|
|
|
|
2017-06-15 14:35:51 +03:00
|
|
|
--error ER_NO_SUCH_TABLE_IN_ENGINE
|
2017-06-13 16:20:21 +03:00
|
|
|
SHOW CREATE TABLE tr;
|
|
|
|
--error ER_NO_SUCH_TABLE_IN_ENGINE
|
|
|
|
SHOW CREATE TABLE tc;
|
|
|
|
--error ER_NO_SUCH_TABLE_IN_ENGINE
|
2018-02-12 13:35:07 +02:00
|
|
|
SELECT * FROM tc;
|
2023-11-17 15:07:51 +02:00
|
|
|
--error ER_GET_ERRNO
|
2017-06-13 16:20:21 +03:00
|
|
|
SHOW CREATE TABLE td;
|
2023-11-17 15:07:51 +02:00
|
|
|
--error ER_GET_ERRNO
|
2018-02-12 13:35:07 +02:00
|
|
|
SELECT * FROM td;
|
2017-06-15 18:02:57 +03:00
|
|
|
# This table was converted to NO_ROLLBACK due to the SYS_TABLES.TYPE change.
|
2017-06-13 16:20:21 +03:00
|
|
|
SHOW CREATE TABLE tz;
|
2017-06-15 18:02:57 +03:00
|
|
|
BEGIN;
|
|
|
|
INSERT INTO tz VALUES(42);
|
|
|
|
ROLLBACK;
|
|
|
|
SELECT * FROM tz;
|
2017-06-13 16:20:21 +03:00
|
|
|
--error ER_NO_SUCH_TABLE_IN_ENGINE
|
|
|
|
SHOW CREATE TABLE tp;
|
|
|
|
|
|
|
|
--source include/shutdown_mysqld.inc
|
|
|
|
|
|
|
|
let SEARCH_FILE= $MYSQLTEST_VARDIR/log/mysqld.1.err;
|
2021-05-20 14:58:25 +03:00
|
|
|
--let SEARCH_PATTERN= InnoDB: Table test/t[cp] in InnoDB data dictionary contains invalid flags\. SYS_TABLES\.TYPE=(129|289|3873|1232[13]) SYS_TABLES\.N_COLS=2147483649
|
2017-06-15 14:35:51 +03:00
|
|
|
--source include/search_pattern_in_file.inc
|
2021-05-20 14:58:25 +03:00
|
|
|
--let SEARCH_PATTERN= InnoDB: Table test/tr in InnoDB data dictionary contains invalid flags\. SYS_TABLES\.TYPE=65 SYS_TABLES\.MIX_LEN=4294967295\b
|
2017-06-13 16:20:21 +03:00
|
|
|
--source include/search_pattern_in_file.inc
|
|
|
|
|
|
|
|
# Restore the backup of the corrupted SYS_TABLES clustered index root page
|
|
|
|
--perl
|
|
|
|
use strict;
|
|
|
|
my $ps= $ENV{INNODB_PAGE_SIZE};
|
|
|
|
my $file= "$ENV{bugdir}/ibdata1";
|
|
|
|
open(FILE, "+<", $file) || die "Unable to open $file\n";
|
|
|
|
open(BACKUP, "<$ENV{bugdir}/sys_tables.bin") || die "Unable to open backup\n";
|
|
|
|
# Read DICT_HDR_TABLES, the root page number of CLUST_IND (SYS_TABLES.NAME).
|
|
|
|
sysseek(FILE, 7*$ps+38+32, 0) || die "Unable to seek $file";
|
|
|
|
die "Unable to read $file\n" unless sysread(FILE, $_, 4) == 4;
|
|
|
|
my $sys_tables_root = unpack("N", $_);
|
|
|
|
print "Restoring SYS_TABLES clustered index root page ($sys_tables_root)\n";
|
|
|
|
sysseek(FILE, $sys_tables_root*$ps, 0) || die "Unable to seek $file";
|
|
|
|
die "Unable to read backup\n" unless sysread(BACKUP, $_, $ps) == $ps;
|
|
|
|
die "Unable to restore backup\n" unless syswrite(FILE, $_, $ps) == $ps;
|
|
|
|
close(BACKUP);
|
|
|
|
close(FILE) || die "Unable to close $file\n";
|
|
|
|
EOF
|
|
|
|
--source include/start_mysqld.inc
|
|
|
|
|
|
|
|
SHOW CREATE TABLE tr;
|
|
|
|
SHOW CREATE TABLE tc;
|
|
|
|
SHOW CREATE TABLE td;
|
|
|
|
SHOW CREATE TABLE tz;
|
|
|
|
SHOW CREATE TABLE tp;
|
|
|
|
|
|
|
|
BEGIN;
|
|
|
|
INSERT INTO tr VALUES(1);
|
|
|
|
INSERT INTO tc VALUES(1);
|
|
|
|
INSERT INTO td VALUES(1);
|
2017-06-15 18:02:57 +03:00
|
|
|
# We cannot access tz, because due to our fiddling of the NO_ROLLBACK flag,
|
|
|
|
# it now has a record with DB_TRX_ID=0, which is invalid for
|
|
|
|
# transactional tables until MDEV-12288 is implemented.
|
|
|
|
# INSERT INTO tz VALUES(1);
|
2017-06-13 16:20:21 +03:00
|
|
|
INSERT INTO tp VALUES(1);
|
|
|
|
ROLLBACK;
|
|
|
|
|
|
|
|
SELECT * FROM tr;
|
|
|
|
SELECT * FROM tc;
|
|
|
|
SELECT * FROM td;
|
2017-06-15 18:02:57 +03:00
|
|
|
# SELECT * FROM tz;
|
2017-06-13 16:20:21 +03:00
|
|
|
SELECT * FROM tp;
|
|
|
|
|
|
|
|
DROP TABLE tr,tc,td,tz,tp;
|
|
|
|
|
|
|
|
--let $restart_parameters=
|
2017-06-15 14:35:51 +03:00
|
|
|
--source include/restart_mysqld.inc
|
2017-06-13 16:20:21 +03:00
|
|
|
|
2017-09-06 19:08:55 +03:00
|
|
|
--error 0,1
|
|
|
|
--remove_file $bugdir/ibtmp1
|
|
|
|
--error 0,1
|
|
|
|
--remove_file $bugdir/ib_buffer_pool
|
|
|
|
|
2017-06-13 16:20:21 +03:00
|
|
|
--list_files $bugdir
|
|
|
|
--remove_files_wildcard $bugdir
|
|
|
|
--rmdir $bugdir
|
2024-05-22 13:16:10 +05:30
|
|
|
--rmdir $undodir
|
2018-12-03 01:12:04 +05:30
|
|
|
|
|
|
|
call mtr.add_suppression("ERROR HY000: Can't create table `test`.`t1`");
|
|
|
|
--error ER_CANT_CREATE_TABLE
|
|
|
|
CREATE TABLE t1(f1 INT, f2 VARCHAR(1), KEY k1(f2),
|
|
|
|
FULLTEXT KEY(f2),
|
|
|
|
FOREIGN KEY (f2) REFERENCES t1(f3))ENGINE=InnoDB;
|
2020-09-07 14:23:05 +05:30
|
|
|
|
|
|
|
--echo #
|
|
|
|
--echo # MDEV-23199 page_compression flag is missing
|
|
|
|
--echo # for full_crc32 tablespace
|
|
|
|
--echo #
|
|
|
|
|
|
|
|
CREATE TABLE t1(f1 BIGINT PRIMARY KEY)ENGINE=InnoDB;
|
|
|
|
INSERT INTO t1 VALUES(1);
|
|
|
|
ALTER TABLE t1 PAGE_COMPRESSED = 1;
|
|
|
|
INSERT INTO t1 VALUES(2);
|
|
|
|
let $shutdown_timeout = 0;
|
|
|
|
--source include/restart_mysqld.inc
|
|
|
|
DROP TABLE t1;
|
2024-05-24 13:17:27 +05:30
|
|
|
|
|
|
|
--echo #
|
|
|
|
--echo # MDEV-34222 Alter operation on redundant table aborts the server
|
|
|
|
--echo #
|
|
|
|
SET @df_row = @@global.INNODB_DEFAULT_ROW_FORMAT;
|
|
|
|
SET GLOBAL INNODB_DEFAULT_ROW_FORMAT=REDUNDANT;
|
|
|
|
CREATE TABLE t1 (c CHAR(1)) ENGINE=InnoDB;
|
|
|
|
SET GLOBAL INNODB_DEFAULT_ROW_FORMAT=compact;
|
|
|
|
--error ER_ILLEGAL_HA_CREATE_OPTION
|
|
|
|
ALTER TABLE t1 PAGE_COMPRESSED=1;
|
|
|
|
DROP TABLE t1;
|
|
|
|
SET @@global.INNODB_DEFAULT_ROW_FORMAT = @df_row;
|