Articles of firewalld

找不到CentOS 7的firewall-cmd

我刚安装了CentOS 7: [root @ new〜]#cat / etc / redhat-release CentOS Linux版本7.1.1503(核心) 我正在尝试configuration防火墙,而且我被告知在CentOS 7中不再使用iptables,取而代之的是firewalld。 当试图运行命令来设置防火墙规则时: firewall-cmd –add-port = 80 / tcp 我收到以下消息: [root @ new〜]#firewall-cmd –add-port = 80 / tcp -bash:firewall-cmd:找不到命令 编辑 :我也尝试了下面的命令: [root @ new〜]#firewall-offline-cmd –add-port = 80 / tcp -bash:firewall-offline-cmd:找不到命令 没有任何成功。 我试着运行以下命令检查是否安装了firewalld: [root @ new〜]#服务firewalld状态 redirect到/ bin / systemctl状态firewalld.service firewalld.service 加载:未find(原因:没有这样的文件或目录) 有效:无效(死) 在这个输出之后,我试着启动firewalld: [root […]

firewalld vs iptables – 什么时候用哪个

TL; DR在新的CentOS服务器上安装我应该使用firewalld还是只禁用它,回到使用/ etc / sysconfig / iptables? firewalld和iptables的用途相似。 两者都进行数据包过滤 – 但是如果我理解正确,每次进行更改时,firewalld都不会刷新整个规则集。 我知道很多关于iptables的知识,但对firewalld却知之甚less。 在Fedora和RHEL / CentOS上 – 传统的iptablesconfiguration是在/ etc / sysconfig / iptables中完成的。 用firewalld,它的configuration生存在/ etc / firewalld /中,是一组XML文件。 Fedora似乎正在转向Firewalld,作为这种传统configuration的替代品。 我明白,firewalld使用iptables在底层,但它也有它自己的命令行界面和configuration文件格式如上 – 这就是我所指的使用一个与其他。 是否有一个特定的configuration/场景,这些都是最适合的? 在NetworkMangaer vsnetworking的情况下,似乎尽pipeNetworkManager可能已经被用作networking脚本的替代品,但是由于缺乏networking桥接支持和其他一些事情,许多人只是没有在服务器设置上使用它所有。 所以似乎有一个普遍的概念:“如果你在Linux桌面上,使用NetworkManager;如果你正在运行服务器,则使用networking。 这正是我阅读各种职位所得到的结果 – 但至less为这些事情提供了一个可行的使用指南 – 至less就其现状而言是如此。 但是我已经用firewalld做了同样的事情,只是把它关掉,而用iptables。 (我几乎总是在服务器上安装Linux,而不是桌面使用)。 firewalld是iptables的有效替代品,我应该在所有新系统上使用它吗?

debuggingiptables和常见的防火墙陷阱?

这是关于理解和debuggingLinux系统上的软件防火墙的一个build议性 规范问题 。 为了回应EEAA的回答和@Shog的评论,我们需要一个合适的典型问答来解决关于iptables的一些相对简单的问题。 什么是结构化的方法来debuggingLinux软件防火墙的问题, netfilter包过滤框架,通常由userland interface iptables引用? 什么是常见的陷阱,反复出现的问题和简单或稍微模糊的事情来检查偶尔的防火墙pipe理员可能会忽略或从知道获益? 即使使用UFW , FirewallD (aka firewall-cmd ), Shorewall或类似的工具,也可以从这些工具所提供的抽象层之下查看底层。 这个问题不是作为构build防火墙的方法:查看产品文档 ,例如为iptables提供食谱,或者search带标记的iptables ufw firewalld firewall-cmd问题,以获得现有频繁和高度评价的高分 Q&A的。

如何在RHEL 7和Fedora 18上启用iptables(而不是firewalld)服务?

最新的fedora有firewalld作为新的防火墙应用程序。 我喜欢旧的iptables服务。 我想让他们回来,但不知道如何做到这一点。 我努力了 : systemctl disable firewalld.service systemctl stop firewalld.service systemctl enable iptables.service systemctl enable ip6tables.service systemctl start iptables.service systemctl start ip6tables.service 但它不工作! 没有find任何帮助维基或谷歌。 禁用firewalld工作好,但是当我试图启用iptables.service我得到: systemctl enable iptables.service Failed to issue method call: No such file or directory

如何在CentOS上使用firewall-cmd打开特定IP地址的端口?

我想在CentOS 7.1服务器上用firewall-cmd命令打开IP地址为1.2.3.4端口4567 。 我怎么能做到这一点,因为我能find的文件太过于具体了?