Pages

Wednesday, October 28, 2020

Golden Gate REPLICAT Error: ERROR OGG-01091 Unable to open file "XXX" (error 2, No such file or directory).

=========================
General
=========================
Oracle Golden Gate Replicat Process abends with following error:
ERROR   OGG-01091  Unable to open file "/software/ogg/191/dirdat/01/in/es000004665" (error 2, No such file or directory).

Checking the file system, indeed there is no such file:
There is indeed no such file.
First file being es000000000

ls -ltr   /software/ogg/191/dirdat/01/in/es*/
-rw-r----- 1 oracle dba 499997096 Feb 13 08:26 es000000000
-rw-r----- 1 oracle dba 499996646 Feb 13 08:26 es000000001
-rw-r----- 1 oracle dba 499999334 Feb 13 08:27 es000000002
-rw-r----- 1 oracle dba 499998299 Feb 13 08:27 es000000003
-rw-r----- 1 oracle dba 499998846 Feb 13 08:27 es000000004


=========================
Solution
=========================
Reset Replicat to start at first available file:

EXTSEQNO 0 - point to file es000000000
EXTRBA 0 - point to start position of the file

GGSCI> DBLOGIN USERID USER PASSWORD PASS

GSCI (qanfv-1-dbs-1b) 17> INFO ALL

Program     Status      Group       Lag at Chkpt  Time Since Chkpt

MANAGER     RUNNING
EXTRACT     RUNNING     DPM_I_01    00:00:00      00:00:09
EXTRACT     RUNNING     DPM_P_01    00:00:00      00:00:05
EXTRACT     RUNNING     DPM_S_01    00:00:03      00:00:04
EXTRACT     RUNNING     EXT_I_01    00:00:03      00:00:02
EXTRACT     RUNNING     EXT_P_01    00:00:02      00:00:09
EXTRACT     RUNNING     EXT_S_01    00:00:02      00:00:05
REPLICAT    RUNNING     REP_I_01    00:00:00      00:00:04
REPLICAT    RUNNING     REP_P_01    00:00:00      00:00:04
REPLICAT    ABENDED     REP_S_01    00:00:00      07:10:31



GGSCI> ALTER REPLICAT REP_S_01, EXTSEQNO 0 EXTRBA 0
REPLICAT altered.

GGSCI> START REPLICAT REP_S_01
REPLICAT REP_P_01 starting

GGSCI> INFO ALL
MANAGER     RUNNING
EXTRACT     RUNNING     DPM_I_01    00:00:00      00:00:02
EXTRACT     RUNNING     DPM_P_01    00:00:00      00:00:01
EXTRACT     RUNNING     DPM_S_01    00:00:00      00:00:04
EXTRACT     RUNNING     EXT_I_01    00:00:03      00:00:04
EXTRACT     RUNNING     EXT_P_01    00:00:00      00:00:03
EXTRACT     RUNNING     EXT_S_01    00:00:02      00:00:04
REPLICAT    RUNNING     REP_I_01    00:00:00      00:00:01
REPLICAT    RUNNING     REP_P_01    00:00:00      00:00:00
REPLICAT    RUNNING     REP_S_01    43:50:16      00:00:00
Since many files were pending replication, there is a backlog, which should be cleared alter some time

REPLICAT    RUNNING     REP_S_01    43:49:57      00:00:00
REPLICAT    RUNNING     REP_S_01    42:12:40      00:00:00

Note: This is not good!!
Because when starting without specific RBA, it will default to RBA from the old file, instead of starting with RBA=0. For example, it will try to start with 
EXTSEQNO 0 EXTRBA 8132, instead of EXTSEQNO 0 EXTRBA 0

GGSCI> ALTER REPLICAT REP_S_01 EXTSEQNO 0
REPLICAT altered.

GGSCI> INFO ALL

GGSCI> REPLICAT    ABENDED     REP_S_01    00:00:00      07:10:31

=========================
Additional info
=========================
Over weekend GG Replication was broken, and files filled up 100% of /software/ogg/191/dirdat/01/

Since this was a test environment, as a quick solution, existing files were deleted and GG started from scratch.

No comments:

Post a Comment