0
点赞
收藏
分享

微信扫一扫

登录mysql时密码正确但是不能登录的解决方案

登录mysql时密码正确但是不能登录的解决方案_不能打开数据库

mysql: [Warning] Using a password on the command line interface can be insecure.

ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES)

这应该是设置密码时没有加密造成的,可以用以下方法解决

[root@host50 ~]# vim /etc/my.cnf

添加这一行

skip-grant-tables

登录mysql时密码正确但是不能登录的解决方案_mysql_02

重启数据库

[root@host50 ~]# systemctl restart mysqld

[root@host50 ~]# mysql

登录mysql时密码正确但是不能登录的解决方案_不能打开数据库_03

举报

相关推荐

0 条评论