Restore MySQL. frm,. myd, and. myi files to the database _ MySQL

Source: Internet
Author: User
Restore MySQL. frm ,. myd ,. myi files were removed from a mobile phone Forum website in the early morning. I was lucky to download the database files, but there were three files in it. frm ,. myd ,. myi file, that is, the original MySQL data file. these three files are:

  • . Frm table structure file
  • . Myd table data file
  • . Myi table index file

So I want to restore these files to a database, but the basic method found on the Internet is one way, which is troublesome to operate.

Then I found a method as follows:

  1. Create a database
  2. Find datadir in my. ini, name the storage location of the database file, and open this folder.
  3. Create a folder. the folder name is the same as the name of the created table.
  4. Copy the three files

OK. refresh the database and it will pop up.

References: http://www.cftea.com/c/2010/09/IRYY0J1QVOOR0PFC.asp

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.