Date: Tue, 19 Oct 2010 11:38:48 -0400 From: Martin Turgeon <freebsd@optiksecurite.com> To: Adam Vande More <amvandemore@gmail.com> Cc: Bas Smeelen <b.smeelen@ose.nl>, freebsd-questions@freebsd.org Subject: Re: How is CPU usage calculated? Message-ID: <4CBDBB88.9030207@optiksecurite.com> In-Reply-To: <AANLkTimNJxGGak3HWRfDCHHvgBPe%2BaANS90pthbpBOQD@mail.gmail.com> References: <20101015071719.1536f19e@mail.ose.nl> <4CBC97CB.80604@optiksecurite.com> <AANLkTimT_4D4THvszdDS=U0UKtScGgKZEN4A9e8BB2%2Bf@mail.gmail.com> <4CBCA8D1.5040005@optiksecurite.com> <AANLkTimNJxGGak3HWRfDCHHvgBPe%2BaANS90pthbpBOQD@mail.gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
Le 2010-10-18 16:35, Adam Vande More a écrit : > On Mon, Oct 18, 2010 at 3:06 PM, Martin Turgeon > <freebsd@optiksecurite.com>wrote: > >> I just reread it and it isn't clearer what is using the CPU so much. Can >> you please give me a little more explanation? >> > A line in top(1) like: > > CPU: 0.0% user, 0.0% nice, 0.4% system, 0.4% interrupt, 99.3% idle > > does not describe how much CPU is being used, but rather a "percentage of > time spent in each of the processor states". It's saying of the CPU cycles > that are being used, this is what it breaks down as. Since MySQL is a > userland application, you'd expect the value of user to be quite high if > that was only thing running on your system and it was under high load. > > You can infer how much CPU is being used from the line, but there are better > and more accurate methods generally of getting that information especially > with SMP systems. > Thank you for the explanation. Would you be kind enough to point me to a method so I can know for sure that it's MySQL that is taking that much CPU ?
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4CBDBB88.9030207>