SlideShare a Scribd company logo
Introduction to High 
Availability with SQL 
Server 
10/14/2014 www.linchpinpeople.com 1
John Sterrett 
Linchpin People Group Principle 
@johnsterrett 
John.Sterrett@linchpinpeople.com 
Johnsterrett.com 
linked.com/in/johnsterrett 
google.com/+johnsterrett 
Leader Austin SQL 
Server User Group 
Leader Virtual Chapter 
“High Availability and 
Disaster Recovery” 
PASS Regional Mentor 
Specialties / Focus Areas / Passions: 
• Performance Tuning & 
Troubleshooting 
• Virtualization 
• Infrastructure 
• Architecture 
• High Availability 
• Disaster Recovery 
• Health Monitoring 
• Capacity Management 
• License Efficiency 
www.linchpinpeople.com 2
You know us individually, but do 
you know Linchpin People®? 
Linchpin People® are database coaches and wellness experts for the 
Microsoft SQL Server Ecosystem. Our team includes more than 15 of the 
world’s top SQL Server experts, and we have presented over 175 combined 
sessions at SQL Saturdays, PASS Summit, and other events in the past year. 
Do you have specific questions about your database environment? Check 
out www.LinchpinPeople.com and take a look at the range of services we 
provide, or contact one of us today to learn how we can help improve your 
business. 
www.linchpinpeople.com 3
Agenda 
• HA != DR 
• Log Shipping 
• Database Mirroring 
• Transactional Replication 
• AlwaysOn Failover Cluster Instance 
• AlwaysOn Availability Groups 
• Wrap Up / Question and Answer 
10/14/2014 www.linchpinpeople.com 4
Introduction 
Definitions 
• What do we mean when we say a system is 
Highly Available? 
• What does it mean to have a Disaster 
Recovery system? 
10/14/2014 www.linchpinpeople.com 5
High Availability 
What is High Availability 
• High availability is a system design approach and 
associated service implementation that ensures a 
prearranged level of operational performance will 
be met during a contractual measurement period. – 
Wikipedia 
• A System Design that allows for minimal downtime. 
• Protection from OS or hardware failure 
10/14/2014 www.linchpinpeople.com 6
Examples of Disasters 
Photo https://www.flickr.com/photos/ross/39556863/ 
10/14/2014 www.linchpinpeople.com 7
Most Common Disaster 
10/14/2014 www.linchpinpeople.com 8
Disaster Recovery 
What is Disaster Recovery 
• Risk Management 
• Recovery Point Objective - RPO 
• Recovery Time Objective - RTO 
• Disaster Recovery Plan - DRP 
• Backups are not enough 
10/14/2014 www.linchpinpeople.com 9
Options 
SQL Server Options for HA/DR 
• Log Shipping 
• Database Mirroring 
• Replication 
• Failover Cluster Instances 
• AlwaysOn Availability Groups 
10/14/2014 www.linchpinpeople.com 10
Intro to Log Shipping 
1. Transactional Log 
Backup 
2. Copy Transactional log backups 
3. Restore Transactional log 
backups 
http://www.mssqltips.com/sqlservertip/2073/migrating-a-vldb-in-sql-server-with-log-shipping/ 
10/14/2014 www.linchpinpeople.com 11
10/14/2014 www.linchpinpeople.com 12
Log Shipping 
• Transaction Log backups occur on the primary 
• Process ships logs to secondary server(s) 
• Data can be read on the secondary except 
during transaction log restore 
• Can have a Log Ship monitor server 
10/14/2014 www.linchpinpeople.com 13
Monitoring Log Shipping 
• sp_help_log_shipping_monitor 
10/14/2014 www.linchpinpeople.com 14
Log Shipping Pros/Cons 
• Works with Standard Edition 
• Multiple target support 
• Readable secondary copies 
• Can delay restores 
• Dependent on backup of 
primary 
• Manual failover process 
• Reasonably high complexity 
10/14/2014 www.linchpinpeople.com 15
Database Mirroring - Modes 
• High Safety (Synchronous) with Automatic Failover 
• High Safety without Automatic Failover 
• High Performance (Asynchronous) 
Primary Server 
Secondary Server 
Witness 
Instance 
Mirror 
DB 
Mirror 
DB 
10/14/2014 www.linchpinpeople.com 16
Synchronous Mode… 
Mode 
Principal • Transaction (Insert/Update/Delete) inserted into 
Transactional Log 
• Transaction read from the transactional log 
• Transaction shipped to mirror 
Mirror • Transaction written to mirrors transactional log 
• Acknowledgement sent to principal 
• Transaction committed 
Principal • Acknowledgement received 
• Transaction committed. 
10/14/2014 www.linchpinpeople.com 17
Asynchronous Mode… 
(Enterprise) 
Mode 
Principal • Transaction (Insert/Update/Delete) inserted into 
Transactional Log 
• Transaction read from the transactional log 
• Transaction committed 
• Transaction shipped to mirror 
Mirror • Transaction written to mirrors transactional log 
• Acknowledgement sent to principal 
• Transaction committed 
Principal • Acknowledgement received 
10/14/2014 www.linchpinpeople.com 18
Database Mirroring 
• Deprecated in SQL 2012 
• Database transactions are compressed and 
shipped to a secondary (2008+) 
• Transfer may be sync or async (Enterprise) 
• Optional witness server can facilitate failover 
10/14/2014 www.linchpinpeople.com 19
Warning.. Warning.. Warning.. 
http://technet.microsoft.com/en-us/library/ms366349.aspx
Pros and Cons 
• Pros 
• Witness can be any edition of SQL Server 
• Page level corruption fixes 
• Doesn’t require Active Directory 
• Database level High Availability 
• High Safety only requires Standard Edition 
• Cons 
• You cannot mirror system databases 
• Automatic Failover requires a witness 
• Database must be in full recovery 
• High Performance requires Enterprise Edition 
• Must create and sync Instance Objects (Jobs, Logins, etc..) 
10/14/2014 www.linchpinpeople.com 21
Replication 
• Numerous topologies and options involved 
with replication 
• Snapshot Replication 
• Transactional Replication 
• Merge Replication 
• Peer to Peer Replication 
10/14/2014 www.linchpinpeople.com 22
10/14/2014 www.linchpinpeople.com 23
How Transactional Replication 
Works 
http://technet.microsoft.com/en-us/library/ms151706(v=sql.105).aspx
Replication Pros/Cons 
• Replicate to multiple servers 
• Replicate subset of data 
• Can be done with Simple Recovery Model 
• Standard Edition for transactional 
• Manual failover process 
• Unknown RPO 
• Known to be fragile 
• Re-sync can be cumbersome 
• Complex 
10/14/2014 www.linchpinpeople.com 25
Failover Cluster Instances 
Windows Failover Cluster 
SQL Instance 
Node 1 Node 2 
Cluster Virtual Name 
10/14/2014 www.linchpinpeople.com 26
How Windows - SQL Clustering works 
• Physical Nodes 
• Windows cluster 
• Windows cluster group 
• MSDTC 
• SQL cluster 
• Other clustered application 
• End User Access 
27
Failover Cluster Instance (FCI) 
• Pre Windows 2012 – Shared Storage 
• Windows Cluster (Windows 2012 Standard Ed) 
• Two Node Limit on SQL 2012 Standard 
• Quorum 
10/14/2014 www.linchpinpeople.com 28
How Window – SQL Clustering Works 
– Failover Cluster Manager 
Things that you should see in 
Service and Application/ Role 
• Current Status 
• Current Owner 
• Resources 
• Client Access Point 
• Virtual Network Name 
• IP address assigned with the name 
• Storage allocated to the application 
• Services / Applications or Predefined 
Resources 
• Others - optional 
• File shares 
• Printers and so on 
29
Quorum 
10/14/2014 www.linchpinpeople.com 30
10/14/2014 www.linchpinpeople.com 31
10/14/2014 www.linchpinpeople.com 32
10/14/2014 www.linchpinpeople.com 33
10/14/2014 www.linchpinpeople.com 34
Failover Cluster Pros/Cons 
• Multiple Servers (HA) 
• Allows for entire instance 
protection 
• Automatic failover 
• Transparent connections 
• Complex setup 
• Idle hardware 
• Some cases storage single 
point of failure 
10/14/2014 www.linchpinpeople.com 35
Introduction to Availability Groups 
Instance 
1 
Instance 
2 
AG (P) AG (S) 
Node 1 Node 2 
Data Center 1 Data Center 2 
Listner Name (VCO) 
Windows Failover Cluster 
10/14/2014 www.linchpinpeople.com 36
Database Mirroring Problems… 
• Cannot group databases 
• Only get one mirror database 
• No readable copies 
• Requires witness (extra SQL instance) for automatic 
failover 
10/14/2014 www.linchpinpeople.com 37
Availability Group Benefits.. 
• No shared storage 
• Listener (Virtual Computer Object for connectivity) 
• Multiple mirrors replicas 
• Readable copies 
10/14/2014 www.linchpinpeople.com 38
AlwaysOn Availability Groups 
• SQL Server Enterprise Edition 
• Windows Cluster 
• Async and Sync modes 
• Databases failover as a group 
• No shared storage needed 
• Readable replicas 
• Supports up to 8 replicas 
10/14/2014 www.linchpinpeople.com 39
Requires Downtime
10/14/2014 www.linchpinpeople.com 41
AG Configurations 
10/14/2014 www.linchpinpeople.com 42
AG Dashboard 
10/14/2014 www.linchpinpeople.com 43
AlwaysOn Pros/Cons 
• No shared storage 
• Readable secondaries 
• SSMS administration 
• Configuration is easy 
• Grouping DB failover helps 
for complex applications 
setups 
• Enterprise Only - Large 
setups can be 
expensive 
• Newer technology 
• App code changes may 
be needed 
10/14/2014 www.linchpinpeople.com 44
Questions? 
10/14/2014 www.linchpinpeople.com 45

More Related Content

What's hot (20)

PDF
Oracle WebLogic 12c New Multitenancy features
Michel Schildmeijer
 
PDF
Turn you Java EE Monoliths into Microservices with WildFly Swarm
Dimitris Andreadis
 
PDF
Nagios Conference 2014 - Jeremy Rust - Avoiding Downtime Using Linux High Ava...
Nagios
 
PDF
Using Oracle Multitenant to efficiently manage development and test databases
Marc Fielding
 
PDF
KoprowskiT_SQLRelay2014#4_Caerdydd_MaintenancePlansForBeginners
Tobias Koprowski
 
PPT
ActiveMQ 5.9.x new features
Christian Posta
 
PPTX
Database Migrations with Gradle and Liquibase
Dan Stine
 
PDF
Single Source of Truth in a Distributed World by Sven Erik Knop
Perforce
 
PDF
KoprowskiT_SQLSaturdayManchester_2AMaDisasterJustbegan
Tobias Koprowski
 
PPTX
Windows Server 2012 R2 Jump Start - WEB
Paulo Freitas
 
PDF
Embracing Git and Distributed Teams
Perforce
 
PDF
How to create a useful my sql bug report fosdem 2019
Valeriy Kravchuk
 
PPTX
2020 pre fosdem mysql clone
Georgi Kodinov
 
