Linux - Networking This 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.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
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.
|
|
08-10-2003, 10:15 PM
|
#1
|
Member
Registered: Aug 2003
Location: Mocksville, NC, USA
Distribution: Gentoo, Slackware.
Posts: 410
Rep:
|
sharing internet through eth0 to sl0, iptables wont work
here is my setup:
I have one windows xp machine that runs ics (connected through dialup, and has an eithernet card connected to the gentoo box) and my gentoo box is routed through it, and attached to the gentoo box over a serial cable (null modem) wtih slip (slattach) is an old laptop without a nic, i can see the internet with the gentoo box fine, but i wish to be able to have the delilinux box (old laptop) be able to access the internet as well through it's null modem connection. i have fooled around with iptables and such and tried
# iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE
but that only comes back and says
iptables: Invalid argument
i was thinking it would be the same as trying to say, have a dsl modem attached to the eth0 on a linux box, and have eth1 share internet to the rest of the network, except wtih eth0 connected to the windows machine, and sl0 connected to the delilinux, but i cant seme to make it work. the delilinux box will ping to and fro with the gentoo box fine, and gentoo box will ping to and fro with windows xp box, but i cant make delilinux ping windows, nor anything else outside the gentoo/delilinux link.
can someone give me some detailed information on how this should all be set up?
thanks
-ox
|
|
|
08-10-2003, 11:38 PM
|
#2
|
Member
Registered: Aug 2003
Location: .bh
Distribution: Gentoo
Posts: 188
Rep:
|
do you have ip forwarding enabled ?
check if /proc/sys/net/ipv4/ip_forward = 1
also, if you are using nat through static connection (eth0), i think you will need -j SNAT instead of MASQUERADE.
|
|
|
08-11-2003, 07:36 PM
|
#3
|
Member
Registered: Aug 2003
Location: Mocksville, NC, USA
Distribution: Gentoo, Slackware.
Posts: 410
Original Poster
Rep:
|
i had /proc/sys/net/ipv4/ip_forward set to 1, and i tired the -j SNAT option instead of MASQUERADE but it didn't seem to make much differance, now after messing with it for a while i have screwed something up and everytime i start iptables i cant get to anything like there is a rule blocking everything, i tired to flush it wtih -F but it did'nt seem to make much differance, and iptables -L (or iptables -t nat -L) dont show antyhing in there.
|
|
|
All times are GMT -5. The time now is 02:11 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|