ORA-04021: timeout occurred while waiting to lock object

ORA-04021: timeout occurred while waiting to lock object
 

CHANGES

 

CAUSE

Bug 18242740 ACTIVE STANDBY DATABASE CRASHED WITH ORA-4021 closed as duplicate of Bug 17018214 - ORA-600 [KRDRSB_END_QSCN_2]

SOLUTION

Fix is already included in 11.2.0.4 but the fix is DISABLED by default.

To enable the fix  set "_adg_parselock_timeout" to the number of centi-seconds LGWR should wait before backing off and retrying the request.
Set  the parameter "_adg_parselock_timeout" 

col name for a30;
col value for a10;
select
x.ksppinm  name,
y.ksppstvl  value,
y.ksppstdf  isdefault,
decode(bitand(y.ksppstvf,7),1,'MODIFIED',4,'SYSTEM_MOD','FALSE')  ismod,
decode(bitand(y.ksppstvf,2),2,'TRUE','FALSE')  isadj
from
sys.x$ksppi x,
sys.x$ksppcv y
where
x.inst_id = userenv('Instance') and
y.inst_id = userenv('Instance') and
x.indx = y.indx and x.ksppinm ='_adg_parselock_timeout'
order by
translate(x.ksppinm, ' _', ' ')
/


On the Active Data Guard Standby set below parameter and restart standby:

ALTER SYSTEM set "_adg_parselock_timeout"=550 scope=both;
 

Active dataguard instance crashed with below error

ORA-29771: process USER (OSID 26451) blocks LGWR (OSID 25719) for more than 70 seconds 
Incident details in: /u01/app/oracle/diag/rdbms/###_TEST/TEST1/incident/incdir_378817/TEST_lmhb_25699_i378817.trc
USER (ospid: 26451) is blocking LGWR (ospid: 25719) in a wait
LMHB (ospid: 25699) kills USER (ospid: 26451).

 

CAUSE

This issue is due to the below bug

BUG 20413540 - STBH: 9X INCREASE IN PARALLEL QUERIES DUE TO FRJD8ZFY2JFDQ POST RDBMS 12102

.
 

SOLUTION

In addition to the fix for the bug 20413540, please set
the init parameter "_adg_parselock_timeout" to 550 on all the instances of the
active DG.

This parameter would make sure that the LGWR times out when waiting for the
instance parse lock which would allow other blocked processes to acquire the
lock and continue with parsing and prevent the processes from blocked behind
LGWR and avoid a hang situation

你可能感兴趣的:(oracle)