PDF
Simplifying MySQL, Pre-FOSDEM MySQL Days, Brussels, January 30, 2020.
Geir Høydalsvik
 
PPTX
WebLogic and GraalVM
Michel Schildmeijer
 
PDF
Webinar: Achieving Economies of Web Scale in Your Enterprise with Containeriz...
WSO2
 
PDF
June OpenNTF Webinar - Domino V12 Certification Manager
Howard Greenberg
 
PPTX
Xen server 6.1 technical sales presentation
Nuno Alves
 
PDF
Building Bizweb Microservices with Docker
Khôi Nguyễn Minh
 
PDF
MySQL Aquarium Paris
Alexis Moussine-Pouchkine
 
Oracle WebLogic 12c New Multitenancy features
Michel Schildmeijer
 
Turn you Java EE Monoliths into Microservices with WildFly Swarm
Dimitris Andreadis
 
Nagios Conference 2014 - Jeremy Rust - Avoiding Downtime Using Linux High Ava...
Nagios
 
Using Oracle Multitenant to efficiently manage development and test databases
Marc Fielding
 
KoprowskiT_SQLRelay2014#4_Caerdydd_MaintenancePlansForBeginners
Tobias Koprowski
 
ActiveMQ 5.9.x new features
Christian Posta
 
Database Migrations with Gradle and Liquibase
Dan Stine
 
