PDA

View Full Version : share internet for incoming modem connection


chronox
2004-09-25, 05:33 AM CDT
i have successfully networked my computers under a router acting as a gateway for the internet. now I have a linux fedora core 2 server which accepts incoming modem connections. It connects and I was able to ping the server but sadly i cant provide internet connection to the incoming modem client.

Server local ip: 192.168.7.7
router ip: 192.168.7.1
gateway (dsl via router): 192.168.7.1
client modem ip: 192.168.7.10

http://www.swcp.com/~jgentry/pers.html <--- followed this guide.

i just want to forward all activity of the client to the router.

how my network looks like:
incoming modem >> linux server >> router >> dsl modem >> internet

devices used:

ttyS0, eth0

firewall is off

blammo
2004-09-25, 07:35 AM CDT
Check into iptables. If the client connects and gets an IP on your network, it's just a matter of forwarding and NAT for it to find the gateway.

chronox
2004-09-26, 10:10 AM CDT
my client gets the ip 192.168.7.10 aqnd is able to ping the server but it doesnt have any access to the internet.

how do i do the forwarding and NAT?

but i believe i've done the forwarding part... but im not sure with the NAT part...

chronox
2004-09-27, 10:29 AM CDT
this is the output of my "route"

Destination Gateway Genmask Flags Metric Ref Use Iface
192.168.7.10 * 255.255.255.255 UH 0 0 0 ppp0
192.168.7.0 * 255.255.255.0 U 0 0 0 eth0
169.254.0.0 * 255.255.0.0 U 0 0 0 eth0
default 192.168.7.1 0.0.0.0 UG 0 0 0 eth0


with that i am able to contact the router itself and ping ALL lan networks...

ppp0 = the client dialing up on the server