查巡AIX 的 cpu利用率高

在aix下用topas命令查看cpu的利用率,可以看到pid为1335526的语句占用淳朴为45.2,Name            PID  CPU%  PgSp Owneroracle      1335526   45.2   4.9 oracleo...显示全部
在aix下用topas命令查看cpu的利用率,可以看到pid为1335526的语句占用淳朴为45.2,

Name            PID  CPU%  PgSp Owner

oracle      1335526   45.2   4.9 oracle

oracle      1143216   3.7   5.0 oracle

再在oracle用户下查询,就可以得到语句是啥了。

select a.username, a.machine, a.sid, a.serial#, a.status, c.DISK_READS, c.sql_text

from v$session a, v$process b, v$sqlarea c

where b.spid='1155396' and b.addr=a.paddr and a.sql_address=c.address(+);

----也可以用这条语句来查看。。

select b.username username,a.disk_reads reads,a.executions exec,

a.disk_reads/decode(a.executions,0,1,a.executions) rds_exec_ratio,

a.sql_text statement

from v$sqlarea a,dba_users b

where a.parsing_user_id=b.user_id

and a.disk_reads>100000收起
参与6

查看其它 5 个回答p509827858的回答

p509827858p509827858系统工程师lei
...........mei kan dong
互联网服务 · 2011-03-15
浏览731

回答者

p509827858
系统工程师lei

p509827858 最近回答过的问题

回答状态

  • 发布时间:2011-03-15
  • 关注会员:0 人
  • 回答浏览:731
  • X社区推广