Re: load imbalance

From: Ulric Eriksson (ulric@siag.nu)
Date: Wed Nov 28 2001 - 20:23:21 CET


On Tue, 27 Nov 2001, Christopher Godaire wrote:

> I've got pen set up to balance httpd on two FreeBSD machines (A and B), with
> pen itself running on A. The problem is that after a day or so all traffic
> seems to gravitate towards one server (the actual server itself varies).
> Currently all traffic is going to B, but last time it was A. Neither machine
> has had any downtime, and connecting directly to them works just fine (as
> does pinging them).

What command line options are you using? There is no reason why there
should be any huge imbalance. The default settings are such that pen tries
to use the same server for the same client every time, to allow state to
be preserved in the server. This can lead to some short term imbalance,
but that is mainly on lightly loaded sites. A site such as siag.nu which
has connections coming in from a variety of addresses will typically get a
pretty even load, on average.

See http://siag.nu/pen/penstats.html, ignore that the "received" column
has wrapped around for server 2. Both servers have sent(*) approximately
2 GB.

If you send a USR1 signal to the pen process, it should spit out
statistics somewhere, depending on how it was started (syslog, stdout or
web page).

Ulric

(*) The "received" column lists how many bytes have been received by pen
    from each of the servers.



This archive was generated by hypermail 2.1.2 : Wed Nov 28 2001 - 20:23:47 CET