 |
|
Data Guard High SCN
Oracle Database Tips by Donald BurlesonDecember 9, 2015
|
Oracle Data Guard
- See
high SCN
olumn Type
Format a12
Column Status Format a40 Trunc
Column High_Scn Format 999999999
Select
Type,
Status,
High_Scn
See code depot for full
scripts
From
V$LOGSTDBY;
A sample output from the script is shown below:
TYPE
STATUS HIGH_SCN
------------
---------------------------------------- ----------
COORDINATOR ORA-16116: no work available
READER ORA-16127: stalled waiting for
additiona
BUILDER ORA-16127: stalled waiting for
additiona 2187196
PREPARER ORA-16116: no work
available 2187196
ANALYZER ORA-16117:
processing 2187196
APPLIER ORA-16117:
processing 2187156
The HIGH_SCN column will give an estimate of the progress of
the individual process. From the above output, it is apparent that
the APPLIER process is falling behind.
Statistics Related to Log Mining
Engine and Memory Usage
A dynamic performance view called
v$logstdby_stats, provides useful information about the log
mining engine and memory usage during the SQL apply operations.
Understanding the data presented by this view will help isolate the
performance related issues. This view will not have any statistics
when the SQL apply service is not running.
Query the view, logstdby_stats.sql, from
the code depot and congregate the results into four bands. These
bands are: LogMiningEngine; Memory Wait; Unsuccessful Handling of
Low Memory; and Total Pageouts. Based on the output of this script,
the determination can be made as to whether the log-mining engine or
the shared_pool_size on a logical Oracle instance
need to be
tuned.
logstdby_stats.sql
--
*************************************************
-- Copyright © 20012 by Rampant TechPress
--
*************************************************
-- Script to gather statistics from
v$logstdby_stats DPT Set linesize 82
Column logMiningEngine format 9999999999
Column MemWait format 9999999999
Column UnsuccHandleLowMem format 99999999
Column PageOuts format a10
Select
a.Value logMiningEngine,
b.Value MemWait,
c.Value UnsuccHandleLowMem,
d.Value PageOuts
From
(Select
sum(Value) Value
From
V$LOGSTDBY_STATS
See code depot for full
scripts
(Select
sum(Value) Value From
V$LOGSTDBY_STATS
From
V$LOGSTDBY_STATS v1,
V$LOGSTDBY_STATS v2
(Select
Value
From
V$LOGSTDBY_STATS;
A sample output of the script is shown below:
LOGMININGENGINE MEMWAIT UNSUCCHANDLELOWMEM
PAGEOUTS
--------------- ----------- ------------------
---------
1234 263 8
7
A high value in LOGMININGENGINE suggests there
are plenty of transactions ready for the APPLIER process, so the
log-mining engine is not a bottleneck. The other three columns in
the output of the logstdby_stats.sql script present data
related to memory usage from the shared pool of the logical standby
database. More about tuning the log apply service will be provided
in next the section.
The above text is
an excerpt from:
the book "Oracle Data
Guard",
ISBN 0-9745993-8-7,
by Bipul Kumar. Order it directly
from the publisher link and save 30%.
|