Sunday, March 6, 2016

ERROR OGG-00446 Unable to lock file "ECBN.cpe


Extract and Replicats running On RAC ACFS got abended report file says process abended with "OGG-00446  Unable to lock file"

GGSCI (tnc1.localdomain) 4> info all
Program     Status      Group       Lag at Chkpt  Time Since Chkpt                                        
EXTRACT     ABENDED     ECBN        0 0:00:09      00:32:52    
REPLICAT    ABENDED     RCBN        00:00:00      00:50:36    

GGSCI (tnc1.localdomain) 5> view report ECBN
ECBN0.rpt:2016-03-04 10:55:18  ERROR   OGG-00446  Unable to lock file "/u02/goldengate/12.1/dirchk/ECBN.cpe" (error 11, Resource temporarily unavailable).
ECBN0.rpt:2016-03-04 10:55:18  ERROR   OGG-01668  PROCESS ABENDING.
ECBN1.rpt:2016-03-04 10:51:38  ERROR   OGG-00446  Unable to lock file "/u02/goldengate/12.1/dirchk/ECBN.cpe" (error 11, Resource temporarily unavailable).  Lock currently held by process id (PID) 14053.

Root cause as follows 
"FROM Doc ID 1330326.1" 
As we Installed GoldenGate on Shared Filesystem (ACFS), OS dosn't shutdown cleanly 
and we have Exclusive locks held on files ""/u02/goldengate/12.1/dirchk/ECBN.cpe"" by Filesystem and makes GG process abended on GoldenGate Home

Resolution: 
Rename the "ExtractName.CPE" 
copy the information in New.cpe to Old.cpe file and Restart the extract  
After restarting extract delete the Rename.cpe File 

[oracle@tnc1 dirchk]$ ls -ltr
total 92
-rw-r----- 1 oracle oinstall  2048 Mar  6 00:32 ECBN.cpb
-rw-r----- 1 oracle oinstall 30720 Mar  6 00:32 RCBN.cpr
-rw-r----- 1 oracle oinstall 22528 Mar  6 00:32 ECBN.cpe

[oracle@tnc1 dirchk]$ mv ECBN.cpe ECBN_BACKUP.cpe
[oracle@tnc1 dirchk]$ ls -ltr
-rw-r----- 1 oracle oinstall 22528 Mar  6 00:32 ECBN_BACKUP.cpe
[oracle@tnc1 dirchk]$ cp ECBN_BACKUP.cpe ECBN.cpe
[oracle@tnc1 dirchk]$ 
[oracle@tnc1 dirchk]$ ggn
[oracle@tnc1 12.1]$ pwd
/u02/goldengate/12.1
[oracle@tnc1 12.1]$ ./ggsci
Oracle GoldenGate Command Interpreter for Oracle
Version 12.2.0.1.1 OGGCORE_12.2.0.1.0_PLATFORMS_151211.1401_FBO
Linux, x64, 64bit (optimized), Oracle 12c on Dec 12 2015 02:56:48
Operating system character set identified as UTF-8.

Copyright (C) 1995, 2015, Oracle and/or its affiliates. All rights reserved.
GGSCI (tnc1.localdomain) 1> info all
Program     Status      Group       Lag at Chkpt  Time Since Chkpt
MANAGER     RUNNING                                           
EXTRACT     ABENDED     ECBN        00:00:09          47:41:59    
EXTRACT     ABENDED     ECBN_BACKUP  00:00:09   47:41:59    
REPLICAT    ABENDED     RCBN        00:00:00           47:55:21    

GGSCI (tnc1.localdomain) 8> info all
Program     Status      Group       Lag at Chkpt  Time Since Chkpt
MANAGER     RUNNING                                           
EXTRACT     RUNNING     ECBN        47:43:16      00:00:09   

After Remove the "Rename.cpe" File 
[oracle@tnc1 dirchk]$ rm ECBN_BACKUP.cpe 
[oracle@tnc1 dirchk]$ ls -ltr

GGSCI (tnc1.localdomain) 2> info all
Program     Status      Group       Lag at Chkpt  Time Since Chkpt
MANAGER     RUNNING                                           
EXTRACT     RUNNING     ECBN        00:00:04      00:00:09    

---Nikhil Tatineni--



Querys to monitor RAC

following few  Query's will help to find out culprits-  Query to check long running transaction from last 8 hours  Col Sid Fo...