一、Centos 6版本解决办法:

1.任意运行一条iptables防火墙规则配置命令:

iptables -P OUTPUT ACCEPT  

2.对iptables服务进行保存:

service iptables save  

3.重启iptables服务:

service iptables restart 

二、Centos 7版本解决办法:

1、停止并屏蔽firewalld服务

systemctl stop firewalld
systemctl mask firewalld

2、安装iptables-services软件包

yum install iptables-services

3、在引导时启用iptables服务

systemctl enable iptables

4、启动iptables服务

systemctl start iptables

5、保存防火墙规则

service iptables save
或
/usr/libexec/iptables/iptables.init save

解决CentOS(6和7版本),/etc/sysconfig/下没有iptables的问题的更多相关文章

  1. 解决opacity属性在低版本IE浏览器下失效的方法

    以前,一直都以为ie9以下的版本不支持opacity属性.所以就同时使用 opacity和ie独特的filter蒙版.但是有些时候需要一些动态的效果,就比如层的渐渐消失,隐藏,就需要使用动态变化的op ...

  2. 解决CentOS(RedHat)中sendmail和sm-client启动慢故障(转)

    Starting sendmail: Starting sm-client: 刚才发了修改主机名那篇文章后,我意外发现重新启动CentOS的时候系统会卡在sendmail和sm-client那里将近3 ...

  3. 解决CentOS无法显示中文字体 | 系统运维 | Web2.0

    解决CentOS无法显示中文字体 | 系统运维 | Web2.0 About Me    博客园    devops    前端    张家港水蜜桃 傍晚好! 2013年09月12日 17:56:08 ...

  4. 解决CentOS 7安装zabbix 3.0 无法启动zabbix-server的问题[segfault at 18 ip 00007f78842b4bd0 sp 00007fff1995a818 error 4 in libpthread-2.17.so[7f78842ab000+16000]]

    解决CentOS 7安装zabbix 3.0 无法启动zabbix-server的问题 [root@localhost sbin]# service zabbix-server start Redir ...

  5. 一秒解决CentOS下service 功能 不能使用 bash: service: command not found

    首先检查自己是否 使用的是root用户 如果是并且还不能用-----执行以下操作 在centos系统中,如果/sbin目录下没有service这个命令,就会出现 bash: service: comm ...

  6. 解决CentOS下service 功能 不能使用 bash: service: command not found

    首先检查自己是否 使用的是root用户 在centos系统中,如果/sbin目录下没有service这个命令,就会出现 bash: service: command not found 解决步骤如下: ...

  7. CentOS 8及以上版本配置IP的方法,你 get 了吗

    接上篇文章讲了 Ubuntu 18及以上版本的配置方法,本文再来讲讲 CentOS 8 及以上版本配置 IP 的方法. Centos/Redhat(8.x) 配置 IP 方法 说明:CentOS 8 ...

  8. /etc/sysconfig/下找不到iptables文件解决方法

    时间:2014-12-19 01:17来源:csdn 作者:大智 举报 点击:5639次 本想做些防火墙策略.防火墙策略都是写在/etc/sysconfig/iptables文件里面的.可我发现我也没 ...

  9. centos 6.7 perl 版本 This is perl 5, version 22 安装DBI DBD

    <pre name="code" class="cpp">centos 6.7 perl 版本 This is perl 5, version 22 ...

随机推荐

  1. 【JAVA基础】一:聊聊笔试常见到的 “==、equal” 比较是否相等的内在差别

    开始本文之前,先让我们记住一个口诀(这个口诀只针对基础的类比如String.Integer等,如果是自定义的类,需要看equal的具体实现): equal比较其值,== 比较地址 这两天在走查代码的时 ...

  2. Linux下卸载Oracle 11g

    第一种方法: 使用oracle自带的runInstaller 卸载 [oracle@VM_0_14_centos deinstall]$ cd $ORACLE_HOME [oracle@VM_0_14 ...

  3. python全栈开发 * 线程队列 线程池 协程 * 180731

    一.线程队列 队列:1.Queue 先进先出 自带锁 数据安全 from queue import Queue from multiprocessing import Queue (IPC队列)2.L ...

  4. C++标准库algorithm

    (1) 基本数学相关: max(t1, t2)和min(t1, t2), 返回t1和t2中的较大.较小者. max_element(b, e)和min_element(b, e), 返回两个迭代器所指 ...

  5. Overview of Azure Storage

    Azure Storage types Blob storage. Containers for data blobs. The three types of blobs are: Page blob ...

  6. golang 学习路径

    目录 一 了解 go 二 入门教程 三 安装运行环境 & IDE(goland) 四 gotour 五 简易源码解析 六 开始写代码 七 学习框架 八 惯用法 九 调优 一 了解 go 谷歌一 ...

  7. (转载)python调用shell命令之os 、commands、subprocess

    linux系统下进入python交互式环境: 一.os 模块 1.1.os模块的exec方法簇: python交互界面中: In [1]: import os In [2]: os.exec os.e ...

  8. oracle初级语法

    --select关键字第一个句型: select emp.ename,emp.sal from emp; --from 关键字后面跟 需要查询表名: select ename from emp; -- ...

  9. tableview Footerview有多余的间距

    调整footerView的高度 UIView *footerV = [[UIView alloc] initWithFrame:CGRectMake(, , Main_Screen_Width, )] ...

  10. RxSwift + Moya + ObjectMapper

    https://www.jianshu.com/p/173915b943af use_frameworks! target 'RXDemo' do pod 'RxSwift' pod 'RxCocoa ...