Pages

Saturday, November 19, 2022

Golden Gate Datapump not working after crash start. "Showing Current status: In recovery[2]: At EOF" and "No active extraction maps."

================
Issue
================
Database server was stopped and was restarted
After that , Golden Gate Datapump Extract is not running.
There is no error, but the Datapump Extract is constantly in recovery.
And it not updating the second node.


================
In General
================
When running
INFO DPM_EXTRACT DETAIL and checking the log file:

 
Switching to next trail file /software/ogg/191/dirdat/01/out/ei000009314
Rolling over remote file /software/ogg/191/dirdat/01/in/ei000009159

dirdat/01/out/ei000009314 - It is s the file on THIS server. It is written by EXTRACT process. Can double check by looking into the report file for EXTRACT(Recovery completed for target file /software/ogg/191/dirdat/01/out/ei000009314, at RBA 1538)

191/dirdat/01/in/ei000009159 - It is the file on REMOTE server. It is written by the DATAPUMP on the REMOTE server, and read by REPLICAT on the REMOTE server as well.
Can double check by looking into the REPLICAT report file on remote server: 
Switching to next trail file /software/ogg/191/dirdat/01/in/ei000009159

================
By Example
================
> SEND DPM_S_01 STATS

Sending STATS request to EXTRACT DPM_S_01 ...

No active extraction maps.

> SEND DPM_S_01 STATUS

Sending STATUS request to EXTRACT DPM_S_01 ...
EXTRACT DPM_S_01 (PID 9275)
  Current status: In recovery[2]: At EOF

  Current read position:
  Sequence #: 10177
  RBA: 212360562
  Timestamp: 2022-11-19 13:10:36.000000
  Extract Trail: /software/ogg/191/dirdat/01/out/es

  Current write position:
  Sequence #: 10177
  RBA: 0
  Timestamp: 2022-11-14 16:19:13.265526
  Extract Trail: /software/ogg/191/dirdat/01/in/es

================
Solution
================
In General:

1. Query the main extract for current Sequence and RBA.

2. Update the Data Pump Extract with the values from step 1.

3. In case it still does not work, do ALTER EXTRACT MAIN_EXTRACT ETROLLOVER and repeat steps 1+2.

ALTER EXTRACT MAIN_EXTRACT ETROLLOVER instructs main extract to switch writing to a new file. It might be that the previous file got somehow corrupted during database server sudden shutdown. 

================
By Example
================
EXT_S_01 - is the main extract
DPM_S_01 - is the data pump extract

> INFO EXT_S_01 SHOWCH

EXTRACT    EXT_S_01  Last Started 2022-11-19 13:09   Status RUNNING
Checkpoint Lag       00:00:02 (updated 00:00:04 ago)
Process ID           12516
Log Read Checkpoint  Oracle Integrated Redo Logs
                     2022-11-19 20:02:51
                     SCN 6.1510356821 (27280160597)


Current Checkpoint Detail:

Read Checkpoint #1

  Oracle Integrated Redo Log

  Startup Checkpoint (starting position in the data source):
    Timestamp: 2022-09-04 06:54:43.000000
    SCN: 0.0 (0)

  Recovery Checkpoint (position of oldest unprocessed transaction in the data source):
    Timestamp: 2022-11-19 20:02:43.000000
    SCN: 6.1510354581 (27280158357)

  Current Checkpoint (position of last record read in the data source):
    Timestamp: 2022-11-19 20:02:51.000000
    SCN: 6.1510356821 (27280160597)

  BR Previous Recovery Checkpoint:
    Timestamp: 2022-11-19 13:09:17.917578
    SCN: 0.0 (0)

  BR Begin Recovery Checkpoint:
    Timestamp: 2022-11-19 17:08:13.000000
    SCN: 6.1507821110 (27277624886)

  BR End Recovery Checkpoint:
    Timestamp: 2022-11-19 17:09:32.000000
    SCN: 6.1507838612 (27277642388)

Write Checkpoint #1

  GGS Log Trail

  Current Checkpoint (current write position):
    Sequence #: 10177
    RBA: 212375522
    Timestamp: 2022-11-19 20:02:53.678942
    Extract Trail: /software/ogg/191/dirdat/01/out/es
    Seqno Length: 9
    Flip Seqno Length: No
    Trail Type: EXTTRAIL

