[MDEV-20974] Don't require .cfg files to import InnoDB tablespaces Created: 2019-11-04  Updated: 2021-09-30  Resolved: 2020-03-30

Status: Closed
Project: MariaDB Server
Component/s: Data Definition - Alter Table, Storage Engine - InnoDB
Fix Version/s: N/A

Type: Task Priority: Major
Reporter: Geoff Montee (Inactive) Assignee: Ralf Gebhardt
Resolution: Duplicate Votes: 0
Labels: None

Issue Links:
Duplicate
duplicates MDEV-11658 Simpler, faster IMPORT of InnoDB tables Open
PartOf
includes MDEV-15225 Can't import .ibd file with temporal ... Closed
Relates
relates to MDEV-14342 Importing partial backup from XtraBac... Closed
relates to MDEV-15049 Importing InnoDB table from 10.1 to 1... Closed
relates to MDEV-16851 On schema mismatch in IMPORT TABLESPA... Closed
relates to MDEV-18288 Transportable Tablespaces leave AUTO_... Closed
relates to MDEV-20930 Document that SHOW CREATE TABLE on In... Closed
relates to MDEV-20931 ALTER...IMPORT can crash the server Closed

 Description   

FLUSH TABLES ... FOR EXPORT creates a .cfg file that is supposed to be copied and imported along with the .ibd file. These .cfg files are not always needed.

However, the .cfg files are absolutely needed in some cases, such as:

  • If you want your AUTO_INCREMENT value to be populated properly on import, then you need to copy the .cfg file (MDEV-18288).
  • If you want to avoid the potential risk of server crashes, then you need to copy the .cfg file to avoid some bugs (MDEV-14342 and MDEV-20931).
  • What other cases are there?

And the .cfg files can also be very helpful for troubleshooting in some cases, such as:

  • If the row format is different between the source server and the destination server, then you need to copy the .cfg file if you want to see a more clear error message (MDEV-15049 and MDEV-16851).

Would it be possible to make the .cfg files completely unnecessary?



 Comments   
Comment by Marko Mäkelä [ 2019-12-19 ]

I think that this request is duplicating much of what has been already described in MDEV-11658.

In MDEV-11658, I wrote that a change of the .ibd file format is necessary to allow secondary indexes to be safely imported without a .cfg file.

Comment by Geoff Montee (Inactive) [ 2019-12-19 ]

marko,

MDEV-15225 and this issue (MDEV-20974) seem a bit different to me. However, maybe MDEV-15225 could technically be considered a subset of this feature request.

The description of MDEV-15225 is specifically about being able to import a tablespace created with a different mysql56_temporal_format value.

The description of this issue (MDEV-20974) is about being able to import tablespaces without .cfg files in all cases. This seems to involve more than the secondary index changes that you mentioned in MDEV-15225. The description of this issue mentions two more kinds of changes that may be required that I know of:

  • If you want your AUTO_INCREMENT value to be populated properly on import, then you need to copy the .cfg file (MDEV-18288).
    ...
  • If the row format is different between the source server and the destination server, then you need to copy the .cfg file if you want to see a more clear error message (MDEV-15049 and MDEV-16851).

As far as I can tell, these two cases would not be fixed by the secondary index changes mention in MDEV-15225, so it doesn't look like MDEV-15225 covers all of the changes that this issue is requesting. If we want to merge this issue with MDEV-15225, then we might need to enhance the description of MDEV-15225.

Comment by Geoff Montee (Inactive) [ 2020-03-30 ]

Closing this as a duplicate of MDEV-11658.

Generated at Thu Feb 08 09:03:38 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.