http://yangtingkun.itpub.net/post/468/524305
这个数据库的版本是11.1.0.6 for Windows 64bits for AMD,在AWR报告中,TOP 5等待事件为:
Event | Waits | Time(s) | Avg wait (ms) | % DB time | Wait Class |
enq: DX - contention | 22,627 | 135,751 | 6000 | 126.41 | Other |
inactive transaction branch | 22,625 | 22,626 | 1000 | 21.07 | Other |
db file scattered read | 1,312,470 | 4,212 | 3 | 3.92 | User I/O |
DB CPU | 3,928 | 3.66 | |||
db file sequential read | 1,349,206 | 3,522 | 3 | 3.28 | User I/O |
其中以enq: DX – contention等待最为严重,其实是inactive transaction branch。而这两个等待事件平均等待时间分别是6秒和1秒,平均等待时间这么整,显然不是偶然,这说明这两个等待时间都经历了各自的超时时间。
查询metalink,这个问题也是BUG所致,在文档High CPU by Sessions Holding DX Enqueue; Others Waiting 'enq: DX - contention' [ID 1275884.1]中描述了这个错误。
导致问题的原因是一些持有分布式事务队列的用户尝试中止或退出分布式事务,Oracle在处理的时候占用了大量的CPU资源。
而用来判断是否出现这个问题的标志是,数据库中出现了明显的enq: DX – contention和inactive transaction branch等待事件。
这个问题影响10.2和11.1版本,在11.2中被FIXED。可以通过打单独的8552942的补丁来解决这个问题。