|If you have intact MySQL data folders, install a fresh instance of that version of MySQL, set |
datadir to the existing data folder, and start the server.
If the MySQL data folder isn't intact but you have a mysqldump backup, install a new MySQL instance, start it with the
--skip-grant-tables option, run the dump script, check that the privilege tables are correct, then stop the server and start it normally.
If you just have bits and pieces, eg .frm files, InnoDB data files ibdata*, and InnoDB log files ib_logfile*, install a new MySQL instance, start it with the
--skip-grant-tables option, restore no data to it, let the server initialise required InnoDB files by starting it with the --skip-grant-tables option, stop the server, copy the .frm files into appropriate data folders, overwrite ibdata* and ib_logfile* with the backups, then restart the server.
Useful info at https://dba.stackexchange.com/questions/16875/restore-table-from-frm-and-ibd-file.