Uploaded image for project: 'Percona XtraBackup'
  1. Percona XtraBackup
  2. PXB-2118

Undo log file was renamed incorrectly to undo tablespace name after restore

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Done
    • Priority: High
    • Resolution: Fixed
    • Affects Version/s: 8.0.9
    • Fix Version/s: 8.0.10
    • Component/s: None
    • Labels:
      None

      Description

      Initialize and start PS8.0.18 with --innodb-undo-directory=${PWD}/undo
      Add another undo tablespace

      CREATE UNDO TABLESPACE new_undo_tablespace ADD DATAFILE 'new.ibu';
      8.0.18>SELECT TABLESPACE_NAME, FILE_NAME FROM INFORMATION_SCHEMA.FILES WHERE FILE_TYPE LIKE 'UNDO LOG';
      +---------------------+-----------------------------------------------------+
      | TABLESPACE_NAME | FILE_NAME |
      +---------------------+-----------------------------------------------------+
      | innodb_undo_001 | /home/mchawla/PS050320_8_0_18_9_debug/undo/undo_001 |
      | innodb_undo_002 | /home/mchawla/PS050320_8_0_18_9_debug/undo/undo_002 |
      | new_undo_tablespace | ./new.ibu |
      +---------------------+-----------------------------------------------------+

      Add some sysbench data.
      Take full backup

      ./xtrabackup --user=root --password='' --backup --target-dir=$HOME/dbbackup_PS8 -S $HOME/PS050320_8_0_18_9_debug/socket.sock --datadir=$HOME/PS050320_8_0_18_9_debug/data

      Prepare the full backup

      ./xtrabackup --prepare --target_dir=$HOME/dbbackup_PS8

      Stop PS server and move the data, undo log directories to another location
      Restore the backup

      ./xtrabackup --copy-back --target-dir=$HOME/dbbackup_PS8 --datadir=$HOME/PS050320_8_0_18_9_debug/data --innodb-undo-directory=$HOME/PS050320_8_0_18_9_debug/undo

      Start the PS server with --innodb-undo-directory=${PWD}/undo
      Check the undo log tablespace

      8.0.18>SELECT TABLESPACE_NAME, FILE_NAME FROM INFORMATION_SCHEMA.FILES WHERE FILE_TYPE LIKE 'UNDO LOG';
      +---------------------+--------------------------------------------------------------------+
      | TABLESPACE_NAME | FILE_NAME |
      +---------------------+--------------------------------------------------------------------+
      | innodb_undo_001 | /home/mchawla/PS050320_8_0_18_9_debug/undo/undo_001 |
      | innodb_undo_002 | /home/mchawla/PS050320_8_0_18_9_debug/undo/undo_002 |
      | new_undo_tablespace | /home/mchawla/PS050320_8_0_18_9_debug/undo/new_undo_tablespace.ibu |
      +---------------------+--------------------------------------------------------------------

      Issue: The new.ibu file has been renamed to new_undo_tablespace.ibu, which is incorrect.

        Smart Checklist

          Attachments

            Activity

              People

              Assignee:
              rahul.malik Rahul Malik
              Reporter:
              manish.chawla Manish Chawla
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - Not Specified
                  Not Specified
                  Logged:
                  Time Spent - 1 day, 1 hour
                  1d 1h