当前位置:懂科普 >

IT科技

> linux防火墙关闭端口命令

linux防火墙关闭端口命令

方法一:

重启后生效 

开启的具体命令是:chkconfig iptables on 

关闭的具体命令是:chkconfig iptables off 

验证防火墙是否关闭的具体命令是chkconfig --list |grep iptables

方法二: 即时生效,但重启后失效 

开启的具体命令是:service iptables start 

关闭的具体命令是:service iptables stop 

在centos 7中:

systemctl stop firewalld.service #停止   

systemctl disable firewalld.service #禁用

linux防火墙关闭端口命令

  • 文章版权属于文章作者所有,转载请注明 https://dongkepu.com/itkeji/0v89xk.html