Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

Sql server 2012 ha dr


Published on

As presented to the Philadelphia SQL Server Users Group on 12/07/2012

Published in: Technology
  • Follow the link, new dating source: ❶❶❶ ❶❶❶
    Are you sure you want to  Yes  No
    Your message goes here
  • Sex in your area is here: ❶❶❶ ❶❶❶
    Are you sure you want to  Yes  No
    Your message goes here

Sql server 2012 ha dr

  1. 1. SQL Server 2012High Availabilityand DRPhiladelphia SQL ServerUser’s Group07-December-2011
  2. 2. About Me @jdanton on Twitter Videos and Blogs at Vice President of the Philadelphia SQL Server UG
  3. 3. Speaker Rate This is a new talk for me—I’d love feedback
  4. 4. Agenda SQL Server 2008 to 2012—What’s Changed in HA and DR Geo-Clustering All about Availability Groups
  5. 5. Learning Objectives SQLServer HA and DR What involved in SQL Clustering How it works What’s new in 2012 HA/DR This presentation is geared towards DBAs—so feel free to stop at any time with questions
  6. 6. Licensing (What’s changed) The Availability Group features will require the Enterprise Edition of SQL Server The licensing model for SQL Enterprise Edition has changed. Consult your friendly Microsoft sales representative for more details Mirroring is listed as being deprecated from Standard Edition. Will still be there in 2012
  7. 7. Windows Core Support No GUI version of Windows Allows for fewer patches Uses PowerShell and MMCs for support
  8. 8. SQL Server 2012 Extended Events are used much more heavily Slipstream Install no longer required—SQL will check for updates from your Windows Update source  Can use internet Windows Update or internal source
  9. 9. High Availability and DROptions in SQL 2008 SQL Server Clustering SQL Server Mirroring Peer to Peer Replication SQL Server Log Shipping*
  10. 10. HA and DR Options in SQLServer 2012 Backup and Recovery Mirroring Availability Groups (2012) Log Shipping Replication SAN Replication* Virtualization*
  11. 11. Clustering--2008 SQLClustering required 1 subnet to be used across the whole cluster  Cluster failover is controlled by isAlive/looksAlive processes, which check the SQL service and run @@servername
  12. 12. What’s new in SQL Server 2012HA/DR New Term: Witness Disk  Can be physical (SAN) disk, or cluster file share Multi-subnet clustering is supported  Requires SAN replication FlexibleFailover The BIG one—Always On Availability Groups
  13. 13. Clustering 2012 Fullsupport for geo-distributed clusters Flexible failover model TempDB on Non-shared Disk Resource  Makes PCI-based Solid State Drive an option  No check for this as of CTP3—instance won’t start if TempDB drive location not available
  14. 14. Geo-Distributed Clustering Requires SAN replication ($$$$) Two of everything Requires really fast network connection Requires some trickery at the network/DNS level for connectivity
  15. 15. Multi-Subnet Cluster
  16. 16. Flexible Failover Replaces looksAlive/isAlive functionality in SQL Clusters (and is used for Availability Groups) Now runs sp_server_diagnostics  Two new parameters  HealthCheckTimeout (Default 60 sec/Minimum 15 sec)  Failover Condition Level
  17. 17. Flexible Failover Policies for ClustersLevel Condition Description No automatic failover • Indicates that no failover or restart will be triggered0 or restart automatically on any failure conditions. Failover or restart on1 • SQL Server service is down. server down • SQL Server instance is not responsive (Resource DLL cannot Failover or restart on2 receive data from sp_server_diagnostics within the server unresponsive HealthCheckTimeout settings). Failover or restart on • System stored procedure sp_server_diagnostics returns3 (Default) critical server errors ‘system error’. (Critical errors > 20) Failover or restart on • System stored procedure sp_server_diagnostics returns4 moderate server errors ‘resource error’. (Moderate errors > 17) Failover or restart on • System stored procedure sp_server_diagnostics returns5 any qualified failure ‘query_processing error’. (Deadlock) conditions
  18. 18. Understanding Quorum There are a few slides on this topic, it’s a little confusing  In a nutshell, you cluster has to be able to talk to itself to keep the cluster service up in running  This applies to both SQL Server Failover Cluster Instances and AlwaysOn Availability Groups
  19. 19. Quorum Quorum is critical—contains master copy of the cluster’s configuration Serves as a tiebreaker if network communications between cluster nodes fail If Quorum fails—cluster is shut down until it’s restored
  20. 20. Quorum Models Node and Disk Majority (Default) Node Majority No Majority (Quorum Disk Only) Node and File Share Majority (Good for Geo Clusters)
  21. 21. Quorum Failure ToleranceNumber of Nodes 2 3 4 5 6 7Node Majority 0 1 1 2 2 3Node and Disk/File Share Majority 1 2 2 3 3 4• Assuming Disk is Up Calculation is: Cluster Up = RoundUp(Total # of Nodes/2)• Assuming Disk is Down Calculation is: ClusterUp = RoundUp (Total # of Nodes/2)-1
  22. 22. DR in SQL 2008 Mirroring  Allowed automatic failover, but only one target  Mirror target is unreadable Log Shipping  Allowed multiple targets, but failover a manual process, requiring a connection string change Replication
  23. 23. AlwaysOn Availability Groups
  24. 24. AlwaysOn Requirements Windows Enterprise (Clustering is a requirement) SQL Server Enterprise Edition Windows Cluster No shared storage is required Quorum Disk Preferred
  25. 25. Flexible AG Failover Similar to how a failover clustered instance fails over Connects to instance every 30 seconds to perform health check Also, similar quorum model to Windows Failover Clustering
  26. 26. Allows for SAN Less HA/DR Thisisn’t a huge thing for SQL Server at big shops It may allow us to incorporate a level of DR into a virtual environment
  27. 27. Failover Modes Automatic failover Planned manual failover (without data loss) Forced manual failover (with possible data loss)
  28. 28. Failover Synchronous- Synchronous- Asynchronous- commit mode commit mode commit mode with manual- with automatic- failover mode failover mode Automatic No No Yes failover Manual failover No Yes Yes Forced failover Yes Yes No
  29. 29. Client Connections in ThisModel Availability Group Listener (Yes, SQL Server now has a listener)  Works just like a failover clustering instance (single instance, single IP)  Creates a VCO (AD Virtual Computer Object)
  30. 30. Contained Databases Isolate Database from Instance  Currently only fully supported with SQL Logins No numbered procedures Eases database movement Allows for ease of migration to Azure Not quite baked out as of RC0
  31. 31. Read Only Replicas Can have up to 3 SQL Client 2012 will allow for this routing specifically Can take backups from read-only copys*  Copy Only Backups (only full copy, does not affect primary log) Indexingmust be same on replicas Bad queries can affect status of replica
  32. 32. Considerations for AvailabilityGroups All SQL servers (including the secondary in the DR site) in the same Windows domain All the databases must be in FULL recovery model The unit of failover (for local HA, as well as DR) is at the AG level, i.e., group of databases – not the instance  Consider using Contained Database for containing logins for failover  For jobs and other objects outside the database, simple customization needed No delayed apply on the secondary Removing log shipping means the regular log backup job is removed  Need to re-establish periodic log backup (essential for truncating the log) New tools for monitoring and alerting  AlwaysOn Dashboard  System Center Operations Manager
  33. 33. Availability Groups Demo
  34. 34. Summary Lotsof Change in the HA/DR Space Licensing also changes—talk to your MS rep SQL Server Failover Clusters still a good HA option AlwaysOn Availability Groups add a lot more flexibility to DR
  35. 35. Contact Info @jdanton jdanton1@yahoo.com