- 论坛徽章:
- 0
|
近日发现系统的CPU占用率较高,有时usr+sys能到100%,mpstat数据如下:
#mpstat 3
CPU minf mjf xcal intr ithr csw icsw migr smtx srw syscl usr sys wt idl
8 28 3 1752 370 196 688 149 118 33 0 2856 58 5 3 34
9 22 1 1193 220 116 626 121 111 28 0 2810 60 4 1 36
10 8 1 1113 461 331 822 157 147 26 0 3167 55 3 1 41
11 33 1 1067 128 2 862 146 146 29 0 2657 46 6 2 46
# sar -u 2 5
08:43:06 %usr %sys %wio %idle
08:43:08 49 8 0 44
08:43:10 71 9 0 20
08:43:12 72 12 0 15
08:43:14 40 9 2 49
08:43:16 31 1 2 65
Average 53 8 1 38
使用ps -eo pid,pcpu,args | sort +1n查看进程占用的CPU,最高的两个是应用系统的进程,均有20%左右,
请教各位,有没有办法跟踪进程,知道进程在做什么操作?使用truss命令能行吗? |
|