0% found this document useful (0 votes)
163 views

DataGuard MAA New Features

High availability No Downtimes during service-times (e.g. Mo-fr) Oracle Maximum Availability Architecture (MAA) is an Oracle best practices blueprint based on proven Oracle high-availability technologies and recommendations.
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
163 views

DataGuard MAA New Features

High availability No Downtimes during service-times (e.g. Mo-fr) Oracle Maximum Availability Architecture (MAA) is an Oracle best practices blueprint based on proven Oracle high-availability technologies and recommendations.
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 16

Disaster Recovery with Oracle Data Guard 10gR2

Martin Decker

Martin Decker, January 2009

Overview
Definitions High Availability, Disaster Recovery, Maximum Availability Architecture (MAA) Data Guard 10g Protection & Transport Modes Switchover/Failover Monitoring Tuning Data Guard 11g New Features

Definitions
High Availability No Downtimes during Service-Times (e.g. Mo-Fr)
99 % 438,3 min/month, 7,3 hrs/month or 87,66 hrs/year 99,9 % 43,8 min/month or 8,76 hrs/year 99,99 % 4,38 min/month or 52,6 min/year 99,999 % 26,3 sec/month or 5,26 min/year

Disaster Recovery Fast Recovery after Failure of data center

Oracle High Availability


Oracle Real Application Cluster (incl. Stretch-Cluster) Shared Storage datafile corruption => Downtime and time-consuming restore. Oracle Data Guard Switchover/Failover at Primary Failure Switchover/Failover within seconds/minutes

Oracle Maximum Availability Architecture (MAA)


Oracle Maximum Availability Architecture (MAA) is an Oracle best practices blueprint based on proven Oracle high-availability technologies and recommendations HA app server connect to current primary (automatically) Real Application Clusters (RAC) against instance crashes DataGuard against Site/Storage failures Redundant RAC Interconnet Dedicated Network between Primary & Standby

Reference: http://www.oracle.com/technology/deploy/availability/htdocs/maaoverview.html

Oracle Data Guard

Management via SQL*Plus Oracle Enterprise Manager dgmgrl

Oracle Data Guard


Transport Modes ARCH LGWR ASYNC (improved in 10.2) LGWR SYNC Protection Modes Maximum Protection (LGWR, SYNC, AFFIRM, Standby Redo Logs) Maximum Availability (LGWR, SYNC, AFFIRM, Standby Redo Logs) Maximum Performance (LGWR oder ARCH)

Physical Standby Switchover


Roles before: Munich Primary Role, Hamburg Standby Role
Database Site: Munich: SQL> SELECT SWITCHOVER_STATUS FROM V$DATABASE; SQL> ALTER DATABASE COMMIT TO SWITCHOVER TO PHYSICAL STANDBY; SQL> SHUTDOWN IMMEDIATE; SQL> STARTUP MOUNT; Database Site: Hamburg

Zeit
Attention with RAC: SWITCHOVER_STATUS stays SESSIONS ACTIVE, because Clusterware is monitoring instance with a logged in session. Solution: racgimon stopd <dbname> SQL> SELECT SWITCHOVER_STATUS FROM V$DATABASE; SQL> ALTER DATABASE COMMIT TO SWITCHOVER TO PRIMARY; SQL> SHUTDOWN IMMEDIATE; SQL> STARTUP;

SQL> ALTER DATABASE RECOVER MANAGED STANDBY DATABASE USING CURRENT LOGFILE DISCONNECT;

Roles afterwards: Munich Standby Role, Hamburg Primary Role

Physical Standby Failover


Roles before: Munich failed, Hamburg Standby Role
Database Site: Munich Database Site: Hamburg

time To avoid data loss, get all available redo data from Primary, then: SQL> ALTER DATABASE RECOVER MANAGED STANDBY DATABASE FINISH FORCE; Do not use the ALTER DATABASE ACTIVATE STANDBY DATABASE to perform a failover, because this statement may cause data loss. http://download.oracle.com/docs/cd/ B19306_01/server.102/b14239/role_ management.htm#i1026464 SQL> ALTER DATABASE COMMIT TO SWITCHOVER TO PRIMARY; SQL> ALTER DATABASE OPEN;

Roles afterwards: Munich failed, Hamburg Primary Role

Oracle Data Guard Monitoring


Transport Lag (in sec) Apply Lag (in sec)

Oracle Data Guard Monitoring

Oracle Data Guard Monitoring


SELECT SUM(DECODE(name, 'apply finish time', value, 0)) FOT, SUM(DECODE(name, 'apply lag', value, 0)) LAG, SUM(DECODE(name, 'transport lag', value, 0)) PDL from ( SELECT name, extract(day from p.val) * 86400 + extract(hour from p.val) * 3600 + extract(minute from p. val) * 60 + extract(second from p.val) value from ( SELECT name, to_dsinterval(value) val from ) p )
Source:Oracle Enterprise Manager Grid Control

v$dataguard_stats

Oracle Data Guard Tuning


TCP Send/Receive Buffers Formula: 3 * BDP (Bandwith Delay Product) 3 * (1 GBit/sec * 0.8 ms Round Trip Time) 3 * (125,000,000 Bytes / sec * 0,0008 sec ) = 300,000 Bytes Multiple of SDU => 327670 Bytes. SDU=32767
http://www.oracle.com/technology/deploy/availability/pdf/MAA_WP_10gR2_DataGuardNetworkBestPractices.pdf

Oracle Data Guard 10g/11g New Featues


10g: Realtime Apply, Open Read Write, then manual Flashback to before Open 11g: Realtime-query (read-only) capability of physical Standby while applying redo Snapshot standby
DB open in read/write mode, Receives redo, but does not apply redo while being open read/write.

Statspack on primary for read-only standby performance management (MetaLink 454848.1)

References
MAA: http://www.oracle.com/technology/deploy/availability/htdocs/maa.htm Oracle Database High Availability Best Practices 10g Release 2 (10.2): http://download.oracle.com/docs/cd/B19306_01/server.102/b25159/toc.htm Oracle Data Guard Concepts and Administration 10g Release 2 (10.2): http://download.oracle.com/docs/cd/B19306_01/server.102/b14239/toc.htm Blog: http://www.ora-solutions.net/web/category/oracle-database/data-guard/ Papers: http://www.ora-solutions.net/web/papers/

Q&A

You might also like