2007年9月29日 星期六

oracle -- 關於v$lock table

第一次看到v$lock 這個table,
真是一頭霧水, 原來它並不指單純的table lock 或record lock.
ID1、ID2會根據TYPE不同而儲存不同的資訊.
例如TM表示對表的更新LOCK,
TX表示對更新的ROLLBACK資訊.通常update的時候, TM和TX是一組.
TYPE
BL - Buffer hash table instance lock
CF - Control file schema global enqueue lock
CI - Cross-instance function invocation instance lock
CS - Control file schema global enqueue lock
CU - Cursor bind lock
DF - Data file instance lock
DL - Direct loader parallel index create
DM - Mount/startup db primary/secondary instance lock
DR - Distributed recovery process lock
DX - Distributed transaction entry lock
FI - SGA open-file information lock
FS - File set lock
HW - Space management operations on a specific segment lock
IN - Instance number lock
IR - Instance recovery serialization global enqueue lock
IS - Instance state lock
IV - Library cache invalidation instance lock
JQ - Job queue lock
KK - Thread kick lock
MB - Master buffer hash table instance lock
MM - Mount definition gloabal enqueue lock
MR - Media recovery lock
PF - Password file lock
PI - Parallel operation lock
PR - Process startup lock
PS - Parallel operation lock
RE - USE_ROW_ENQUEUE enforcement lock
RT - Redo thread global enqueue lock
RW - Row wait enqueue lock
SC - System commit number instance lock
SH - System commit number high water mark enqueue lock
SM - SMON lock
SN - Sequence number instance lock
SQ - Sequence number enqueue lock
SS - Sort segment lock
ST - Space transaction enqueue lock
SV - Sequence number value lock
TA - Generic enqueue lock
TD - DDL enqueue lock
TE - Extend-segment enqueue lock
TM - DML enqueue lock
TT - Temporary table enqueue lock
TX - Transaction enqueue lock
UL - User supplied lock
UN - User name lock
US - Undo segment DDL lock
WL - Being-written redo log instance lock
WS - Write-atomic-log-switch global enqueue lock

LMODE
1 - No Lock
2 - Row Share
3 - Row Exclusive
4 - Share
5 - Share Row Exclusive
6 - Exclusive

沒有留言: