CentOS 7.0默认使用的是firewall作为防火墙,使用iptables必须重新设置一下
1、直接关闭防火墙
systemctl stop firewalld.service #关闭firewall
systemctl disable firewalld.service #禁止firewall开机启动
2、设置 iptables service
yum -y install iptables-services
如果要修改防火墙配置,如增加防火墙端口3306
vi /etc/sysconfig/iptables
增加规则
-A INPUT -m state --state NEW -m tcp -p tcp --dport 3306 -j ACCEPT
保存退出后
systemctl restart iptables.service #重启防火墙使配置生效
systemctl enable iptables.service #设置防火墙开机启动
最后重启系统使设置生效即可。

Centos7.0关闭防火墙的更多相关文章

  1. centos7.0 关闭防火墙

    1.关闭firewall:systemctl stop firewalld.service #停止firewallsystemctl disable firewalld.service #禁止fire ...

  2. CentOS7/6 关闭防火墙

    CentOS6关闭防火墙使用以下命令, //临时关闭 service iptables stop //禁止开机启动 chkconfig iptables off CentOS7中若使用同样的命令会报错 ...

  3. Centos7永久关闭防火墙

    Centos7永久关闭防火墙 查看防火墙状态: systemctl status firewalld.service 绿的running表示防火墙开启 执行关闭命令: systemctl stop f ...

  4. Centos7设置关闭防火墙

    CentOS 7.0默认使用的是firewall作为防火墙,要想使用iptables必须重新设置一下. 1.关闭防火墙 [root@localhost ~]# systemctl stop firew ...

  5. centos7上关闭防火墙

    centos7上默认开启的是+firewalld,关闭了iptables 停止防护墙: systemctl stop firewalld.service 开机不启动: systemctl disabl ...

  6. centOS7.0配置防火墙

    之前用的iptables来管理的防火墙,后来发现centOS7.0中已经用firewalld取代iptables了,于是与时俱进,停用了iptables. systemctl stop iptable ...

  7. centos7上面关闭防火墙

    CentOS 7.0默认使用的是firewall作为防火墙:若没有启用iptables 作为防火墙,则使用以下方式关闭防火墙: systemctl stop firewalld.service 关闭开 ...

  8. 【Linux】CentOS7 打开关闭防火墙及端口

    一.centos7版本对防火墙进行加强,不再使用原来的iptables,启用firewalld1.firewalld的基本使用启动: systemctl start firewalld查状态:syst ...

  9. 003 centos7中关闭防火墙

    在centos7中,防火墙有了新的变化.下面是常用的几个命令. 1.查看状态 systemctl status firewalld 2.关闭防火墙 systemctl stop firewalld.s ...

随机推荐

  1. 模拟Vue之数据驱动

    一.前言 在随笔"模拟Vue之数据驱动1"结尾处,我们说到如果监听的属性是个对象呢?那么这个对象中的其他属性岂不就是监听不了了吗? 如下: 倘若user中的name.age属性变化 ...

  2. php中的echo,json_decode,json_encode常用函数使用注意事项

    ---恢复内容开始--- 1.echo函数 echo只能输出单个字符串或者整数,不能直接输出数组.要输出多个字符串必须用分号 eg: echo可以输出字符串加变量,如果输出的数字字符串则会将对应的数字 ...

  3. Developing Skills

    题目传送门:点击打开链接 #include <iostream> #include <cstdio> #include <cstdlib> #include < ...

  4. flume1.8 开发指南学习感悟

    概述: Apache Flume是一个分布式.可用的系统,用于从许多不同的sources有效的收集并移动大量日志数据用于集中存储数据. 架构及数据流动模型: flume实际上就是一个Agent.Age ...

  5. Asp.Net Core Use MongoDB

    前几天在网上想找一下Asp.Net Core使用MongoDB相关的文章,也看了几篇,发现都是在写简单的例子,这样的例子是不能用在生产环境的,不能用的生产环境的.封装一个东西一定是建立在你对这个东西足 ...

  6. MFC中菜单的命令响应顺序

    响应只可以由Doc,View,MainFrame以及APP四个类完成. 响应顺序是: 点击某菜单项,框架类最先接到菜单命令消息. 框架类把接收到得这个消息交给它的子窗口,即视图类. 视图类根据命令消息 ...

  7. linux 下CentOS 下 npm命令安装gitbook失败的问题

    运行环境 linux 服务器:CentOS 7.0 系统:安装了nodejs :使用 npm 安装 gitbook 出现错误提示: npm install -g gitbook-cli symbol ...

  8. PageRank_网页排名_MapReduceJava代码实现思路

    PageRank 1.    概念 2.    原理   3.    java代码实现思路   1.定义收敛标准     每次算出新的pr-oldpr=差值 ,所有页面的差值累加 ,除以pagecou ...

  9. 最近公司用到了lombok,感觉很不错的样子,所以上网搜了一些资料,总结了一下用法。

    lombok作用:它提供了简单的注解形式来帮助我们简化消除一些必须有但显得很臃肿的Java代码,特别是相对于 POJO.缺点是使用lombok虽然能够省去手动创建setter和getter方法的麻烦, ...

  10. javascript中window.location.search的用法和作用。

    用该属性获取页面 URL 地址: window.location 对象所包含的属性 属性 描述 hash 从井号 (#) 开始的 URL(锚) host 主机名和当前 URL 的端口号 hostnam ...