篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了text configuraciones de Mysql相关的知识,希望对你有一定的参考价值。
MySQL Error: : 'Access denied for user 'root'@'localhost'
https://stackoverflow.com/questions/41645309/mysql-error-access-denied-for-user-rootlocalhost
All solutions I found were much more complex than necessary and none worked for me. Here is the solution that solved my problem. No need to restart mysqld or start it with special privileges.
sudo mysql
ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY 'root';
With a single query we are changing the auth_plugin to mysql_native_password and setting the root password to root (feel free to change it in the query)
Now you should be able to login with root. More information can be found in mysql documentation
(exit mysql console with Ctrl + D or by typing exit)
以上是关于text configuraciones de Mysql的主要内容,如果未能解决你的问题,请参考以下文章