Data Recovery Overview
Percona can often recover lost or corrupted data from MyISAM and InnoDB type tables, or from corrupted binary logs and general query logs. These scenarios are often recoverable:
- You have accidentally deleted data.
- You have dropped your tables.
- You have truncated or recreated your tables.
- You have InnoDB tablespace corruption that innodb_force_recovery won't repair.
- You have filesystem corruption.
We always encrypt your sensitive data, and we destroy our copy of it after we're done.
Recovery Prospects
InnoDB data recovery can be very successful because of InnoDB's page layout. Percona has developed recovery procedures for InnoDB tables in MySQL 4.1 and below (which use the REDUNDANT page format) and for MySQL 5.0 and above (which use the newer COMPACT format). We can also recover InnoDB tables from both the single-tablespace and file-per-table modes.
MyISAM data recovery is less assured, but is still often possible, depending on a mix of factors.
How To Prepare For Recovery
If you realize that you've lost data that you want to attempt to recover, do this:
- Stop the MySQL Server immediately.
- Use kill -9 to for the quickest shutdown.
- Your goal is to prevent any further writes to disk.
- Unmount the filesystem or make it read-only if...
- You have filesystem corruption OR
- You have dropped tables in innodb_file_per_table format
- Make a copy of the original data including...
- All MyISAM data files
- All InnoDB tablespaces or partitions
- All log files
Items Needed For Recovery
Percona will need these items to begin any data recovery project:
- Access to the data that needs to be recovered, either on your server or ours.
- Exact details on what data you need to be recovered.
- Instructions on your highest priority for recovery, because we typically can recover only one table at a time.
- For dropped tables, we need table structure info. This can come from:
- A backup of the table OR
- SHOW CREATE TABLE OR
- The table's *.frm file.
- If you have an older uncorrupted backup of the data which needs recovery, that helps us a lot.
- If you have sample data illustrating what needs to be recovered, that helps us a lot too.
- Record the MySQL server and operating system versions.
- Describe the circumstances that led up to the loss of data.
How Percona Performs Recovery
We perform data recovery in two stages. First we analyze your data to see if it can be recovered, and to estimate how much of the data we can recover. Sometimes full recovery is impossible, because data was already overwritten by MySQL or the operating system. We will also estimate how long recovery will take, based on the data you provided. If you approve, we begin the recovery.
Percona's Recovery Tool
Percona created innodb-tools, the only software we know of designed specifically for data recovery from InnoDB tables. If you want try InnoDB data recovery yourself, see InnoDBRecoveryHowto.
No Warranty on Recovery
We give you our maximum best effort and we strive to recover as much as is humanly possible. However Percona requires upfront payment on all data recovery projects, and there are no refunds if we are unsuccessful.
To Order Recovery
During weekday business hours (8-5 Pacific time) call our sales office at +1-208-473-2904. At other times 24x7 call our support emergency line at +1-877-862-4316. You will need to have a credit card to order.
