Operating System - HP-UX
1832857 Members
3448 Online
110047 Solutions
New Discussion

Re: I dont understand what the load is?

 
SOLVED
Go to solution
Scott Dunkley
Regular Advisor

I dont understand what the load is?

Hi All,

Just wondering what exactly the load is that is on a top or when you use uptime? I realise that with uptime it is a 1,5 and 15 minute snapshot of the load.

is the load the number of processes waiting for CPU time, if so what is an acceptable limit, abou 2 or 3?

So the real question is can someone please explain to me exactly what the load is all about please?
Better to regret something you have done, than something you havn't
6 REPLIES 6
Elena Leontieva
Esteemed Contributor
Solution

Re: I dont understand what the load is?

Scott,
From the man page:
uptime prints the current time, the length of time the system has been
up, the number of users logged on to the system, and the average
number of jobs in the run queue over the last 1, 5, and 15 minutes for
the active processors.
See also this thread:
http://forums.itrc.hp.com/cm/QuestionAnswer/1,,0x9f7637f45ef7d4118fef0090279cd0f9,00.html
Elena.
Brian Bergstrand
Honored Contributor

Re: I dont understand what the load is?

The load as given by uptime/top is an average of the number of processes waiting in the run queue. Processes in the run queue are those that have been marked runable by the scheduler.

HTH.
Kent Ostby
Honored Contributor

Re: I dont understand what the load is?

What is an "acceptable limit" is really based on you and your users perceptions of the system.

I have a system here that is "busy" when it hits about 6. But then again, its a single CPU system.

When troubleshooting medium sized systems I get concerned when its over 20 or so.

A good way to approach this is to run uptime at various times when the system is "normal" so you can get a feel for what that level is and then compare from there.

Best regards,

Kent M. Ostby
"Well, actually, she is a rocket scientist" -- Steve Martin in "Roxanne"
Scott Dunkley
Regular Advisor

Re: I dont understand what the load is?

The system in question is running 3 440Mhz CPU's and is an OLTP with an Oracle back end. when the load gets to about 4 thats when the users start complaining so I guess I just answered my own question, anything around 3 or under is ok in my situation.

If the load consistently creeps above 4 then would this be a sign of the system being CPU bound? The CPU Idle is normally about 20% when the load goes over 3.5-4
Better to regret something you have done, than something you havn't
Chris Wilshaw
Honored Contributor

Re: I dont understand what the load is?

It's possible that at that point you are starting to get processes that are CPU bound, but it's worth checking on the other factors too.

Firstly, memory/swap space.

Use swapinfo -tam to get figures for the % of memory and swap space used.

eg:

Mb Mb Mb PCT START/ Mb
TYPE AVAIL USED FREE USED LIMIT RESERVE PRI NAME
dev 4096 0 2048 0% 0 - 1 /dev/vg00/lvol2
reserve - 1290 -1290
memory 3208 795 2413 25%
total 7304 2085 3171 29% - 0 -

If the dev swap (on disk) has a % used value, and , % memory is high, you should look at what's using the memory.

This can be achieved using

UNIX95= ps -opid,vsz,args | sort -rnk2 | more

This lists the pid, memory size (in KB) of the process, and the process name with arguments, sorted with the highest memory use first. It may be that you have poor coding in your application causing memory leaks, in which case, the highest figures will rise constantly (up to the limit defined by the maxdsiz parameter in the kernel).

If memory is diagnosed as the cause of the performance issue, it's probably easier and cheaper to buy some more, rather than getting your applications tuned (I know that this isn't the "best" way to fix the problem, but it gets you out of your immediate situation, and helps to keep your users happy).


Disk performance should also be considered.

When you have a report of performance problems, run

sar -d 1 5

This will give

16:56:23 device %busy avque r+w/s blks/s avwait avserv
16:56:24 c1t2d0 1.01 0.50 3 12 3.18 5.94
c2t2d0 1.01 0.50 2 8 2.76 4.32
16:56:25
16:56:26
16:56:27
16:56:28 c1t2d0 1.00 0.50 1 6 3.98 7.78
c2t2d0 1.00 0.50 1 6 4.02 6.89
c4t0d5 2.00 0.50 4 64 3.77 6.16

Average c1t2d0 0.40 0.50 1 4 3.38 6.40
Average c2t2d0 0.40 0.50 1 3 3.18 5.18
Average c4t0d5 0.40 0.50 1 13 3.77 6.16

As you can see, the disks on this system have an average %busy rating of 0.40, which is obviously not a problem. If you regularly find that one of your disks is busier than the others, you need to look at what filesystems are on that disk (pvdisplay -v /dev/dsk/) where DISK is the device that is giving the problems. It may be that by moving filesystems onto other disks in the system, you can reduce (or even eliminate) the problems.

Hope that's of use to you.

Chris.
Bernhard Mueller
Honored Contributor

Re: I dont understand what the load is?

Scott,

I never worry about the load, instead I use
vmstat 1 1000
sar 1 1000

if im vmstat the po (page out) remains at zero and there is always free memory
AND in sar %wio is low and %idle is low then you are CPU bound.

Glance is even better for performance monitoring, might consider installing the trial version.

Regards,
Bernhard