Thursday, March 4, 2010

Transaction rollback monitoring

Rollback is based on a transaction in the database and the number of undo blocks it created.
When a transaction is rolling back those blocks will decrease. We can see this in v$transaction.

select s.username,        s.sid,        s.serial#,        t.used_ublk,        t.used_urec from v$transaction t, v$session s where  s.saddr = t.ses_addr and s.sid = 890 order by t.used_ublk desc


Once the used_ublk and used_urec return to 0, the rollback is complete.

******************************************
keywords: undo rollback monitoring
******************************************
rdbms version: 9i 10g
******************************************

No comments: