First, .FRM files contain none of your "data". They are simply the definition of the table.
If all of the following are true:
- The table is using the MyISAM storage engine
- You know the CREATE TABLE statement required to recreate the table
Then, do the following:
- Stop MySQL
- Backup your table_name.frm, table_name.MYI, table_name.MYD files
- Delete them from your mysql data directory (/var/lib/mysql usually)
- Start MySQL
- CREATE the table again
- Stop MySQL
- Copy the .MYD and .MYI files back into the datadir, replacing the ones there.
- Start MySQL
- ???
- Profit
阅读(1929) | 评论(1) | 转发(0) |