top的id(空闲CPU)为什么在系统空闲时不是200%?(我双核)
发表于 : 2016-03-16 22:55
top的id(空闲CPU)为什么在系统空闲时不是200%?(我双核)
<I> :Irix/Solaris_Mode_toggle
When operating in 'Solaris mode' ('I' toggled Off), a
task's cpu usage will be divided by the total number of
CPUs.
......
if 'Irix mode' is Off, top will operate in
'Solaris mode' where a task's cpu usage will be divided by the
total number of CPUs. You toggle 'Irix/Solaris' modes with the
'I' interactive command
您是用什么关键词进行搜索的呢?英语渣都不知道输入什么关键词去搜,希望分享下搜索词来提示一下vickycq 写了:貌似只有进程 CPU 占用才会按 “一个核心为 100,两个核心为 200” 规则计算
(但根据某些搜索结果,其它人的并不是这样?)
top 的进程 CPU 占用计算模式,按 Shift + i 切换
1. IRIX Mode (默认)
2. Solaris Mode
<I> :Irix/Solaris_Mode_toggle
When operating in 'Solaris mode' ('I' toggled Off), a
task's cpu usage will be divided by the total number of
CPUs.
......
if 'Irix mode' is Off, top will operate in
'Solaris mode' where a task's cpu usage will be divided by the
total number of CPUs. You toggle 'Irix/Solaris' modes with the
'I' interactive command
代码: 全选
$ top -v
procps-ng version 3.3.9
Usage:
top -hv | -bcHiOSs -d secs -n max -u|U user -p pid(s) -o field -w [cols]
我用的关键词为 'top cpu usage over 100'科学之子 写了: 您是用什么关键词进行搜索的呢?英语渣都不知道输入什么关键词去搜,希望分享下搜索词来提示一下
irix mode 影响的是 每个进程的占用率统计,不是上面 2.7 us, 2.5 sy, 0.0 ni, 93.6 id 这一行总占用率科学之子 写了:不论Irix mode状态如何 就算我打开两个死循环程序,CPU还是接近100,并非接近200%
man top 写了:1. %CPU -- CPU Usage
The task's share of the elapsed CPU time since the last screen update, expressed as a percentage of total CPU time.
In a true SMP environment, if a process is multi-threaded and top is not operating in Threads mode, amounts greater than 100% may be reported. You toggle Threads mode with the
`H' interactive command.
Also for multi-processor environments, if Irix mode is Off, top will operate in Solaris mode where a task's cpu usage will be divided by the total number of CPUs. You toggle
Irix/Solaris modes with the `I' interactive command.