//這裡發現防火牆是開啟的,再來檢視防火牆控制的埠systemctl status firewalld
//檢視防火牆控制的埠,發現我想要監聽的8081埠沒有開啟
//永久開啟3306埠
sudo firewall-cmd --zone=public --add-port=3306/tcp --permanent
//過載防火牆
sudo firewall-cmd --reload
firewall-cmd --list-all檢視所有埠
Linux防火牆操作埠號
檢視防火牆狀態 systemctl status firewalld開啟防火牆 systemctl start firewalld關閉防火牆 systemctl stop firewalld檢視已經開放的埠 firewall cmd list ports查詢指定埠是否已開 比如zk的2181 提示 ...
centos7開啟防火牆和開啟指定埠
1 開啟防火牆firewall cmd statesystemctl start firewalld.servicesystemctl enable firewalld.servicesystemctl restart firewalld.servicefirewall cmd statesyste...
centos7開啟防火牆和指定埠
1 開啟防火牆firewall cmd statesystemctl start firewalld.servicesystemctl enable firewalld.servicesystemctl restart firewalld.servicefirewall cmd statesyste...