Request for testing - top 3.8b1 in the base system
yanefbsd at gmail.com
Sun Sep 28 18:06:16 UTC 2008
On Sun, Sep 28, 2008 at 9:16 AM, William LeFebvre <bill at lefebvre.org> wrote:
> Edwin Groothuis wrote:
>> On Sun, Sep 28, 2008 at 02:09:00AM -0700, Garrett Cooper wrote:
>>> On Sun, Sep 28, 2008 at 1:14 AM, Alex Keda <admin at lissyara.su> wrote:
>>>> Some strange. Count running processes not match with system top
>> That has been explained in an email before.
>>> I'm not sure I'm finding an issue, but I do find it interesting that...
>>> 1. It takes a reasonably long amount of time for top to plateau the
>>> WCPU field (approximately 8-10 iterations), whereas ps registering the
>>> WCPU percentage value is almost instantaneous.
> Top 3.8 doesn't display WCPU. It is an antequated measure that is only
> maintained by the kernel so that ps can display it. It no longer has any
> meaning to the scheduler, so why bother displaying it.
>> With ps it takes 10 2 second steps to get the WCPU from 0 to 100,
>> with the new top (which doesn't have WCPU (See Changes file, and
>> the m_freebsd.c file, I don't know of the real reason behind it)
>> anymore) goes from 0 to 100 in 2 2 second steps.
> ps shows a decaying average as calculated by the kernel over the past minute
> and recorded in the proc structure. Top calculates its own average based on
> the difference in cpu time between the last measurement and the current
> measurement. The output from ps is fine when you want a single snapshot:
> you want it to show information averaged over a long period of time. Top is
> showing you only what's going on right now, since the last update. That's
> why percent CPU in top will climb to its final value so quickly.
> Bill LeFebvre
Actually, I was trying to say it was the other way around -- WCPU took
a long time in top to climb to its final value where it took a short
period of time with ps. Retrying that though, it appears that I was
flip-flopping my statement and yes it aligns with Bill's.
I still find the averaging discrepancy a bit interesting, but it's
merely a function of how the average is being taken.
More information about the freebsd-stable