Logical standby on 9i stalls

hello.
Has anyone ever seen this or knows how to resolve it?...
I created a logical standby database which works at the beginning. All ddl and dml gets propagated until I try a shutdown of the primary. When I bring back the primary, archive logs are still being sent correctly to standby, but standby stalls. SELECT APPLIED_SCN, NEWEST_SCN FROM DBA_LOGSTDBY_PROGRESS shows no progress for applied_scn.
CPU is at 100% by a one of the Parallel Query processes. I don't see any locks being held on any objects. looking at the v$sqlarea, the following query generates an enormous and constantly growing rows_processed also parse and execute requests are huge and growing as well. It seems that this process is stuck in an infinite loop running this query (I gave it 2 days - no change). This query is also at the bottom of the lsp trace log. I tried a different machine for a standby - same problem. couldn't find anything on metalink or any documentation.
thanks,
Henry
offending query:
ELECT C.SEGCOL#, C.INTCOL#, C.COLNAME, C.TYPE#, C.LENGTH, C.PRECISION,
C.SCALE, C.Interval_Leading_Precision,
C.Interval_Trailing_Precision, C.PROPERTY,
C.CHARSETID, C.CHARSETFORM
FROM SYSTEM.LOGMNRC_GTCS C
WHERE C.LOGMNR_UID = :Logminer_ID
     AND C.OBJV# = :ObjVersion
     AND C.OBJ# = :ObjNum
ORDER BY C.SEGCOL#
alert log:
Fri Dec 17 18:08:50 2004
WARNING: the following transaction makes no progress
WARNING: in the last 300 seconds for the given message!
WARNING: xid =
0x0008.012.00000283 cscn = 5835031, message# = 2, slavid = 1
lsp trace:
*** 2004-12-17 18:13:53.263
WARNING: the following transaction makes no progress
WARNING: in the last 300 seconds for the given message!
WARNING: xid = 0x0008.012.00000283 cscn = 5835031, message# = 2, slavid = 1
KNACDMP: *******************************************************
KNACDMP: Dumping apply coordinator's context at efffe9a8
KNACDMP: Apply Engine # 0
KNACDMP: Apply Engine name
KNACDMP: Coordinator's Watermarks ------------------------------
KNACDMP: Apply High Watermark = 0x0000.00590901
KNACDMP: Apply Low Watermark = 0x0000.00590901
KNACDMP: Fetch Low Watermark = 0x0000.00590934
KNACDMP: Oldest SCN = 0x0000.00590874
KNACDMP: Last replicant syncpoint SCN = 0x0000.00000000
KNACDMP: Last syncpoint at primary SCN = 0x0000.00590901
KNACDMP: First partition max SCN = 0x0000.005a89e7
KNACDMP: Last partition max SCN = 0x0000.005a89e7
KNACDMP: Last processed SCN = 0x0000.00590901
KNACDMP: Coordinator's constants -------------------------------
KNACDMP: number of apply slaves = 5
KNACDMP: safety level (K) = 1
KNACDMP: max txns in memory = 40000
KNACDMP: max constraints per table = 119
KNACDMP: hash table size (in entries) = 40000
KNACDMP: Coordinator's intervals -------------------------------
KNACDMP: syncpoint interval (ms) = 0
KNACDMP: write low watermark interval(ms)= 1
KNACDMP: Coordinator's timers/counters -------------------------
KNACDMP: current time = 1103336032
KNACDMP: low watermark timer = 0
KNACDMP: shutdown counter = 1
KNACDMP: syncpoint timer = 1103335430
KNACDMP: Coordinator's State/Flags -----------------------------
KNACDMP: Coordinator's State = KNACST_APPLY_UNTIL_END
KNACDMP: Coordinator's Flags = 4
KNACDMP: Slave counts ------------------------------------------
KNACDMP: number of reserved slaves = 0
KNACDMP: number of admin slaves = 0
KNACDMP: number of slaves in wait cmt = 3
KNACDMP: number of safe slaves = 4
KNACDMP: Slave Lists -------------------------------------------
KNACDMP: Dumping All Slaves :-
Slave id = 0, State = 8, Flags = 0, Not Assigned
Slave id = 1, State = 5, Flags = 1, Assigned Xid = 0x0008.012.00000283
Slave id = 2, State = 6, Flags = 3, Assigned Xid = 0x0009.003.0000028a
Slave id = 3, State = 6, Flags = 3, Assigned Xid = 0x0003.02d.0000028b
Slave id = 4, State = 7, Flags = 3, Assigned Xid = 0x0009.022.00000289
Slave id = 5, State = 0, Flags = 0, Not Assigned
KNACDMP: End dumping all slaves
KNACDMP: syncdep slaves = { 2 3 }
KNACDMP: cont chunk slaves = { }
KNACDMP: cont slaves = { }
KNACDMP: exec txn slaves = { }
KNACDMP:Idle slaves (1) ={ 5 }
KNACCPD: *******************************************************
v$lock information for this slave is:
type:PS, id1:1, id2:4, lmode:4, request:0
type:SR, id1:1, id2:0, lmode:4, request:0
Current SQL for this slave is:
SELECT C.SEGCOL#, C.INTCOL#, C.COLNAME, C.TYPE#, C.LENGTH, C.PRE
CISION, C.SCALE, C.Interval_Leading_Precision,
C.Interval_Trailing_Precision, C.PROPERTY, C.CHARSE
TID, C.CHARSETFORM FROM SYSTEM.LOGMNRC_GTCS C WHERE
C.LOGMNR_UID = :Logminer_ID AND C.OBJV# = :ObjVersio
n AND C.OBJ# = :ObjNum ORDER BY C.SEGC
OL#
KNACCPD: end ***************************************************

Check following doc for procedure to set up a logical standby database
Creating a Logical Standby Database

