LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 10-20-2003, 10:15 AM   #1
jogress
LQ Newbie
 
Registered: Sep 2003
Posts: 8

Rep: Reputation: 0
Route dialup modem packets back through dialup instead of default route cable modem


Hi,

I have a linux 2.4.22 box running pppd 2.4.1. On it, I have 2 ethernet cards and one external serial dialup modem.

eth0 is my default gateway and it does dhcp to my cable provider

eth1 is my lan

ppp0 is my dialup

(this is redhat 9)

$ more /etc/sysconfig/network
NETWORKING=yes
HOSTNAME=go.XXXXXX.com (paranoid)
GATEWAYDEV=eth0

$ more /etc/sysconfig/network-scripts/ifcfg-eth0
DEVICE=eth0
BOOTPROTO=dhcp
ONBOOT=yes

$ more /etc/sysconfig/network-scripts/ifcfg-eth1
DEVICE=eth1
BOOTPROTO=static
BROADCAST=10.0.1.255
IPADDR=10.0.1.1
NETMASK=255.255.255.0
NETWORK=10.0.1.0
ONBOOT=yes

*curses* darn i left my modem off at home, and i'm an hour away. I was going to connect and paste the route table. Anyways, maybe I dont need it.

Basically, when the modem connects, I cant get anything to talk to it. It sits there happy at layer 2, but layer 3 is broken... no routing. I can set host and net routes manually, though. I know everything is happy up to layer 3. In fact I can down my eth0 and use ppp0 for inet access if need be. (but that of course makes sense because it gets me down to one network interface other than my non routing lan node)

What I want is, if a packet comes in on the dialup modem's IP address, I want it to go back out the interface it came in on (ppp0 in this case). What I believe is happening is that the packets are dropping out my default route, creating an asymmetrical route that is getting all confused. Now, I believe it should work anyways, but thats another issue altogether. I just want them to go back out the interface from whence it came. (heh.. I said 'whence')

I havent bothered learning how a packet sniffer works yet, but that might be my next attempt, if I get into it enough. It's just a backup link, but I'd prefer to just leave it connected for no reason other than giving phone spammers a constant busy.

I do have a packet filter (iptables) running, but I've tried flushing it to no avail. If anyone thinks I should paste a copy of this in anyways, just say the word. It's not psycho but it's verbose and I dont want to drown my post.
 
Old 10-21-2003, 03:48 PM   #2
peter_robb
Senior Member
 
Registered: Feb 2002
Location: Szczecin, Poland
Distribution: Gentoo, Debian
Posts: 2,458

Rep: Reputation: 48
What you've described is nearly word for word in the http://tldp.org/HOWTO/Adv-Routing-HOWTO/

Have a look at Chapter 4. It describes using iproute2 to manage multiple internet providers.

Once you have it running I can copy you some script changes to make it operate with ifup/ifdown.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Dialup Modem rinku Linux - Newbie 2 03-11-2005 04:10 PM
Route to subnet exists but I get "Network unreachable" when adding default route fciuffani Linux - Networking 4 08-18-2004 02:11 PM
Route packets between cable modem and another router k1mgy Linux - Networking 0 08-01-2004 07:22 PM
need to setup router to share and route dialup connection Insurr3cti0n Linux - Networking 2 11-18-2003 12:32 AM
configuring my modem for dialup teenole Linux - Newbie 8 05-19-2003 07:04 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 08:55 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration