预备环境
系统:centos6或者7
More info: Centos
Centos防火墙操作
###Centos6防火墙操作
$ sudo service firewalld stop #停止服务
$ sudo service firewalld start #启动服务
$ sudo service firewalld status #查看状态
###Centos7防火墙操作
$ sudo systemctl enable firewalld.service #"开机启动"启用
$ sudo systemctl disable firewalld.service #"开机自启"禁用
$ sudo systemctl start firewalld.service #启动防火墙
$ sudo systemctl stop firewalld.service #停止防火墙
$ sudo systemctl status firewalld.service #查看防火墙状态