RENAME TABLE causes incremental prepare to fail
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Percona XtraBackup moved to https://jira.percona.com/projects/PXB |
Fix Released
|
Medium
|
Sergei Glushchenko | ||
2.0 |
Fix Released
|
Medium
|
Sergei Glushchenko | ||
2.1 |
Fix Released
|
Medium
|
Sergei Glushchenko |
Bug Description
Issue we're seeing is that renaming a table after taking and preparing a full backup but before taking and applying an incremental backup is causing the incremental prepare step to fail with the following error. Backup in total is about 180GB in size, and the tables here are ~3MB and ~70,000 rows. We use the renames to rotate a set of tables in order to introduce some new data to the system. Our workaround for this at the moment is to convert the tables to MyISAM so that they're not part of the incremental step.
Relevant tables:
---
mytable
mytable_old
Rotate process:
---
CREATE TABLE mytable_temp [ ... ]
LOAD DATA INFILE data INTO TABLE mytable_temp
DROP TABLE IF EXISTS mytable_old
RENAME TABLE mytable TO mytable_old
RENAME TABLE mytable_temp TO mytable
ANALYZE TABLE mytable
Backup process:
---
$ innobackupex --no-timestamp /backup/full/
...
$ innobackupex --apply-log --redo-only --use-memory=16GB /backup/full/
...
[ ROTATE HAPPENS HERE ]
$ innobackupex --no-timestamp --incremental --incremental-
...
$ innobackupex --apply-log --redo-only --use-memory=16GB --incremental-
[ ... APPLYING DELTA FILES UP TO HERE ... ]
xtrabackup: Temporary instance for recovery is set as followings.
xtrabackup: innodb_
xtrabackup: innodb_
xtrabackup: innodb_
xtrabackup: innodb_
xtrabackup: innodb_
120214 15:25:58 InnoDB: Using Linux native AIO
xtrabackup: Starting InnoDB instance for recovery.
xtrabackup: Using 17179869184 bytes for buffer pool (set by --use-memory parameter)
120214 15:25:58 InnoDB: The InnoDB memory heap is disabled
120214 15:25:58 InnoDB: Mutexes and rw_locks use GCC atomic builtins
120214 15:25:58 InnoDB: Compressed tables use zlib 1.2.3
120214 15:25:58 InnoDB: Using Linux native AIO
120214 15:25:58 InnoDB: Warning: innodb_
120214 15:25:58 InnoDB: Initializing buffer pool, size = 16.0G
120214 15:25:59 InnoDB: Completed initialization of buffer pool
120214 15:25:59 InnoDB: highest supported file format is Barracuda.
InnoDB: Log scan progressed past the checkpoint lsn 9195483965206
120214 15:25:59 InnoDB: Database was not shut down normally!
InnoDB: Starting crash recovery.
InnoDB: Reading tablespace information from the .ibd files...
InnoDB: Error: trying to add tablespace 6558 of name './database/
InnoDB: to the tablespace memory cache, but tablespace
InnoDB: 6558 of name './database/
InnoDB: memory cache!
innobackupex: Error:
innobackupex: ibbackup failed at /usr/bin/
Related branches
- Alexey Kopytov (community): Approve
-
Diff: 904 lines (+582/-113)3 files modifiedpatches/innodb51_builtin.patch (+67/-4)
src/xtrabackup.c (+430/-109)
test/t/bug932623.sh (+85/-0)
- Alexey Kopytov (community): Approve
-
Diff: 955 lines (+594/-111)9 files modifiedpatches/innodb51_builtin.patch (+67/-4)
src/fil_cur.c (+1/-0)
src/fil_cur.h (+1/-0)
src/innodb_int.c (+76/-0)
src/innodb_int.h (+29/-0)
src/write_filt.c (+1/-0)
src/xtrabackup.c (+333/-107)
src/xtrabackup.h (+1/-0)
test/t/bug932623.sh (+85/-0)
description: | updated |
description: | updated |
Verified with a bit different symptoms. Will attach a test case.