Linux - NetworkingThis forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I am using a linux box (Linux 2.4.19-pre2-rmap12g) as a NAT/Server. I don't really know much about linux and the configuration has been done by somebody else (from my ISP), and it is using 'iptables'. I want to start using a file-sharing program on a Windows box that is behind the NAT and has a private ip, so i have documented about 'port forwarding using DNAT', and i found what i needed. This is the command I used: ' iptables -t nat -A PREROUTING -p tcp -i eth0 -d xxx.xxx.xxx.xxx --dport 81 -j DNAT --to 192.168.0.2:80 ' . ( xxx.xxx.xxx.xxx is the public IP address of the Linux box(NAT) ) . I opened a web-server on the .2 box , and tried to access xxx.xxx.xxx.xxx:81 and it did not work. I did ' iptables -t nat -L' and everything seemed ok. Why dose it not work ?
PS. Remember that I do not know much about Linux/iptables, for example I know that '-t nat' makes a reffernece to the < "nat" table > but I don't know what that is, or if it must be created at first...
But is this not the same thing ? I am trying all this from another computer, using telnet, so I only have access to this PC , on witch I also run the web-server. The packets I send to xxx.xxx.xxx.xxx:81 should be returned to my 80 port. Other ideeas ? PS. Please keep in mind that I am a newbie and it might be something obvios, for you, that I have overlook.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.