启动:systemctl start firewalld
关闭:systemctl stop firewalld
查看状态:systemctl status firewalld
开机禁用:systemctl disable firewalld
开机启用:systemctl enable firewalld
配置firewalld-cmd
查看版本:firewall-cmd --version
查看帮助:firewall-cmd --help
显示状态:firewall-cmd --state
重新载入:firewall-cmd --reload
固定ip访问固定端口命令
firewall-cmd --permanent --add-rich-rule="rule family="ipv4" source address="ip地址" port protocol="tcp" port="端口号" accept"
删除固定ip访问固定端口命令
firewall-cmd --permanent --remove-rich-rule="rule family="ipv4" source address="ip地址" port protocol="tcp" port="端口号" accept"
查看已添加的ip地址和端口信息
firewall-cmd --list-rich-rules