enq:HW contention
If the event is constantly occurring in the database, just run the following query to identify the sessions encountering the HW contention
1.select * from v$session_wait where event='enq: HW - contention';
Determine the correct file and block number
2.select DBMS_UTILITY.DATA_BLOCK_ADDRESS_FILE(51236787) FILE#,
DBMS_UTILITY.DATA_BLOCK_ADDRESS_BLOCK(51236787) BLOCK#
from dual;
FILE# BLOCK#
12 905139
here you will get file and block no
in the above query "51236787" is P3 value from V$session query 1.
Optionally can check file name by query -
3.select * from dba_data_files where file_id='12';
now get segment name and owner from query:
1.select * from v$session_wait where event='enq: HW - contention';
Determine the correct file and block number
2.select DBMS_UTILITY.DATA_BLOCK_ADDRESS_FILE(51236787) FILE#,
DBMS_UTILITY.DATA_BLOCK_ADDRESS_BLOCK(51236787) BLOCK#
from dual;
FILE# BLOCK#
12 905139
here you will get file and block no
in the above query "51236787" is P3 value from V$session query 1.
Optionally can check file name by query -
3.select * from dba_data_files where file_id='12';
now get segment name and owner from query:
4. select owner, segment_type, segment_name
from dba_extents
where file_id = 12
and 905139 between block_id and block_id + blocks - 1;
Next, isolate the table name that references this LOB segment
using the following query:
5. select * from all_lobs where segment_name='SYS_LOB0000124825C00354$$';
Determine the biggest extent size of this object for segment space management auto
6. SELECT
DISTINCT bytes
FROM dba_extents
WHERE segment_name = 'SYS_LOB0000124825C00354$$';
AND owner = 'SCOTT';
Add some extents to this LOB segment:
7. ALTER TABLE SCOTT.EMPLOYEE
MODIFY LOB (JOININGDOC_BYTE)
(ALLOCATE EXTENT (SIZE 1M));
check again for this enqueue by query 1. Now you wont get it .
Comments
Post a Comment