 |
|
Data Guard Log Apply Statistics
Oracle Database Tips by Donald BurlesonDecember 9, 2015
|
Oracle Data Guard-
Performance Tuning of Data Guard Configuration
Gathering Log Apply Service Related Statistics
Physical Standby Database
The following is a sample output from the script:
PROCESS STATUS SEQUENCE# BLOCK#
BLOCKS
------- ------------ ----------- ---------
---------
ARCH CONNECTED 0
0 0
ARCH CONNECTED
0 0
0
RFS RECEIVING 1965 2046
2046
RFS ATTACHING 1964 2046
2046
MRP0 WAIT_FOR_LOG 1948 2044
2046
The SEQUENCE# column indicates the archived log
file sequence number being processed. A significant difference
between the SEQUENCE# of RFS and MRP0 shows a poor performance of
the log apply service.
Logical Standby Database Log Apply Services
In order to find the overall progress of the
log apply service on a logical standby database, the
dba_logstdby_progress view can be queried. The view provides
read and applied SCN. The script named log_progress.sql, from
the code depot, can be executed on a logical Oracle instance
in
order to find the overall progress of the log apply service. This
should be the starting point in the diagnosis of performance issues
with SQL apply operation. A sample output from the
log_progress.sql is shown below:
APPLIED_SCN READ_SCN NEWEST_SCN
------------- ------------- ---------------
2187154 1987779 2187417
If the APPLIED_SCN and NEWEST_SCN are the same,
the SQL apply operation has applied all the available transactions.
In cases where these two values are not equal, further investigation
into the level of individual processes involved in the SQL apply
operation is required.
Querying the dynamic performance v$logstdby
on a logical Oracle instance
will provide the performance of
individual processes involved in the SQL apply operation. The
script, sql_apply_progress.sql, from the code depot can be
used to gather data from v$logstdby.
sql_apply_progress.sql
--
*************************************************
-- Copyright © 2015 by Rampant TechPress
--
*************************************************
-- Script to find out the progress of
individual process
-- involved in SQL Apply operation column 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
|