navicat连接Mysql8报错

2059 - Authentication plugin ‘caching_sha2_password‘ cannot be loaded
原因:mysql8的密码的默认加密方式是caching_sha2_password,要将其改为mysql_native_password
第一步,执行命令
alter user ‘root’@’%’ identified with mysql_native_password by ‘Admin@123’;
第二步,执行命令flush privileges使权限配置项立即生效。再次尝试连接Mysql,连接成功。

1130 - Host '121.32.76.246 is not allowed to connect to this MysQL server
update mysql.user set Host = ‘%’ where Host = ‘::1’ and User = ‘root’;
参考:https://www.cnblogs.com/codecat/p/10729033.html

1449 - The user specified as a definer (‘mysql.infoschema’@localhost) does not exist

2003- Can’t connect to MySQL server on ‘xxx.xxx.xxx.xxx’ (10060 “Unknown error”) .
防火墙的问题,把防火墙开了再关掉

重启
systemctl restart firewalld.service
开放端口
firewall-cmd --zone=public --add-port=3306/tcp --permanent
#命令含义
--zone #作用域 
--add-port=3306/tcp #添加端口,格式为:端口/通讯协议 
--permanent #永久生效
重启
systemctl restart firewalld.service
关闭
systemctl stop firewalld.service
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值