jayrick213 Posted April 11, 2013 Group: Members Topic Count: 10 Topics Per Day: 0.00 Content Count: 25 Reputation: 0 Joined: 01/10/12 Last Seen: August 15, 2024 Share Posted April 11, 2013 is there anybody can help how to make a fake root password in phpmysql, i accedentaly deleted my root user thats why i cant login to phpmyadmin.. thanks in advance.. Quote Link to comment Share on other sites More sharing options...
Brian Posted April 11, 2013 Group: Members Topic Count: 75 Topics Per Day: 0.02 Content Count: 2223 Reputation: 593 Joined: 10/26/11 Last Seen: June 2, 2018 Share Posted April 11, 2013 is there anybody can help how to make a fake root password in phpmysql, i accedentaly deleted my root user thats why i cant login to phpmyadmin.. thanks in advance..I'm guessing YOU are hosting your MySQL Server.Here are instructions (for both Windows and Linux) to Reset the MySQL root password Since you need to re-create the root user, for step 3 you would use this query instead: CREATE USER 'root'@'localhost'; GRANT ALL ON *.* TO 'root'@'localhost' WITH GRANT OPTION; FLUSH PRIVILEGES; Quote Link to comment Share on other sites More sharing options...
Mootie Posted April 11, 2013 Group: Members Topic Count: 43 Topics Per Day: 0.01 Content Count: 815 Reputation: 86 Joined: 10/26/12 Last Seen: June 10, 2022 Share Posted April 11, 2013 If you are hosting to asurahosting or somewhere else you can ask your provider to reset it for you. Quote Link to comment Share on other sites More sharing options...
jayrick213 Posted April 12, 2013 Group: Members Topic Count: 10 Topics Per Day: 0.00 Content Count: 25 Reputation: 0 Joined: 01/10/12 Last Seen: August 15, 2024 Author Share Posted April 12, 2013 tnx Quote Link to comment Share on other sites More sharing options...
Asura Posted April 14, 2013 Group: Members Topic Count: 3 Topics Per Day: 0.00 Content Count: 707 Reputation: 168 Joined: 01/26/12 Last Seen: February 7, 2014 Share Posted April 14, 2013 Hi Brian, From my own experience; there is no way to re-create a full 'root' account after it has been deleted. Even with running MySQL in safe mode and the option to skip privileges, it would not allow you to re-create that 'root' with "All Privileges". I would use the following syntax to re-create the closest thing to 'root'; INSERT INTO `mysql`.`user`(`Host`, `User`, `Password`, `Select_priv`, `Insert_priv`, `Update_priv`, `Delete_priv`, `Create_priv`, `Drop_priv`, `Reload_priv`, `Shutdown_priv`, `Process_priv`, `File_priv`, `Grant_priv`, `References_priv`, `Index_priv`, `Alter_priv`, `Show_db_priv`, `Super_priv`, `Create_tmp_table_priv`, `Lock_tables_priv`, `Execute_priv`, `Repl_slave_priv`, `Repl_client_priv`, `Create_view_priv`, `Show_view_priv`, `Create_routine_priv`, `Alter_routine_priv`, `Create_user_priv`, `ssl_type`, `ssl_cipher`, `x509_issuer`, `x509_subject`, `max_questions`, `max_updates`, `max_connections`, `max_user_connections`) VALUES ('%', 'root', PASSWORD('password_is_here'), 'Y', 'Y', 'Y', 'Y', 'Y', 'Y', 'Y', 'Y', 'Y', 'Y', 'Y', 'Y', 'Y', 'Y', 'Y', 'Y', 'Y', 'Y', 'Y', 'Y', 'Y', 'Y', 'Y', 'Y', 'Y', 'Y', '', '', '', '', '0', '0', '0', '0'); Quote Link to comment Share on other sites More sharing options...
Question
jayrick213
is there anybody can help how to make a fake root password in phpmysql, i accedentaly deleted my root user thats why i cant login to phpmyadmin.. thanks in advance..
Link to comment
Share on other sites
4 answers to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.