SQL 2012 – Always On Deep Dive Bob Duffy Database Architect Prodata SQL Centre of Excellence 11 th April 2013.

Slides:



Advertisements
Similar presentations
SQL Server AlwaysOn: Active Secondaries Luis Vargas Program Manager Microsoft Corporation DBI312.
Advertisements

SQL Server Disaster Recovery Chris Shaw Sr. SQL Server DBA, Xtivia Inc.
SharePoint 2013 & SQL Server 2012 Availability Groups The Rough Guide.
Mecanismos de alta disponibilidad con Microsoft SQL Server 2008 Por: ISC Lenin López Fernández de Lara.
Oracle Data Guard Ensuring Disaster Recovery for Enterprise Data
0 SQL Server AlwaysOn – SharePoint 2013 High Availability and Disaster Recovery Sal Bawany, Solutions Architect
Keith Burns Microsoft UK Mission Critical Database.
Virtual techdays INDIA │ September 2011 High Availability - A Story from Past to Future Balmukund Lakhani │ Technical Lead – SQL Support, Microsoft.
Denali – Always On Deep Dive 30 th Sept 2011 Bob Duffy Database Architect Prodata SQL Centre of Excellence.
SQL Server 2012 Always On Premier Field Engineer Microsoft Corporation Lisa Gardner
SQL Server AlwaysOn: Active Secondaries Luis Vargas Program Manager Microsoft Corporation DBI312.
SharePoint Business Continuity Management with SQL Server AlwaysOn
Building Highly Available Systems with SQL Server™ 2005 Vineet Gupta Evangelist – Data and Integration Microsoft Corp.
Chapter 10 : Designing a SQL Server 2005 Solution for High Availability MCITP Administrator: Microsoft SQL Server 2005 Database Server Infrastructure Design.
Implementing Database Snapshot & Database Mirroring in SQL Server 2005 Presented by Tarek Ghazali IT Technical Specialist Microsoft SQL Server MVP Microsoft.
Architecting Availability Groups
SQL-Server 2012 Always On.
Get More out of SQL Server 2012 in the Microsoft Private Cloud environment Guy BowermanMadhan Arumugam DBI208.
Sofia, Bulgaria | 9-10 October SQL Server 2005 High Availability for developers Vladimir Tchalkov Crossroad Ltd. Vladimir Tchalkov Crossroad Ltd.
MODIFY THIS SLIDE FOR ACTUAL PRESENTER, DELETE THIS BAR AFTER MODIFICATION.
SQLintersection SQL37 SQL Server 2012 Availability Groups: High Availability for Your Most Important Data Aaron Bertrand,
SQLintersection Session SQL37 SQL Server 2012 Availability Groups Aaron Bertrand
DBI Meets mission critical high availability SLA Integrated Efficient Flexible.
SQLCAT: SQL Server HA and DR Design Patterns, Architectures, and Best Practices Using Microsoft SQL Server 2012 AlwaysOn Sanjay Mishra Program Manager.
Alwayson Availability Groups
Course Topics Administering SQL Server 2012 Jump Start 01 | Install and Configure SQL Server04 | Manage Data 02 | Maintain Instances and Databases05 |
Log Shipping, Mirroring, Replication and Clustering Which should I use? That depends on a few questions we must ask the user. We will go over these questions.
Narasimha Reddy Gopu Jisha J. Agenda Introduction to AlwaysOn * AlwaysOn Availability Groups (AG) & Listener * AlwaysOn Failover * AlwaysOn Active Secondaries.
SQL Server 2014 AlwaysOn Step-by-Step SQL Server 2014 AlwaysOn Step-by-Step A hands on look at implementing AlwaysOn in SQL Server 2014.
What HADR Option(s) Are Right For You?. Where’s The AlwaysOn?
SQL Server High Availability Introduction to SQL Server high availability solutions.
All the things you need to know before setting up AlwaysOn Michael Steineke SQL & BI Solution Lead Enterprise Architect Concurrency, Inc.
Windows Server Failover Clustering (WSFC) with SQL Server.
AlwaysOn Introduction in Denali November 27 th, 2011.
William Durkin A Gourmet Menu of SQL Server High Availability Options.
AlwaysOn In SQL Server 2012 Fadi Abdulwahab – SharePoint Administrator - 4/2013
Level 400 SQL Server 2012 AlwaysOn Deep Dive Christian Bolton, Coeo Ltd.
Microsoft Dynamics NAV Dynamics NAV 2016 one Azure SQL Dmitry Chadayev Microsoft.
High Availability & Disaster Recovery with SQL Server AlwaysOn Availability Groups Turgay Sahtiyan Microsoft – Senior SQL Server PFE
SQLSaturday (Silicon Valley) – Mar
Turgay Sahtiyan Istanbul, Turkey
Sponsors.
SQL Server AlwaysOn Availability Groups DrillDown
AlwaysON Availability groups
SQL Server 2012 AlwaysOn and SQLSentry
ALWAYSON AVAILABILITY GROUPS
Disaster Recovery Where to Begin
AlwaysOn Mirroring, Clustering
AlwaysOn Readable Secondary
Maximum Availability Architecture Enterprise Technology Centre.
A Technical Overview of Microsoft® SQL Server™ 2005 High Availability Beta 2 Matthew Stephen IT Pro Evangelist (SQL Server)
Always On Availability Groups
Always on HA SQL Server Always ON feature is the new comprehensive high availability and disaster recovery solution which increases application availability.
Contained DB? Did it do something wrong?
unexplained AG failover
Required 9s and data protection: introduction to sql server 2012 alwayson, new high availability solution Santosh Balasubramanian Senior Program Manager.
AlwaysOn, an Early bird Overview
SQL Server High Availability Amit Vaid.
Disaster Recovery Where to Begin
Architecting Availability Groups
Planning High Availability and Disaster Recovery
Example of a page header
AlwaysOn Availability Groups
High Availability/Disaster Recovery Solution
Top 5 TIPS TO KEEP Always on AGs humming and users happy
Distributed Availability Groups
04 | Always On High Availability
Distributed Availability Groups Praveen Kumar. What we will cover Availability group refresher The HA/DR solution Distributed availability groups – what.
Top 5 TIPS TO KEEP Always on AGs humming and users happy
Designing Database Solutions for SQL Server
Presentation transcript:

