Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-18543

IMPORT TABLESPACE fails after instant DROP COLUMN

    XMLWordPrintable

Details

    Description

      After the MDEV-18295 fix, IMPORT TABLESPACE will fail to import data files on which columns have been instantly reordered or dropped (MDEV-15562).

      The problem is demonstrated by this part of the test innodb.instant_alter_import:

      --echo # Import a data file that contains instant DROP COLUMN metadata
      alter table t2 drop x;
      alter table t1 drop x, force;
      alter table t1 discard tablespace;
       
      flush tables t2 for export;
      --move_file $MYSQLD_DATADIR/test/t2.cfg $MYSQLD_DATADIR/test/t1.cfg
      --copy_file $MYSQLD_DATADIR/test/t2.ibd $MYSQLD_DATADIR/test/t1.ibd
      unlock tables;
       
      --error ER_TABLE_SCHEMA_MISMATCH
      alter table t1 import tablespace;
      

      The IMPORT TABLESPACE code should read the metadata record and the metadata BLOB early, to augment the metadata. Because the pages have not been adjusted yet, the buffer pool will have to be bypassed while reading the pages.

      Attachments

        Issue Links

          Activity

            People

              kevg Eugene Kosov (Inactive)
              marko Marko Mäkelä
              Votes:
              6 Vote for this issue
              Watchers:
              12 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Git Integration

                  Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.