top command first iteration always returns the same result

后端 未结 5 852
故里飘歌
故里飘歌 2021-01-12 16:12

When running top -b -n 1, the command always returns the same CPU values. Consider the following test run 5 times in succession:

[user@server ~]$ top -b -n          


        
5条回答
  •  孤城傲影
    2021-01-12 16:21

    CPU utilisation figures are calculated as an average over a time interval. For the first iteration, that time interval is "from system boot until now"; for subsequent iterations, the time interval is "from the last iteration until now".

提交回复
热议问题