Re: Where to add own rules in /etc/sysconfig/iptables

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

 



On Thu, 2002-10-31 at 04:36, Michael Schwendt wrote:

> On 30 Oct 2002 16:15:36 -0600, Alejandro González Hernández - Imoq
> wrote:
> 
> > My computer has two network cards; eth0 has a real, public and valid
> > IP address. eth1 has a private address (192.168.1.169).
> > 
> > What I am trying to to is to route the port 80 from the public network
> > to a computer (192.168.105.220) in the private network.
> > 
> > To achieve this, I just set up the firewall with lokkit and then added
> > the two rules commented before:
> > 
> > iptables -t nat -A PREROUTING -p tcp --dport 80 -j DNAT --to
> > 192.168.105.220:80
> > iptables -I RH-Lokkit-0-50-INPUT 5 -p tcp --dport 80 -j ACCEPT
> > 
> > But still can't reach port 80 from public network.
> > 
> > I even tried stopping iptables and then only use the two rules above,
> > without luck :(
> > 
> > What do you advise me to do?
> 
> In that case the rule in the INPUT chain is not needed. Your FORWARD
> chain accepts everything, though. Hence I guess you haven't turned
> on IP Forwarding in the kernel:
> 
>   # echo "1" > /proc/sys/net/ipv4/ip_forward
> or
>   # sysctl -w net.ipv4.ip_forward=1
> 
> and edit /etc/sysctl.conf appropriately, so next reboot will enable
> IP Forwarding automatically.

Unfortunatelly I already had ip_forward enabled:

[root@imoqland root]# cat /etc/sysctl.conf | grep forw
# Controls IP packet forwarding
net.ipv4.ip_forward = 1
[root@imoqland root]# cat /proc/sys/net/ipv4/ip_forward
1

But still doesn't work :(. I left the whole previous message on purpouse
so the original question doesn't get lost.

Why is it so hard? I have read the documentation, tried to follow the
instructions but it still doesn't work. I think it has been one of the
more difficult task latelly. Three days and still no luck :(.

Alex.

-- 
ˇSé libre, usa software libre!
Be free, use free software!
http://www.imoqland.com/



-- 
Psyche-list mailing list
Psyche-list@redhat.com
https://listman.redhat.com/mailman/listinfo/psyche-list

[Index of Archives]     [Fedora General Discussion]     [Red Hat General Discussion]     [Centos]     [Kernel]     [Red Hat Install]     [Red Hat Watch]     [Red Hat Development]     [Red Hat 9]     [Gimp]     [Yosemite News]

  Powered by Linux