Visit Jeremy's Blog.
Go Back > Forums > Linux Forums > Linux - Networking
User Name
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.


  Search this Thread
Old 09-12-2007, 10:52 AM   #1
LQ Newbie
Registered: Jul 2005
Posts: 21

Rep: Reputation: 15
routing to a node with same subnet?

I'm running a Linux 2.6.18 machine with two interfaces

eth0 subnet X
eth1 subnet Y

I have a node A with address on subnet X which really isn't on that lan. However, there is a node B on eth1 that can talk to A.

On solaris I can just do a

route add A gw B

and that works. Solaris honors the route before treating A as local on eth0.

On Linux, it adds the additional route but still arps for A on eth0, and of course never gets an answer, and never goes to the route. Even if I made B proxy arp for A, it would be the wrong interface and I suspect wouldn't help.

Is there a way to force Linux to push A's packet to B?
Old 09-12-2007, 06:46 PM   #2
Registered: Jun 2007
Posts: 359

Rep: Reputation: 34
hmm.. not too clear.

A <1.2> 10.0-----router-----1.1--------B <1.3> ? like this?

yes it will work if you plugged both node A and the router in the same unmanaged hub. no need to route.

"Solaris honors the route before treating A as local on eth0."

where did you get this?


Last edited by rossonieri#1; 09-12-2007 at 06:57 PM.
Old 09-13-2007, 06:05 AM   #3
LQ Newbie
Registered: Sep 2007
Location: Iran - Zanjan
Distribution: Slackware
Posts: 5

Rep: Reputation: 0
Use device name in your route command

I have some experiance like this, and I bet Linux also honors the route before broadcast. But you have to use device name instead of gateway IP in your route command. Something like this :

# route add -host <IP-of-node-A> dev eth1
Old 09-13-2007, 07:59 AM   #4
LQ Newbie
Registered: Jul 2005
Posts: 21

Original Poster
Rep: Reputation: 15
OOPS! It turns out Linux handles the host route just like Solaris.

I had the address of "node A" incorrect, and just didn't notice.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
wrong node routing agent newbie06 Linux - Newbie 1 03-01-2007 02:59 AM
routing from one subnet to another NetAX Linux - Networking 2 06-16-2004 09:10 AM
Help with Subnet Routing xatmes Linux - Networking 6 04-27-2004 12:52 AM
routing problem with the same subnet nobody Linux - Newbie 1 10-03-2003 03:23 PM
NAT'd subnet routing question ealpert1 Linux - Networking 10 05-19-2003 03:07 PM > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 04:25 PM.

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