Sunday, May 12, 2019

Find table in trail file using Goldengate logdump utility



Check TABLE (CUST.SALES) in Trail file using LOGDUMP

cd  $GG_HOME

$./logdump
Logdump 1 >ghdr on
Logdump 2 >detail on
Logdump 3 >detail data
Logdump 4 >open /goldengate/home/dirdat/xxxx/CS000023799
Current LogTrail is /goldengate/home/dirdat/xxxx/CS000023799

Logdump 6 >FILTER INCLUDE FILENAME CUST.sales
Logdump 7 >count
Scanned     10000 records, RBA    7356269, 2019/05/03 14:44:45.000.000
Scanned     20000 records, RBA   14846486, 2019/05/03 14:46:49.000.000
Scanned     30000 records, RBA   23290032, 2019/05/03 14:56:03.000.000
Scanned     40000 records, RBA   32171981, 2019/05/03 15:04:39.000.000
Scanned     50000 records, RBA   41262061, 2019/05/03 15:09:51.000.000
Partial record at RBA 46133384
Format 550 record, total len = 3268
LogTrail /goldengate/home/xxxx/hp000023799 has 0 records
Filtering matched            0 records
          suppressed     56004 records

 Logdump 8 >n

RFS[11]: Client instance is standby database instead of primary


Server: RHEL6
Oracle DB version: 12.1

In my Primary Alert log i'm seeing RFS messages writing frequently like below

Primary alert log :

RFS[10]: Assigned to RFS process (PID:16586)
RFS[10]: Database mount ID mismatch [0x6666ae9b:0x666707e4] (1718005403:171802260)
RFS[10]: Client instance is standby database instead of primary
Tue Feb 19 16:10:14 2019
RFS[11]: Assigned to RFS process (PID:174682)
RFS[11]: Database mount ID mismatch [0x6666ae9b:0x666707e4] (1718005403:1718028260)
RFS[11]: Client instance is standby database instead of primary

 After researching further and according to Oracle (Doc ID 1450132.1)

Cause:

It's due to my Standby database is sending ARCH logs back to my Primary site (RAC exadata machine) (don’t know how this was happening) and causing these messages writing to my Primary alert log  and to fix this I’ve to find and remove "dest_" parameter which is pointing back to primary site

On standby site

SQL> sho parameter dest_2

NAME                                 TYPE        VALUE
------------------------------------ ----------- ------------------------------
db_create_online_log_dest_2          string
log_archive_dest_2                   string      service=myprod_prim ARCH SYNC NO
                                                              AFFIRM delay=0 OPTIONAL reopen=15 register


SQL> sho parameter dest_state_2

NAME                                 TYPE        VALUE
------------------------------------ ----------- ------------------------------
log_archive_dest_state_2             string      ENABLE

Yes i see my dest_2 is pointing to Primary and it is ENABLED so remove this parameter (OR) DEFER it 

FIX:

SQL> ALTER SYSTEM SET log_archive_dest_2='' scope=both;

System altered.

Now i see  NO messages are writing in alert log

Auto Scroll Stop Scroll