2016年9月27日19:07:19
[ERROR]The last packet sent successfully to the server was 0 milliseconds ago. The last packet sent successfully to the server was 0 milliseconds ago. The driver has not received any packets from the server.
解决方法:
(1)使用JDBC URL中使用autoReconnect属性,url添加&autoReconnect=true&failOverReadOnly=false&maxReconnects=10
(2) 修改MySQL的参f 添加[mysqld]wait_timeout=31536000 interactive_timeout=31536000
(3)重启mysqlservice mysql restart原因分析:
(1)大量数据访问情况下,mysql connection连接有可能失效
(2)长时间不妨问,connection会失效