Forgot your password with mysql service name

Because of his previous service name also forgot to forget the root password, mysql password forgot search online, you need net start service name into an infinite loop

One can find the password reset message, and would like to share.

 MySQL service shutdown is running
2. Open a DOS window, go to the mysql \ bin directory
3. Enter mysqld --skip-grant-tables Enter --skip-grant-tables means that the MySQL service start time to skip the permissions table certification
4. to open a DOS window (DOS window because that just can not move), go to the mysql \ bin directory 
5. enter the mysql enter, if successful, will appear MySQL prompt>
6. connect privileges on the database: use mysql ;
6. change your password: Update User SET password = password ( "the root") WHERE User = "the root"; 
   mysql5.7 above -> UPDATE user SET authentication_string = pASSWORD ( "root") WHERE User = "root";
7. refresh permission (must step): flush privileges; 
8. quit quit.

This can be a normal landing 

He published 192 original articles · won praise 27 · Views 100,000 +

Guess you like

Origin blog.csdn.net/lovely_girl1126/article/details/82916009