Archive log missing on standby: FAL[client]: Failed to request gap sequence

My current environment is Oracle 10.2.0.4 with ASM 10.2.0.4 on a 2 node RAC in production and a standby that is the same setup. I'm also running on Oracle Linux 5. Almost daily now an archivelog doesnt make it to the standby and oracle doesnt seem to resolve the gap sequence from the primary. If I stop and restart recovery it gets the logfile and continues recovery just fine. I have checked my fal_client and fal_server settings and they look good. The logs after this error do continue to get written to the standby but the standby wont continue recovery until I stop and restart recovery and it fetches this missing log.
The only thing I know thats happening is that the firewall people are disconnecting any connections that are inactive for 60 minutes and recently did an upgrade that they are claiming didnt change anything:)  I dont know if this is causing this problem or not. Any thoughts on what might be happening?
Error in standby alert.log:
Tue Jun 29 23:15:35 2010
RFS[258]: Possible network disconnect with primary database
Tue Jun 29 23:15:36 2010
Fetching gap sequence in thread 2, gap sequence 9206-9206
Tue Jun 29 23:16:46 2010
FAL[client]: Failed to request gap sequence
GAP - thread 2 sequence 9206-9206
DBID 661398854 branch 714087609
FAL[client]: All defined FAL servers have been attempted.
Error on primary alert.log:
Tue Jun 29 23:00:07 2010
ARC0: Creating remote archive destination LOG_ARCHIVE_DEST_2: 'WSSPRDB' (thread 1 sequence 9265)
(WSSPRD1)
ARC0: Transmitting activation ID 0x29c37469
Tue Jun 29 23:00:07 2010
Errors in file /u01/app/oracle/admin/WSSPRD/bdump/wssprd1_arc0_14024.trc:
ORA-03135: connection lost contact
FAL[server, ARC0]: FAL archive failed, see trace file.
Tue Jun 29 23:00:07 2010
Errors in file /u01/app/oracle/admin/WSSPRD/bdump/wssprd1_arc0_14024.trc:
ORA-16055: FAL request rejected
ARCH: FAL archive failed. Archiver continuing
Tue Jun 29 23:00:07 2010
ORACLE Instance WSSPRD1 - Archival Error. Archiver continuing.
Tue Jun 29 23:00:41 2010
Redo Shipping Client Connected as PUBLIC
-- Connected User is Valid
Tue Jun 29 23:00:41 2010
FAL[server, ARC2]: Begin FAL archive (dbid 0 branch 714087609 thread 2 sequence 9206 dest WSSPRDB)
FAL[server, ARC2]: FAL archive failed, see trace file.
Tue Jun 29 23:00:43 2010
Errors in file /u01/app/oracle/admin/WSSPRD/bdump/wssprd1_arc2_14028.trc:
ORA-16055: FAL request rejected
ARCH: FAL archive failed. Archiver continuing
Tue Jun 29 23:00:43 2010
ORACLE Instance WSSPRD1 - Archival Error. Archiver continuing.
Tue Jun 29 23:01:16 2010
Redo Shipping Client Connected as PUBLIC
-- Connected User is Valid
Tue Jun 29 23:15:01 2010
Thread 1 advanced to log sequence 9267 (LGWR switch)
I have checked the trace files that get spit out but they arent anything meaningful to me as to whats really happening. Snipit of the trace file:
tkcrrwkx: Starting to process work request
tkcrfgli: SRL header: 0
tkcrfgli: SRL tail: 0
tkcrfgli: ORL to arch: 4
tkcrfgli: le# seq thr for bck tba flags
tkcrfgli: 1 359 1 2 0 3 0x0008 ORL active cur
tkcrfgli: 2 358 1 0 1 1 0x0000 ORL active
tkcrfgli: 3 361 2 4 0 0 0x0008 ORL active cur
tkcrfgli: 4 360 2 0 3 2 0x0000 ORL active
tkcrfgli: 5 -- entry deleted --
tkcrfgli: 6 -- entry deleted --
tkcrfgli: 7 -- entry deleted --
tkcrfgli: 8 -- entry deleted --
tkcrfgli: 9 -- entry deleted --
tkcrfgli: 191 -- entry deleted --
tkcrfgli: 192 -- entry deleted --
*** 2010-03-27 01:30:32.603 20998 kcrr.c
tkcrrwkx: Request from LGWR to perform: <startup>
tkcrrcrlc: Starting CRL ARCH check
*** 2010-03-27 01:30:32.603 66085 kcrr.c
Beginning controlfile transaction 0x0x7fffd0b53198 [kcrr.c:20395 (14011)]
*** 2010-03-27 01:30:32.645 66173 kcrr.c
Acquired controlfile transaction 0x0x7fffd0b53198 [kcrr.c:20395 (14024)]
*** 2010-03-27 01:30:32.649 66394 kcrr.c
Ending controlfile transaction 0x0x7fffd0b53198 [kcrr.c:20397]
tkcrrasgn: Checking for 'no FAL', 'no SRL', and 'HB' ARCH process
# HB NoF NoS CRL Name
29 NO NO NO NO ARC0
28 NO YES YES NO ARC1
27 NO NO NO NO ARC2
26 NO NO NO NO ARC3
25 YES NO NO NO ARC4
24 NO NO NO NO ARC5
23 NO NO NO NO ARC6
22 NO NO NO NO ARC7
21 NO NO NO NO ARC8
20 NO NO NO NO ARC9
Thanks.
Kristi

It's the network that's messing up; unlikely due to firewall timeout as it waits for 60 minutes and you are switching every 15 minutes. There may be some other network glitch that needs rectified.
In any case - arch file missing/ corrupt / halfway through - FAL setting should have refetched the problematic archive log automatically.
As many had suggested already, the best way to resolve RFS issues I believe is to use real-time apply by configuring standby redo logs. It's very easy to configure it and you can opt for real-time apply even in max-performance mode that you are using right now.
Even though you are maintaining (I guess) 1-1 between primary & standby instances, you can provide both primary instances in fal_server (like fal_server=string1,string2). See if that helps.
lastly, check if you are having simiar issue at other times as well that might be getting rectified automatically as expected.
col message for a80
col time for a20
select message, to_char(timestamp,'dd-mon-rr hh24:mi:ss') time
from v$dataguard_status
where severity in ('Error','Fatal')
order by timestamp;
Cheers.