Similar Messages

  • Logical standby stopped lastnight

    Subject: Logical standby stopped lastnight
    Author: raghavendra rao yella, United States
    Date: Nov 14, 2007, 0 minutes ago
    Os info: solaris 5.9
    Oracle info: 10.2.0.3
    Error info: ORA-16120: dependencies being computed for transaction at SC
    N 0x0002.c8f6f182
    Message: Our logical standby stopped last night. we tried to stop and start the standby but no help.
    Below are some of the queries to get the status:
    APPLIED_SCN LATEST_SCN MINING_SCN RESTART_SCN
    11962328446 11981014649 11961580453 11961536228
    APPLIED_TIME LATEST_TIME MINING_TIME RESTART_TIME
    07-11-13 09:09:41 07-11-14 10:26:26 07-11-13 08:57:53 07-11-13 08:56:36
    sys@RP06>SELECT TYPE, HIGH_SCN, STATUS FROM V$LOGSTDBY;
    TYPE HIGH_SCN STATUS
    COORDINATOR 1.1962E+10 ORA-16116: no work available
    READER 1.1962E+10 ORA-16127: stalled waiting for additional transact
    ions to be applied
    BUILDER 1.1962E+10 ORA-16127: stalled waiting for additional transact
    ions to be applied
    PREPARER 1.1962E+10 ORA-16127: stalled waiting for additional transact
    ions to be applied
    ANALYZER 1.1962E+10 ORA-16120: dependencies being computed for transac
    tion at SCN 0x0002.c8f6c002
    APPLIER ORA-16116: no work available
    APPLIER ORA-16116: no work available
    APPLIER ORA-16116: no work available
    APPLIER ORA-16116: no work available
    APPLIER ORA-16116: no work available
    10 rows selected.
    Select PID,
    TYPE,
    STATUS
    From
    V$LOGSTDBY
    Order by
    HIGH_SCN; 2 3 4 5 6 7 8
    PID TYPE STATUS
    17896 ANALYZER ORA-16120: dependencies being computed for transaction at SC
    N 0x0002.c8f6f182
    17892 PREPARER ORA-16127: stalled waiting for additional transactions to be
    applied
    17890 BUILDER ORA-16243: paging out 8144 bytes of memory to disk
    17888 READER ORA-16127: stalled waiting for additional transactions to be
    applied
    28523 COORDINATOR ORA-16116: no work available
    17904 APPLIER ORA-16116: no work available
    17906 APPLIER ORA-16116: no work available
    17898 APPLIER ORA-16116: no work available
    17900 APPLIER ORA-16116: no work available
    17902 APPLIER ORA-16116: no work available
    10 rows selected.
    How can i get this transaction information, which log miner is looking for dependencies?
    Let me know if you have any questions.
    Thanks in advance.
    Message was edited by:
    raghu559

    Hi reega,
    Thanks for your reply, our logical stdby has '+RT06_DATA/RT06'
    and primary has '+OT06_DATA/OT06TSG001'
    so we are using db_file_name_convert init parameter but it doesn't work.
    Is there any thing particular steps hiding to use this parameter? as i tried this parameter for rman cloning it din't work, as a workaround i used rman set new name command for clonning.
    Let me know if you have any questions.
    Thanks in advance.

  • How to apply the changes in logical standby database

    Hi,
    I am new to Dataguard. I am now using 10.2.0.3 and followed the steps from Oracle Data Guard Concepts and Administration Guide to setup a logical standby database.
    When I insert a record to a table from the primary database side, when i query the same table from the logical standby database, it doesn't show the new records.
    Did I miss something? What I want to do is when I insert a record in the primary db, then the corresponding record will be inserted in the standby db.
    Or I totally misunderstand what Oracle data guard is? Any help are appreciated.
    Denis

    Hi
    Can anyone help to answer me is my logical standby db have a archive gap?
    SQL> SELECT APPLIED_SCN, APPLIED_TIME, READ_SCN, READ_TIME, NEWEST_SCN, NEWEST_T
    IME FROM DBA_LOGSTDBY_PROGRESS;
    APPLIED_SCN APPLIED_TIME READ_SCN READ_TIME NEWEST_SCN
    NEWEST_TIME
    851821 29-JUL -08 17:58:29 851822 29-JUL -08 17:58:29 1551238
    08-AUG -08 08:43:29
    SQL> select pid, type, status, high_scn from v$logstdby;
    no rows selected
    SQL> alter database start logical standby apply;
    Database altered.
    SQL> select pid, type, status, high_scn from v$logstdby;
    PID
    TYPE
    STATUS HIGH_SCN
    2472
    COORDINATOR
    ORA-16116: no work available
    3380
    READER
    ORA-16127: stalled waiting for additiona 852063
    l transactions to be applied
    2480
    BUILDER
    ORA-16116: no work available
    2492
    ANALYZER
    ORA-16111: log mining and apply setting
    up
    2496
    APPLIER
    ORA-16116: no work available
    2500
    APPLIER
    ORA-16116: no work available
    3700
    APPLIER
    ORA-16116: no work available
    940
    APPLIER
    ORA-16116: no work available
    2504
    APPLIER
    ORA-16116: no work available
    9 rows selected.
    Thanks a lot.
    Message was edited by:
    Denis Chan

  • [Logical Standby] Which table/SQL caused paging-out

    We have a Primary-Logical DR configuration.
    Recently, it has a problem with the logical: it's continuously paging out data from some transactions:
    SELECT SUBSTR(name, 1, 40) AS NAME, SUBSTR(value,1,32) AS VALUE FROM GV$LOGSTDBY_STATS;
    number of preparers     3
    number of appliers     18
    maximum SGA for LCR cache     4095
    parallel servers in use     24
    maximum events recorded     1000000
    preserve commit order     TRUE
    transaction consistency     FULL
    record skip errors     Y
    record skip DDL     Y
    record applied DDL     N
    record unsupported operations     Y
    coordinator state     IDLE
    transactions ready     7
    transactions applied     0
    coordinator uptime     9646
    realtime logmining     Y
    apply delay     0
    Log Miner session ID     1
    txns delivered to client     1068651
    DML txns delivered     1017135
    DDL txns delivered     15
    CTAS txns delivered     0
    Recursive txns delivered     51501
    Rolled back txns seen     23463
    LCRs delivered to client     11682189
    bytes of redo processed     14475529508
    bytes paged out     1482524624
    seconds spent in pageout     8922
    bytes checkpointed     0
    seconds spent in checkpoint     0
    bytes rolled back     7500032
    seconds spent in rollback     90
    seconds system is idle     0
    SELECT SID, SERIAL#, SPID, TYPE, HIGH_SCN, STATUS_CODE, STATUS
    FROM GV$LOGSTDBY_PROCESS
    ORDER BY TYPE, SPID;
    ANALYZER     16116     ORA-16116: no work available
    APPLIER     16116     ORA-16116: no work available
    APPLIER     16116     ORA-16116: no work available
    APPLIER     16116     ORA-16116: no work available
    APPLIER     16116     ORA-16116: no work available
    APPLIER     16116     ORA-16116: no work available
    APPLIER     16116     ORA-16116: no work available
    APPLIER     16116     ORA-16116: no work available
    APPLIER     16116     ORA-16116: no work available
    APPLIER     16116     ORA-16116: no work available
    APPLIER     16116     ORA-16116: no work available
    APPLIER     16116     ORA-16116: no work available
    APPLIER     16116     ORA-16116: no work available
    APPLIER     16116     ORA-16116: no work available
    APPLIER     16116     ORA-16116: no work available
    APPLIER     16116     ORA-16116: no work available
    APPLIER     16116     ORA-16116: no work available
    APPLIER     16116     ORA-16116: no work available
    APPLIER     16116     ORA-16116: no work available
    BUILDER     16243     ORA-16243: paging out 4752 bytes of memory to disk
    COORDINATOR     16116     ORA-16116: no work available
    PREPARER     16127     ORA-16127: stalled waiting for additional transactions to be applied
    PREPARER     16127     ORA-16127: stalled waiting for additional transactions to be applied
    PREPARER     16127     ORA-16127: stalled waiting for additional transactions to be applied
    READER     16127     ORA-16127: stalled waiting for additional transactions to be applied
    select xidusn, xidslt, xidsqn, count(*) from system.logmnr_spill$
    group by xidusn, xidslt, xidsqn;
    996     46     249     254
    710     37     838     825
    623     3     706     254
    478     7     42564     254
    765     38     649     824
    42     6     415494     3729
    264     35     4817     3738
    How can we identify the table/SQL to skip & instantiate it later so the logical DB will not being lag far behind.
    Thank you.

    Hi,
    Best way to find SQL is to mine the current archive log getting applied on standby and check for the SQL, you might not get the exact SQL, but you will get the object which is getting updated.
    Or
    You can use AWR report from logical standby of this time to find the update statement which is resource extensive.
    There is no way to find the exact SQL on primary which is causing the issue on standby.
    Regards
    Anudeep

  • Logical Standby Apply became TOO SLOW !!

    Hi,
    I recently have setup a logical standby database. Everything was fine until the apply procedure on the standby became too slow:
    SQL> alter session set nls_date_format = 'HH24:MI:SS (MM/DD)';
    Session altered.
    SQL> SELECT APPLIED_SCN, APPLIED_TIME, READ_SCN, READ_TIME, NEWEST_SCN, NEWEST_TIME FROM DBA_LOGSTDBY_PROGRESS;
    APPLIED_SCN APPLIED_TIME READ_SCN READ_TIME NEWEST_SCN
    NEWEST_TIME
    3036960310 18:33:28 (05/31) 3035938077 18:12:43 (05/31) 3060387972
    16:30:16 (06/02)
    SQL>
    The applied time changed about 20 minutes during last 46 hours. v$logstdby says:
    COORDINATOR: ORA-16116: no work available
    READER, BUILDER and PREPARER: ORA-16127: stalled waiting for additional transactions to be applied
    All APPLIERs: ORA-16116: no work available
    I really don't have any idea about this issue. Any help will be appreciated.
    regards

    One reason could be the SQL Apply engine performs too many slow full table scans, check metalink note:
    Determining if SQL Apply Engine is Performing Full Table Scans
    Doc ID: Note:255958.1
    If this is the reason for the slowness you have to tune your DML statements.
    Werner

  • Bytes paged out Logical standby (urgent!!!!!)

    Hi,
    We are having  a 3 node  LOGICAL STANDBY RAC ,it is continuoulsly  paging out bytes to disk.
    SQl > select from v$logstdby_stats;*
    NAME     VALUE
    number of preparers     2
    number of appliers     27
    maximum SGA for LCR cache     3072
    parallel servers in use     32
    maximum events recorded     100
    preserve commit order     FALSE
    transaction consistency     NONE
    record skip errors     Y
    record skip DDL     Y
    record applied DDL     N
    record unsupported operations     N
    coordinator state     IDLE
    transactions ready     0
    transactions applied     0
    coordinator uptime     10848
    realtime logmining     Y
    apply delay     0
    Log Miner session ID     1
    txns delivered to client     3425760
    DML txns delivered     3315152
    DDL txns delivered     1072
    CTAS txns delivered     153
    Recursive txns delivered     109536
    Rolled back txns seen     4226
    LCRs delivered to client     20249373
    bytes of redo processed     29038698292
    bytes paged out     4482430016
    seconds spent in pageout     8677
    bytes checkpointed     0
    seconds spent in checkpoint     0
    bytes rolled back     0
    seconds spent in rollback     7
    seconds system is idle     0
    SQL > SELECT TYPE, HIGH_SCN, STATUS FROM V$LOGSTDBY;
    TYPE     HIGH_SCN     STATUS
    COORDINATOR     61551734060     ORA-16116: no work available
    READER     61551732712     ORA-16127: stalled waiting for additional transactions to be applied
    BUILDER     61551732695     ORA-16243: paging out 607512 bytes of memory to disk
    PREPARER     61551732695     ORA-16127: stalled waiting for additional transactions to be applied
    PREPARER     61551732692     ORA-16127: stalled waiting for additional transactions to be applied
    ANALYZER     61551732694     ORA-16116: no work available
    APPLIER          ORA-16116: no work available
    APPLIER          ORA-16116: no work available
    APPLIER          ORA-16116: no work available
    APPLIER          ORA-16116: no work available
    APPLIER          ORA-16116: no work available
    APPLIER          ORA-16116: no work available
    APPLIER          ORA-16116: no work available
    APPLIER          ORA-16116: no work available
    APPLIER          ORA-16116: no work available
    APPLIER          ORA-16116: no work available
    APPLIER          ORA-16116: no work available
    APPLIER          ORA-16116: no work available
    APPLIER          ORA-16116: no work available
    APPLIER          ORA-16116: no work available
    APPLIER          ORA-16116: no work available
    APPLIER          ORA-16116: no work available
    APPLIER          ORA-16116: no work available
    APPLIER          ORA-16116: no work available
    APPLIER          ORA-16116: no work available
    APPLIER          ORA-16116: no work available
    APPLIER          ORA-16116: no work available
    APPLIER          ORA-16116: no work available
    APPLIER          ORA-16116: no work available
    APPLIER          ORA-16116: no work available
    APPLIER          ORA-16116: no work available
    APPLIER          ORA-16116: no work available
    APPLIER          ORA-16116: no work available
    The main issue is LogMiner is busy mining 1 logfile(512mb) from last 6 hrs and the value of " bytes paged out" is continuoulsy increasing and many log switches are happening on the logical standby but still no new transactions are getting applied on logical standby .
    we took an AWR report for the given period and found that no SQL were being fired upon...but still generatiing archives of 512mb each .
    Database version :- 10.2.0.2 RAC
    OS : Solaris 10
    Kindly help me to resolve this issue?????????
    Edited by: user8974795 on Sep 26, 2011 2:15 AM

    Hi,
    please execute the following steps:
    1. Copy the partially corrupted file over from primary.
    2. Re-register the logfile if needed.
    alter database register or replace logical logfile 'xxxxxxxxxxxxx';
    3. Restart Logical Apply

  • Creating a new schema in a Logical Standby Database

    Hi All,
    I am experimenting with logical standby databases for the purpose of reporting, and have not been able to create a new schema in the logical standby database - one of the key features of logical standbys.
    I have setup primary and logical standby databases, and they seem to be running just fine - changes are moved from the primary to the standby and queries on the standby seem to run ok.
    However, If I try to create a new schema on the logical standby, that does not exist on the primary, I get "ORA-01031: insufficient privileges" errors when I try to create new objects.
    Show below are the steps I have taken to create the new schema on the logical standby. Any help would be greatly appreciated.
    SYS@UATDR> connect / as sysdba
    Connected.
    SYS@UATDR>
    SYS@UATDR> select name, log_mode, database_role, guard_status, force_logging, flashback_on, db_unique_name
    2 from v$database
    3 /
    NAME LOG_MODE DATABASE_ROLE GUARD_S FOR FLASHBACK_ON DB_UNIQUE_NAME
    UATDR ARCHIVELOG LOGICAL STANDBY ALL YES YES UATDR
    SYS@UATDR>
    SYS@UATDR> create tablespace ts_new
    2 /
    Tablespace created.
    SYS@UATDR>
    SYS@UATDR> create user new
    2 identified by new
    3 default tablespace ts_new
    4 temporary tablespace temp
    5 quota unlimited on ts_new
    6 /
    User created.
    SYS@UATDR>
    SYS@UATDR> grant connect, resource to new
    2 /
    Grant succeeded.
    SYS@UATDR> grant unlimited tablespace, create table, create any table to new
    2 /
    Grant succeeded.
    SYS@UATDR>
    SYS@UATDR> -- show privs given to new
    SYS@UATDR> select * from dba_sys_privs where grantee='NEW'
    2 /
    GRANTEE PRIVILEGE ADM
    NEW CREATE ANY TABLE NO
    NEW CREATE TABLE NO
    NEW UNLIMITED TABLESPACE NO
    SYS@UATDR>
    SYS@UATDR> -- create objects in schema
    SYS@UATDR> connect new/new
    Connected.
    NEW@UATDR>
    NEW@UATDR> -- prove ability to create tables
    NEW@UATDR> create table new
    2 (col1 number not null)
    3 tablespace ts_new
    4 /
    create table new
    ERROR at line 1:
    ORA-01031: insufficient privileges
    NEW@UATDR>
    NEW@UATDR>

    HI Daniel,
    I appreciate your quick response.
    My choice of name may not have been ideal, however changing new to another name - like gav - does not solve the problem.
    SYS@UATDR> connect / as sysdba
    Connected.
    SYS@UATDR>
    SYS@UATDR> select name, log_mode, database_role, guard_status, force_logging, flashback_on, db_unique_name
    2 from v$database
    3 /
    NAME LOG_MODE DATABASE_ROLE GUARD_S FOR FLASHBACK_ON DB_UNIQUE_NAME
    UATDR ARCHIVELOG LOGICAL STANDBY ALL YES YES UATDR
    SYS@UATDR>
    SYS@UATDR> create tablespace ts_gav
    2 /
    Tablespace created.
    SYS@UATDR>
    SYS@UATDR> create user gav
    2 identified by gav
    3 default tablespace ts_gav
    4 temporary tablespace temp
    5 quota unlimited on ts_gav
    6 /
    User created.
    SYS@UATDR>
    SYS@UATDR> grant connect, resource to gav
    2 /
    Grant succeeded.
    SYS@UATDR> grant unlimited tablespace, create table, create any table to gav
    2 /
    Grant succeeded.
    SYS@UATDR>
    SYS@UATDR> -- show privs given to gav
    SYS@UATDR> select * from dba_sys_privs where grantee='GAV'
    2 /
    GRANTEE PRIVILEGE ADM
    GAV CREATE TABLE NO
    GAV CREATE ANY TABLE NO
    GAV UNLIMITED TABLESPACE NO
    SYS@UATDR>
    SYS@UATDR> -- create objects in schema
    SYS@UATDR> connect gav/gav
    Connected.
    GAV@UATDR>
    GAV@UATDR> -- prove ability to create tables
    GAV@UATDR> create table gav
    2 (col1 number not null)
    3 tablespace ts_gav
    4 /
    create table gav
    ERROR at line 1:
    ORA-01031: insufficient privileges
    GAV@UATDR>

  • Logical standby and Primary keys

    Hi All,
    Why primary keys are essential for creating logical standby database? I have created a logical standby database on testing basis without having primary keys on most of the tables and it's working fine. I have not event put my main DB in force logging mode.

    I have not event put my main DB in force logging mode. This is because, redo log files or standby redo logfiles transforms into set of sql statements to update logical standby.
    Have you done any DML operations with nologging options and do you notice any errors in the alert.log? I just curious to know.
    But I wanted to know that, while system tablespace in hot backup mode,In the absence of both a primary key and a nonnull unique constraint/index, all columns of bounded size are logged as part of the UPDATE statement to identify the modified row. In other words, all columns except those with the following types are logged: LONG, LOB, LONG RAW, object type, and collections.
    Jaffar

  • Logical standby and truncate partition

    Hi,
    I'm evaluation whether a logical standby database would meet our needs.
    We have a live database and want a reporting database that is identical to the live one, just minutes behind in time to the live one, plus we want to create other summary tables etc on the reporting db.
    Logical standby seems to meet our needs but I have one query.
    - On the live db the most of the tables are organized by date partitions and only 5 days are kept with new partitions being created every night for the forthcoming days and the oldest date partitions being truncated.
    On the reporting database we want to keep 30 days partitions.
    Can we have all the DDL and DML from live being applied to the standby APART from the specific truncate partition statements?
    Many Thanks,
    Kailas

    Addendum.
    If you can , it is better to truncate the partition but not drop it, after exporting the partition for archive purposes. If you ever need to bring the data back, the data will go into the correct partition . If the table structure has been changed by adding or lengthening columns, this will still work OK where column names match.
    Test ease of restoration of archived data to existing and non-existing partitions with altered structure (dropped columns,added columns, renamed columns) for yourself though.
    Regards, Vin.
    PS. When splitting maxdata partition to create new 'highest' partition, use a small initial extent then the 'next' being the expected real size needed. When the partition is truncated, the only space that should remain un-claimable will be that allocated for the initial extent.

  • Logical Standby Database in NOARCHIVE Mode

    Hi,
    I have configured a Logical Standby Database for Reporting purposes. A Physical Standby Database is running for MAA. i.e. in case of Role Transition (switch/Failover) the Physical Stdby Db will get the role of the Primary.
    The logical standby database is creating a lot of Archive Redologs files, nearly every minute. Redolog files are 50MB and there is no work done in db during the time. I'm NOT using Standby Redolog files.
    Is there a need for logical standby database to be in NOARCHIVELOG mode? The Primary is definatley in ARCHIVELOG mode.
    Thanks for any responses.
    regards
    Sahba

    hi,
    well there are two things to the above:-
    1. there was an archive file nearly every minute:
    this is due to a db recovery. for some reason, the db was in inconsistent state, after a sudden shutdownof the OS. I was on a test environment, on windows vista, unfortunately. unimportant ... a reboot solved it.
    2. Logical standby db in NOARCHIVE MODE when setup for the purpose of Reporting.
    As long as the MAA configured for the primary db, such as physical standby db, and a second, the logical standby db setup purely for the purpose of reporting, which then can run with NOARCHIVELOG mode, after converting the physical standby db to logical.
    logical standby db uses Streams architecture, so this method brings cost, time and performance advantages to the customer.
    regards
    Sahba

  • Best practice on using Flashback and Logical Standby

    Hello,
    I'm testing a fail-back scenario where I first need to activate a logical standby, then do some dummy transactions before I flashback this db and resme the redo apply. Here is what the steps look like:
    1)     Ensure logical standby is in-sync with primary
    2)     Enable flashback on standby
    3)     Create a flashback guaranteed restore point
    4)     Defer log shipping from primary
    5)     Activate the logical standby so it’s fully open to read-write
    6)     Dummy activities against the standby (which is now fully open)
    7)     Flashback the database to the guaranteed checkpoint
    8)     Resume log shipping on primary
    9)     Resume redo apply on secondary
    In the end, i can see the log shipping is happening but the logical standby does not apply any of these..and there is no error in the alert log on Standby side. But the following query could explains why the standby is idle:
    SELECT TYPE, HIGH_SCN, STATUS FROM V$LOGSTDBY;
    TYPE HIGH_SCN STATUS
    COORDINATOR ORA-16240: Waiting for log file (thread# 2, sequence# 0)
    ORA-16240: Waiting for log file (thread# string, sequence# string)
    Cause: Process is idle waiting for additional log file to be available.
    Action: No action necessary. This informational statement is provided to record the event for diagnostic purposes.
    I dont understand why it's looking for sequence #0 after the flashback.
    Thanks for the help.

    Hello;
    I hesitate to answer your question because you are not doing a good job of keeping the forum clean :
    Total Questions: 13 (13 unresolved)
    Please consider closing some of you old answered questions and rewarding those who helped you.
    No action necessary.
    Do you really have a thread 2? ( Redo thread number )
    Quick check
    select applied_scn,latest_scn from v$logstdby_progress;Use the DBA_LOGSTDBY_LOG View if you don't have a thread 2 then the sequence# is meaningless.
    COLUMN DICT_BEGIN FORMAT A10;
    SELECT FILE_NAME, SEQUENCE#, FIRST_CHANGE#, NEXT_CHANGE#,
    TIMESTAMP, DICT_BEGIN, DICT_END, THREAD# AS THR# FROM DBA_LOGSTDBY_LOG
    ORDER BY SEQUENCE#;Logical Standby questions are difficult, not a lot of them out there I'm thinking.
    Check
    http://docs.oracle.com/cd/E14072_01/server.112/e10700/manage_ls.htm
    "Waiting On Gap State" ( However I still believe you don't have a 2nd thread# )
    OR
    http://psilt.wordpress.com/2009/04/29/simple-logical-standby/
    Best Regards
    mseberg
    Edited by: mseberg on Apr 26, 2012 5:13 PM

  • Logical standby in noarchive mode

    Hello,
    does anybody know if it is possible to run a logical standby (10gR2) in noarchivelog mode?
    For my understanding it should be possible, why not... But I can't find a piece of documentation which prove this.
    Thanks in advance,
    Boris...

    I also was curious if setting up a Logical Standby in noarchivelog mode was possible. It looks like it is...
    We use this simply as a reporting copy of our data. Our analysts do not change any of this data. They just need it to be fairly current (~3 days). At this point, there isn't any need to generate archivelogs so we want to disable the feature to minimize our maintenance and our storage requirements.
    STANDBY DB:
    SQL> select log_mode, open_mode from v$database;
    LOG_MODE     OPEN_MODE
    ARCHIVELOG   READ WRITE
    SQL> ALTER DATABASE STOP LOGICAL STANDBY APPLY;
    Database altered.
    SQL> shutdown immediate;
    Database closed.
    Database dismounted.
    ORACLE instance shut down.
    SQL> startup mount;
    ORACLE instance started.
    Database mounted.
    SQL>  alter database noarchivelog;
    Database altered.
    SQL> alter database open;
    Database altered.
    SQL> ALTER DATABASE START LOGICAL STANDBY APPLY IMMEDIATE;
    Database altered.Then I created an object on the production server:
    SQL> create table testuser.noarchivelog_testing as select * from dba_objects;
    Table created.
    SQL> alter system switch logfile;
    System altered.
    Mon Jun 22 11:13:26 2009
    Beginning log switch checkpoint up to RBA [0xe6.2.10], SCN: 1031235046
    Mon Jun 22 11:13:26 2009Now I see it on the standby:
    Mon Jun 22 11:13:43 2009
    RFS LogMiner: RFS id [25920] assigned as thread [1] PING handler
    RFS[1]: Archived Log: '/oracle/LH1/oraarch/LH1arch_1_229_680639127.arc'
    Mon Jun 22 11:13:46 2009
    RFS LogMiner: Registered logfile [/oracle/LH1/oraarch/LH1arch_1_229_680639127.arc] to LogMiner session id [1]
    Mon Jun 22 11:13:48 2009
    LOGSTDBY status: ORA-16204: DDL successfully applied
    Mon Jun 22 11:13:51 2009
    LOGMINER: End mining logfile: /oracle/LH1/oraarch/LH1arch_1_229_680639127.arc
    SQL> select count(*) from testuser.noarchivelog_testing;
      COUNT(*)
         24444

  • Logical standby stuck at initializing SQL apply only coordinator process up

    Hi
    OS: solaris 5.10
    Hardware: sun sparc
    Oracle database: 11.2.0.1.0
    Primary database name: asadmin
    Standby database name: test
    I had been trying to convert a physical standby to logical standby database. Both the primary and standby reside on the same machine.
    The physical standby was created with a hot backup of primary.
    I had been following document id 278371.1 to convert the physical to logical standby and used the following steps:
    Relevant init parameters on primary:
    *.db_name='asadmin'
    *.db_unique_name='asadmin'
    *.log_archive_config='dg_config=(asadmin,test)'
    *.log_archive_dest_1='location=/u01/asadmin/archive valid_for=(all_logfiles,all_roles) db_unique_name=asadmin'
    *.log_archive_dest_2='SERVICE=test async valid_for=(online_logfiles,primary_role) db_unique_name=test'
    *.log_archive_dest_state_1='enable'
    *.log_archive_dest_state_2='enable'
    *.fal_client='asadmin'
    *.fal_server='test'
    *.remote_login_passwordfile='EXCLUSIVE'
    Relevant init parameters on standby database:
    *.db_name='test' -- Was asadmin before I renamed the DB during conversion to logical standby
    *.db_unique_name='test'
    *.log_archive_dest_1='location=/u01/test/archive valid_for=(all_logfiles,all_roles) db_unique_name=test'
    *.log_archive_dest_2='service=asadmin async valid_for=(online_logfiles,primary_role) db_unique_name=asadmin'
    *.log_archive_dest_state_1=enable
    *.log_archive_dest_state_2=defer
    *.remote_login_passwordfile='EXCLUSIVE'*.fal_server=test
    *.fal_client=asadmin
    Steps on primary:
    1) alter system set log_archive_dest_state_2=defer;
    2) shutdown immediate;
    3) Made sure that the physical standby has applied all of the redo sent to it following the shutdown.
    4) startup mount;
    5) ALTER DATABASE BACKUP CONTROLFILE to '/home/oracle/control01.ctl';
    6) ALTER SYSTEM ENABLE RESTRICTED SESSION;
    7) ALTER DATABASE OPEN;
    8) Verified that the supplemental logging is on.
    9) ALTER SYSTEM ARCHIVE LOG CURRENT;
    10) Checked for the checkpoint change no. at this point which is 72403818 and is present in archive log file 1_62_775102253.dbf
    11) EXECUTE DBMS_LOGSTDBY.BUILD;
    12) ALTER SYSTEM ARCHIVE LOG CURRENT;
    13) Checked for the archive log containing dictionary build which is 1_64_775102253.dbf
    14) ALTER SYSTEM DISABLE RESTRICTED SESSION;
    Details of archive logs and related checkpoint change nos:
    NAME FIRST_CHANGE# NEXT_CHANGE#
    /u01/asadmin/archive/1_61_775102253.dbf 72402901 72403817
    /u01/asadmin/archive/1_62_775102253.dbf 72403817 72404069
    /u01/asadmin/archive/1_63_775102253.dbf 72404069 72404211
    /u01/asadmin/archive/1_64_775102253.dbf 72404211 72405700
    Steps on standby:
    1) shutdown immediate;
    2) Copy the archivelog file 61(was created at primary after apply stopped at standby), 62(contains checkpoint no. 72403818), 63 and 64(contains dictionary build). Copy the backup controlfile from step 5 above to the controlfile location in standby init.
    3) startup mount;
    4) Rename all datafiles and redo log files (including standby redo log files) to the correct path on standby.
    5) alter database recover automatic from '/u01/test/archive' until change 72405700 using backup controlfile; -- This completed error-free
    6) alter database guard all; -- this completed error free
    7) alter database open resetlogs; -- this completed error free.
    8) nid target=sys/oracle12 dbname=test
    9) Changed the db_name in init file to new name test.
    10) Added a tempfile to temp tablespaces.
    11) ALTER DATABASE REGISTER LOGICAL LOGFILE '/u01/test/archive/1_61_775102253.dbf'; -- ORA-16225: Missing LogMiner session name for Streams
    12) ALTER DATABASE START LOGICAL STANDBY APPLY INITIAL 72405700; -- This completed error free.
    Also enabled the log_archive_dest_state_2 on primary.
    After this output from some views:
    SQL> SELECT SESSION_ID, STATE FROM V$LOGSTDBY_STATE;
    SESSION_ID STATE
    1 INITIALIZING
    SQL> SELECT SID, SERIAL#, SPID, TYPE FROM V$LOGSTDBY_PROCESS;
    SID SERIAL# SPID TYPE
    587 22 15476 COORDINATOR
    SELECT PERCENT_DONE, COMMAND
    FROM V$LOGMNR_DICTIONARY_LOAD
    WHERE SESSION_ID = (SELECT SESSION_ID FROM V$LOGSTDBY_STATE);
    PERCENT_DONE
    COMMAND
    0
    SQL> SELECT TYPE, HIGH_SCN, STATUS FROM V$LOGSTDBY;
    TYPE HIGH_SCN STATUS
    COORDINATOR ORA-16111: log mining and apply setting up
    SQL> SELECT APPLIED_SCN, NEWEST_SCN FROM DBA_LOGSTDBY_PROGRESS;
    APPLIED_SCN NEWEST_SCN
    72405700 72411501
    SELECT THREAD#, SEQUENCE#, FILE_NAME FROM DBA_LOGSTDBY_LOG L
    WHERE NEXT_CHANGE# NOT IN
    (SELECT FIRST_CHANGE# FROM DBA_LOGSTDBY_LOG WHERE L.THREAD# = THREAD#)
    ORDER BY THREAD#,SEQUENCE#;
    no rows selected
    SQL> SELECT EVENT_TIME, STATUS, EVENT
    FROM DBA_LOGSTDBY_EVENTS
    ORDER BY EVENT_TIMESTAMP, COMMIT_SCN; 2 3
    EVENT_TIME STATUS EVENT
    14-FEB-12 02:00:50 ORA-16111: log mining and apply setting up
    14-FEB-12 02:00:50 Apply LWM 72405699, HWM 72405699, SCN 72405699
    14-FEB-12 02:20:11 ORA-16128: User initiated stop apply successfully
    completed
    14-FEB-12 02:20:39 ORA-16111: log mining and apply setting up
    14-FEB-12 02:20:39 Apply LWM 72405699, HWM 72405699, SCN 72405699
    14-FEB-12 02:54:15 ORA-16128: User initiated stop apply successfully
    completed
    14-FEB-12 02:57:38 ORA-16111: log mining and apply setting up
    EVENT_TIME STATUS EVENT
    14-FEB-12 02:57:38 Apply LWM 72405699, HWM 72405699, SCN 72405699
    14-FEB-12 03:01:36 ORA-16128: User initiated stop apply successfully
    completed
    14-FEB-12 03:13:44 ORA-16111: log mining and apply setting up
    14-FEB-12 03:13:44 Apply LWM 72405699, HWM 72405699, SCN 72405699
    14-FEB-12 04:32:23 ORA-16128: User initiated stop apply successfully
    completed
    14-FEB-12 04:34:17 ORA-16111: log mining and apply setting up
    14-FEB-12 04:34:17 Apply LWM 72405699, HWM 72405699, SCN 72405699
    EVENT_TIME STATUS EVENT
    14-FEB-12 04:36:16 ORA-16128: User initiated stop apply successfully
    completed
    14-FEB-12 04:36:21 ORA-16111: log mining and apply setting up
    14-FEB-12 04:36:21 Apply LWM 72405699, HWM 72405699, SCN 72405699
    14-FEB-12 05:15:22 ORA-16128: User initiated stop apply successfully
    completed
    14-FEB-12 05:15:29 ORA-16111: log mining and apply setting up
    14-FEB-12 05:15:29 Apply LWM 72405699, HWM 72405699, SCN 72405699
    I also greped for lsp and lcr processes and found that lsp is up but do not see any lcr.
    The logs are getting transported to the archive destination on standby whenever they are archived on primary but are not getting applied to standby.
    Also in case the standby is down while a log is generated on primary it is not automatically transported to standby once the standby is up, means gap resolution is also not working.
    I see the following in alert log every time I try to restart the log apply, everything seems to be stuck at initialization.
    ALTER DATABASE START LOGICAL STANDBY APPLY (test)
    with optional part
    IMMEDIATE
    Attempt to start background Logical Standby process
    Tue Feb 14 05:15:28 2012
    LSP0 started with pid=28, OS id=23391
    Completed: alter database start logical standby apply immediate
    LOGMINER: Parameters summary for session# = 1
    LOGMINER: Number of processes = 3, Transaction Chunk Size = 201
    LOGMINER: Memory Size = 30M, Checkpoint interval = 150M
    LOGMINER: SpillScn 0, ResetLogScn 0
    -- NOTHING AFTER THIS

    Hello;
    I noticed some of your parameters seem to be wrong.
    fal_client - This is Obsolete in 11.2
    You have db_name='test' on the Standby, it should be 'asadmin'
    fal_server=test is set like this on the standby, it should be 'asadmin'
    I might consider changing VALID_FOR to this :
    VALID_FOR=(ONLINE_LOGFILES,ALL_ROLES)Would review 4.2 Step-by-Step Instructions for Creating a Logical Standby Database of Oracle Document E10700-02
    Document 278371.1 is showing its age in my humble opinion.
    -----Wait on this until you fix your parameters----------------------
    Try restarting the SQL Apply
    ALTER DATABASE START LOGICAL STANDBY APPLY IMMEDIATEI don't see the parameter MAX_SERVERS, try setting it to 8 times the number of cores.
    Use these statements to trouble shoot :
    SELECT NAME, VALUE, UNIT FROM V$DATAGUARD_STATS;
    SELECT NAME, VALUE FROM V$LOGSTDBY_STATS WHERE NAME LIKE ;TRANSACTIONS%';
    SELECT COUNT(1) AS IDLE_PREPARERS FROM V$LOGSTDBY_PROCESS WHERE
    TYPE = 'PREPERER' AND STATUS_CODE = 16166;Best Regards
    mseberg
    Edited by: mseberg on Feb 14, 2012 7:37 AM

  • How to delete the foreign archivelogs in a Logical Standby database

    How do I remove the foreign archive logs that are being sent to my logical standby database. I have files in the FRA of ASM going back weeks ago. I thought RMAN would delete them.
    I am doing hot backups of the databases to FRA for both databases. Using ASM, FRA, in a Data Guard environment.
    I am not backing up anything to tape yet.
    The ASM FRA foreign_archivelog directory on the logical standby FRA keeps growing and nothing is get deleted when
    I run the following command every day.
    delete expired backup;
    delete noprompt force obsolete;
    Primary database RMAN settings (Not all of them)
    CONFIGURE RETENTION POLICY TO RECOVERY WINDOW OF 9 DAYS;
    CONFIGURE ARCHIVELOG BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default
    CONFIGURE DB_UNIQUE_NAME 'WMRTPRD' CONNECT IDENTIFIER 'WMRTPRD_CWY';
    CONFIGURE DB_UNIQUE_NAME 'WMRTPRD2' CONNECT IDENTIFIER 'WMRTPRD2_CWY';
    CONFIGURE DB_UNIQUE_NAME 'WMRTPRD3' CONNECT IDENTIFIER 'WMRTPRD3_DG';
    CONFIGURE ARCHIVELOG DELETION POLICY TO APPLIED ON ALL STANDBY;
    Logical standby database RMAN setting (not all of them)
    CONFIGURE RETENTION POLICY TO RECOVERY WINDOW OF 9 DAYS;
    CONFIGURE ARCHIVELOG BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default
    CONFIGURE ARCHIVELOG DELETION POLICY TO NONE; # default
    How do I cleanup/delete the old ASM foreign_archivelog files?

    OK, the default is TRUE which is what it is now
    from DBA_LOGSTDBY_PARAMETERS
    LOG_AUTO_DELETE     TRUE          SYSTEM     YES
    I am not talking about deleting the Archive logs files for the Logical database that it is creating, but the Standby archive log files being sent to the Logical Database after they have been applied.
    They are in the alert log as follows under RFS LogMiner: Registered logfile
    RFS[1]: Selected log 4 for thread 1 sequence 159 dbid -86802306 branch 763744382
    Thu Jan 12 15:44:57 2012
    *RFS LogMiner: Registered logfile [+FRA/wmrtprd2/foreign_archivelog/wmrtprd/2012_01_12/thread_1_seq_158.322.772386297] to LogM*
    iner session id [1]
    Thu Jan 12 15:44:58 2012
    LOGMINER: Alternate logfile found. Transition to mining archived logfile for session 1 thread 1 sequence 158, +FRA/wmrtprd2/
    foreign_archivelog/wmrtprd/2012_01_12/thread_1_seq_158.322.772386297
    LOGMINER: End mining logfile for session 1 thread 1 sequence 158, +FRA/wmrtprd2/foreign_archivelog/wmrtprd/2012_01_12/threa
    d_1_seq_158.322.772386297
    LOGMINER: Begin mining logfile for session 1 thread 1 sequence 159, +DG1/wmrtprd2/onlinelog/group_4.284.771760923                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

  • Error while Creating a Logical Standby Database

    Dears
    I setup physical standby db. Now trying to convert it to logical standby db by following this link:
    http://download-east.oracle.com/docs/cd/B19306_01/server.102/b14239/create_ls.htm#i92346
    When i issue this statement:
    ALTER DATABASE RECOVER TO LOGICAL STANDBY orcl2;
    I am getting following error:
    ORA-00905: missing keyword.
    I do not find anything in ALERT.LOG file. The syntax seems to be correct as i carefully copied from the document itself.
    Please reply.

    Any ideas?

Maybe you are looking for

  • Can i get an iPod plug in for shuffle?

    i Need to get my shuffle into an ipod dock is there an accessory to do this?

  • Difference between Stored Procedure & Stored Function

    I want to know the difference between Procedure Procedure & Stored Function in compiler in oracle 10g. Thanks in advance

  • []ad dwnload is so slow, worked fine for a while but now painstaking slow?

    My Ipad (new @ xmas) has started having download issues, It is so impossible slow now. Seems anything via Safari takes forever or does not show up at all.

  • PPPoE (not finding host)

    I'm having internet connection issues. I have recently moved apartments and my internet was installed. Now the internet connection, hardware (modem, cables, etc.), and my computer all operate fine, yet I'm unable to connect to the PPPoE host. I don't

  • Photoshop cs5 upgrade

    I recently bought cs5 upgrade.  I have the web premium cs4 on my computer.  I also have the whole program of photoshop cs2, but it is not installed.  I read that an upgrade will not install over a collection. I had a hard time with the trial photosho