1. Problem one: After using update mysql.user set password= ' root ' to change the password, you cannot log in
Workaround: The procedure is as follows.
(1) Close MySQL (Kill the mysqld process), then use the command:
Mysqld--skip-grant-tables
(2) Start the database, you can connect the normal
(3) Then clear the root password:
Update Mysql.user Set Password=null
(4) Start the database using the command mysqld
After you have done this, you can log in normally.
2. Problem two: MySQL Error 1130 Host ' localhost ' is not allowed to connect to this MySQL server
Workaround: authorize with authorization statement
GRANT all privileges on * * to ' root ' @ '% ' identified by ' 123456 ' with GRANT OPTION ;
Authorize local access for root.
Copyright NOTICE: This article for Bo Master original article, without Bo Master permission not reproduced.
MySQL Login Issues