[ale] questions about load averages
Jason Boyles
jason at alltel.net
Tue Nov 18 10:53:41 EST 1997
On Mon, 17 Nov 1997, Geoffrey Myers wrote:
> The man page for top say that the load average numbers are: "the average
> number of processes ready to run during the last 1, 5 and 15 minutes."
> Question is, does this mean they are sitting in the run queue? I'm
> trying to understand what these numbers mean. What's high?
They represent the average number of processes over these time
periods which are candidates for dispatching. IOW, processes that are
potentially runnable. This number is sampled at each clock tick, which
occurs every 10ms. On a single CPU machine a load average of one means
that the CPU is saturated. In general, a single CPU can handle only one
execution context at a time. In this case the OS can give it exactly as
much work as it can do, which is 1 process. Load averages higher than one
(again, on a single CPU system) indicate that, on average, there are more
processes that want the CPU than we can run at each clock interrupt,
therefore potentially runnable processes are sometimes not being run.
Whether a particular load average of one or higher is bad is a
matter for debate. On my slower Linux machines, I can definitely feel a
load average higher than 2. On some big RS/6000s (non-SMP) at work larger
load averages don't seem to impact the system as much. Whether >1 is bad
can also depend on your application. If latency is critical, then higher
load averages are less tolerable.
Some folks look at a load average of 1 (or 1*N, where N is the
number of CPUs) as "perfect." It means you are using exactly as much of a
resource (the CPU) as available, so you didn't buy too big of a machine
for your needs. OTOH, if one stupid process is spinning on a file
descriptor or in a busy loop it can drive your load to 1.
I'm sure other members of the list can offer corrections and/or
clarifications to my little spiel here.
-----
Jason Boyles <jason at alltel.net>
"Those who consider arithmetical means of generating random numbers are,
of course, in a state of sin." --J.V.N.
More information about the Ale
mailing list