由于服務(wù)器沒(méi)有對(duì)外開(kāi)放mysql的默認(rèn)端口3306導(dǎo)致
CentOs7以下開(kāi)啟方式
iptables?-I?INPUT?-p?tcp?--dport?3306?-j?ACCEPT
iptables save
service?iptables?restart
CnetOs7開(kāi)啟方式
firewall-cmd --permanent --zone=public --add-port=3306/tcp
firewall-cmd --reload