ITPub博客

首页 > Linux操作系统 > Linux操作系统 > How To Determine Who Is Using Undo Tablespace And How Much? [ID 304513.1]

How To Determine Who Is Using Undo Tablespace And How Much? [ID 304513.1]

原创 Linux操作系统 作者:spider0283 时间:2012-02-26 14:59:56 0 删除 编辑

Applies to:

Oracle Server - Enterprise Edition - Version: 9.2.0.5 to 11.2.0.3 - Release: 9.2 to 11.2
Information in this document applies to any platform.
***Checked for relevance on 17-Jan-2012***

Goal

How do you determine which users are using and how much UNDO is being used?

Solution

Use the next query:
select a.sid, a.serial#, a.username, b.used_urec, b.used_ublk
from   v$session a,
       v$transaction b
where  a.saddr = b.ses_addr;


EXAMPLE:
SQL> select a.sid, a.serial#, a.username, b.used_urec, b.used_ublk
2 from v$session a, v$transaction b
3 where a.saddr=b.ses_addr;


SID        SERIAL#    USERNAME                       USED_UREC  USED_UBLK
---------- ---------- ------------------------------ ---------- ----------
21               7856 KBCOOK                                  1          1

With:
  USED_UBLK = Number of undo blocks used 
  USED_UREC = Number of undo records used

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/38267/viewspace-717170/,如需转载,请注明出处,否则将追究法律责任。

请登录后发表评论 登录
全部评论

注册时间:2011-03-29

  • 博文量
    194
  • 访问量
    609370