navicat 登陆服务器报错1045-Access denied for user 'root'

原因:权限的问题

解决办法

grant all privileges on *.* to 'root'@'ip地址' identified by 'mysql 密码';

如果是本地登录:

grant all privileges on *.* to 'root'@'localhost' identified by 'mysql 密码';

开放权限给所有ip设定root登陆:

grant all privileges on *.* to 'root'@'%' identified by 'mysql 密码';

最后:

flush privileges;
发布了56 篇原创文章 · 获赞 42 · 访问量 43万+

猜你喜欢

转载自blog.csdn.net/SIMPLE1995/article/details/102948052