lkml.org 
[lkml]   [1996]   [Aug]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
Subject/proc/stat idle count goes backwards in SMP
From
When running 2.0.13 SMP, I notice that vmstat's output is ridiculuous
for usr/sys/idl when we're effectively using more than one cpu. I've
traced this to the idle jiffy count in the first line of /proc/stat.
When heavily loaded, the idle count will go *down*. I didn't think that
was possible. The usr/sys counts always go up.

Further, the man page for proc says that the idle count should always be
100 times the second value in /proc/uptime. With SMP, the second value
is always zero for me. With UP, everything is correct.

What's going on?

Here is a snapshot of the first line of /proc/stat taken every second
while I was utilizing both cpus:

cpu 67578 1 779364 6400895
cpu 67605 1 779461 6400881
cpu 67644 1 779552 6400873
cpu 67715 1 779597 6400876
cpu 67746 1 779687 6400864
cpu 67776 1 779773 6400858
cpu 67798 1 779866 6400852

Note that this seems to happen when user+nice+sys > 100%.

Here is a snippet when the system was more or less idle:

cpu 74145 1 795433 6420079
cpu 74145 1 795434 6420189
cpu 74145 1 795435 6420295
cpu 74148 1 795443 6420393

Here is my /proc/uptime:

73129.29 0.00

Lee Hetherington
ilh@lcs.mit.edu


\
 
 \ /
  Last update: 2005-03-22 13:37    [W:0.028 / U:0.084 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site