MySQL Forums
Forum List  »  Newbie

Re: Accidentally delete 'root' account
Posted by: Peter Brawley
Date: May 30, 2022 05:06PM

On another machine, call it mach 2, install the same version of MySQL as you have where the root account is missing, call that machine mach 1. On mach 2, ensure innodb_file_per_table is ON and that it has a working root account with full privs. Once it's working without error, bring it down.

On mach 1, ensure also that innodb_file_per_table is ON. Bring down mach 1 too. Copy the mach 1 mysql folder to somewhere safe. Copy the mysql database table files from mach 2 data\mysql folder into the mach 1 installation'sdata\mysql folder. Move mach 1 data\ib_logfile* to a safe place so mach 1 can rebuild its logs. Start up mach 1, log in as root.

Please let us know the result.

Options: ReplyQuote




Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.