Single Source of Truth in a Distributed World by Sven Erik Knop
Perforce
 
KoprowskiT_SQLSaturdayManchester_2AMaDisasterJustbegan
Tobias Koprowski
 
Windows Server 2012 R2 Jump Start - WEB
Paulo Freitas
 
Embracing Git and Distributed Teams
Perforce
 
How to create a useful my sql bug report fosdem 2019
Valeriy Kravchuk
 
2020 pre fosdem mysql clone
Georgi Kodinov
 
Simplifying MySQL, Pre-FOSDEM MySQL Days, Brussels, January 30, 2020.
Geir Høydalsvik
 
WebLogic and GraalVM
Michel Schildmeijer
 
Webinar: Achieving Economies of Web Scale in Your Enterprise with Containeriz...
WSO2
 
June OpenNTF Webinar - Domino V12 Certification Manager
Howard Greenberg
 
Xen server 6.1 technical sales presentation
Nuno Alves
 
Building Bizweb Microservices with Docker
Khôi Nguyễn Minh
 
MySQL Aquarium Paris
Alexis Moussine-Pouchkine
 

Similar to Introduction to High Availability with SQL Server (20)

PPTX
Cognos Performance Tuning Tips & Tricks
Senturus
 
PPTX
BIWUG1303 - HA & DR
BIWUG
 
PDF
Keynote: Architecting for Continuous Delivery (Pivotal Cloud Platform Roadshow)
VMware Tanzu
 
PDF
Cloud Foundry and Microservices: A Mutualistic Symbiotic Relationship
VMware Tanzu
 
PDF
Cloud Foundry and Microservices: A Mutualistic Symbiotic Relationship
Matt Stine
 
PDF
Best Practices for Becoming an Exceptional Postgres DBA
EDB
 
PPTX
Apache Geode (incubating) Introduction with Docker
William Markito Oliveira
 
PPTX
SharePoint Performance: Physical to Virtual to Microsoft Azure Cloud and Offi...
Joel Oleson
 
PPTX
12 Factor App Methodology
laeshin park
 
PDF
Architecting Your Own DBaaS in a Private Cloud with EM12c
Gustavo Rene Antunez
 
PPTX
V mware view™ poc jumpstart service
solarisyougood
 
PDF
VMware VCP7-DTM: More than just Horizon View
Matt Crape
 
PPTX
From Zero to Performance Hero in Minutes - Agile Testing Days 2014 Potsdam
Andreas Grabner
 
PDF
Building Apps with Distributed In-Memory Computing Using Apache Geode
PivotalOpenSourceHub
 
PDF
SQL Server 2019 CTP2.4
Gianluca Hotz
 
PPTX
Webinar : Microservices and Containerization
Newt Global Consulting LLC
 
PPTX
Configurando Aplicaciones para Réplicas de Lectura de SQL-Server AlwaysOn - C...
SpanishPASSVC
 
PDF
Navigating Transactions: ACID Complexity in Modern Databases
Shivji Kumar Jha
 
PDF
Navigating Transactions: ACID Complexity in Modern Databases- Mydbops Open So...
Mydbops
 
PPTX
Driving Operational Excellence: Delivering Service Assurance in your Virtual ...
Dell Virtualization Operations Management
 
Cognos Performance Tuning Tips & Tricks
Senturus
 
BIWUG1303 - HA & DR
BIWUG
 
Keynote: Architecting for Continuous Delivery (Pivotal Cloud Platform Roadshow)
VMware Tanzu
 
Cloud Foundry and Microservices: A Mutualistic Symbiotic Relationship
VMware Tanzu
 
Cloud Foundry and Microservices: A Mutualistic Symbiotic Relationship
Matt Stine
 
Best Practices for Becoming an Exceptional Postgres DBA
EDB
 
