# Wrong idle time in /proc/uptime, anyone ?

## aCOSwt

I suspect the idle time in /proc/uptime to be wrong.

At first it is greater than 2*uptime (on a dual core system)

```
$ cat /proc/uptime

13743.06 [35517.30]
```

And second it is far from being USER_HZ times the second entry in the /proc/uptime pseudo-file. As man proc tells.

```
$ cat /proc/stat

cpu  129971 3649 17017 [2499837] 47800 3 208 0 0 0
```

(USER_HZ=1/100th of a second for my arch)

Anyone to confirm ? Under which kernel ? dynticks dis/en-abled ?

----------

## ulenrich

 *aCOSwt wrote:*   

> (USER_HZ=1/100th of a second for my arch)
> 
> Anyone to confirm ? Under which kernel ? dynticks dis/en-abled ?

 

HZ=300, no dynticks.

```
uname -r; cat /proc/uptime

3.10.2-1103.bd3r

452.15 721.21

 maci etc # cat /proc/stat

cpu  4883 12 645 79804 11854 0 105 0 0 0

cpu0 2159 4 230 40582 5539 0 105 0 0 0

cpu1 2723 8 414 39221 6315 0 0 0 0 0

intr 523192 174812 0 0 0 0 0 0 0 1 3 0 0 0 0 0 0 0 27 3938 0 307 4794 435 4 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 24899 0 1904 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0

ctxt 386300

btime 1374773427

processes 1907

procs_running 1

procs_blocked 0

softirq 346282 0 294459 3 44 24673 0 3045 0 1 24057
```

I have just compiled linux-3.10.2+100-3rc1-patches with BFS enabled. I don't yet know what these numbers are. I have booted ca 2 minutes ago.

----------

## aCOSwt

 *ulenrich wrote:*   

> 
> 
> ```
> uname -r; cat /proc/uptime
> 
> ...

 

Thank you for helping ulenrich.

I put brackets around the figures I am interested in.

As a matter of fact, if, what  I imagine, you waited less than 70/2=35 seconds after cat /proc/uptime before issuing cat /proc/stat, then... we indeed get a problem.

----------

## ulenrich

My linux-3.10.3rc-bfs just crashed. I rebooted some minutes ago:

```
uname -r; cat /proc/uptime ; cat /proc/stat |head -n 1

3.9.11-1001.bd3r

1840.47 3135.84

cpu  20989 68 1679 313584 25977 0 533 0 0 0

```

This also is an bfs kernel, I remember special code letters in my version string:

b-Bfs, d-DeadlineInOut, 3-is300Hz, r-I forgot about what .config variation I tried some time ago ...Last edited by ulenrich on Thu Jul 25, 2013 8:44 pm; edited 1 time in total

----------

## aCOSwt

 *ulenrich wrote:*   

> My linux-3.10.3rc-bfs just crashed. I rebooted some minutes ago:
> 
> ```
> uname -r; cat /proc/uptime ; cat /proc/stat |head -n 1
> 
> ...

 

That seems much more coherent.

----------

