关闭防火墙
systemctl stop firewalld
开启防火墙
systemctl start firewalld
关闭开机启动
systemctl disable firewalld
开启开机启动
systemctl enable firewalld
开启某个端口(如:2231端口)
firewall-cmd --zone=public --add-port=19080/tcp --permanent
firewall-cmd --reload
查询端口号(如:2231端口) 是否开启:
firewall-cmd --query-port=2231/tcp
查询有哪些端口是开启的:
firewall-cmd --list-port