Bug 14131
Summary: | Idle-time in /proc/uptime wrong | ||
---|---|---|---|
Product: | Timers | Reporter: | Johan van Baarlen (JF) |
Component: | Other | Assignee: | john stultz (john.stultz) |
Status: | CLOSED OBSOLETE | ||
Severity: | low | CC: | alan |
Priority: | P1 | ||
Hardware: | All | ||
OS: | Linux | ||
Kernel Version: | 2.6.30.5 | Subsystem: | |
Regression: | No | Bisected commit-id: | |
Attachments: | test patch to make /proc/uptime and /proc/stat use same idle calculation |
Description
Johan van Baarlen
2009-09-06 12:19:29 UTC
I'm not seeing this on a 2.6.31 kernel. Are you still seeing this with any more recent kernels? Sorry john for the long delay in following up - I did not exactly rank this as high-priority and never noticed you posted a response. Latest kernel I have running is a 2.6.31, and this oddity is definitely showing there. [root@backup2 ~]# cat /proc/uptime; cat /proc/stat | grep cpu 2592026.88 2569.52 cpu 11818453 10108 22715895 959211273 40687278 976152 1473425 0 0 cpu0 3146061 1410 4115859 250600571 340377 381680 637221 0 0 cpu1 1126544 3014 3020324 251840161 3042936 69833 120339 0 0 cpu2 1385205 1235 2265371 254987993 555561 8976 18794 0 0 cpu3 6160643 4449 13314341 201782548 36748404 515663 697071 0 0 allcpuidle / numcores / kernelfreq = 959211273 / 4 / 100 = 2398028, this box only sees activity twice a day so about 90% idle CPU sounds perfect. Johan: My apologies for such a long delay between updates. Just trying to run over the bug backlog. I'm still unable to reproduce this on three different x86_64 machines. That said, looking at the code, I can see that proc/stat and proc/uptime use different methods to calculate idle. Created attachment 72181 [details]
test patch to make /proc/uptime and /proc/stat use same idle calculation
Give this a whirl and let me know if it seems to resolve the issue.
|