Similar Messages

  • Failed to request gap sequence. Thread #: 1, gap sequence: 6859-6859

    Dear all,
    1.while applying the log manually 6859 it tells that is already registered. then i appplied 6860,6861,6862,6863 its get appplied.
    2.But while check on the alertlog it tells
    Failed to request gap sequence. Thread #: 1, gap sequence: 6859-6859,All FAL server has been attempted.
    Thu May 17 13:04:59 2012
    idle dispatcher 'D000' terminated, pid = (11, 18)"
    3.the alert logfile from standby is given below
    Completed: ALTER DATABASE RECOVER MANAGED STANDBY DATABASE DI
    Thu May 17 13:04:20 2012
    Failed to request gap sequence. Thread #: 1, gap sequence: 6859-6859
    All FAL server has been attempted.
    Thu May 17 13:04:59 2012
    idle dispatcher 'D000' terminated, pid = (11, 18)
    thanks in advance,
    regards,
    DB

    Hello again;
    12154 is a common error. If this was Oracle 11 i would say check your Standby password file, I assume this is OK.
    If not you must copy the password to the standby and rename it. After that you must cancel recovery and shutdown the standby
    and START MOUNT on the new password file.
    Can you tnsping both servers from the other?
    Can you connect from ( sqlplus ) from each server to the other?
    Example :
    sqlplus sys/password@primary as sysdba (from the standby system)
    Most likely your tnsname is missing an entry or has an incorrect entry. Sometimes this is a listener issue, double check your status.
    Is your listener setup correctly?
    If you do a :
    lsnrctl status
    The READY status comes from the instance registering with the listener.
    The UNKNOWN status comes from the sid list entry in listener.ora.
    from standby
    $lsnrctl services
    And make sure your service is available.
    You can compare you tnsnames and listener.ora setup with my short notes :
    http://www.visi.com/~mseberg/data_guard_on_oracle_11_step_by_step.html
    Best Regards
    mseberg

  • Archived log missed in standby database

    Hi,
    OS; Windows 2003 server
    Oracle: 10.2.0.4
    Data Guard: Max Performance
    Dataguard missed some of the archivelog files and but latest log files are applying. standby database is not in sync with primary.
    SELECT LOCAL.THREAD#, LOCAL.SEQUENCE# FROM (SELECT THREAD#, SEQUENCE# FROM V$ARCHIVED_LOG WHERE DEST_ID=1) LOCAL WHERE LOCAL.SEQUENCE# NOT IN (SELECT SEQUENCE# FROM V$ARCHIVED_LOG WHERE DEST_ID=2 AND THREAD# = LOCAL.THREAD#);
    I queried above command and I found some files are missed in standby.
    select status, type, database_mode, recovery_mode,protection_mode, srl, synchronization_status,synchronized from V$ARCHIVE_DEST_STATUS where dest_id=2;
    STATUS TYPE DATABASE_MODE RECOVERY_MODE PROTECTION_MODE SRL SYNCHRONIZATION_STATUS SYN
    VALID PHYSICAL MOUNTED-STANDBY MANAGED MAXIMUM PERFORMANCE NO CHECK CONFIGURATION NO
    Anyone can tell me how to apply those missed archive log files.
    Thanks in advacne

    Deccan Charger wrote:
    I got below error.
    SQL> ALTER DATABASE RECOVER MANAGED STANDBY DATABASE DISCONNECT FROM SESSION;
    ALTER DATABASE RECOVER MANAGED STANDBY DATABASE DISCONNECT FROM SESSION
    ERROR at line 1:
    ORA-01153: an incompatible media recovery is activeYou need to essentially do the following.
    1) Stop managed recovery on the standby.
    ALTER DATABASE RECOVER MANAGED STANDBY DATABASE CANCEL;2) Resolve the archive log gap - if you have configured FAL_SERVER and FAL_CLIENT Oracle should do this when you follow step 3 below, as you've manually copied the missed logs you should be OK
    3) restart managed recovery using the command shown above.
    You can monitor archive log catchup using the alert.log or your original query.
    Niall Litchfield
    http://www.orawin.info/
    Edited by: Niall Litchfield on May 4, 2010 2:29 PM
    missed tag

  • Redo Archive Logs Missing

    Hi Gurus
    While Configuring Data Guard for ORacle 10g (10.2.0.4) 64 bits on Windows 2007 Server 64 bits.
    I got few questions
    1. What is the Default mode of Standby Database?
    2. Should we Always Start Physical Standby Database to Recover Missing Redo Archive Log?
    SQL> startup mount;
    ORACLE instance started.
    Total System Global Area 591396864 bytes
    Fixed Size 2067496 bytes
    Variable Size 163578840 bytes
    Database Buffers 419430400 bytes
    Redo Buffers 6320128 bytes
    Database mounted.
    SQL> alter databse recover managed standby database disconnect from session;
                   Database altered.
    3. When there are missing Redo Log Archives e.g.
    ----On Standby Database--------
    SQL> SELECT RESETLOGS_ID,SEQUENCE#,STATUS,ARCHIVED FROM V$ARCHIVED_LOG
    2 ORDER BY RESETLOGS_ID,SEQUENCE#;
    RESETLOGS_ID SEQUENCE# S ARC
    812980008 15 A YES
    812980008 16 A YES
    812980008 17 A YES
    812980008 18 A YES
    812980008 19 A YES
    812980008 20 A YES
    812980008 21 A YES
    812980008 22 A YES
    812980008 23 A YES
    812980008 24 A YES
    812980008 25 A YES
    RESETLOGS_ID SEQUENCE# S ARC
    812980008 26 A YES
    812980008 27 A YES
    812980008 28 A YES
    812980008 29 A YES
    812980008 30 A YES
    812980008 31 A YES
    812980008 32 A YES
    812980008 33 A YES
    812980008 34 A YES
    812980008 35 A YES
    812980008 36 A YES
    RESETLOGS_ID SEQUENCE# S ARC
    812980008 37 A YES
    812980008 38 A YES
    812980008 39 A YES
    812980008 40 A YES
    812980008 41 A YES
    812980008 42 A YES
    812980008 43 A YES
    29 rows selected.
    ---------------On Primary Database---------------------
    SQL> SELECT RESETLOGS_ID,SEQUENCE#,STATUS,ARCHIVED FROM V$ARCHIVED_LOG
    2 ORDER BY RESETLOGS_ID,SEQUENCE# ;
    RESETLOGS_ID SEQUENCE# S ARC
    *812980008 8 A YES*
    *812980008 9 A YES*
    *812980008 10 A YES*
    *812980008 11 A YES*
    *812980008 12 A YES*
    *812980008 13 A YES*
    *812980008 14 A YES*
    812980008 15 A YES
    812980008 15 A YES
    812980008 16 A YES
    812980008 16 A YES
    RESETLOGS_ID SEQUENCE# S ARC
    812980008 17 A YES
    812980008 17 A YES
    812980008 18 A YES
    812980008 18 A YES
    812980008 19 A YES
    812980008 19 A YES
    812980008 20 A YES
    812980008 20 A YES
    812980008 21 A YES
    812980008 21 A YES
    812980008 22 A YES
    RESETLOGS_ID SEQUENCE# S ARC
    812980008 22 A YES
    812980008 23 A YES
    812980008 23 A YES
    812980008 24 A YES
    812980008 24 A YES
    812980008 25 A YES
    812980008 25 A YES
    812980008 26 A YES
    812980008 26 A YES
    812980008 27 A YES
    812980008 27 A YES
    RESETLOGS_ID SEQUENCE# S ARC
    812980008 28 A YES
    812980008 28 A YES
    812980008 29 A YES
    812980008 29 A YES
    812980008 30 A YES
    812980008 30 A YES
    812980008 31 A YES
    812980008 31 A YES
    812980008 32 A YES
    812980008 32 A YES
    812980008 33 A YES
    RESETLOGS_ID SEQUENCE# S ARC
    812980008 33 A YES
    812980008 34 A YES
    812980008 34 A YES
    812980008 35 A YES
    812980008 35 A YES
    812980008 36 A YES
    812980008 36 A YES
    812980008 37 A YES
    812980008 37 A YES
    812980008 38 A YES
    812980008 38 A YES
    RESETLOGS_ID SEQUENCE# S ARC
    812980008 39 A YES
    812980008 39 A YES
    812980008 40 A YES
    812980008 40 A YES
    812980008 41 A YES
    812980008 41 A YES
    812980008 42 A YES
    812980008 42 A YES
    812980008 43 A YES
    812980008 43 A YES
    65 rows selected.
    Log 8, 9, 10, 11, 12, 13, 14, 15 are missing.
    How to Apply / Recover These Logs on Standby Database?
    Regards
    Thunder2777

    Hi
    Thunder2777 wrote:
    Hi Gurus
    While Configuring Data Guard for ORacle 10g (10.2.0.4) 64 bits on Windows 2007 Server 64 bits.
    I got few questions
    1. What is the Default mode of Standby Database?
    What is default mode? I think you want ask in what mode standby database is apply redo logs.
    Standby database can apply received redo only MOUNT mode, (your version is 10g, after 11g can apply open mode with READ ONLY WITH APPLY)
    2. Should we Always Start Physical Standby Database to Recover Missing Redo Archive Log?
    If Standby database opened mount mode, then database can receive redo.
    If you are start Redo Apply then MPR can request from primary for missing redo logs.
    SQL> startup mount;
    ORACLE instance started.
    Total System Global Area 591396864 bytes
    Fixed Size 2067496 bytes
    Variable Size 163578840 bytes
    Database Buffers 419430400 bytes
    Redo Buffers 6320128 bytes
    Database mounted.
    SQL> alter databse recover managed standby database disconnect from session;
                   Database altered.
    It is started recovery, in other words Redo Apply (MRP0 process)
    >
    3. When there are missing Redo Log Archives e.g.
    ----On Standby Database-------->
    SQL> SELECT RESETLOGS_ID,SEQUENCE#,STATUS,ARCHIVED FROM V$ARCHIVED_LOG
    2 ORDER BY RESETLOGS_ID,SEQUENCE#;
    RESETLOGS_ID SEQUENCE# S ARC
    812980008 15 A YES
    812980008 16 A YES
    812980008 17 A YES
    812980008 18 A YES
    812980008 19 A YES
    812980008 20 A YES
    812980008 21 A YES
    812980008 22 A YES
    812980008 23 A YES
    812980008 24 A YES
    812980008 25 A YES
    RESETLOGS_ID SEQUENCE# S ARC
    812980008 26 A YES
    812980008 27 A YES
    812980008 28 A YES
    812980008 29 A YES
    812980008 30 A YES
    812980008 31 A YES
    812980008 32 A YES
    812980008 33 A YES
    812980008 34 A YES
    812980008 35 A YES
    812980008 36 A YES
    RESETLOGS_ID SEQUENCE# S ARC
    812980008 37 A YES
    812980008 38 A YES
    812980008 39 A YES
    812980008 40 A YES
    812980008 41 A YES
    812980008 42 A YES
    812980008 43 A YES
    29 rows selected.
    ---------------On Primary Database---------------------
    SQL> SELECT RESETLOGS_ID,SEQUENCE#,STATUS,ARCHIVED FROM V$ARCHIVED_LOG
    2 ORDER BY RESETLOGS_ID,SEQUENCE# ;
    RESETLOGS_ID SEQUENCE# S ARC
    *812980008 8 A YES*
    *812980008 9 A YES*
    *812980008 10 A YES*
    *812980008 11 A YES*
    *812980008 12 A YES*
    *812980008 13 A YES*
    *812980008 14 A YES*
    812980008 15 A YES
    812980008 15 A YES
    812980008 16 A YES
    812980008 16 A YES
    RESETLOGS_ID SEQUENCE# S ARC
    812980008 17 A YES
    812980008 17 A YES
    812980008 18 A YES
    812980008 18 A YES
    812980008 19 A YES
    812980008 19 A YES
    812980008 20 A YES
    812980008 20 A YES
    812980008 21 A YES
    812980008 21 A YES
    812980008 22 A YES
    RESETLOGS_ID SEQUENCE# S ARC
    812980008 22 A YES
    812980008 23 A YES
    812980008 23 A YES
    812980008 24 A YES
    812980008 24 A YES
    812980008 25 A YES
    812980008 25 A YES
    812980008 26 A YES
    812980008 26 A YES
    812980008 27 A YES
    812980008 27 A YES
    RESETLOGS_ID SEQUENCE# S ARC
    812980008 28 A YES
    812980008 28 A YES
    812980008 29 A YES
    812980008 29 A YES
    812980008 30 A YES
    812980008 30 A YES
    812980008 31 A YES
    812980008 31 A YES
    812980008 32 A YES
    812980008 32 A YES
    812980008 33 A YES
    RESETLOGS_ID SEQUENCE# S ARC
    812980008 33 A YES
    812980008 34 A YES
    812980008 34 A YES
    812980008 35 A YES
    812980008 35 A YES
    812980008 36 A YES
    812980008 36 A YES
    812980008 37 A YES
    812980008 37 A YES
    812980008 38 A YES
    812980008 38 A YES
    RESETLOGS_ID SEQUENCE# S ARC
    812980008 39 A YES
    812980008 39 A YES
    812980008 40 A YES
    812980008 40 A YES
    812980008 41 A YES
    812980008 41 A YES
    812980008 42 A YES
    812980008 42 A YES
    812980008 43 A YES
    812980008 43 A YES
    65 rows selected.
    Log 8, 9, 10, 11, 12, 13, 14, 15 are missing.It is no missing, you are created standby database, after sequence 15.
    As you know , if a sequence redo is not applied, then after is sequenced redo log is cannot apply to standby database.
    It means GAP.
    There have 43 archived redo log, and your last sequenced archive log received by standby database
    and applied.
    You can check with following scripts, too
    select max(Sequence#) from v$archived_log; -- on primary
    select max(Sequence#) from v$archived_log where applied = 'YES';  - on standby  Regards
    Mahir M. Quluzade

  • *HOW TO DELETE THE ARCHIVE LOGS ON THE STANDBY*

    HOW TO DELETE THE ARCHIVE LOGS ON THE STANDBY
    I have set the RMAN CONFIGURE ARCHIVELOG DELETION POLICY TO APPLIED ON STANDBY; on my physical standby server.
    My archivelog files are not deleted on standby.
    I have set the CONFIGURE ARCHIVELOG DELETION POLICY TO NONE; # default on the Primary server.
    I've checked the archivelogs with the FRA and they are not beign deleted on the STANDBY. Do I have to do something for the configuation to take effect? Like run a RMAN backup?
    I've done a lot ofresearch and i'm getting mixed answers. Please help. Thanks in advanced.
    J

    Setting the Policy will not delete the Archive logs on the Standby. ( I found a thread where the Data Guard product manager says "The deletion policy on both sides will do what you want" ). However I still
    like to clean them off with RMAN.
    I would use RMAN to delete them so that it can use that Policy are you are protected in case of Gap, transport issue etc.
    There are many ways to do this. You can simply run RMAN and have it clean out the Archive.
    Example :
    #!/bin/bash
    # Name: db_rman_arch_standby.sh
    # Purpose: Database rman backup
    # Usage : db_rman_arch_standby <DBNAME>
    if [ "$1" ]
    then DBNAME=$1
    else
    echo "basename $0 : Syntax error : use . db_rman_full <DBNAME> "
    exit 1
    fi
    . /u01/app/oracle/dba_tool/env/${DBNAME}.env
    echo ${DBNAME}
    MAILHEADER="Archive_cleanup_on_STANDBY_${DBNAME}"
    echo "Starting RMAN..."
    $ORACLE_HOME/bin/rman target / catalog <user>/<password>@<catalog> << EOF
    delete noprompt ARCHIVELOG UNTIL TIME 'SYSDATE-8';
    exit
    EOF
    echo `date`
    echo
    echo 'End of archive cleanup on STANDBY'
    mailx -s ${MAILHEADER} $MAILTO < /tmp/rmandbarchstandby.out
    # End of ScriptThis uses ( calls an ENV) so the crontab has an environment.
    Example ( STANDBY.env )
    ORACLE_BASE=/u01/app/oracle
    ULIMIT=unlimited
    ORACLE_SID=STANDBY
    ORACLE_HOME=$ORACLE_BASE/product/11.2.0.2
    ORA_NLS33=$ORACLE_HOME/ocommon/nls/admin/data
    LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib
    LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/lib
    LIBPATH=$LD_LIBRARY_PATH:/usr/lib
    TNS_ADMIN=$ORACLE_HOME/network/admin
    PATH=$ORACLE_HOME/bin:$ORACLE_BASE/dba_tool/bin:/bin:/usr/bin:/usr/ccs/bin:/etc:/usr/sbin:/usr/ucb:$HOME/bin:/usr/bin/X11:/sbin:/usr/lbin:/GNU/bin/make:/u01/app/oracle/dba_tool/bin:/home/oracle/utils/SCRIPTS:/usr/local/bin:.
    #export TERM=linux=80x25 wrong wrong wrong wrong wrong
    export TERM=vt100
    export ORACLE_BASE ORACLE_SID ORACLE_TERM ULIMIT
    export ORACLE_HOME
    export LIBPATH LD_LIBRARY_PATH ORA_NLS33
    export TNS_ADMIN
    export PATH
    export MAILTO=?? your email hereNote use the env command in Unix to get you settings.
    There are probably ten other/better ways to do this, but this works.
    other options ( you decide )
    Configure RMAN to purge archivelogs after applied on standby [ID 728053.1]
    http://www.oracle.com/technetwork/database/features/availability/rman-dataguard-10g-wp-1-129486.pdf
    Maintenance Of Archivelogs On Standby Databases [ID 464668.1]
    Tip I don't care myself but in some of the other forums people seem to mind if you use all caps in the subject. They say it shouting. My take is if somebody is shouting at me I'm probably going to just move away.
    Best Regards
    mseberg
    Edited by: mseberg on May 8, 2012 11:53 AM
    Edited by: mseberg on May 8, 2012 11:56 AM

  • How: Script archive log transfer to standby db

    Hi,
    I’m implementing disaster recovery right now. For some special reason, the only option for me is to implement non-managed standby (manual recovery) database.
    The following is what I’m trying to do using shell script:
    1.     Compress archive logs and copy them from Primary site to Standby site every hour. ( I have a very low network )
    2.     Decompress archive logs at standby site
    3.     Check if there are missed archive logs. If no, then do the manual recovery
    Did I miss something above? And I’m not skill in to build shell scripts, is there any sample scripts I can follow? Thanks.
    Nabil
    Message was edited by:
    11iuser

    Hi,
    Take a look at data guard packages. There is a package just for this purpose: Bipul Kumar notes:
    http://www.dba-oracle.com/t_oracledataguard_174_unskip_table_.htm
    "the time lag between the log transfer and the log apply service can be built using the DELAY attribute of the log_archive_dest_n initialization parameter on the primary database. This delay timer starts when the archived log is completely transferred to the standby site. The default value of the DELAY attribute is 30 minutes, but this value can be overridden as shown in the following example:
    LOG_ARCHIVE_DEST_3=’SERVICE=logdbstdby DELAY=60’;"
    1. Compress archive logs and copy them from Primary site to Standby site every hour.Me, I use tar (or compress) and rcp, but I don't know the details of your environment. Jon Emmons has some good notes:
    http://www.lifeaftercoffee.com/2006/12/05/archiving-directories-and-files-with-tar/
    2. Decompress archive logs at standby siteSee the man pages for uncompress. I do it through a named pipe to simplify the process:
    http://www.dba-oracle.com/linux/conditional_statements.htm
    3. Check if there are missed archive logs.I keep my standby data in recovery mode, and as soon as the incoming logs are uncompressed, they are applied automatically.
    Again, if you don't feel comfortable writing your own, consider using the data guard packages.
    Hope this helps. . .
    Donald K. Burleson
    Oracle Press author

  • Capture process issue...archive log missing!!!!!

    Hi,
    Oracle Streams capture process is alternating between INITIALIZING and DICTIONARY INITIALIZATION state and not proceeding after this state to capture updates made on table.
    we have accidentally missing archivelogs and no backup archive logs.
    Now I am going to recreate the capture process again.
    How I can start the the capture process from new SCN ?
    And Waht is the batter way to remove the archive log files from central server, because
    SCN used by capture processes?
    Thanks,
    Faziarain
    Edited by: [email protected] on Aug 12, 2009 12:27 AM

    Using dbms_Streams_Adm to add a capture, perform also a dbms_capture_adm.build. You will see in v$archived_log at the column dictionary_begin a 'yes', which means that the first_change# of this archivelog is first suitable SCN for starting capture.
    'rman' is the prefered way in 10g+ to remove the archives as it is aware of streams constraints. If you can't use rman to purge the archives, then you need to check the min required SCN in your system by script and act accordingly.
    Since 10g, I recommend to use rman, but nevertheless, here is the script I made in 9i in the old time were rman was eating the archives needed by Streams with appetite.
    #!/usr/bin/ksh
    # program : watch_arc.sh
    # purpose : check your archive directory and if actual percentage is > MAX_PERC
    #           then undertake the action coded by -a param
    # Author : Bernard Polarski
    # Date   :  01-08-2000
    #           12-09-2005      : added option -s MAX_SIZE
    #           20-11-2005      : added option -f to check if an archive is applied on data guard site before deleting it
    #           20-12-2005      : added option -z to check if an archive is still needed by logminer in a streams operation
    # set -xv
    #--------------------------- default values if not defined --------------
    # put here default values if you don't want to code then at run time
    MAX_PERC=85
    ARC_DIR=
    ACTION=
    LOG=/tmp/watch_arch.log
    EXT_ARC=
    PART=2
    #------------------------- Function section -----------------------------
    get_perc_occup()
      cd $ARC_DIR
      if [ $MAX_SIZE -gt 0 ];then
           # size is given in mb, we calculate all in K
           TOTAL_DISK=`expr $MAX_SIZE \* 1024`
           USED=`du -ks . | tail -1| awk '{print $1}'`    # in Kb!
      else
        USED=`df -k . | tail -1| awk '{print $3}'`    # in Kb!
        if [ `uname -a | awk '{print $1}'` = HP-UX ] ;then
               TOTAL_DISK=`df -b . | cut -f2 -d: | awk '{print $1}'`
        elif [ `uname -s` = AIX ] ;then
               TOTAL_DISK=`df -k . | tail -1| awk '{print $2}'`
        elif [ `uname -s` = ReliantUNIX-N ] ;then
               TOTAL_DISK=`df -k . | tail -1| awk '{print $2}'`
        else
                 # works on Sun
                 TOTAL_DISK=`df -b . | sed  '/avail/d' | awk '{print $2}'`
        fi
      fi
      USED100=`expr $USED \* 100`
      USG_PERC=`expr $USED100 / $TOTAL_DISK`
      echo $USG_PERC
    #------------------------ Main process ------------------------------------------
    usage()
        cat <<EOF
                  Usage : watch_arc.sh -h
                          watch_arc.sh  -p <MAX_PERC> -e <EXTENTION> -l -d -m <TARGET_DIR> -r <PART>
                                        -t <ARCHIVE_DIR> -c <gzip|compress> -v <LOGFILE>
                                        -s <MAX_SIZE (meg)> -i <SID> -g -f
                  Note :
                           -c compress file after move using either compress or gzip (if available)
                              if -c is given without -m then file will be compressed in ARCHIVE DIR
                           -d Delete selected files
                           -e Extention of files to be processed
                           -f Check if log has been applied, required -i <sid> and -g if v8
                           -g Version 8 (use svrmgrl instead of sqlplus /
                           -i Oracle SID
                           -l List file that will be processing using -d or -m
                           -h help
                           -m move file to TARGET_DIR
                           -p Max percentage above wich action is triggered.
                              Actions are of type -l, -d  or -m
                           -t ARCHIVE_DIR
                           -s Perform action if size of target dir is bigger than MAX_SIZE (meg)
                           -v report action performed in LOGFILE
                           -r Part of files that will be affected by action :
                               2=half, 3=a third, 4=a quater .... [ default=2 ]
                           -z Check if log is still needed by logminer (used in streams),
                                    it requires -i <sid> and also -g for Oracle 8i
                  This program list, delete or move half of all file whose extention is given [ or default 'arc']
                  It check the size of the archive directory and if the percentage occupancy is above the given limit
                  then it performs the action on the half older files.
            How to use this prg :
                    run this file from the crontab, say, each hour.
         example
         1) Delete archive that is sharing common arch disk, when you are at 85% of 2500 mega perform delete half of the files
         whose extention is 'arc' using default affected file (default is -r 2)
         0,30 * * * * /usr/local/bin/watch_arc.sh -e arc -t /arc/POLDEV -s 2500 -p 85 -d -v /var/tmp/watch_arc.POLDEV.log
         2) Delete archive that is sharing common disk with oother DB in /archive, act when 90% of 140G, affect by deleting
         a quater of all files (-r 4) whose extention is 'dbf' but connect before as sysdba in POLDEV db (-i) if they are
         applied (-f is a dataguard option)
         watch_arc.sh -e dbf -t /archive/standby/CITSPRD -s 140000 -p 90 -d -f -i POLDEV -r 4 -v /tmp/watch_arc.POLDEV.log
         3) Delete archive of DB POLDEV when it reaches 75% affect 1/3 third of files, but connect in DB to check if
         logminer do not need this archive (-z). this is usefull in 9iR2 when using Rman as rman do not support delete input
         in connection to Logminer.
         watch_arc.sh -e arc -t /archive/standby/CITSPRD  -p 75 -d -z -i POLDEV -r 3 -v /tmp/watch_arc.POLDEV.log
    EOF
    #------------------------- Function section -----------------------------
    if [ "x-$1" = "x-" ];then
          usage
          exit
    fi
    MAX_SIZE=-1  # disable this feature if it is not specificaly selected
    while getopts  c:e:p:m:r:s:i:t:v:dhlfgz ARG
      do
        case $ARG in
           e ) EXT_ARC=$OPTARG ;;
           f ) CHECK_APPLIED=YES ;;
           g ) VERSION8=TRUE;;
           i ) ORACLE_SID=$OPTARG;;
           h ) usage
               exit ;;
           c ) COMPRESS_PRG=$OPTARG ;;
           p ) MAX_PERC=$OPTARG ;;
           d ) ACTION=delete ;;
           l ) ACTION=list ;;
           m ) ACTION=move
               TARGET_DIR=$OPTARG
               if [ ! -d $TARGET_DIR ] ;then
                   echo "Dir $TARGET_DIR does not exits"
                   exit
               fi;;
           r)  PART=$OPTARG ;;
           s)  MAX_SIZE=$OPTARG ;;
           t)  ARC_DIR=$OPTARG ;;
           v)  VERBOSE=TRUE
               LOG=$OPTARG
               if [ ! -f $LOG ];then
                   > $LOG
               fi ;;
           z)  LOGMINER=TRUE;;
        esac
    done
    if [ "x-$ARC_DIR" = "x-" ];then
         echo "NO ARC_DIR : aborting"
         exit
    fi
    if [ "x-$EXT_ARC" = "x-" ];then
         echo "NO EXT_ARC : aborting"
         exit
    fi
    if [ "x-$ACTION" = "x-" ];then
         echo "NO ACTION : aborting"
         exit
    fi
    if [ ! "x-$COMPRESS_PRG" = "x-" ];then
       if [ ! "x-$ACTION" =  "x-move" ];then
             ACTION=compress
       fi
    fi
    if [ "$CHECK_APPLIED" = "YES" ];then
       if [ -n "$ORACLE_SID" ];then
             export PATH=$PATH:/usr/local/bin
             export ORAENV_ASK=NO
             export ORACLE_SID=$ORACLE_SID
             . /usr/local/bin/oraenv
       fi
       if [ "$VERSION8" = "TRUE" ];then
          ret=`svrmgrl <<EOF
    connect internal
    select max(sequence#) from v\\$log_history ;
    EOF`
    LAST_APPLIED=`echo $ret | sed 's/.*------ \([^ ][^ ]* \).*/\1/' | awk '{print $1}'`
       else
        ret=`sqlplus -s '/ as sysdba' <<EOF
    set pagesize 0 head off pause off
    select max(SEQUENCE#) FROM V\\$ARCHIVED_LOG where applied = 'YES';
    EOF`
       LAST_APPLIED=`echo $ret | awk '{print $1}'`
       fi
    elif [ "$LOGMINER" = "TRUE" ];then
       if [ -n "$ORACLE_SID" ];then
             export PATH=$PATH:/usr/local/bin
             export ORAENV_ASK=NO
             export ORACLE_SID=$ORACLE_SID
             . /usr/local/bin/oraenv
       fi
        var=`sqlplus -s '/ as sysdba' <<EOF
    set pagesize 0 head off pause off serveroutput on
    DECLARE
    hScn number := 0;
    lScn number := 0;
    sScn number;
    ascn number;
    alog varchar2(1000);
    begin
      select min(start_scn), min(applied_scn) into sScn, ascn from dba_capture ;
      DBMS_OUTPUT.ENABLE(2000);
      for cr in (select distinct(a.ckpt_scn)
                 from system.logmnr_restart_ckpt\\$ a
                 where a.ckpt_scn <= ascn and a.valid = 1
                   and exists (select * from system.logmnr_log\\$ l
                       where a.ckpt_scn between l.first_change# and l.next_change#)
                  order by a.ckpt_scn desc)
      loop
        if (hScn = 0) then
           hScn := cr.ckpt_scn;
        else
           lScn := cr.ckpt_scn;
           exit;
        end if;
      end loop;
      if lScn = 0 then
        lScn := sScn;
      end if;
       select min(sequence#) into alog from v\\$archived_log where lScn between first_change# and next_change#;
      dbms_output.put_line(alog);
    end;
    EOF`
      # if there are no mandatory keep archive, instead of a number we just get the "PLS/SQL successfull"
      ret=`echo $var | awk '{print $1}'`
      if [ ! "$ret" = "PL/SQL" ];then
         LAST_APPLIED=$ret
      else
         unset LOGMINER
      fi
    fi
    PERC_NOW=`get_perc_occup`
    if [ $PERC_NOW -gt $MAX_PERC ];then
         cd $ARC_DIR
         cpt=`ls -tr *.$EXT_ARC | wc -w`
         if [ ! "x-$cpt" = "x-" ];then
              MID=`expr $cpt / $PART`
              cpt=0
              ls -tr *.$EXT_ARC |while read ARC
                  do
                     cpt=`expr $cpt + 1`
                     if [ $cpt -gt $MID ];then
                          break
                     fi
                     if [ "$CHECK_APPLIED" = "YES" -o "$LOGMINER" = "TRUE" ];then
                        VAR=`echo $ARC | sed 's/.*_\([0-9][0-9]*\)\..*/\1/' | sed 's/[^0-9][^0-9].*//'`
                        if [ $VAR -gt $LAST_APPLIED ];then
                             continue
                        fi
                     fi
                     case $ACTION in
                          'compress' ) $COMPRESS_PRG $ARC_DIR/$ARC
                                     if [ "x-$VERBOSE" = "x-TRUE" ];then
                                           echo " `date +%d-%m-%Y' '%H:%M` : $ARC compressed using $COMPRESS_PRG" >> $LOG
                                     fi ;;
                          'delete' ) rm $ARC_DIR/$ARC
                                     if [ "x-$VERBOSE" = "x-TRUE" ];then
                                           echo " `date +%d-%m-%Y' '%H:%M` : $ARC deleted" >> $LOG
                                     fi ;;
                          'list'   )   ls -l $ARC_DIR/$ARC ;;
                          'move'   ) mv  $ARC_DIR/$ARC $TARGET_DIR
                                     if [ ! "x-$COMPRESS_PRG" = "x-" ];then
                                           $COMPRESS_PRG $TARGET_DIR/$ARC
                                           if [ "x-$VERBOSE" = "x-TRUE" ];then
                                                 echo " `date +%d-%m-%Y' '%H:%M` : $ARC moved to $TARGET_DIR and compressed" >> $LOG
                                           fi
                                     else
                                           if [ "x-$VERBOSE" = "x-TRUE" ];then
                                                 echo " `date +%d-%m-%Y' '%H:%M` : $ARC moved to $TARGET_DIR" >> $LOG
                                           fi
                                     fi ;;
                      esac
              done
          else
              echo "Warning : The filesystem is not full due to archive logs !"
              exit
          fi
    elif [ "x-$VERBOSE" = "x-TRUE" ];then
         echo "Nothing to do at `date +%d-%m-%Y' '%H:%M`" >> $LOG
    fi

  • Archive log miss : How to restart capture

    Hi Gurus,
    I configured hotlog CDC distributed on 10.2.0.4 Databases.
    I make a mistake: in my source Db I have deleted an Archive log,
    and now the state of Capture process in V_$STREAM_CAPTURE is "WAITING FOR REDO: LAST SCN MINED 930696".
    Now I'd like to restart the capture process from the next archive (just after the missed archive)
    How is it possible?
    tnk Fabio

    I'm sorry to tell you that, but it's not possible. (Just as it's not possible to recover database with missing logs...)
    You will have to recreate the capture process and to re-instantiate the replicated tables.
    Regards,

  • How to delete archive logs on the standby database....in 9i

    Hello,
    We are planning to setup a data guard (Maximum performance configuration ) between two Oracle 9i databases on two different servers.
    The archive logs on the primary servers are deleted via a RMAN job bases on a policy , just wondering how I should delete the archive logs that are shipped to the standby.
    Is putting a cron job on the standby to delete archive logs that are say 2 days old the proper approach or is there a built in data guard option that would some how allow archive logs that are no longer needed or are two days old deleted automatically.
    thanks,
    C.

    We are planning to setup a data guard (Maximum performance configuration ) between two Oracle 9i databases on two different servers.
    The archive logs on the primary servers are deleted via a RMAN job bases on a policy , just wondering how I should delete the archive logs that are shipped to the standby.
    Is putting a cron job on the standby to delete archive logs that are say 2 days old the proper approach or is there a built in data guard option that would some how allow archive logs that are no longer needed or are two days old deleted automatically.From 10g there is option to purge on deletion policy when archives were applied. Check this note.
    *Configure RMAN to purge archivelogs after applied on standby [ID 728053.1]*
    Still it is on 9i, So you need to schedule RMAN job or Shell script file to delete archives.
    Before deleting archives
    1) you need to check is all the archives are applied or not
    2) then you can remove all the archives completed before 'sysdate-2';
    RMAN> delete archvielog all completed before 'sysdate-2';
    As per your requirement.

  • Skip archive log on logical standby

    hi ,
    I want to skip archive log from nmber 1150 to 1161 on logical standby dtbs.
    I knw , we can skip ddl , dml on logical standby .
    How can archive this ??
    (oracle 10g entreprise edition )

    Hello;
    I do not believe this is an option. The closest to this would be "applying modifications to specific tables"
    See :
    9.4.3 Using DBMS_LOGSTDBY.SKIP to Prevent Changes to Specific Schema Objects
    Data Guard Concepts and Administration 10g Release 2 (10.2) B14239-05
    While this is not the answer you want the skip Archive would create a Gap and cause many other issues you don't want.
    Best Regards
    mseberg

  • Archive log generation in standby

    Dear all,
    DB: 11.1.0.7
    We are configuring physical standby for our production system.we have the same file
    system and configuration for both the servers.. now primary archive
    destination is d:/arch and the standby server also have d:/arch .Now
    archive logs are properly logged into the standby and the data is
    intact . the problem we have archive log generation proper in the
    primary arch destionation. but no archive logs are getting
    generated in the standby archive location. but archive logs are being
    applied to the standby database ?
    is this normal ?..in standby archive logs will not be generated ?
    Please guide
    Kai

    There are no standby logs should be generated on standby side. Why do you think it should. If you are talking about parameter standby_archive_dest then, if you set this parameter oracle will copy applied log to this directory, not create new one.
    in 11g oracle recomended to not use this parameter. Instead oracle recomended to set log_archive_dest_1 and log_archive_dest_3 similar to this:
    ALTER SYSTEM SET log_archive_dest_1 = 'location="USE_DB_RECOVERY_FILE_DEST", valid_for=(ALL_LOGFILES,ALL_ROLES)'
    ALTER SYSTEM SET log_archive_dest_3 = 'SERVICE=<primary_tns> LGWR ASYNC db_unique_name=<prim_db_unique_name> valid_for=(online_logfile,primary_role)'
    /

  • Archived log application to a cold backup fails with ora-00328

    I am testing backup and recovery scenario as mentioned in Metalink Doc id:69468.1 where a cold backup of one production server is restored on a separate machine. Some activity, say a table creation in some schema and insertion of rows in it is followed by a few log switches. Next I moved just the archived logs ( newly generated) to the test machine and proceed as follow to recover but log application is failing as below,any help would be appreciated!
    SQL> startup mount;
    ORACLE instance started.
    Total System Global Area 205520896 bytes
    Fixed Size 1248116 bytes
    Variable Size 71304332 bytes
    Database Buffers 130023424 bytes
    Redo Buffers 2945024 bytes
    Database mounted.
    SQL> recover database until cancel using backup controlfile;
    ORA-00279: change 581754 generated at 12/21/2007 02:35:04 needed for thread 1
    ORA-00289: suggestion :
    C:\ORACLE\PRODUCT\10.2.0\ARCHIVE\ARC00001_0641874107.001
    ORA-00280: change 581754 for thread 1 is in sequence #1
    Specify log: {<RET>=suggested | filename | AUTO | CANCEL}
    auto
    ORA-00328: archived log ends at change 581535, need later change 581754
    ORA-00334: archived log:
    'C:\ORACLE\PRODUCT\10.2.0\ARCHIVE\ARC00001_0641874107.001'
    SQL> recover database until cancel;
    ORA-00283: recovery session canceled due to errors
    ORA-01610: recovery using the BACKUP CONTROLFILE option must be done
    SQL> recover database until cancel using backup controlfile;
    ORA-00279: change 581754 generated at 12/21/2007 02:35:04 needed for thread 1
    ORA-00289: suggestion :
    C:\ORACLE\PRODUCT\10.2.0\ARCHIVE\ARC00001_0641874107.001
    ORA-00280: change 581754 for thread 1 is in sequence #1
    Specify log: {<RET>=suggested | filename | AUTO | CANCEL}
    C:\oracle\product\10.2.0\archive\ARC00001_0641874107.001
    ORA-00328: archived log ends at change 581535, need later change 581754
    ORA-00334: archived log:
    'C:\ORACLE\PRODUCT\10.2.0\ARCHIVE\ARC00001_0641874107.001'
    SQL> recover database using backup controlfile;
    ORA-00279: change 581754 generated at 12/21/2007 02:35:04 needed for thread 1
    ORA-00289: suggestion :
    C:\ORACLE\PRODUCT\10.2.0\ARCHIVE\ARC00001_0641874107.001
    ORA-00280: change 581754 for thread 1 is in sequence #1
    Specify log: {<RET>=suggested | filename | AUTO | CANCEL}
    C:\oracle\product\10.2.0\archive\ARC00001_0641874107.001
    ORA-00328: archived log ends at change 581541, need later change 581754
    ORA-00334: archived log:
    'C:\ORACLE\PRODUCT\10.2.0\ARCHIVE\ARC00001_0641874107.001'
    Please Help

    The error displayed stated you are required to have an specific sequence:
    ORA-00280: change 581754 for thread 1 is in sequence #1
    Check the contents of the v$recover_file dynamic view and verify if you really have all required archivelog files.
    ~ Madrid

  • Archive logs not applied on standby!!

    Hi Guys,
    I am trying to set up physical standby on windows 2003 server. I am using oracle 10.2.0.4.0. I get the following error in my alert file on standby
    Failed to request gap sequence
    Following is the results of some queries :
    SQL> SELECT PROCESS, STATUS, THREAD#, SEQUENCE#, BLOCK#, BLOCKS FROM V$MANAGED_STANDBY;
    PROCESS STATUS THREAD# SEQUENCE# BLOCK# BLOCKS
    ARCH CONNECTED 0 0 0 0
    ARCH CONNECTED 0 0 0 0
    ARCH CONNECTED 0 0 0 0
    ARCH CONNECTED 0 0 0 0
    ARCH CONNECTED 0 0 0 0
    ARCH CONNECTED 0 0 0 0
    ARCH CONNECTED 0 0 0 0
    ARCH CONNECTED 0 0 0 0
    ARCH CONNECTED 0 0 0 0
    ARCH CONNECTED 0 0 0 0
    MR(fg) WAIT_FOR_GAP 1 10004 0 0
    SQL> select * from v$archive_gap;
    no rows selected
    SQL> select message from v$dataguard_status;
    MESSAGE
    ARC0: Archival started
    ARC1: Archival started
    ARC2: Archival started
    ARC3: Archival started
    ARC4: Archival started
    ARC5: Archival started
    ARC6: Archival started
    ARC7: Archival started
    ARC8: Archival started
    ARC9: Archival started
    ARC0: Becoming the 'no FAL' ARCH
    MESSAGE
    ARC0: Becoming the 'no SRL' ARCH
    ARC1: Becoming the heartbeat ARCH
    Attempt to start background Managed Standby Recovery process
    MRP0: Background Managed Standby Recovery process started
    Managed Standby Recovery not using Real Time Apply
    Media Recovery Waiting for thread 1 sequence 10004
    Fetching gap sequence in thread 1, gap sequence 10004-10017
    FAL[client]: Failed to request gap sequence
    GAP - thread 1 sequence 10004-10017
    DBID 2422302575 branch 670594799
    FAL[client]: All defined FAL servers have been attempted.
    MESSAGE
    MRP0: Background Media Recovery cancelled with status 16037
    MRP0: Background Media Recovery process shutdown
    Managed Standby Recovery Canceled
    Media Recovery Start: Managed Standby Recovery
    Managed Standby Recovery not using Real Time Apply
    Media Recovery Waiting for thread 1 sequence 10004
    Fetching gap sequence in thread 1, gap sequence 10004-10017
    FAL[client]: Failed to request gap sequence
    GAP - thread 1 sequence 10004-10017
    DBID 2422302575 branch 670594799
    FAL[client]: All defined FAL servers have been attempted.
    SQL>SELECT THREAD#, SEQUENCE#, APPLIED FROM V$ARCHIVED_LOG
    where applied= 'YES'
    no rows selected
    ##Modification to primary##
    *.log_archive_dest_2='SERVICE=STANDBY'
    *.fal_client='STUTEST'
    *.fal_server='STUSTANDBY'
    *.log_archive_config='DG_CONFIG=(STUTEST,STUSTANDBY)'
    ##Modification to standby##
    *.db_unique_name='STANDBY'
    *.log_archive_dest_2='SERVICE=STANDBY'
    *.log_archive_dest_state_2='ENABLE'
    *.Fal_server=STUTEST
    *.Fal_client=STUSTANDBY
    *.db_file_name_convert='H:\ORACLE\ORADATA\STUTEST\','I:\ORACLE\ORADATA\STUTEST\s_'
    *.log_file_name_convert='D:\oracle\oradata\STUTEST\','D:\oracle\oradata\STUTEST\s_'
    Nore: I used RMAN to create the standby database. The following are brief steps
    Below are the steps to accomplish the task :
    Step 1: Backup the database that includes backup of datafiles, archivelogs and controlfile for standby
    backup current controlfile for standby;
    Step 2: Move the backups to the standby server and restore control file from backup
    Step 3: Make changes in the parameter files of both primary and standby database
    Step 4: Do the restore and recover on standby database
    Step 5: Put the standby database in recover managed mode
    Thanks for help guys!!!!!

    Hi sb92075
    Alert log on standby
    alter database mount standby database
    Mon Jul 26 14:10:40 2010
    Setting recovery target incarnation to 1
    ARCH: STARTING ARCH PROCESSES
    ARC0 started with pid=21, OS id=6708
    ARC1 started with pid=22, OS id=3892
    ARC2 started with pid=23, OS id=4380
    ARC3 started with pid=24, OS id=4896
    ARC4 started with pid=25, OS id=6348
    ARC5 started with pid=26, OS id=5868
    ARC6 started with pid=27, OS id=6904
    ARC7 started with pid=28, OS id=4428
    ARC8 started with pid=29, OS id=5008
    Mon Jul 26 14:10:40 2010
    ARC0: Archival started
    ARC9 started with pid=30, OS id=5804
    Mon Jul 26 14:10:41 2010
    ARC1: Archival started
    ARC2: Archival started
    ARC3: Archival started
    ARC4: Archival started
    ARC5: Archival started
    ARC6: Archival started
    ARC7: Archival started
    ARC8: Archival started
    ARC9: Archival started
    ARCH: STARTING ARCH PROCESSES COMPLETE
    Mon Jul 26 14:10:41 2010
    ARC0: Becoming the 'no FAL' ARCH
    ARC0: Becoming the 'no SRL' ARCH
    ARC0: Thread not mounted
    Mon Jul 26 14:10:41 2010
    Successful mount of redo thread 1, with mount id 2477113436
    Mon Jul 26 14:10:41 2010
    Physical Standby Database mounted.
    Mon Jul 26 14:10:42 2010
    ARC1: Becoming the heartbeat ARCH
    Completed: alter database mount standby database
    Mon Jul 26 14:10:42 2010
    Errors in file c:\oracle\admin\stustandby\udump\stustandby_ora_6604.trc:
    Mon Jul 26 14:11:41 2010
    alter database recover managed standby database disconnect from session
    MRP0 started with pid=19, OS id=3696
    Managed Standby Recovery not using Real Time Apply
    parallel recovery started with 7 processes
    Mon Jul 26 14:11:46 2010
    Waiting for all non-current ORLs to be archived...
    Media Recovery Waiting for thread 1 sequence 10004
    Fetching gap sequence in thread 1, gap sequence 10004-10017
    Mon Jul 26 14:11:47 2010
    Completed: alter database recover managed standby database disconnect from session
    Mon Jul 26 14:12:16 2010
    *FAL[client]: Failed to request gap sequence*
    GAP - thread 1 sequence 10004-10017
    DBID 2422302575 branch 670594799
    *FAL[client]: All defined FAL servers have been attempted.*
    Alert log on primary
    Mon Jul 26 13:50:11 2010
    db_recovery_file_dest_size of 40960 MB is 49.73% used. This is a
    user-specified limit on the amount of space that will be used by this
    database for recovery-related files, and does not reflect the amount of
    space available in the underlying filesystem or ASM diskgroup.
    Mon Jul 26 13:50:12 2010
    Successfully onlined Undo Tablespace 19.
    Mon Jul 26 13:50:12 2010
    SMON: enabling tx recovery
    Mon Jul 26 13:50:12 2010
    Database Characterset is WE8ISO8859P1
    Opening with internal Resource Manager plan
    where NUMA PG = 1, CPUs = 8
    replication_dependency_tracking turned off (no async multimaster replication found)
    Starting background process QMNC
    QMNC started with pid=38, OS id=3776
    Mon Jul 26 13:50:14 2010
    Completed: ALTER DATABASE OPEN
    Mon Jul 26 13:51:10 2010
    Shutting down archive processes
    Mon Jul 26 13:51:15 2010
    ARCH shutting down
    ARCa: Archival stopped
    Mon Jul 26 14:11:47 2010
    Redo Shipping Client Connected as PUBLIC
    -- Connected User is Valid
    *FAL[server]: DGID from FAL client not in Data Guard configuration*
    *FAL[server]: FAL request for destination STUSTANDBY was:*
    GAP - thread 1 sequence 10004-10017
    DBID 2422302575 branch 670594799
    Mon Jul 26 15:04:10 2010
    Redo Shipping Client Connected as PUBLIC
    -- Connected User is Valid
    *FAL[server]: DGID from FAL client not in Data Guard configuration*
    *FAL[server]: FAL request for destination STUSTANDBY was:*
    GAP - thread 1 sequence 10004-10017 DBID 2422302575 branch 670594799

  • ORA-00332 - archived log is too small - may be incompletely archived

    Hi, i have a problem with a physical standby database, the apply process is stoped, the databas is version 9.2.0.7.0 on Solaris 10. I received the the next errors into the alert logfile, What can i do??
    Thanks for your help.
    Regards.
    Media Recovery Waiting for thread 1 seq# 16958 (in transit)
    Media Recovery Log /dbf/dbnte01/oralogs/archivelogs/dbnte01_1_16958.dbf
    Media Recovery Waiting for thread 1 seq# 16959 (in transit)
    Media Recovery Log /dbf/dbnte01/oralogs/archivelogs/dbnte01_1_16959.dbf
    Media Recovery Waiting for thread 1 seq# 16960 (in transit)
    Media Recovery Log /dbf/dbnte01/oralogs/archivelogs/dbnte01_1_16960.dbf
    Fri Aug 24 06:57:37 2007
    Media Recovery Waiting for thread 1 seq# 16961 (in transit)
    Fri Aug 24 16:51:51 2007
    RFS: Possible network disconnect with primary database
    Closing latent archivelog for thread 1 sequence 16961
    EOF located at block 102401 low SCN 1510:-1868154783 next SCN 1510:-1868154783
    Latent archivelog '/dbf/dbnte01/oralogs/archivelogs/dbnte01_1_16961.dbf'
    If you wish to failover to this standby database, you should use the
    following command to manually register the archivelog for recovery:
    ALTER DATABASE REGISTER LOGFILE '/dbf/dbnte01/oralogs/archivelogs/dbnte01_1_16961.dbf';
    Fri Aug 24 16:51:51 2007
    Errors in file /sfw/oracle/admin/dbnte01/udump/stnte01_rfs_15414.trc:
    ORA-00367: checksum error in log file header
    ORA-00332: archived log is too small - may be incompletely archived
    ORA-00334: archived log: '/dbf/dbnte01/oralogs/archivelogs/dbnte01_1_16961.dbf'
    ORA-12161: TNS:internal error: partial data received
    Fri Aug 24 18:58:05 2007
    Fetching gap sequence for thread 1, gap sequence 16961-16961
    Trying FAL server: (DESCRIPTION=(ADDRESS_LIST = (ADDRESS=(PROTOCOL=tcp)(HOST=sunvk05)(PORT=1521)))(CONNECT_DATA=(SID=dbnte01)(SERVER
    =DEDICATED)))
    Fri Aug 24 19:03:40 2007
    Failed to request gap sequence. Thread #: 1, gap sequence: 16961-16961
    All FAL server has been attempted.
    Fri Aug 24 21:07:24 2007
    Shutting down instance: further logons disabled
    Fri Aug 24 21:07:30 2007
    MRP0: Background Media Recovery user canceled with status 16037
    Recovery interrupted.

    Somehow your archivelog file got corrupted and it was not possible to apply it to the stand by database, check if the requested sequence still exists on the active database and apply it manually.
    ~ Madrid

  • Standby database is not applying redo logs due to missing archive log

    We use 9.2.0.7 Oracle Database. My goal is to create a physical standby database.
    I have followed all the steps necessary to fulfill this in Oracle Data Guard Concepts and Administration manual. Archived redo logs are transmitted from primary to standby database regularly. But the logs are not applied due to archive log gap.
    SQL> select process, status from v$managed_standby;
    PROCESS STATUS
    ARCH CONNECTED
    ARCH CONNECTED
    MRP0 WAIT_FOR_GAP
    RFS RECEIVING
    RFS ATTACHED
    SQL> select * from v$archive_gap;
    THREAD# LOW_SEQUENCE# HIGH_SEQUENCE#
    1 503 677
    I have tried to find the missing archives on the primary database, but was unable to. They have been deleted (somehow) regularly by the existing backup policy on the primary database. I have looked up the backups, but these archive logs are too old to be in the backup. Backup retention policy is 1 redundant backup of each file. I didn't save older backups as I didn't really need them from up to this point.
    I have cross checked (using rman crosscheck) the archive log copies on the primary database and deleted the "obsolete" copies of archive logs. But, v$archived_log view on the primary database only marked those entries as "deleted". Unfortunately, the standby database is still waiting for those logs to "close the gap" and doesn't apply the redo logs at all. I am reluctant to recreate the control file on the primary database as I'm afraid this occurred through the regular database backup operations, due to current backup retention policy and it probably might happen again.
    The standby creation procedure was done by using the data files from 3 days ago. The archive logs which are "producing the gap" are older than a month, and are probably unneeded for standby recovery.
    What shall I do?
    Kind regards and thanks in advance,
    Milivoj

    On a physical standby database
    To determine if there is an archive gap on your physical standby database, query the V$ARCHIVE_GAP view as shown in the following example:
    SQL> SELECT * FROM V$ARCHIVE_GAP;
    THREAD# LOW_SEQUENCE# HIGH_SEQUENCE#
    1 7 10
    The output from the previous example indicates your physical standby database is currently missing log files from sequence 7 to sequence 10 for thread 1.
    After you identify the gap, issue the following SQL statement on the primary database to locate the archived redo log files on your primary
    database (assuming the local archive destination on the primary database is LOG_ARCHIVE_DEST_1):
    SQL> SELECT NAME FROM V$ARCHIVED_LOG WHERE THREAD#=1 AND DEST_ID=1 AND 2> SEQUENCE# BETWEEN 7 AND 10;
    NAME
    /primary/thread1_dest/arcr_1_7.arc /primary/thread1_dest/arcr_1_8.arc /primary/thread1_dest/arcr_1_9.arc
    Copy these log files to your physical standby database and register them using the ALTER DATABASE REGISTER LOGFILE statement on your physical standby database. For example:
    SQL> ALTER DATABASE REGISTER LOGFILE
    '/physical_standby1/thread1_dest/arcr_1_7.arc';
    SQL> ALTER DATABASE REGISTER LOGFILE
    '/physical_standby1/thread1_dest/arcr_1_8.arc';
    After you register these log files on the physical standby database, you can restart Redo Apply.
    Note:
    The V$ARCHIVE_GAP fixed view on a physical standby database only returns the next gap that is currently blocking Redo Apply from continuing. After resolving the gap and starting Redo Apply, query the V$ARCHIVE_GAP fixed view again on the physical standby database to determine the next gap sequence, if there is one. Repeat this process until there are no more gaps.
    Restoring the archived logs from the backup set
    If the archived logs are not available in the archive destination then at that time we need to restore the required archived logs from the backup step. This task is accomplished in the following way.
    To restore range specified archived logs:
    Run {
    Set archivelog destination to '/oracle/arch/arch_restore'
    Restore archivelog from logseq=<xxxxx> until logseq=<xxxxxxx>
    To restore all the archived logs:
    Run {
    Set archivelog destination to '/oracle/arch/arch_restore';
    Restore archivelog all;
    }

Maybe you are looking for

  • How do I format a 2008 macbook pro

    I am getting a new Macbook Pro and want to give my 2008 to my grandson. I have the original Macbook Pro OSX disks (2), but had upgraded to Leopard and then to Lion. Lion is the current OS, but that was a download. I no longer have the Leopord disk as

  • How do I install "Apple Mobile Device", how do I install "Apple Mobile Device"

    I am trying to move my iPod library (all CD's I have downloaded to iPod) to my iphone but it is telling me "iphone cannot be used because the Apple Mobile Device is not installed"  yet there are no instructions on how to do that.  No icon appears whe

  • My cd burning doesn´t work

    Suddenly my burning device doesn´t work, it appears some errors but I can read music cds..What can I do?

  • IPhone 4s 'ringer' icon stays on the screen and i can't get rid of it..?

    Hi, I have the new iPhone 4s but am finding that the mute o'ringer' icon stays on the screen and i can't get rid of it..! Which means it overshadows anything you are doing. Any ideas how to get rid of it? I have tried holding on/off and home button b

  • VO4 Error - not again....

    3 months after having my VO4 problems fixed, like a bad smell - its back ! Took BT two weeks to sort last time due to alleged "faults on the line"... Anyway reset the hub by the standard buttion, the concealed reset button and by the power socket - a