From owner-freebsd-questions@FreeBSD.ORG Mon May 25 07:57:27 2009 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 746EB106566C for ; Mon, 25 May 2009 07:57:27 +0000 (UTC) (envelope-from freebsd-questions@m.gmane.org) Received: from ciao.gmane.org (main.gmane.org [80.91.229.2]) by mx1.freebsd.org (Postfix) with ESMTP id F340C8FC1A for ; Mon, 25 May 2009 07:57:26 +0000 (UTC) (envelope-from freebsd-questions@m.gmane.org) Received: from list by ciao.gmane.org with local (Exim 4.43) id 1M8V3g-0008F8-OQ for freebsd-questions@freebsd.org; Mon, 25 May 2009 07:57:20 +0000 Received: from lara.cc.fer.hr ([161.53.72.113]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 25 May 2009 07:57:20 +0000 Received: from ivoras by lara.cc.fer.hr with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 25 May 2009 07:57:20 +0000 X-Injected-Via-Gmane: http://gmane.org/ To: freebsd-questions@freebsd.org From: Ivan Voras Date: Mon, 25 May 2009 09:57:08 +0200 Lines: 64 Message-ID: References: <4A18BEC8.5060506@rawbw.com> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="------------enigC82C072E671010A42972C794" X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: lara.cc.fer.hr User-Agent: Thunderbird 2.0.0.21 (X11/20090409) In-Reply-To: <4A18BEC8.5060506@rawbw.com> X-Enigmail-Version: 0.95.7 Sender: news Subject: Re: How can this 'top' command output make sense? Load over 7 and total CPU use ~5% X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 25 May 2009 07:57:27 -0000 This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enigC82C072E671010A42972C794 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Yuri wrote: > Look below: load over 7 and no processes take much CPU. >=20 > Yuri >=20 > 7.2-PRERELEASE, 32-bit on i7-920. >=20 > ------------------------------------------------------------ > last pid: 93192; load averages: 7.68, 6.27,=20 > 4.61 = =20 > up 2+03:11:29 20:25:24 > 204 processes: 9 running, 193 sleeping, 1 stopped, 1 zombie > CPU: 5.3% user, 0.0% nice, 0.0% system, 0.0% interrupt, 94.7% idle > Mem: 867M Active, 1684M Inact, 279M Wired, 65M Cache, 112M Buf, 92M Fre= e > Swap: 16G Total, 142M Used, 16G Free Couple of possible reasons: 1) You have many short lived processes that are spawned, do some work and die (some kind of web server?). You can't see them because they live too shortly. See if the "last pid" is rapidly increasing. Also, hit "H" to display individual threads. 2) You have kernel processes that are doing some intermittent work. Hit "S" to see them. In any case, see the line where it says "9 running" processes? This is where the load average comes from. The CPU utilization is not directly related to the load average. Load average is not scaled to NCPU - a count of "7" (or in your case, aymptotically 9) means there are 7 (or 9) processes wanting to run. The "global" CPU utilization (the "CPU:" line) *is* scaled to NCPU - 100% here means all CPUs are busy all the time. Individual processes' CPU utilization *isn't* scaled to NCPU. A process taking 100% CPU on its own means it only requires / runs on 1 CPU. A multithreading process can have, for example, 400% CPU utilization and the global CPU utilization can be <=3D 100%. --------------enigC82C072E671010A42972C794 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iEYEARECAAYFAkoaT1oACgkQldnAQVacBcgs6gCgr8MBCGADFuGnDPMtQv8zq4ex nxcAn3cMNIdDzZNpA9KlB47PeAxwVjWS =2ECw -----END PGP SIGNATURE----- --------------enigC82C072E671010A42972C794--