Apache Geode (incubating) Introduction with Docker
William Markito Oliveira
 
SharePoint Performance: Physical to Virtual to Microsoft Azure Cloud and Offi...
Joel Oleson
 
12 Factor App Methodology
laeshin park
 
Architecting Your Own DBaaS in a Private Cloud with EM12c
Gustavo Rene Antunez
 
V mware view™ poc jumpstart service
solarisyougood
 
VMware VCP7-DTM: More than just Horizon View
Matt Crape
 
From Zero to Performance Hero in Minutes - Agile Testing Days 2014 Potsdam
Andreas Grabner
 
Building Apps with Distributed In-Memory Computing Using Apache Geode
PivotalOpenSourceHub
 
SQL Server 2019 CTP2.4
Gianluca Hotz
 
Webinar : Microservices and Containerization
Newt Global Consulting LLC
 
Configurando Aplicaciones para Réplicas de Lectura de SQL-Server AlwaysOn - C...
SpanishPASSVC
 
Navigating Transactions: ACID Complexity in Modern Databases
Shivji Kumar Jha
 
Navigating Transactions: ACID Complexity in Modern Databases- Mydbops Open So...
Mydbops
 
Driving Operational Excellence: Delivering Service Assurance in your Virtual ...
Dell Virtualization Operations Management
 
Ad

More from John Sterrett (15)

PDF
Database Management Myths for Developers
John Sterrett
 
PDF
DBA Basics: Getting Started with Performance Tuning.pdf
John Sterrett
 
PDF
Getting Started with SQL Server Performance Tuning.pdf
John Sterrett
 
PDF
Workload Replay in the Cloud: Secret Weapon for Cloud Migrations
John Sterrett
 
PDF
PowerPivot for DBAs
John Sterrett
 
PPTX
Introduction to PowerShell for DBA's
John Sterrett
 
PPTX
SQL Server Performance Root Cause Analysis in 10 Minutes
John Sterrett
 
PDF
Table Partitioning: Secret Weapon for Big Data Problems
John Sterrett
 
PPTX
Introduction to execution plan analysis
John Sterrett
 
PDF
12 Steps to Workload Tuning
John Sterrett
 
PDF
Performance Tuning for Pirates!
John Sterrett
 
PPTX
Can You Host a SQL Saturday?
John Sterrett
 
PPTX
Evaluating Daily Checklist Against 1000 Servers using Policy Based Management
John Sterrett
 
PPTX
SQL Server 2008 For Developers
John Sterrett
 
PPTX
Evaluate Daily Checklist with PBM and CMS
John Sterrett
 
Database Management Myths for Developers
John Sterrett
 
DBA Basics: Getting Started with Performance Tuning.pdf
John Sterrett
 
Getting Started with SQL Server Performance Tuning.pdf
John Sterrett
 
Workload Replay in the Cloud: Secret Weapon for Cloud Migrations
John Sterrett
 
PowerPivot for DBAs
John Sterrett
 
Introduction to PowerShell for DBA's
John Sterrett
 
SQL Server Performance Root Cause Analysis in 10 Minutes
John Sterrett
 
Table Partitioning: Secret Weapon for Big Data Problems
John Sterrett
 
Introduction to execution plan analysis
John Sterrett
 
12 Steps to Workload Tuning
John Sterrett
 
Performance Tuning for Pirates!
John Sterrett
 
Can You Host a SQL Saturday?
John Sterrett
 
Evaluating Daily Checklist Against 1000 Servers using Policy Based Management
John Sterrett
 
SQL Server 2008 For Developers
John Sterrett
 
Evaluate Daily Checklist with PBM and CMS
John Sterrett
 
Ad

Recently uploaded (20)

PDF
CIFDAQ Token Spotlight for 9th July 2025
CIFDAQ
 
PDF
Fl Studio 24.2.2 Build 4597 Crack for Windows Free Download 2025
faizk77g
 
PPTX
Q2 FY26 Tableau User Group Leader Quarterly Call
lward7
 
PPTX
Building Search Using OpenSearch: Limitations and Workarounds
Sease
 
