mysql 爆出,本地連接正常,遠程鏈接無法鏈接,爆出錯誤
Lost connection to MySQL server at ‘reading initial communication packet
大量無法遠程鏈接的問題
1.iptables 導致 看看iptables -L
2.mysqld 下增加
skip-name-resolve
我加了發現不行
看下面
3.bind-adress
我發現mysqld 還有一句
bind-address = ::ffff:127.0.0.1
[mysqld]#bind-address = ::ffff:127.0.0.1local-infile=0datadir=/var/lib/mysqlsocket=/var/lib/mysql/mysql.sock# Disabling symbolic-links is recommended to prevent assorted security riskssymbolic-links=0# Settings user and group are ignored when systemd is used.# If you need to run mysqld under a different user or group,# customize your systemd unit file for mariadb according to the# instructions in http://fedoraproject.org/wiki/Systemdskip-name-resolve