IDEA2021.3.2
Mysql5.7.25
错误代码:
[08S01]
Communications link failure
The last packet sent successfully to the server was 0 milliseconds ago. The driver has not received any packets from the server.
No appropriate protocol (protocol is disabled or cipher suites are inappropriate).
参考网址(解决问题):
https://www.cnblogs.com/shuangxinyuan/p/15506469.html
查找my.ini配置文件:
mysql 查找配置文件 my.ini 位置方法_微风–轻许–的博客-CSDN博客
更改配置文件后,重新启动MYSQL服务,报错,navicat无法连接,服务无法启动
重启服务方法:
MySQL启动不了,无法启动MySQL服务解决技巧_mysql起不来_普通网友的博客-CSDN博客
怎么解决mysql服务无法启动的问题-百度经验
cmd可以连上MySQL,navicat也连上了
idea报错,还是08S01.
官方文档:
Cannot connect to a database | IntelliJ IDEA
进行telnet连接,问题:
1.telnet既不是内部也不是外部命令
解决方法:
快搜_360搜索
2.连接3306端口,显示对主机的遗失
https://blog.csdn.net/m0_47505062/article/details/122318498
问题依旧回到原地
根据
https://blog.csdn.net/m0_46202073/article/details/113839557
检查端口号没有问题,是3306,排除
尝试将连接的主机名由localhost改为IP地址,出现其他错误,错误代码:
[HY000][1130] null, message from server: “Host ‘LAPTOP-Q4D1JEGR’ is not allowed to connect to this MySQL server”.
查找到解决办法:
https://blog.csdn.net/xionglangs/article/details/50385057
解决后,又回到原先的08S01.