LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   NAT problem (https://www.linuxquestions.org/questions/linux-newbie-8/nat-problem-540491/)

Braynid 03-25-2007 01:49 PM

NAT problem
 
Hey,
I use Ubuntu Desktop 6.10 and i know this has been discussed over and over and over again but i just can't manage it.

I have the linux PC that i use as a gateway for my other, Windows PC. All I want to do i use iptables to NAT trough my linux to my other PC.

My internet connection is eth0 and my LAN is eth1.

I have used:
Code:

iptables -P FORWARD ACCEPT
iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE
echo 1 > /proc/sys/net/ipv4/ip_forward

and it worked just fine 10 minutes. Then i did a 'apt-get update/upgrade' and ever since i can't get it to work.

What am I doing wrong ?

Braynid 03-26-2007 03:20 AM

I have tried also

Code:

iptables -t nat -A POSTROUTING -s 192.168.0.10 -o eth0 -j MASQUERADE
and still won't do it.


All times are GMT -5. The time now is 07:07 PM.