[vox-tech] using a modem and ethernet concurrently

Charles McLaughlin vox-tech@lists.lugod.org
Sat, 20 Dec 2003 14:30:55 -0800


Mark & Ryan, thanks for your help!

I don't have internet access via the LAN, but eth0 was set to use DHCP and
was using the gateway that the DHCP server specified.  Now I've set my
machines to use static IP address.

192.168.0.100 is the soon-to-be router that will dial-up
192.168.0.101 is my desktop machine that needs to share .100's dial-up
connection

-------

Now that I've switched to static IPs, this is before I dial up:

linux-router:/home/cmclaugh# route -n
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use
Iface
192.168.0.0     0.0.0.0         255.255.255.0   U     0      0        0 eth0

This is after I dial-up:

linux-router:/home/cmclaugh# route -n
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use
Iface
169.237.16.225  0.0.0.0         255.255.255.255 UH    0      0        0 ppp0
192.168.0.0     0.0.0.0         255.255.255.0   U     0      0        0 eth0
0.0.0.0         169.237.16.225  0.0.0.0         UG    0      0        0 ppp0

-------

Now that I've switched to static IPs, the modem and eth0 are playing nice
together (I can ping google, etc).

Next what I'd like to do is share .100's ppp connection.  I tried this:

linux-router:/home/cmclaugh# modprobe iptable_nat
linux-router:/home/cmclaugh# iptables -t nat -A POSTROUTING -o ppp0 -j
MASQUERADE
linux-router:/home/cmclaugh# echo "1" > /proc/sys/net/ipv4/ip_forward

Then I went to my desktop machine, .101, and set it to use .100 as the
gateway.  I didn't have any luck with this.. can't ping google, etc.

Any suggestions on how to share the ppp connection?

Thanks!!!!!

Charles