zoukankan      html  css  js  c++  java
  • iptables 配置问题,以及centos firewall 配置

    1、新装centos系统 没有iptables文件的问题解决.
    这时候就需要自己写一个iptables文件并且写入相关指令
    然后使用 service iptables save 时
    显示错误:The service command supports only basic LSB actions (start, stop, restart, try-restart, reload, force-reload, status). For other actions, please try to use systemctl.

    找到解决方法:
    首先不管防火墙有没有关 都使用systemctl stop firewalld 关闭防火墙
    然后使用 yum install iptables-services 安装或更新服务
    再使用systemctl enable iptables 启动iptables
    最后 systemctl start iptables 打开iptables
    大功告成
    试试service iptables save

    2、Centos7 防火墙开放80端口.

    firewall-cmd --zone=public --add-port=80/tcp --permanent
    

      

    返回success 说明设置成功,然后重启firewalld, systemctl restart firewalld

  • 相关阅读:
    Servlet开发
    HTML实现页面自动跳转的五种方法
    AVAYA话机管理
    AVAYA路由
    报关相关知识
    基本杆法
    AVAYA初始配置
    加塞和瞄准
    基本杆法图解
    AVAYA拨号计划
  • 原文地址:https://www.cnblogs.com/murenhui/p/9035920.html
Copyright © 2011-2022 走看看