Re: Load Balancer Trouble, are "Routes with Memory" Possible?

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

 



On 05/24/2006 01:56 PM, desert@xxxxxxxxxxxxxxxx wrote:
> What i need is this.
> 
> 1) A connection comes from LAN trying to access an IP in WAN
> 2) Round robin (or whatever) to select any WAN pipe.
> 3) Remember that route for many minutes
>    or until client closes it.
> 
> I dont care if other LAN clients follow the same route or if they
> select a different route.
> 
> The real trick is to mantain the route for as long as the client needs
> it.

Use CONNMARK.  Save the mark for packets with a NEW state in the
POSTROUTING chain based on which interfaces was selected by the
round robin.  Restore the mark for packets ESTABLISHED or RELATED
states in the PREROUTING and OUTPUT chains, and use the mark to
route it out the corresponding interface.

I posted some rules a couple of months ago, search the archives.


[Index of Archives]     [Linux Netfilter Development]     [Linux Kernel Networking Development]     [Netem]     [Berkeley Packet Filter]     [Linux Kernel Development]     [Advanced Routing & Traffice Control]     [Bugtraq]

  Powered by Linux