留着给ora-04036: pga memory used by the instance exceeds pga_aggregate_limit 这个用。
set lines 200;
set pages 200;
column name format a25;
column pname format a12;
col spid for a15
column "
usedmb" format a10;
set numwidth 6;
select s.sid, s.serial#,p.pid, p.spid,p.pname, sn.name, round(ss.value/(1024 *1024))||'mb' "usedmb"
from v$sesstat ss, v$statname sn, v$session s, v$process p
where s.paddr = p.addr
and sn.statistic# = ss.statistic#
and s.sid = ss.sid
and sn.name in ('session pga memory' , 'session pga memory max')
and p.pname like 'dia%'
order by ss.value desc;
效果如下:
sid serial# pid spid pname name usedmb
------ ------- ------ ------------------------ ------------ ------------------------- ----------
406 40961 17 46617 dia0 session pga memory 4mb
406 40961 17 46617 dia0 session pga memory max 4mb
399 29754 8 3095 diag session pga memory 1mb
399 29754 8 3095 diag session pga memory max 1mb
阅读(1806) | 评论(0) | 转发(0) |