Link to home
Create AccountLog in
Avatar of SC Team
SC TeamFlag for Malaysia

asked on

how to restore .ibd file

How you we restore .ibd file from an imported backup file into AWS RDS instances? 

and 

How you we restore .ibd file from an imported backup file into MySQL Workbench 8.0? 


User generated image


Avatar of noci
noci

Better export a database using mysqldump and then importing it into a new server.
(mysqldump files are augmented SQL files, and work accross versions).

Each of the .IBD files is one table.  (file per table setting) of InnoDB.
Ensure you create a new database of type InnoDB... as a starter.
  1. Step 1 – Create a MySQL Database and Recreate the Table.
  2. Step 2 – Find Table Schema.
  3. Step 3 – Recreate the Database Table.
  4. Step 4 – Delete the New . IBD File.
  5. Step 5 – Copy the Old . IBD file.
  6. Step 6 – Import the Tablespace.

ASKER CERTIFIED SOLUTION
Avatar of noci
noci

Link to home
membership
Create an account to see this answer
Signing up is free. No credit card required.
Create Account

You cannot directly do that to AWS RDS instances. You have no underlying disks. Same is the case with workbench.


You need to restore that ibd file in a separate mysql instance, may be your local. Take mysqldump and restore it on AWS RDS.


Here is a blog to restore-single-mysql-table-from-xtrabackup with video demo.