Re: how to config 80 port for apache in iptables

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, 2009-04-12 at 22:18 +0800, Nathan Huang wrote:
> Hi guys
> who can help me with opening 80 port for apache in iptables, I want to
> access my apache server from remote computer,  but I failed in config
> iptables with 80 port.
> 
> First step:
> echo '-A RH-Firewall-1-INPUT -m state --state NEW -m tcp -p tcp --dport
> 80 -j ACCEPT' >> /etc/sysconfig/iptables

Is this syntax the same as the rest of your rules?  In particular, I'm
looking at "RH-Firewall-1-INPUT".

> Second step:
> /sbin/service iptables restart
> 
> error:
> iptables: Flushing firewall rules:                         [  OK  ]
> iptables: Setting chains to policy ACCEPT: filter          [  OK  ]
> iptables: Unloading modules:                               [  OK  ]
> iptables: Applying firewall rules: iptables-restore: line 15 failed
>                                                            [FAILED]
> 
> who can tell me what's wrong with my iptable configuration.

Probably nobody, until you post the list the rest of your rules.

I think you're also missing a "COMMIT" after your rule.  And I suspect
you should stop the iptables service before directly fiddling with its
configuration file (that rather depends on when, and if, it saves the
current rule set, when you tell it to restart).


-- 
[tim@localhost ~]$ uname -r
2.6.27.21-78.2.41.fc9.i686

Don't send private replies to my address, the mailbox is ignored.  I
read messages from the public lists.



-- 
fedora-list mailing list
fedora-list@xxxxxxxxxx
To unsubscribe: https://www.redhat.com/mailman/listinfo/fedora-list
Guidelines: http://fedoraproject.org/wiki/Communicate/MailingListGuidelines

[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux