免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
12下一页
最近访问板块 发新帖
查看: 4307 | 回复: 11
打印 上一主题 下一主题

今天发现系统中oninit进程占用资源特别高,请问怎么分析是否正常?(新手问题) [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2006-05-24 09:33 |只看该作者 |倒序浏览
系统中有8个CPU,16G内存,CPU利用率一度达到100%,而且一直稳在80%以上;不知道是否正常;改用哪些命令进行分析查看呢??

论坛徽章:
0
2 [报告]
发表于 2006-05-24 10:06 |只看该作者
用top或者之类的工具看看是不是oninit进程消耗了大部分的系统资源,如果是,需要看看数据库方面,主要是SQL方面有没有什么可优化的空间.....

论坛徽章:
0
3 [报告]
发表于 2006-05-24 10:21 |只看该作者
确实时ONINIT占完呢cpu,现在应该是数据库哪里出问题了,但不知道这么分析,请指教!!

论坛徽章:
0
4 [报告]
发表于 2006-05-24 10:35 |只看该作者
各位大侠给点提示啊!!!!

论坛徽章:
0
5 [报告]
发表于 2006-05-24 10:43 |只看该作者
1)        使用操作系统命令(例如topas)查看最繁忙的oninit进程,记录它的pid
2)        用onstat -g glo查看vp class,看相应进程里运行的是那个vp(用pid去匹配)。确定瓶颈是在那一类vp上(比如是在cpu vp上还是在aio vp上)。记录vp,class。
3)        用onstat -g act(或onstat -g ath)查看相应vp里运行的是那个线程(用vp class去匹配),记录它的tid,rstcb。
4)        用onstat -g ses ses_id检查session信息(用tid,rstcb去匹配)

论坛徽章:
0
6 [报告]
发表于 2006-05-24 10:55 |只看该作者
top: cannot open /dev/kmem
kvm_open: Permission denied

load averages:  5.40,  5.79,  5.88                                                                                         10:47:23
91 processes:  84 sleeping, 7 on cpu
CPU states: 15.9% idle, 82.7% user,  1.4% kernel,  0.0% iowait,  0.0% swap
Memory: 16G real, 8856M free, 12G swap free

  PID USERNAME THR PRI NICE  SIZE   RES STATE   TIME    CPU COMMAND
3146 informix   2  30    0    0K    0K cpu6   53.5H  9.79% oninit
3140 informix   2  30    0    0K    0K cpu5   51.4H  9.70% oninit
3150 informix   2  30    0    0K    0K cpu3   25.3H  9.64% oninit
3147 informix   2  50    0    0K    0K sleep  48.7H  9.34% oninit
3149 informix   2  30    0    0K    0K cpu7   32.8H  8.96% oninit
3148 informix   2  30    0    0K    0K cpu4   40.7H  8.89% oninit
3151 informix   2  50    0    0K    0K sleep  19.4H  8.65% oninit
3152 informix   2  30    0    0K    0K cpu2  927:18  6.37% oninit
3172 informix   1  58    0    0K    0K sleep  82:19  0.35% oninit
12037 informix   1  58    0 1872K 1224K cpu0    0:00  0.00% top
  307 root      13  20    0 7632K 6680K sleep   4:47  0.00% picld
3156 informix   1  58    0    0K    0K sleep   0:28  0.00% oninit
  481 root      12   0    0 3136K 2416K sleep   0:16  0.00% nscd
  684 root      12  52    0 2656K 1904K sleep   0:13  0.00% mibiisa
  673 root       4  58    0 5192K 2208K sleep   0:08  0.00% dtlogin

论坛徽章:
0
7 [报告]
发表于 2006-05-24 10:55 |只看该作者
onstat -g glo

IBM Informix Dynamic Server Version 9.40.FC2W2   -- On-Line -- Up 6 days 09:34:57 -- 8872960 Kbytes

MT global info:
sessions threads  vps      lngspins
82       142      29       95      

          sched calls     thread switches yield 0   yield n   yield forever
total:    2666955785      1350631184      1336130430 1808203   122403628
per sec:  0               0               0         0         0        

Virtual processor summary:
class       vps       usercpu   syscpu    total   
cpu         8         1025742.40  10707.65  1036450.05
aio         16        0.00      0.05      0.05   
tli         1         1443.91   3503.68   4947.59
lio         1         0.00      0.01      0.01   
pio         1         0.00      0.01      0.01   
adm         1         0.00      0.08      0.08   
msc         1         16.12     12.90     29.02   
total       29        1027202.43  14224.38  1041426.81

Individual virtual processors:
vp    pid       class       usercpu   syscpu    total   
1     3140      cpu         183680.18  1793.59   185473.77
2     3145      adm         0.00      0.08      0.08   
3     3146      cpu         190938.40  1950.00   192888.40
4     3147      cpu         173919.32  1816.00   175735.32
5     3148      cpu         145430.59  1487.88   146918.47
6     3149      cpu         117104.67  1229.09   118333.76
7     3150      cpu         90253.64  978.46    91232.10
8     3151      cpu         69259.53  794.76    70054.29
9     3152      cpu         55156.07  657.87    55813.94
10    3153      lio         0.00      0.01      0.01   
11    3154      pio         0.00      0.01      0.01   
12    3155      aio         0.00      0.01      0.01   
13    3156      msc         16.12     12.90     29.02   
14    3157      aio         0.00      0.01      0.01   
15    3158      aio         0.00      0.00      0.00   
16    3159      aio         0.00      0.00      0.00   
17    3160      aio         0.00      0.00      0.00   
18    3161      aio         0.00      0.01      0.01   
19    3162      aio         0.00      0.00      0.00   
20    3163      aio         0.00      0.00      0.00   
21    3164      aio         0.00      0.00      0.00   
22    3165      aio         0.00      0.00      0.00   
23    3166      aio         0.00      0.00      0.00   
25    3167      aio         0.00      0.00      0.00   
26    3168      aio         0.00      0.01      0.01   
27    3169      aio         0.00      0.01      0.01   
24    3170      aio         0.00      0.00      0.00   
28    3171      aio         0.00      0.00      0.00   
29    3172      tli         1443.91   3503.68   4947.59
                 tot         1027202.43  14224.38  1041426.81

论坛徽章:
0
8 [报告]
发表于 2006-05-24 10:56 |只看该作者
onstat -g act

IBM Informix Dynamic Server Version 9.40.FC2W2   -- On-Line -- Up 6 days 09:36:30 -- 8872960 Kbytes

Running threads:
tid     tcb             rstcb            prty status                vp-class      name
23      29040db60        0                2    running                29tli        tlitcppoll
157     291440570        28f962208        2    running                 1cpu        sqlexec
69580   294edd028        28f9619e8        2    running                 3cpu        sqlexec
69601   2947fa028        28f977748        2    running                 6cpu        sqlexec
69609   2980e83a8        28f97a808        2    running                 7cpu        sqlexec
69616   291370948        28f957768        2    running                 9cpu        sqlexec
69622   293972128        28f956f48        2    running                 4cpu        sqlexec
69629   2910d81c0        28f972608        2    running                 6cpu        sqlexec


eomsdb2-/opt/informix> onstat -g ses ses_id
Unable to open input file 'ses_id'
eomsdb2-/opt/informix> onstat -g ses

IBM Informix Dynamic Server Version 9.40.FC2W2   -- On-Line -- Up 6 days 09:39:11 -- 8872960 Kbytes

session                                      #RSAM    total      used       dynamic
id       user     tty      pid      hostname threads  memory     memory     explain
69475    informix -        0        -        0        12288      10792      off
69473    informix -        -1       10.101.9 1        118784     78440      off
69472    informix -        -1       10.101.9 1        61440      46400      off
69471    informix -        -1       10.101.9 1        106496     77928      off
69470    informix -        -1       10.101.9 1        122880     79176      off
69469    informix -        -1       10.101.9 1        200704     162760     off
69468    informix -        -1       10.101.9 1        118784     78800      off
69465    informix -        -1       10.101.1 1        53248      41768      off
69463    informix -        -1       10.101.9 1        184320     110696     off
69462    informix -        -1       10.101.9 1        167936     102920     off
69461    informix -        -1       10.101.9 1        147456     90080      off
69460    informix -        -1       10.101.9 1        188416     105856     off
69458    informix -        -1       10.101.1 1        53248      41768      off
69457    informix -        -1       10.101.9 1        151552     91128      off
69456    informix -        -1       10.101.9 1        159744     92880      off
69455    informix -        -1       10.101.9 1        208896     96656      off
69454    informix -        -1       10.101.9 1        200704     94608      off
69453    informix -        -1       10.101.9 1        53248      41768      off
69451    informix -        -1       10.101.1 1        53248      41768      off
69450    informix -        -1       10.101.1 1        53248      41768      off
69446    informix -        -1       10.101.9 1        229376     121600     off
69445    informix -        -1       10.101.9 1        204800     99328      off
69444    informix -        -1       10.101.9 1        253952     191424     off
69443    informix -        -1       10.101.9 1        172032     100592     off
69442    informix -        -1       10.101.9 1        266240     174704     off
69441    informix -        -1       10.101.9 1        208896     112080     off
69440    informix -        -1       10.101.9 1        212992     109408     off
69433    informix -        -1       10.101.9 1        122880     108504     off
69432    informix -        -1       10.101.9 1        237568     145872     off
69431    informix -        -1       10.101.9 1        180224     112648     off
69430    informix -        -1       10.101.9 1        311296     270080     off
69429    informix -        -1       10.101.9 1        184320     112376     off
69428    informix -        -1       10.101.9 1        176128     112592     off
69427    informix -        -1       10.101.9 1        192512     112056     off
69422    informix -        -1       10.101.9 1        208896     118736     off
69414    informix -        -1       10.101.9 1        53248      41768      off
69400    informix -        -1       10.101.9 1        53248      41768      off
69399    informix -        -1       10.101.9 1        53248      41768      off
69398    informix -        -1       10.101.9 1        53248      41768      off
69397    informix -        -1       10.101.9 1        53248      41768      off
69396    informix -        -1       10.101.1 1        53248      41768      off
69393    informix -        -1       10.101.1 1        57344      46704      off
69392    informix -        -1       10.101.1 1        57344      46704      off
69384    informix -        -1       10.101.9 1        184320     108128     off
69383    informix -        -1       10.101.9 1        237568     123104     off
69336    informix -        -1       10.101.9 1        57344      44872      off
69335    informix -        -1       eomsdb1  1        53248      41768      off
69334    informix -        -1       eomsdb1  1        53248      41768      off
69332    informix -        -1       eomsdb1  1        53248      41768      off
69330    informix -        -1       eomsdb1  1        53248      41768      off
69329    informix -        -1       eomsdb1  1        53248      41768      off
69327    informix -        -1       eomsdb1  1        53248      41768      off
69326    informix -        -1       eomsdb1  1        53248      41768      off
69323    informix -        -1       eomsdb1  1        53248      41768      off
69321    informix -        -1       10.101.1 1        65536      45160      off
69215    informix -        -1       10.101.1 1        53248      41768      off
69200    informix -        -1       10.101.9 1        57344      44880      off
69199    informix -        -1       10.101.9 1        57344      44880      off
69198    informix -        -1       10.101.9 1        57344      44880      off
69149    informix -        -1       10.101.1 1        53248      41768      off
69148    informix -        -1       10.101.1 1        53248      41768      off
69130    informix -        -1       eomsdb1  1        53248      41768      off
69129    informix -        -1       eomsdb1  1        53248      41768      off
69079    informix -        -1       10.101.1 1        53248      41768      off
69078    informix -        -1       10.101.1 1        53248      41768      off
69075    informix -        -1       eomsdb1  1        53248      41768      off
69074    informix -        -1       eomsdb1  1        53248      41768      off
69073    informix -        -1       eomsdb1  1        53248      41768      off
69072    informix -        -1       eomsdb1  1        53248      41768      off
69071    informix -        -1       eomsdb1  1        53248      41768      off
69043    informix -        -1       10.101.1 1        151552     82248      off
69042    informix -        -1       10.101.1 1        200704     159256     off
69024    informix -        -1       10.101.1 1        184320     93944      off
69006    informix -        -1       10.101.1 1        167936     94712      off
68985    informix -        -1       10.101.1 1        143360     84512      off
67723    informix -        0        -        0        12288      10792      off
66935    informix CMCC-EOM 4852     10.101.1 1        61440      46256      off
65558    informix -        -1       10.101.1 1        106496     75328      off
65417    informix -        -1       10.101.1 1        106496     74904      off
112      informix -        -1       10.101.1 1        61440      43688      off
7        informix -        0        -        0        16384      12376      off
6        informix -        0        -        0        12288      10792      off
4        informix -        0        -        0        16384      12376      off
3        informix -        0        -        0        12288      10792      off
2        informix -        0        -        0        12288      10792      off

论坛徽章:
0
9 [报告]
发表于 2006-05-24 10:59 |只看该作者
这样看得出来什么问题吗??
好有什么命令可以分析吗??

论坛徽章:
0
10 [报告]
发表于 2006-05-24 17:02 |只看该作者
给8008101818打电话吧!
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP