2

I recently had an incident in which several MySQL files were wiped out (mostly from WordPress, but also a few of MySQL’s own files). The IBDATA1 file is unaffected, but several .frm are gone as are a few .myi and .myd files.

So now I need to find out if there is a way to rebuild the missing files from IBDATA1. I tried Googling it, assuming that such an issue has come up before, and indeed there were numerous search results (including this question), but all of the ones I looked at were the opposite, about recovering from .frm and .my* files or somehow required these files.

Is there a way to rebuild these files? I know I have a relatively recent backup (a .SQL file) if there isn’t, but I’m hoping that these are the kind of files that are rebuilt if missing or outdated.

Synetech
  • 948
  • 1
  • 12
  • 27

1 Answers1

0

What I ended up doing was to create a new, empty database, imported the last backup, compared the new .frm, .myi, and .myd files to the old ones that were still available, saw that they were identical, and so copied the missing ones. It may not be ideal, but it was simple enough and “just works”.

Synetech
  • 948
  • 1
  • 12
  • 27