Load Balancing Problems

Linux Advanced Routing and Traffic Control

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

 



Hi,

I have a router that got its second link. I was trying to do load balancing, but i can not get it to work properly.

Just one link works at time, and is always the second in the command ip route add default table 222 proto static.

Am I missing something? My script is below. I am using Debian, tried with kernel 2.6.19 (my compilation) or debian's one (2.6.18-3-486), same results

Thanks


=========================================================================
ip rule add prio 50 table main
ip route del default table main

ip rule add prio $PRIO1 from $NET1 table $PRIO1
ip route add default via $IPGW1 dev $INTERFACE1 src $IP1 proto static table $PRIO1
ip route append prohibit default table $PRIO1 metric 1 proto static

ip rule add prio $PRIO2 from $NET2 table $PRIO2
ip route add default via $IPGW2 dev $INTERFACE2 src $IP2 proto static table $PRIO2
ip route append prohibit default table $PRIO2 metric 1 proto static

ip rule add prio 222 table 222
ip route add default table 222 proto static \
         nexthop via $IPGW1 dev $INTERFACE1 weight $WE1 \
         nexthop via $IPGW2 dev $INTERFACE2 weight $WE2
=================================================================


--
Alan Romaniuc

_______________________________________________
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