PDF
HCIP-Data Center Facility Deployment V2.0 Training Material (Without Remarks ...
mcastillo49
 
PDF
Empower Inclusion Through Accessible Java Applications
Ana-Maria Mihalceanu
 
PDF
Building Real-Time Digital Twins with IBM Maximo & ArcGIS Indoors
Safe Software
 
PPTX
COMPARISON OF RASTER ANALYSIS TOOLS OF QGIS AND ARCGIS
Sharanya Sarkar
 
PPTX
WooCommerce Workshop: Bring Your Laptop
Laura Hartwig
 
PPTX
Webinar: Introduction to LF Energy EVerest
DanBrown980551
 
PDF
Chris Elwell Woburn, MA - Passionate About IT Innovation
Chris Elwell Woburn, MA
 
PDF
Biography of Daniel Podor.pdf
Daniel Podor
 
PDF
"AI Transformation: Directions and Challenges", Pavlo Shaternik
Fwdays
 
PDF
CIFDAQ Market Wrap for the week of 4th July 2025
CIFDAQ
 
PDF
Smart Trailers 2025 Update with History and Overview
Paul Menig
 
PDF
"Beyond English: Navigating the Challenges of Building a Ukrainian-language R...
Fwdays
 
PDF
Newgen 2022-Forrester Newgen TEI_13 05 2022-The-Total-Economic-Impact-Newgen-...
darshakparmar
 
PDF
Reverse Engineering of Security Products: Developing an Advanced Microsoft De...
nwbxhhcyjv
 
PDF
Using FME to Develop Self-Service CAD Applications for a Major UK Police Force
Safe Software
 
PDF
Agentic AI lifecycle for Enterprise Hyper-Automation
Debmalya Biswas
 
CIFDAQ Token Spotlight for 9th July 2025
CIFDAQ
 
Fl Studio 24.2.2 Build 4597 Crack for Windows Free Download 2025
faizk77g
 
Q2 FY26 Tableau User Group Leader Quarterly Call
lward7
 
Building Search Using OpenSearch: Limitations and Workarounds
Sease
 
HCIP-Data Center Facility Deployment V2.0 Training Material (Without Remarks ...
mcastillo49
 
Empower Inclusion Through Accessible Java Applications
Ana-Maria Mihalceanu
 
Building Real-Time Digital Twins with IBM Maximo & ArcGIS Indoors
Safe Software
 
COMPARISON OF RASTER ANALYSIS TOOLS OF QGIS AND ARCGIS
Sharanya Sarkar
 
WooCommerce Workshop: Bring Your Laptop
Laura Hartwig
 
Webinar: Introduction to LF Energy EVerest
DanBrown980551
 
Chris Elwell Woburn, MA - Passionate About IT Innovation
Chris Elwell Woburn, MA
 
Biography of Daniel Podor.pdf
Daniel Podor
 
"AI Transformation: Directions and Challenges", Pavlo Shaternik
Fwdays
 
CIFDAQ Market Wrap for the week of 4th July 2025
CIFDAQ
 
Smart Trailers 2025 Update with History and Overview
Paul Menig
 
"Beyond English: Navigating the Challenges of Building a Ukrainian-language R...
Fwdays
 
Newgen 2022-Forrester Newgen TEI_13 05 2022-The-Total-Economic-Impact-Newgen-...
darshakparmar
 
Reverse Engineering of Security Products: Developing an Advanced Microsoft De...
nwbxhhcyjv
 
Using FME to Develop Self-Service CAD Applications for a Major UK Police Force
Safe Software
 
Agentic AI lifecycle for Enterprise Hyper-Automation
Debmalya Biswas
 

Introduction to High Availability with SQL Server

  • 1. Introduction to High Availability with SQL Server 10/14/2014 www.linchpinpeople.com 1
  • 2. John Sterrett Linchpin People Group Principle @johnsterrett [email protected] Johnsterrett.com linked.com/in/johnsterrett google.com/+johnsterrett Leader Austin SQL Server User Group Leader Virtual Chapter “High Availability and Disaster Recovery” PASS Regional Mentor Specialties / Focus Areas / Passions: • Performance Tuning & Troubleshooting • Virtualization • Infrastructure • Architecture • High Availability • Disaster Recovery • Health Monitoring • Capacity Management • License Efficiency www.linchpinpeople.com 2
  • 3. You know us individually, but do you know Linchpin People®? Linchpin People® are database coaches and wellness experts for the Microsoft SQL Server Ecosystem. Our team includes more than 15 of the world’s top SQL Server experts, and we have presented over 175 combined sessions at SQL Saturdays, PASS Summit, and other events in the past year. Do you have specific questions about your database environment? Check out www.LinchpinPeople.com and take a look at the range of services we provide, or contact one of us today to learn how we can help improve your business. www.linchpinpeople.com 3
  • 4. Agenda • HA != DR • Log Shipping • Database Mirroring • Transactional Replication • AlwaysOn Failover Cluster Instance • AlwaysOn Availability Groups • Wrap Up / Question and Answer 10/14/2014 www.linchpinpeople.com 4
  • 5. Introduction Definitions • What do we mean when we say a system is Highly Available? • What does it mean to have a Disaster Recovery system? 10/14/2014 www.linchpinpeople.com 5
  • 6. High Availability What is High Availability • High availability is a system design approach and associated service implementation that ensures a prearranged level of operational performance will be met during a contractual measurement period. – Wikipedia • A System Design that allows for minimal downtime. • Protection from OS or hardware failure 10/14/2014 www.linchpinpeople.com 6
  • 7. Examples of Disasters Photo https://www.flickr.com/photos/ross/39556863/ 10/14/2014 www.linchpinpeople.com 7
  • 8. Most Common Disaster 10/14/2014 www.linchpinpeople.com 8
  • 9. Disaster Recovery What is Disaster Recovery • Risk Management • Recovery Point Objective - RPO • Recovery Time Objective - RTO • Disaster Recovery Plan - DRP • Backups are not enough 10/14/2014 www.linchpinpeople.com 9
  • 10. Options SQL Server Options for HA/DR • Log Shipping • Database Mirroring • Replication • Failover Cluster Instances • AlwaysOn Availability Groups 10/14/2014 www.linchpinpeople.com 10
  • 11. Intro to Log Shipping 1. Transactional Log Backup 2. Copy Transactional log backups 3. Restore Transactional log backups http://www.mssqltips.com/sqlservertip/2073/migrating-a-vldb-in-sql-server-with-log-shipping/ 10/14/2014 www.linchpinpeople.com 11
  • 13. Log Shipping • Transaction Log backups occur on the primary • Process ships logs to secondary server(s) • Data can be read on the secondary except during transaction log restore • Can have a Log Ship monitor server 10/14/2014 www.linchpinpeople.com 13
  • 14. Monitoring Log Shipping • sp_help_log_shipping_monitor 10/14/2014 www.linchpinpeople.com 14
  • 15. Log Shipping Pros/Cons • Works with Standard Edition • Multiple target support • Readable secondary copies • Can delay restores • Dependent on backup of primary • Manual failover process • Reasonably high complexity 10/14/2014 www.linchpinpeople.com 15
  • 16. Database Mirroring - Modes • High Safety (Synchronous) with Automatic Failover • High Safety without Automatic Failover • High Performance (Asynchronous) Primary Server Secondary Server Witness Instance Mirror DB Mirror DB 10/14/2014 www.linchpinpeople.com 16
  • 17. Synchronous Mode… Mode Principal • Transaction (Insert/Update/Delete) inserted into Transactional Log • Transaction read from the transactional log • Transaction shipped to mirror Mirror • Transaction written to mirrors transactional log • Acknowledgement sent to principal • Transaction committed Principal • Acknowledgement received • Transaction committed. 10/14/2014 www.linchpinpeople.com 17
  • 18. Asynchronous Mode… (Enterprise) Mode Principal • Transaction (Insert/Update/Delete) inserted into Transactional Log • Transaction read from the transactional log • Transaction committed • Transaction shipped to mirror Mirror • Transaction written to mirrors transactional log • Acknowledgement sent to principal • Transaction committed Principal • Acknowledgement received 10/14/2014 www.linchpinpeople.com 18
  • 19. Database Mirroring • Deprecated in SQL 2012 • Database transactions are compressed and shipped to a secondary (2008+) • Transfer may be sync or async (Enterprise) • Optional witness server can facilitate failover 10/14/2014 www.linchpinpeople.com 19
  • 20. Warning.. Warning.. Warning.. http://technet.microsoft.com/en-us/library/ms366349.aspx
  • 21. Pros and Cons • Pros • Witness can be any edition of SQL Server • Page level corruption fixes • Doesn’t require Active Directory • Database level High Availability • High Safety only requires Standard Edition • Cons • You cannot mirror system databases • Automatic Failover requires a witness • Database must be in full recovery • High Performance requires Enterprise Edition • Must create and sync Instance Objects (Jobs, Logins, etc..) 10/14/2014 www.linchpinpeople.com 21
  • 22. Replication • Numerous topologies and options involved with replication • Snapshot Replication • Transactional Replication • Merge Replication • Peer to Peer Replication 10/14/2014 www.linchpinpeople.com 22
  • 24. How Transactional Replication Works http://technet.microsoft.com/en-us/library/ms151706(v=sql.105).aspx
  • 25. Replication Pros/Cons • Replicate to multiple servers • Replicate subset of data • Can be done with Simple Recovery Model • Standard Edition for transactional • Manual failover process • Unknown RPO • Known to be fragile • Re-sync can be cumbersome • Complex 10/14/2014 www.linchpinpeople.com 25
  • 26. Failover Cluster Instances Windows Failover Cluster SQL Instance Node 1 Node 2 Cluster Virtual Name 10/14/2014 www.linchpinpeople.com 26
  • 27. How Windows - SQL Clustering works • Physical Nodes • Windows cluster • Windows cluster group • MSDTC • SQL cluster • Other clustered application • End User Access 27
  • 28. Failover Cluster Instance (FCI) • Pre Windows 2012 – Shared Storage • Windows Cluster (Windows 2012 Standard Ed) • Two Node Limit on SQL 2012 Standard • Quorum 10/14/2014 www.linchpinpeople.com 28
  • 29. How Window – SQL Clustering Works – Failover Cluster Manager Things that you should see in Service and Application/ Role • Current Status • Current Owner • Resources • Client Access Point • Virtual Network Name • IP address assigned with the name • Storage allocated to the application • Services / Applications or Predefined Resources • Others - optional • File shares • Printers and so on 29
  • 35. Failover Cluster Pros/Cons • Multiple Servers (HA) • Allows for entire instance protection • Automatic failover • Transparent connections • Complex setup • Idle hardware • Some cases storage single point of failure 10/14/2014 www.linchpinpeople.com 35
  • 36. Introduction to Availability Groups Instance 1 Instance 2 AG (P) AG (S) Node 1 Node 2 Data Center 1 Data Center 2 Listner Name (VCO) Windows Failover Cluster 10/14/2014 www.linchpinpeople.com 36
  • 37. Database Mirroring Problems… • Cannot group databases • Only get one mirror database • No readable copies • Requires witness (extra SQL instance) for automatic failover 10/14/2014 www.linchpinpeople.com 37
  • 38. Availability Group Benefits.. • No shared storage • Listener (Virtual Computer Object for connectivity) • Multiple mirrors replicas • Readable copies 10/14/2014 www.linchpinpeople.com 38
  • 39. AlwaysOn Availability Groups • SQL Server Enterprise Edition • Windows Cluster • Async and Sync modes • Databases failover as a group • No shared storage needed • Readable replicas • Supports up to 8 replicas 10/14/2014 www.linchpinpeople.com 39
  • 42. AG Configurations 10/14/2014 www.linchpinpeople.com 42
  • 43. AG Dashboard 10/14/2014 www.linchpinpeople.com 43
  • 44. AlwaysOn Pros/Cons • No shared storage • Readable secondaries • SSMS administration • Configuration is easy • Grouping DB failover helps for complex applications setups • Enterprise Only - Large setups can be expensive • Newer technology • App code changes may be needed 10/14/2014 www.linchpinpeople.com 44