Linux Fedora 19 - iptables 启动失败

Linux Fedora 19 - iptables 启动失败

我一直在尝试启动iptables防火墙服务,但始终失败。出了什么问题?

# systemctl status iptables.service
iptables.service - IPv4 firewall with iptables
  Loaded: loaded (/usr/lib/systemd/system/iptables.service; enabled)
  Active: failed (Result: exit-code) since Sat 2013-10-26 11:01:54 CDT; 41s ago
 Process: 2114 ExecStart=/usr/libexec/iptables/iptables.init start (code=exited, status=1/FAILURE)

Oct 26 11:01:54 localhost.localdomain iptables.init[2114]: iptables: Applying firewall rules: iptables-restore: line 1 failed
Oct 26 11:01:54 localhost.localdomain systemd[1]: iptables.service: main process exited, code=exited, status=1/FAILURE
Oct 26 11:01:54 localhost.localdomain systemd[1]: Failed to start IPv4 firewall with iptables.
Oct 26 11:01:54 localhost.localdomain systemd[1]: Unit iptables.service entered failed state.

答案1

尝试(以 root 身份):

iptables-restore < /etc/sysconfig/iptables

如果失败,应该会给您提供更多信息的错误。如果有效,则 systemd 服务文件可能有问题。

相关内容