SQL 2012 – Always On Deep Dive Bob Duffy Database Architect Prodata SQL Centre of Excellence 11 th April 2013

Speaker Bio – Bob Duffy 20 years in database sector, 250+ projects 20 years in database sector, 250+ projects Senior Consultant with Microsoft Senior Consultant with Microsoft One of about 25 MCA for SQL Server globally (aka SQL Ranger) One of about 25 MCA for SQL Server globally (aka SQL Ranger) SQL MCM on SQL 2005 and 2008 SQL MCM on SQL 2005 and 2008 SQL Server MVP SQL Server MVP SSAS Maestro SSAS Maestro Database/Solution Architect at Prodata SQL Centre of Excellence Database/Solution Architect at Prodata SQL Centre of Excellence Regular speaker for TechNet, MSDN, Users Groups, Irish and UK Technology Conferences Regular speaker for TechNet, MSDN, Users Groups, Irish and UK Technology Conferences

Agenda Typical HADR Requirements Typical HADR Requirements Always On Installation Always On Installation Migrating to Availability Groups Migrating to Availability Groups Planned Failover Planned Failover Automated Failover Automated Failover Active Secondary Replicas Active Secondary Replicas

Case Study – Dell DVD Store Enterprises Need to accept 24 x 7 transactions For High Availability Zero down time and data loss (automatic) SLA to cover storage failure “I see web site unavailable and you are fired” “Reporting” Near real time. No more than 1 minute behind With minimal impact on live transactions Disaster Recovery Have second data centre. No more than 30 mins down time and 5 minutes data loss Migration Any upgrade needs to be with no down time or data loss Performance We don’t want backups affecting live server

Typical HA/DR/Reporting Architecture DR Site

SQL 2012 Always On – Availability Groups DR Site Synchronous Asynchronous

