I am busy rebuilding an entire MySQL DB. There are multiple schemas and multiple tables in each schema.

I am restoring them using *.frm files as all other methods used have either failed or corrupted the data.

I am using the command:

mysqlfrm --server=root:password@localhost:3306 F:\DirectoryStructure\File.frm > file.txt --diagnostic

Is there a way to export ALL frm files from the same command using only one command? As doing each file one by one is going to take forever. I have tried using:

mysqlfrm --server=root:password@localhost:3306 F:\DirectoryStructure\*.frm > filename.txt --diagnostic

but this doesn't work.

Any help is really appreciated


You can use online service https://recovery.twindb.com/ (I'm the author). Basically, it's a wed interface to mysqlfrm.

To restore structure from multiple frm files you can run this

find /path/to/frm_files -name '*.frm' | \
xargs mysqlfrm --basedir /usr --port 3333

In /usr mysqlfrm should find mysqld (it starts it to read the frm).

  • Hi, do you have any idea why mysqlfrm can't open frm file (use --diagnostic) but service recovery.twindb.com opens it?
    – kusanagi
    Jul 8 '18 at 7:17
  • It's because recovery.twindb.com is awesome service! :) Jokes aside, try to use mysqlfrm with the latest MySQL version (from 5.7.x releases)
    – akuzminsky
    Aug 31 '18 at 15:56

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.