mirror of
https://github.com/MariaDB/server.git
synced 2025-01-30 02:30:06 +01:00
MDEV-18589 Assertion on info.page_size failed in xb_delta_open_matching_space
xb_read_delta_metadata(): For ROW_FORMAT=COMPRESSED tables, initialize
the info.zip_size with the physical page size and let info.page_size
remain the logical page size, like xb_delta_open_matching_space()
expects it to be ever since
commit 0a1c3477bf
(MDEV-18493).
This commit is contained in:
parent
289105e282
commit
3e3cfa8934
3 changed files with 46 additions and 1 deletions
|
@ -2411,7 +2411,8 @@ xb_read_delta_metadata(const char *filepath, xb_delta_info_t *info)
|
||||||
msg("page_size is required in %s", filepath);
|
msg("page_size is required in %s", filepath);
|
||||||
r = FALSE;
|
r = FALSE;
|
||||||
} else {
|
} else {
|
||||||
info->page_size = zip_size ? zip_size : page_size;
|
info->page_size = page_size;
|
||||||
|
info->zip_size = zip_size;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (info->space_id == ULINT_UNDEFINED) {
|
if (info->space_id == ULINT_UNDEFINED) {
|
||||||
|
|
18
mysql-test/suite/mariabackup/incremental_compressed.result
Normal file
18
mysql-test/suite/mariabackup/incremental_compressed.result
Normal file
|
@ -0,0 +1,18 @@
|
||||||
|
#
|
||||||
|
# MDEV-18589 Assertion ...physical_size(flags) == info.page_size
|
||||||
|
# failed in xb_delta_open_matching_space
|
||||||
|
#
|
||||||
|
CREATE TABLE t (pk INT PRIMARY KEY) ENGINE=InnoDB ROW_FORMAT=COMPRESSED;
|
||||||
|
ALTER TABLE t PARTITION BY KEY(pk);
|
||||||
|
# shutdown server
|
||||||
|
# remove datadir
|
||||||
|
# xtrabackup move back
|
||||||
|
# restart
|
||||||
|
SHOW CREATE TABLE t;
|
||||||
|
Table Create Table
|
||||||
|
t CREATE TABLE `t` (
|
||||||
|
`pk` int(11) NOT NULL,
|
||||||
|
PRIMARY KEY (`pk`)
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 COLLATE=latin1_swedish_ci ROW_FORMAT=COMPRESSED
|
||||||
|
PARTITION BY KEY (`pk`)
|
||||||
|
DROP TABLE t;
|
26
mysql-test/suite/mariabackup/incremental_compressed.test
Normal file
26
mysql-test/suite/mariabackup/incremental_compressed.test
Normal file
|
@ -0,0 +1,26 @@
|
||||||
|
--source include/have_innodb.inc
|
||||||
|
--source include/have_partition.inc
|
||||||
|
|
||||||
|
let $basedir=$MYSQLTEST_VARDIR/tmp/backup;
|
||||||
|
let $incremental_dir=$MYSQLTEST_VARDIR/tmp/backup_inc1;
|
||||||
|
|
||||||
|
--echo #
|
||||||
|
--echo # MDEV-18589 Assertion ...physical_size(flags) == info.page_size
|
||||||
|
--echo # failed in xb_delta_open_matching_space
|
||||||
|
--echo #
|
||||||
|
|
||||||
|
CREATE TABLE t (pk INT PRIMARY KEY) ENGINE=InnoDB ROW_FORMAT=COMPRESSED;
|
||||||
|
|
||||||
|
--exec $XTRABACKUP --backup --target-dir=$basedir --protocol=tcp --port=$MASTER_MYPORT --user=root
|
||||||
|
|
||||||
|
ALTER TABLE t PARTITION BY KEY(pk);
|
||||||
|
|
||||||
|
--exec $XTRABACKUP --backup --target-dir=$incremental_dir --incremental-basedir=$basedir --protocol=tcp --port=$MASTER_MYPORT --user=root > $incremental_dir.log 2>&1
|
||||||
|
--exec $XTRABACKUP --prepare --target-dir=$basedir --user=root > $MYSQL_TMP_DIR/backup_prepare_0.log 2>&1
|
||||||
|
--exec $XTRABACKUP --prepare --target-dir=$basedir --incremental-dir=$incremental_dir --user=root > $MYSQL_TMP_DIR/backup_prepare_1.log
|
||||||
|
--cat_file $MYSQL_TMP_DIR/backup_prepare_1.log
|
||||||
|
let $targetdir=$basedir;
|
||||||
|
-- source include/restart_and_restore.inc
|
||||||
|
|
||||||
|
SHOW CREATE TABLE t;
|
||||||
|
DROP TABLE t;
|
Loading…
Add table
Reference in a new issue