刚下载的datagrip连接mysql数据库失败,但navicat连接是正常的。
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)
MySql版本为8.0, 5.7.28, 5.6.46和以上版本,如果服务端启用了TLSv1.2配置,而客户端没进行对应配置时,就会出现上述问题。
可以在数据库的链接属性data source properties的高级设置中设置enabledTLSprotocols的值为TLSv1,TLSv1.1,TLSv1.2,TLSv1.3(默认这个链接值为空)
If you are running MySQL 8.0, 5.7.28, 5.6.46 and later and your server is configured with TLSv1.2 you can enabled it in driver:
open up data source properties, switch to Advanced tab and set value for enabledTLSprotocols to TLSv1,TLSv1.1,TLSv1.2,TLSv1.3