Recap - Key Always On Features Up to three “secondary” replicas Can be Synchronous or Asynchronous Automatic and/or Manual Failover Fast Failover – similar to a Mirror You can do stuff on the Secondary's BackupReportingDBCC

Installation Always On relies on WSFC Always On is NOT a clustered install of SQL Does not need Shared Disk Windows 2008 Server+ EE needed Need to Enable sqlAlwaysOn service Via configuration manager Or via PowerShell Some Patches and QFE Recommended KB KB Lots of others at us/library/ff878487(v=sql.110).aspxhttp://msdn.microsoft.com/en- us/library/ff878487(v=sql.110).aspx

Installation Cluster + SqlAlwaysOn Feature

Migrating to Always On / Denali Any normal migration is possible: Backup / Restore Attach / Detach Mirroring Log Shipping Replication Might need some post migration tasks Compatibility Use of new features such as Containment

Migrating to Denali

Creating your First Availability Group

Failover to Secondary

Flexible Failover Policy Flexible Failover Policy provides administrators control over the conditions when an automatic failover should be initiated. DiagnosticsDiagnostics Configurable options eliminate false failover Improved logging for better diagnostics

New Failure Condition Levels LevelConditionExample 0No Automatic FailureMaintenance Mode 1Server DownInstance Not Started 2Server Hang No data from sp_server_diagnostics 3*System Unhealthy sp_server_diagnostics Return ‘system error’ stack dumps occurring 4Resource Unhealthy sp_server_diagnostics Return ‘resource error’ Low on Memory 5Failover or restart on any qualified failure conditions sp_server_diagnostics Return ‘query processing error’ Deadlock

Quorum Changes Required for automatic failover Built in feature of WSFC Replaces the concept of “witness” to avoid split brain Two recommended Steps 1. Select nodes to vote 2. Select the Quorum Type If Odd number use “Node Majority” If even number use “Node Majority plus File Share Witness” Requires QFE KB Requires QFE KB KB to enable Voting May need to adjust quorum after failover outside automatic target May need to adjust quorum after failover outside automatic target

Automated Failover

Secondary Replica Features Failover Backup \ DBCC Reporting Queries AlwaysOn AutoStat Automatic Page Repair

Read Only Replicas

Secondary Replica – Active Log Sync Log Cache Secondary read is behind primary Log is first hardened and then applied Redo thread is asynchronous and runs in the background Latency (typically seconds) can be larger for log intensive operations like bulk import or index create/rebuild DB1 DB1 Log DB1 Log Capture Log Recieve DB1 Data Redo Thread Redo Pages DB1 Log DB1 Data Page Updated Log Harden Log Flush CommitCommit Acknowledge Commit Log Pool NetworkNetwork

Auto-Stats on Readable Secondary Query Optimization and Statistics SQL Server uses cost based optimizer that heavily relies on object statistics If statistics are missing, SQL Server automatically creates them and persists Auto-stat on readable secondary will require physical Changes Example: Table T1 (C1, C2, C3) Query on primary with predicate (C3 > 10). SQL Server auto-create the statistics, if needed, on column C3 on primary replica Won’t work on Readable Secondary as it will cause physical changes to the database. Similar issue if the statistical information is stale on the secondary replica. Solution Auto-create statistics on the secondary replica but persist them in TempDB Existing catalog views (e.g. sys.stats) show temporary statistics

Unplanned Disaster!

Questions ?

AlwaysOn Resources AlwaysOn Resources AlwaysOn Resource Center: us/sqlserver/gg490638(en-us,MSDN.10) us/sqlserver/gg490638(en-us,MSDN.10) us/sqlserver/gg490638(en-us,MSDN.10)Documentation MSDN forums Microsoft Connect AlwaysOn Blog

Availability Groups and Failover Cluster Instance

Supportability Catalog Views Sys.availability_replicas (used to see if secondary allows READ) Sys.stats New column to indicate if the statistics is temporary DMVsSys.dm_hadr_database_replica_statesXevents REDO Blocked REDO Unblocked PerfMon REDO blocking

Thank You!