Restoration of corrupted data in mysql database _ MySQL

Source: Internet
Author: User
The restoration of corrupted data in the mysql database is shared with the restoration of corrupted data in the MySQL database for your reference. if you have similar problems in the future, you can avoid detours, solve the problem as soon as possible.

Environment: windows2003

Database: MySQL

Corrupted data File name: function_products

Import the physical files of the database content directly to MySQLdata. Each table has three files, respectively. frm. MYD. MYI

First of all, I first thought about searching online, searching for similar tools, and trying to restore corrupted files. so I searched for a tool named MySQLRecovery on GOOGLE, after the installation, I use it for recovery, but unfortunately the effect is too bad. after the restoration, it prompts that I only have dozens of K data files.

I also thought that MySQL should have its own repair program and so on, so I wanted to use it for recovery. I found the information on the Internet and prompted: due to temporary power failure, use kill-9 to stop the MySQL service process, or perform a forced backup operation when mysql is running at high speed, all of which may destroy MySQL data files. If the service is changing the file when it is disturbed, the file may be in an incorrect or inconsistent state. This destruction is sometimes not easy to find. it may be a long time before you find this mistake.

So when you find this problem, maybe all the backups have the same error.

I think the problem I encountered may be that the backup data is damaged, so it cannot be fully run, realize that the myisamchk program should be unique in accessing MySQL data files used for checking and modifying. If the MySQL service is using a file and modifying the file myisamchk is checking, myisamchk will mistakenly think that an error has occurred and will try to fix it.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.