Re: 2 ISP connection sharing problem

Linux Advanced Routing and Traffic Control

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

 



On Sun, Sep 02, 2007 at 03:25:11PM +0500, Arman wrote:
> Thats fine but primary problem is that only one connection is used at a time
> but I want to utilize both at the same time. Please guide
> 
> 
> ---------- Forwarded message ----------
> From: "Jorge Evangelista" <netsecuredata@xxxxxxxxx>
> To: lartc@xxxxxxxxxxxxxxx
> Date: Sat, 1 Sep 2007 18:33:35 -0500
> Subject: Re:  2 ISP connection sharing problem
> Hi,
> 
> You should change your last rule for some as it:
> 
> ip route add  equalize default  nexthop via 192.168.1.1 dev eth0
> nexthop via 201.81.219.1  dev eth2
> 
> It works fine for load balancing, but when a failure occurrs on one
> line, whats happen? if one line is down the change it is too slow, and
> the cache for the route is still there and when I want this Host again
> the old route is through from the "down" line.
> 
> I have a script which runs via ping and cron when next hop is down,
> the box linux will change to use one line.

i have something similiar, but my problem is conntrack/natting. once a stream 
is up and running, conntrack remembers with external ip and tries to route out 
that one untill the connection is closed - which it will not be until it gets 
an rst/finish.  This can take a while to settle down - wait for all the timers 
to run out...

> 
> 
> 
> 
> 
> 
> On 9/1/07, Arman <arman.anwar@xxxxxxxxx> wrote:
> > Hi all,
> >
> >         I have a similar question like  many asked before I know but
> Please
> > help as i cant figure out where the problem is and how should I tackle.
> >
> > I have 2 ISP connections. I want to share the bandwidth from both. I have
> > copied the script from many places and created my own after changes.
> Problem
> > is that only one connection is utilized at a time. Not both working. ratio
> > of consuming bandwisth between then is around 1:30.
> >
> > both connections are from dhcp that is dynamic. configuration from 1 ISP
> > remains same and from 1 changes.
> >
> > EXTERNAL_IP_2="201.81.219.95"
> > EXTERNAL_NETWORK_2=" 201.81.219.0"
> > EXTERNAL_GATEWAY_IP_2="201.81.219.1"
> >
> > echo 200 T1 >> /etc/iproute2/rt_tables
> > echo 201 T2 >> /etc/iproute2/rt_tables
> >
> >   ip route add 192.168.1.0 dev eth1 src 192.168.1.2 table T1
> >   ip route add default via 192.168.1.1 table T1
> >   ip route add $EXTERNAL_NETWORK_2 dev eth2 src $EXTERNAL_IP_2 table T2
> >   ip route add default via $EXTERNAL_GATEWAY_IP_2 table T2
> >
> >   ip route add 192.168.3.0      dev eth0        table T1
> >   ip route add 192.168.1.0      dev eth1        table T1
> >   ip route add 127.0.0.0/8 dev lo   table T1
> >   ip route add 192.168.3.0      dev eth0        table T2
> >   ip route add $EXTERNAL_NETWORK_2      dev eth2        table T2
> >   ip route add 127.0.0.0/8 dev lo   table T2
> >
> >   ip route add 192.168.1.0 dev eth1  src 192.168.1.2
> >   ip route add $EXTERNAL_NETWORK_2 dev eth2  src $EXTERNAL_IP_2
> >
> >   ip route add default via $EXTERNAL_GATEWAY_IP_2
> >
> >   ip rule add from 192.168.1.2 table T1
> >   ip rule add from $EXTERNAL_IP_2 table T2
> >
> >  ip route add default scope global nexthop via 192.168.1.1 dev eth1 weight
> 1
> > nexthop via $EXTERNAL_GATEWAY_IP_2 dev eth2 weight 2
> >
> >
> > route command output is
> >
> > Destination     Gateway           Genmask           Flags   Metric  Ref
> > Use  Iface
> > 192.168.1.0     *                      255.255.255.255  UH      0
> 0
> >       0    eth1
> > 192.168.3.0     *                      255.255.255.0      U        0
> > 0        0    eth0
> > 192.168.1.0     *                      255.255.255.0      U        0
> > 0        0    eth1
> > 201.81.219.0    *                     255.255.255.0      U        0
> > 0        0     eth2
> > default         201.81.219.1         0.0.0.0               UG      0
> > 0        0      eth2
> >
> > Problem is that the interface which is set gateway is used only. The other
> > one remains idle.
> >
> > --
> > Regards,
> > Arman
> >

> _______________________________________________
> LARTC mailing list
> LARTC@xxxxxxxxxxxxxxx
> http://mailman.ds9a.nl/cgi-bin/mailman/listinfo/lartc

Attachment: signature.asc
Description: Digital signature

_______________________________________________
LARTC mailing list
LARTC@xxxxxxxxxxxxxxx
http://mailman.ds9a.nl/cgi-bin/mailman/listinfo/lartc

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