1. 程式人生 > >本地無法連線linux伺服器mysql(10060)

本地無法連線linux伺服器mysql(10060)

可能的原因:

1、linux防火牆未加3306埠

2、關閉firewalld防火牆:systemctl stop firewalld,systemctl disable firewalld

3、伺服器上登入mysql,檢視是否有地址限制,

use mysql;

select host,user from user;

grant all privileges on *.* to 'root'@'%' identified by '密碼';

flush privileges;