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

Re: Dual Interface Routing Question



Dnia 29-12-2006, pią o godzinie 17:47 +0530, Ritesh Raj Sarraf
napisał(a):

> geeKISSexy:~# route -n
> Kernel IP routing table
> Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
> 202.3.112.38    10.73.16.1      255.255.255.255 UGH   0      0        0 eth1
> 10.73.16.0      0.0.0.0         255.255.252.0   U     0      0        0 eth1
> 10.73.36.0      0.0.0.0         255.255.252.0   U     0      0        0 eth2
> 172.16.0.0      0.0.0.0         255.255.0.0     U     0      0        0 tap0
> 0.0.0.0         10.73.16.1      0.0.0.0         UG    0      0        0 eth1
> 
> 
> So currently, still everything is being routed through eth1. Surprisingly (or
> maybe not) all is being routed through VPN which was fired in the post-up of
> eth2
> 
> What I'm looking for is to know, what changes do I need to make into this
> routing table so that:
> a) All 10.x.x.x related traffic passes through eth1
> b) As for the rest (and default route) passes through eth2
Try to delete current default route, then (I assume that your eth2
gateway is 10.73.36.1)
route add default gw 10.73.36.1
route add -net 10.0.0.0 netmask 255.0.0.0 dev eth1 
or if you want to route traffic to 10.x through gateway
route add -net 10.0.0.0 netmask 255.0.0.0 gw 10.73.16.1


-- 
Jakub Ambrozewicz





Reply to: