Thanks for your advices.

Currently my test scripts will make both WAN connections break, when I
unplug one WAN connection.
So I can not implement the fail-over mechanism.
My original idea is to mark all packets as 1 when connection WAN2 breaks
or mark all packets as 2 when connection WAN1 breaks.
But now one connection breaks will make both connections break.
I could not identify which connection breaks? It is weird. ><"




------------------------------------------------------------------------------------------------------

Grant Taylor wrote:

Could you give me a suggestion?
Thanks.

Do not use this method to load balance.  Look in to Equal Cost Multi
Path (a.k.a. ECMP) routing and specifying multiple default gateways on
one route command.  The kernel should try to load balance across the
multiple default gateways for you while maintaining connections.


This is a bad bad advice in this day and age. If there are not enough
users route caching will kill him. Here is a recent discussion of this:
http://marc.info/?l=lartc&m=117912699505681&w=2

HTH

Peter

P.S. I am not insisting that netfilter is superior in this regard, I am
simply expressing common requirements and looking into ways of achieving
them. If someone can point me to how to do this with kernel routes - I
am all ears, since I recognize that the netfilter solution is not very
elegant, although it works.
_______________________________________________
LARTC mailing list
LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/cgi-bin/mailman/listinfo/lartc

Reply via email to