traceroute misbehaviour on dual-home using -i or -s

Linux Advanced Routing and Traffic Control

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



My Linux workstation (Mandrake 10.1 kernel 2.6.8.1) is dual-homed to two
ADSL Internet providers.  Card eth0 (192.168.9.250) is the default route
and leads to an SMC router (192.168.9.254).  Card eth1 (192.168.1.250)
leads to a Linksys router (192.168.1.1).  I'm not doing any NAT or PPPoE
in the workstation - the SMC and Linksys handle it all.

I know four commands that let you set an IP source address.  Of the four,
only traceroute misbehaves with this configuration:

   # nc -s 192.168.1.250 foo.bar           # works out eth1
   # mtr -a 192.168.1.250 foo.bar          # works out eth1
   # ping -I eth1 foo.bar                  # works out eth1
   # traceroute -i eth1 foo.bar            # misbehaves out eth0
   # traceroute -s 192.168.1.250 foo.bar   # misbehaves out eth0

I can see using tcpdump that traceroute -i or -s correctly sets the eth1
source address, but traceroute persists in sending out the packets on the
default interface eth0, not on eth1 that I asked for.

When I do something like "traceroute -i eth1 foo.bar" I see nothing
on eth1.  On eth0 (the default route goes via eth0) tcpdump shows me
packets with the eth1 source address heading out to foo.bar.  (They don't
come back!)  I expected that the eth1 source packets would leave on eth1,
not on eth0.

Is this my own LARTC misconfiguration, or a traceroute issue?  Given that
traceroute is the only one misbehaving, I'm inclined to think it isn't
my fault.  I'm trying to locate the current maintainer of traceroute
and see what the story is.

Detailed config follows:

----- IP Rules ----------------------------------
0:	from all lookup local 
10:	from 192.168.9.0/24 lookup 1 
20:	from 192.168.1.0/24 lookup 2 
32766:	from all lookup main 
32767:	from all lookup default 
 
----- Table local ----------------------------------
broadcast 192.168.1.0 dev eth1  proto kernel  scope link  src 192.168.1.250 
broadcast 127.255.255.255 dev lo  proto kernel  scope link  src 127.0.0.1 
broadcast 192.168.9.0 dev eth0  proto kernel  scope link  src 192.168.9.250 
broadcast 192.168.1.255 dev eth1  proto kernel  scope link  src 192.168.1.250 
broadcast 192.168.9.255 dev eth0  proto kernel  scope link  src 192.168.9.250 
local 192.168.1.250 dev eth1  proto kernel  scope host  src 192.168.1.250 
broadcast 127.0.0.0 dev lo  proto kernel  scope link  src 127.0.0.1 
local 192.168.9.250 dev eth0  proto kernel  scope host  src 192.168.9.250 
local 127.0.0.1 dev lo  proto kernel  scope host  src 127.0.0.1 
local 127.0.0.0/8 dev lo  proto kernel  scope host  src 127.0.0.1 
 
----- Table 1 ----------------------------------
default via 192.168.9.254 dev eth0  proto static  src 192.168.9.250 
 
----- Table 2 ----------------------------------
default via 192.168.1.1 dev eth1  proto static  src 192.168.1.250 
 
----- Table main ----------------------------------
192.168.1.0/24 dev eth1  proto kernel  scope link  src 192.168.1.250 
192.168.9.0/24 dev eth0  proto kernel  scope link  src 192.168.9.250 
127.0.0.0/8 dev lo  scope link 
 
----- Table default ----------------------------------
default via 192.168.9.254 dev eth0  proto static  src 192.168.9.250  metric 1 
default via 192.168.1.1 dev eth1  proto static  src 192.168.1.250  metric 2 

-- 
-IAN!  Ian! D. Allen   Ottawa, Ontario, Canada
       EMail: idallen@xxxxxxxxxx   WWW: http://www.idallen.com/
       College professor (Linux) via: http://teaching.idallen.com/
       Support free and open public digital rights:  http://eff.org/
_______________________________________________
LARTC mailing list / LARTC@xxxxxxxxxxxxxxx
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/

[Index of Archives]     [LARTC Home Page]     [Netfilter]     [Netfilter Development]     [Network Development]     [Bugtraq]     [GCC Help]     [Yosemite News]     [Linux Kernel]     [Fedora Users]
  Powered by Linux