Header:
  Version = 2
  Record Source = A
  Type = 18
  # Input Checkpoints = 1
  # Output Checkpoints = 1

Configuration:
  Data Source = 3
  Transaction Integrity = 1
  Task Type = 0

Status:
  Start Time = 2022-11-19 13:09:25
  Last Update Time = 2022-11-19 20:02:53
  Stop Status = A
  Last Result = 0

STOP EXTRACT DPM_S_01
> ALTER EXTRACT DPM_S_01 EXTSEQNO 10177
> ALTER EXTRACT DPM_S_01 EXTRBA 212375522
> START EXTRACT DPM_S_01

Datapump still showing that it is not working.
SEND DPM_S_01 STATS
Sending STATS request to EXTRACT DPM_S_01 ...
No active extraction maps.


In case it still does not work, do ALTER EXTRACT MAIN_EXTRACT ETROLLOVER and repeat steps 1+2.

> STOP  EXTRACT EXT_S_01
ALTER EXTRACT EXT_S_01 ETROLLOVER
START EXTRACT EXT_S_01
> INFO EXTRACT EXT_S_01 SHOWCH
  Current Checkpoint (current write position):
    Sequence #: 10178
    RBA: 1464
    Timestamp: 2022-11-19 20:50:25.993536
    Extract Trail: /software/ogg/191/dirdat/01/out/es
    Seqno Length: 9
    Flip Seqno Length: No
    Trail Type: EXTTRAIL

> STOP EXTRACT DPM_S_01
> ALTER EXTRACT DPM_S_01 EXTSEQNO 10178
> ALTER EXTRACT DPM_S_01 EXTRBA 1464
> START EXTRACT DPM_S_01
> INFO EXTRACT DPM_S_01

EXTRACT    DPM_S_01  Last Started 2022-11-19 20:51   Status RUNNING
Checkpoint Lag       00:00:00 (updated 00:00:03 ago)
Process ID           16893
Log Read Checkpoint  File /software/ogg/191/dirdat/01/out/es000010178
                     First Record  RBA 1464

> INFO ALL
Program     Status      Group       Lag at Chkpt  Time Since Chkpt

MANAGER     RUNNING
EXTRACT     RUNNING     DPM_I_01    00:00:00      00:00:07
EXTRACT     RUNNING     DPM_P_01    00:00:00      00:00:01
EXTRACT     RUNNING     DPM_S_01    00:00:00      00:00:07
EXTRACT     RUNNING     EXT_I_01    00:00:02      00:00:04
EXTRACT     RUNNING     EXT_P_01    00:00:02      00:00:01
EXTRACT     RUNNING     EXT_S_01    00:00:03      00:00:01
REPLICAT    RUNNING     REP_I_01    00:00:00      00:00:03
REPLICAT    RUNNING     REP_P_01    00:00:05      00:00:02
REPLICAT    RUNNING     REP_S_01    00:00:07      00:00:01
> SEND DPM_S_01 STATS

Sending STATS request to EXTRACT DPM_S_01 ...

Start of Statistics at 2022-11-19 21:46:50.

Output to /software/ogg/191/dirdat/01/in/es:

Extracting from SOME_USER.SGA_W_PSMS_SUBSCRIBER to SOME_USER.SGA_W_PSMS_SUBSCRIBER:

*** Total statistics since 2022-11-19 21:12:34 ***
        Total inserts                                      0.00
        Total updates                                      2.00
        Total deletes                                      0.00
        Total upserts                                      0.00
        Total discards                                     0.00
        Total operations                                   2.00

*** Daily statistics since 2022-11-19 21:12:34 ***
        Total inserts                                      0.00
        Total updates                                      2.00
        Total deletes                                      0.00
        Total upserts                                      0.00
        Total discards                                     0.00
        Total operations                                   2.00

*** Hourly statistics since 2022-11-19 21:12:34 ***
        Total inserts                                      0.00
        Total updates                                      2.00
        Total deletes                                      0.00
        Total upserts                                      0.00
        Total discards                                     0.00
        Total operations                                   2.00

*** Latest statistics since 2022-11-19 21:12:34 ***
        Total inserts                                      0.00
        Total updates                                      2.00
        Total deletes                                      0.00
        Total upserts                                      0.00
        Total discards                                     0.00
        Total operations                                   2.00

End of Statistics.

No comments:

Post a Comment