CARP Load Balance by CUP - Memory - Ethernet Usage

Nikos Vassiliadis nvass9573 at
Mon Mar 23 02:34:39 PDT 2009

Hari Emani wrote:
> Good Day every one!
> We have a situation and we are looking for a solution (the client is
> specific to implement this way):

The client must be wrong!

> We are using FreeBSD FW cluster (2 units) for our DMZ zone. We are
> using CARP for VIP and round robin load balance. The result is not
> always balance, most of the times it is 80/20. We are looking at the
> following solution: Implement a solution that provides LB based on
> the following factors:
> 1.    CPU

Hm, let's say that a host needs to send a packet to VIP, how
will it know the CPU utilization of the FWs and choose the
right one?

> 2.    Memory

Hm, same as above plus s/CPU/memory/

> 3.    Ethernet traffic utilization

That's feasible. But it's the sender, that is the switch, who knows
at what rate it sends to each FW.

The thing with IP forwarding load balancing is that it must be done
in a non-intrusive way, you don't want to add additional logic to
the existing users of the network. You don't to change the infra-

> Theoretically I can think when a packet comes to FW1, if it is busy
> (say CPU is 80%) then we need to implement a solution to send the
> packet to FW2 and vice verse. I heard that some tools exist to
> complement CARP for this purpose, but could not find at Google.

Since FW1 will have to process the packet, that is forward the
packet to FW2, why not forward it towards its destination?
How forwarding to FW2 would be more lightweight?

> I would highly appreciate any suggestions on this (or alternate
> solutions – we know we can use LB appliances, but we will have to
> many of them for several other servers too).
> I would appreciate your help or any alternate suggestions on how we
> can achieve this solution (apart from CARP).

The new CARP in OpenBSD provides an additional mechanism to
do load-balancing. This new mechanism achieves better load-
balancing with a downside. Read more here:
That's not in FreeBSD for the time being.

Also, it has nothing to do with your requirements about
memory, CPU and ethernet usage.


More information about the freebsd-questions mailing list