This discussion is archived
5 Replies Latest reply: Dec 4, 2012 6:40 AM by Victor Armbrust RSS

how to solve sequence gaps on standby

Kaye Chow Newbie
Currently Being Moderated
Hi Experts,

I really need to hear your thoughts.

I have 11g databases for both production and standby database. FYI production is setup with RAC. For some reason, the standby database lost connection for 20 days. So we have sequence gaps.

What I did copied the archived logs from the production to standby since its not deleted. But I just notice that there is file_name convert associated with archivelogs. I already registered the archivelogs but with the wrong naming convention. It is correct to transfer archivelogs from prod to standby?

And the dg is working fine now, it's transporting the recent archivelogs but its not applying. How to applied those logs?

I would be very grateful of your response.

Thanks!
  • 1. Re: how to solve sequence gaps on standby
    Shivananda Rao Guru
    Currently Being Moderated
    Hello,

    Try registering the archives with the correct naming convention. Make sure that the MRP is started on the standby database.

    On the standby database:
    SQL>select process,status,sequence# from v$managed_standby;
  • 2. Re: how to solve sequence gaps on standby
    Kaye Chow Newbie
    Currently Being Moderated
    Hi,

    SQL> select process,status,sequence# from v$managed_standby;

    PROCESS STATUS SEQUENCE#
    --------- ------------ ----------
    ARCH CLOSING 5370
    ARCH CONNECTED 0
    ARCH CLOSING 5371
    ARCH CLOSING 5369
    MRP0 WAIT_FOR_GAP 811
    RFS IDLE 0
    RFS IDLE 5372
    RFS IDLE 0
    RFS IDLE 4241

    9 rows selected.



    this is the result of the query.

    so is it ok if i rename manually the from OS the archivelogs? like for example, we have archivelogs from prod named "oradb.arc" and on standby we have "orasty.arc". so i just copied the oradb.arc to standby. is it ok if i manually rename it? then register the archivelog?

    Edited by: Kaye Chow on Nov 23, 2012 6:50 AM
  • 3. Re: how to solve sequence gaps on standby
    Step_Into_Oracle_DBA Explorer
    Currently Being Moderated
    Kaye,

    Use below sql to find the gaps in the database.

    Select * from v$archive_gap;

    This will show the lowest and highest sequence need to resolve the gaps.

    and then just scp the archives from primary to standby location and register the archives in standby. It will automatically start applying.

    Alter database register logfile '\u01\app\oracle\standby_arch\oradb.arc';

    Let me know if you have any issues.

    Cheers,

    StepIntoOracleDBA
  • 4. Re: how to solve sequence gaps on standby
    974842 Newbie
    Currently Being Moderated
    Try to register those log files manually using

    alter database register logfile 'path'

    or whatever the syntax is
    try this.

    Or check whether MRP is started
  • 5. Re: how to solve sequence gaps on standby
    Victor Armbrust Oracle ACE
    Currently Being Moderated
    You can do this manually by registering the archivelog files on standby

    If you have broker configured on your DG you can also see the gap using "show database <standby db>" command

    You can also look from errors using the query below



    column message format a80
    select message, timestamp
    from v$dataguard_status
    where severity in ('Error','Fatal')
    order by timestamp;

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points