Oops - and now with reply-all... Hi. You should run both these commands (I will not disclose how you make it apply after-reboot for now)
1. echo 1 > /proc/sys/net/ipv4/ip_forward 2. iptables -t nat -A POSTROUTING -o ppp0 -j MASQUERADE Don't forget to set correct DNS on your host B Ez On Tue, Apr 20, 2010 at 8:29 AM, Dan Shimshoni <danshi...@gmail.com> wrote: > Hello, > First, I don't know much about iptables. > > Second, I have a Linux machine ("A") with two nics, which is connected > to the Internet via Bezeq ADSL router. > This machines runs a pppoe connection to the intenet, so the > connection is done via ppp0. > On eth1 I have an inner IP address which I set manually (192.168.0.10). > > I have a second Linux machine ("B"), nearby. This machine is connected > directly > to machine "A" via ethernet cable. On eth0 I have an inner IP address which > I set manually (192.168.0.11). So I can ping from 192.168.0.11 to > 192.168.0.10. > > Sometimes I want to connect from machine "B" to the Internet via machine > "A". > I suppose this is possible by setting some iptables rule on machine "A", > and > setting it to work in forwarding mode. Could this done by setting one > iptables rule > on machine "A"? > What is the proper rule to achieve it? > > DS > > _______________________________________________ > Linux-il mailing list > Linux-il@cs.huji.ac.il > http://mailman.cs.huji.ac.il/mailman/listinfo/linux-il >
_______________________________________________ Linux-il mailing list Linux-il@cs.huji.ac.il http://mailman.cs.huji.ac.il/mailman/listinfo/linux-il