Caused by: com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: 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.
Caused by: java.net.ConnectException: 拒绝连接 (Connection refused)
网上有很多种情况,有可能是MySQL崩了,需要重启MySQL,解决方案如下:
[root@hadoop102 hive]# service mysql status
MySQL is not running, but lock file (/var/lock/subsys