• 快速安装,配置,启动,检查 - 关闭 5002 - 5011 端口开放所有其它
yum install iptables
iptables -F
iptables -X
iptables -Z
iptables -A INPUT -i lo -j ACCEPT
iptables -A INPUT -p tcp --dport 5002:5011 -j DROP
iptables -A INPUT -j ACCEPT
iptables -A OUTPUT -j ACCEPT
iptables -A FORWARD -j ACCEPT
/etc/rc.d/init.d/iptables save
service iptables restart
service iptables status
  • 命令常用
防火墙的基本操作命令:
安装: yum install iptables 帮助: http://linux.die.net/man/8/iptables 查询防火墙状态: service iptables status
停止防火墙: service iptables stop
启动防火墙:service iptables start
重启防火墙:service iptables restart
永久关闭防火墙: chkconfig iptables off
永久关闭后启用:chkconfig iptables on<回车>
命令配置后保存:/etc/rc.d/init.d/iptables save
列出规则:iptables -L

CentOS Linux iptables 防火墙的更多相关文章

  1. CentOS系统配置 iptables防火墙

    阿里云CentOS系统配置iptables防火墙   虽说阿里云推出了云盾服务,但是自己再加一层防火墙总归是更安全些,下面是我在阿里云vps上配置防火墙的过程,目前只配置INPUT.OUTPUT和FO ...

  2. 利用CentOS系统IPtables防火墙添加网站IP白名单

    参考博文: 利用CentOS系统IPtables防火墙添加360网站卫士节点IP白名单 centos6.5添加白名单如下: 在防火墙 配置文件中加入白名单  ip -A INPUT -s 183.13 ...

  3. linux iptables 防火墙简介

    iptables防火墙简介 Netfilter/Iptables(以下简称Iptables)是unix/linux自带的一款优秀且开放源代码的安全自由的基于包过滤的防火墙工具,它的功能十分强大,使用非 ...

  4. 15.linux iptables防火墙规则vsftp服务

    一.服务所开启的端口号.          dhcp 67       samba 139 445       http 80  https 443       mysql 3306         ...

  5. CentOS启用iptables防火墙

    centos 7默认的防火墙使用firewall,系统服务管理方式也变更了,可以通过systemctl命令控制. 可以参考这个链接 但是习惯用iptables,可以按下面的操作改下 1.关闭firew ...

  6. Linux iptables防火墙

    查找安装包yum list | grep iptables 安装iptables yum install iptables-services 重启防火墙使配置文件生效 systemctl restar ...

  7. CentOS系统IPTables防火墙中FTP规则设置

    时间 2016-04-21 10:32:15  虫虫开源 原文  http://www.sijitao.net/2403.html 主题 iptablesFTP防火墙 在设置ftp通过iptables ...

  8. Linux iptables 防火墙

    内容摘要 防火墙 防火墙定义 防火墙分类 netfilter/iptables netfilter 设计架构 iptables 简述 iptables 命令详解 命令语法 table 参数 comma ...

  9. CentOS中iptables防火墙 开放80端口方法

    开放端口:  代码如下 复制代码 [root@WX32 ~]# iptables -I INPUT -p tcp --dport 80 -j ACCEPT 保存配置:  代码如下 复制代码 [root ...

随机推荐

  1. Oracle连接字符串C#

    Password=密码;User ID=ID;Data Source=(DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = ...

  2. php四种基础算法:冒泡,选择,插入和快速排序法

    转自:http://www.php100.com/html/php/rumen/2013/1029/6333.html 许多人都说 算法是程序的核心,一个程序的好于差,关键是这个程序算法的优劣.作为一 ...

  3. html介绍

    Html的介绍 Html 是一种标记语言,主要的用处是开发网页 展示出文字,图片,视频,声音等等 是我们web开发的基础 做什么 所谓的静态页面,指的是能不能交互,而不是东西能不能动 网页设计师(ht ...

  4. eclipse alt+/ 无效时,如何设置 《转》

    一般情况下alt+/有代码提示作用,还有代码提示的快捷代码也不是alt+/,因此要恢复代码提示用alt+/.需要做两件事. 在 Window - Preferences - General - Key ...

  5. Tomcate配置单向双向SSL

    1.单向SSL 一.在Tomcate的service.xml文件中放开SSL配置 <!-- <Connector port="8443" protocol=" ...

  6. CodeForces 651B Beautiful Paintings 贪心

    A. Joysticks time limit per test 1 second memory limit per test 256 megabytes input standard input o ...

  7. C#打开指定路径文件对话框

    private string OpenFileDlog(string DeafultDir) { OpenFileDialog Ofd = new OpenFileDialog(); Ofd.AddE ...

  8. Oracle中创建用户和授权

    默认的:最高权限用户:SYSTEM 密码:MANAGER 管理员权限用户:SYS 密码:CHANGE_ON_INSTALL 普通用户:SCOTT 密码:TIGER 登 陆管理员或超级管理员用户可以自己 ...

  9. UVA 1424 二 Salesmen

    Salesmen Time Limit:3000MS     Memory Limit:0KB     64bit IO Format:%lld & %llu Submit Status Pr ...

  10. 昂贵的聘礼 Dijkstra法

    poj 1062 Time Limit: 1000MS   Memory Limit: 10000K Total Submissions: 39437   Accepted: 11432 Descri ...