Oracle Active Dataguard g

Improving Quality of Service for Mission Critical Applications

by: Randy Cunningham
Principal Solutions Architect, SageLogix, Inc.

Data Guard Concepts

2

Oracle Data Guard Low-cost disaster recovery from site failure Real‐time  Queries Production Database Standby  Database Continuous redo shipment & apply 3 .

 Reports g & Backups p Testing Oracle   Net .Data Guard 11g Process Architecture Synchronous Redo Transport (SYNC)– Zero Data Loss User Transactions Online  Redo d Logs LGWR SGA Redo  Buffer LNS RFS Active Standby Database MRP LSP Standby Redo  Logs Primary Database MRP ‐ p physical ys ca LSP ‐ logical Queries.

Data Guard 11g Process Architecture Asynchronous Redo Transport (ASYNC) User Transactions Online  Redo d Logs LGWR SGA Redo  Buffer LNS RFS Active Standby Database MRP LSP Standby Redo  Logs Primary Database MRP ‐ p physical ys ca LSP ‐ logical Queries. Reports g & Backups p Testing Oracle   Net .

Data Guard 11g Process Architecture ASYNC – If Network Can’t Keep Pace User Transactions Online  Redo Logs LGWR SGA Redo  Buffer LNS RFS Active Standby Database MRP LSP Standby Redo  Logs Primary Database MRP ‐ p physical ys ca LSP ‐ logical Queries. Reports g & Backups p Testing Oracle   Net 6 .

Redo Transport vs. Protection Mode Protection Mode Controls Response to Failure Events Mode Maximum Protection Maximum Availability Maximum Performance Risk of data loss Zero Data Loss Double Failure Protection Zero Data Loss Single Failure Protection Potential for Minimal Data Loss Transport If no acknowledgement ackno ledgement from standby: standb Stall primary until acknowledgement is received from replica Stall primary until acknowledgement is received or timeout threshold period expires – then resume processing Primary never waits for standby acknowledgement SYNC SYNC ASYNC NET_TIMEOUT parameter of LOG_ARCHIVE_DEST_n Data Guard 11g default = 30 seconds Data Guard 10g default = 180 seconds  7 .

Comparing Data Guard and Active Data Guard 8 .

Traditional Standby Database using Oracle Data Guard Real‐time  Queries Production Database Standby  Database Physical standby database remains ‘closed’ 9 .

 backups. reports run on production only 10 .Traditional Physical Standby Databases Investment in Disaster Recovery only Real‐time  Queries Production Database b Standby  Database b Applications.

With Oracle Active Data Guard Offload production reporting to standby Real‐time  Queries Production Database Standby  Database Simultaneously available in read and recovery mode 11 .

data is 8 hours old Active Data Guard Option Redo apply is always on Always y open p read only y Failover is immediate when needed. standby database always up up-toto date Queries and reports always l see llatest t td data t 12 .Data Guard vs. Active Data Guard Data Guard 11g Stop redo apply at 8am Open p read-only y for queries Any failover is delayed due to backlog of data that must be applied By 4pm.

Without Active Data Guard All Workloads Run on Production 2000 1500 Read‐write service 480 tps 1000 Read d‐only l  service  640 tps 500 0 Production Database Data Guard Standby Primary server at  100% of capacity 13 .

350 tps  500 +110% Production Database Active Data Guard Standby Primary server at  60% of capacity 0 14 .680 tps 1000 +250% Read d‐only l  service i 1.Active Data Guard 11g Easily Optimize Performance for All Workloads 2000 1500 Read‐write service 1.

Active Data Guard Data Latency 15 .

2 1 0.Active Data Guard Queries Return Up-to-date Results Latency Between Primary Commit and Ability to Read the Same Data on an Active Standby 1.4 0.2 0 6:24:16 6:24:34 6:24:52 6:25:10 6:25:28 6:25:46 6:26:04 6:26:22 6:26:40 6:26:58 6:27:16 6:27:34 6:27:52 6:28:10 6:28:28 6:28:46 6:29:04 6:29:22 6:29:40 6:29:58 dw4 16 .6 0.8 Seconds 0.

Active Data Guard Connections and Failover 17 .

Routing New User Connections Primary and reporting applications should connect using role specific service name The Oracle Net alias should list all hosts in the ADDRESS_LIST to accommodate role changes Primary Application Sales_RW = (ADDRESS_LIST= (ADDRESS=(PROTOCOL=TCP) (HOST=hasun01) (PORT=1521)) (ADDRESS=(PROTOCOL=TCP) (HOST=hasun02) (PORT=1521)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = sales_rw))) Reporting Application Sales_RO = (ADDRESS_LIST= (ADDRESS=(PROTOCOL=TCP) (HOST=hasun02) (PORT=1521)) (ADDRESS=(PROTOCOL=TCP) (HOST=hasun01) (PORT=1521)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = sales_ro))) 18 .

Routing User Connections Role Transitions Following a failover / switchover o User connections to the read-only service on Active Data Guard standby will be disconnected o This standby becomes new primary o Primary read-write service automatically enabled on new primary via service management trigger o Primary clients can connect to this service o Read Read-only only service has to be started manually on the new Active Data Guard standby 19 .

Other Features of Active Data Guard 20 .

With Oracle Active Data Guard Offload fast incremental backups to standby Real‐time  Q i Queries Production Database Standby  Database Use RMAN block change tracking on standby database Fast incremental backups complete 20x faster 21 .

Snapshot Standby in Data Guard 11g Use standby database for pre-production testing Real‐time  Queries Production Database Standby  Database Convert to ‘snapshot’ standby for testing purposes Part of Data Guard 11g. no additional license required 22 .

With Oracle Snapshot Standby Test changes – then resync standby with production Real‐time  Queries Production Database Snapshot Standby  Database Test on standby until guaranteed production‐ready 23 .

Uses and Benefits of Active Data Guard 24 .

Active Data Guard Use Examples Education .Access legal reports. billing rates … Transportation – Track packages. jury verdicts … Telecommunications . market prices. order status … Bottom  Line B Li  … • Most businesses require a significant number of read‐only operations • Use Active Data Guard to: • Offload these operations to physical standbys. view delivery rates … Web-business – Browse catalogs.View usage history.Access medical records.Report student grades. trial histories. compare prices. search doctors. course catalogs … Financial . facilities … Legal . archived statements … Healthcare . and thus  • Unlock additional processing power of the production database 25 . unused minutes.View past transactions. campus directory.

Aggressive recovery point and recovery time objectives Highest possible level of protection from physical and logical  data corruptions A desire to minimize additional hardware  cost An ability to perform rolling database upgrades with  minimal downtime Full resource utilization Making dual‐use of the disaster recovery standby database  to improve performance 26 .Data Guard and Active Data Guard Option are compelling solutions when requirements include …….

com/ha 27 .oracle.com active data guard or http://oracle.For More Information http://search.

Questions? info@sagelogix.com 28 .