SlideShare ist ein Scribd-Unternehmen logo
1 von 33
SQL Server
AlwaysOn for
Dummies
Mark Broadbent
Principal SQL Consultant
SQLCloud
SQLCLOUD.CO.UK
About
Mark Broadbent
“Possibly the hardest drinking DBA on the planet”
“30 billion times more intelligent than a live mattress”
Email: mark.broadbent@sqlcambs.org.uk
Twitter: retracement
Blog: http://tenbulls.co.uk
PASS UK Regional Mentor
Event Lead to the UK’s first ever SQLSaturday (Cambridge)
Event #2nd due on Friday 27th Sept 2013 (pre-con) 28th Sept (Community day)
http://www.sqlsaturday.com/228/eventhome.aspx
Cambridgeshire PASS Chapter UG Leader http://sqlcambs.org.uk
SQLSaturday Cambridge 2013
27th (pre-con) and 28th (free) September
http://www.sqlsaturday.com/228
Queen’s College, Cambridge CB3 9ET
What is the air-speed velocity of an unladen swallow?
Agenda
Windows Server
Failover Clustering
& Quorum
AlwaysOn
Availability Groups
AlwaysOn Failover
Clustered Instances
Introduction to
AlwaysOn
3
2
1
4
Introduction to AlwaysOn
AlwaysOn Technologies*1
*1 According to my interpretation!
AlwaysOn
Availability Groups
AlwaysOn Failover
Clustered Instances
Database
Mirroring
Scalable Shared
Database
Replication
“AlwAys On” isnae new!
Dr. Evil
Senior Microsoft
Windows Clustering
Program Manager
Don’t let the terms confuse you!
Cluster Node
Cluster Server
Node
Server
Cluster Group
Role
Service or Application
Virtual Server
Failover Cluster
Clustered Instance
SQL Server
Server
Resources (take your pick)
Quorum
Client Network
Private Network
Interconnect
Internal Network
Public Network...
LAN
SAN
Shared Storage
Disk
Cluster Storage
Active/Passive
Single Instance
Multi Instance
N+n Cluster
Majority
Votes
Availability Group
Replica
Readonly Replica
AlwaysOn Clustered Instances Provide…
• Abstraction of SQL instance
• High availability of Instance name
• Instance and related services failover as a unit
• Instance components such as jobs and logins not
a consideration
• Distributed Transaction Support
BUT
• Shared data with single point of failure per
instance.
• Complex to administrate
Availability Groups Provide…
• Abstraction at the databases level
• Failover as a single Unit
• High availability of “Instance” (listener) name
• All the benefits of DB Mirroring
….and less of the problems (FS is supported)
BUT
• Connected replicas are potentially single point of failure (i.e
user error – deletion of records)
• Complex (arguably less than FCI) to administrate
• Instance level components not failed over –contained dbs
partially come to the rescue
• No Distributed Transaction support for failover
AlwaysOn is…
Windows Server
Failover Clustering
The foundation of AlwaysOn
“The Magic” of Clustering
Clustered
“Application”
Cluster Nodes
The “magic” of clustering is the ability for the cluster to ensure only one set of services,
executables and resources are alive on one node for a clustered application at any one time.
A clustered application will be installed onto each node
“The Magic” of Clustering
Clustered
“Application”
Cluster Nodes
failover
“The Magic” of Clustering
Clustered
“Application”
Cluster Nodes
failover
Storage
Network
Internal
Network
A Basic Windows Cluster
Public
(or Client) Network
Shared
(or Asymmetric) Storage
Quorum
The Cluster
Group
Cluster Node
Cluster Service
Understanding Quorum
I’m
Alive!
Quorum Models
Node majority (no witness)
Node majority with witness (disk or file share)
No majority (disk witness only)
+Node weighting
Dynamic weighting -new to
Windows 2012
DEMO
Taking a look at our Cluster
AlwaysOn Failover
Clustered Instances
Instance Level High Availability
Installation
Create and install your clustered
instance on the first cluster node
For all other nodes install
executables on every other node
Clustered Instances
Node A Node B
SQL Server Instance A
Role (formerly known as
Cluster Group)
Network
Name
Clustered Instances
failoverNode A Node B
SQL Server Instance A
Role (formerly known as
Cluster Group)
Network
Name
AlwaysOn
Availability Groups
Database[s] Level High Availability
Availability Group consists of…
Listener
(Name and
IP)
Availability
Group
Resource
Availability
Group
Databases
SQL Instance Components Wndows Cluster Resources
Replica/s
Availability
Cluster Group
Mirroring
Endpoints
Availability
Group
Listener
(Name and
IP)
Do not flippin’ touch!
Transaction Logs
Secondary Replica
SQL Server Instance A
Transaction Logs
Primary Replica
SQL Server Instance A
Availability Groups
Transaction Logs
Redo
Sync/ Async
Secondary Replica
SQL Server Instance B
Listener
Transaction Logs
Secondary Replica
SQL Server Instance A
Availability Groups
Transaction Logs
Sync/ Async
Secondary Replica
SQL Server Instance B
Listener
Redo
Transaction Logs
Primary Replica
SQL Server Instance B
Availability Groups and Readable Secondaries
• 5 Replicas
• 2 Synchronous, others Asynchronous
• 1 Read-Write
• 4 either Read-only, Read-Intent or No Access
DEMO
Using AlwaysOn
ReadOnly Routing
• Set connection string property
ApplicationIntent=ReadOnly
• Must connect to a listener.
• Modify Secondary Replica Roles with read
only routing url.
• Modify Primary Replica Roles with read only
routing list.
In Summary…
• It is not all Butterflys and Unicorns so choose the
HA solution appropriate to your requirements.
• Failover Clustering is a very mature technology
but requires specialist skill and understanding. It
does not provide scalability.
• Availability Groups partially rely on Windows
Clustering but are slightly easier to setup and
manage. They also provide reporting query
scalability.
Tha mo bhàta-foluaimein loma-làn easgannan
for attending this session and
SQLSaturday #202 in Edinburgh
Thank you!

Weitere ähnliche Inhalte

Was ist angesagt?

Oracle Database Overview
Oracle Database OverviewOracle Database Overview
Oracle Database Overview
honglee71
 
Overview of oracle database
Overview of oracle databaseOverview of oracle database
Overview of oracle database
Samar Prasad
 

Was ist angesagt? (20)

Oracle Database Overview
Oracle Database OverviewOracle Database Overview
Oracle Database Overview
 
Sql server basics
Sql server basicsSql server basics
Sql server basics
 
Ms sql server architecture
Ms sql server architectureMs sql server architecture
Ms sql server architecture
 
Microsoft SQL Server internals & architecture
Microsoft SQL Server internals & architectureMicrosoft SQL Server internals & architecture
Microsoft SQL Server internals & architecture
 
Oracle archi ppt
Oracle archi pptOracle archi ppt
Oracle archi ppt
 
Overview SQL Server 2019
Overview SQL Server 2019Overview SQL Server 2019
Overview SQL Server 2019
 
Sql server 2019 new features
Sql server 2019 new featuresSql server 2019 new features
Sql server 2019 new features
 
SQL Server Performance Tuning Baseline
SQL Server Performance Tuning BaselineSQL Server Performance Tuning Baseline
SQL Server Performance Tuning Baseline
 
Rapid Home Provisioning
Rapid Home ProvisioningRapid Home Provisioning
Rapid Home Provisioning
 
Sql Server Basics
Sql Server BasicsSql Server Basics
Sql Server Basics
 
Sql server basics
Sql server basicsSql server basics
Sql server basics
 
153 Oracle dba interview questions
153 Oracle dba interview questions153 Oracle dba interview questions
153 Oracle dba interview questions
 
An Introduction To Oracle Database
An Introduction To Oracle DatabaseAn Introduction To Oracle Database
An Introduction To Oracle Database
 
MSBI-SSRS PPT
MSBI-SSRS PPTMSBI-SSRS PPT
MSBI-SSRS PPT
 
Oracle dba training
Oracle  dba    training Oracle  dba    training
Oracle dba training
 
SQLServer Database Structures
SQLServer Database Structures SQLServer Database Structures
SQLServer Database Structures
 
Troubleshooting sql server
Troubleshooting sql serverTroubleshooting sql server
Troubleshooting sql server
 
Microsoft Azure Data Factory Hands-On Lab Overview Slides
Microsoft Azure Data Factory Hands-On Lab Overview SlidesMicrosoft Azure Data Factory Hands-On Lab Overview Slides
Microsoft Azure Data Factory Hands-On Lab Overview Slides
 
Table Partitioning in SQL Server: A Magic Solution for Better Performance? (P...
Table Partitioning in SQL Server: A Magic Solution for Better Performance? (P...Table Partitioning in SQL Server: A Magic Solution for Better Performance? (P...
Table Partitioning in SQL Server: A Magic Solution for Better Performance? (P...
 
Overview of oracle database
Overview of oracle databaseOverview of oracle database
Overview of oracle database
 

Ähnlich wie SQL Server AlwaysOn for Dummies SQLSaturday #202 Edition

SQL Server Cluster Presentation
SQL Server Cluster PresentationSQL Server Cluster Presentation
SQL Server Cluster Presentation
webhostingguy
 
SQL Server Clustering for Dummies
SQL Server Clustering for DummiesSQL Server Clustering for Dummies
SQL Server Clustering for Dummies
Mark Broadbent
 
Clustered Architecture Patterns Delivering Scalability And Availability
Clustered Architecture Patterns Delivering Scalability And AvailabilityClustered Architecture Patterns Delivering Scalability And Availability
Clustered Architecture Patterns Delivering Scalability And Availability
ConSanFrancisco123
 
Jdbc Best Practices - DB2/ IDUG - Orlando, May 10, 2004
Jdbc Best Practices - DB2/ IDUG - Orlando, May 10, 2004Jdbc Best Practices - DB2/ IDUG - Orlando, May 10, 2004
Jdbc Best Practices - DB2/ IDUG - Orlando, May 10, 2004
derek_clark_ashmore
 
QConSF2016-JoshEvans-MasteringChaosANetflixGuidetoMicroservices-compressed.pdf
QConSF2016-JoshEvans-MasteringChaosANetflixGuidetoMicroservices-compressed.pdfQConSF2016-JoshEvans-MasteringChaosANetflixGuidetoMicroservices-compressed.pdf
QConSF2016-JoshEvans-MasteringChaosANetflixGuidetoMicroservices-compressed.pdf
SimranjyotSuri
 

Ähnlich wie SQL Server AlwaysOn for Dummies SQLSaturday #202 Edition (20)

SQL Server Cluster Presentation
SQL Server Cluster PresentationSQL Server Cluster Presentation
SQL Server Cluster Presentation
 
Using Kubernetes to deliver a “serverless” service
Using Kubernetes to deliver a “serverless” serviceUsing Kubernetes to deliver a “serverless” service
Using Kubernetes to deliver a “serverless” service
 
SQL Server Clustering for Dummies
SQL Server Clustering for DummiesSQL Server Clustering for Dummies
SQL Server Clustering for Dummies
 
Schizophrenic High Availability with SQL and Windows 2016
Schizophrenic High Availability with SQL and Windows 2016Schizophrenic High Availability with SQL and Windows 2016
Schizophrenic High Availability with SQL and Windows 2016
 
Microservices and Friends
Microservices and FriendsMicroservices and Friends
Microservices and Friends
 
Clustering van IT-componenten
Clustering van IT-componentenClustering van IT-componenten
Clustering van IT-componenten
 
Sql server 2012 ha dr
Sql server 2012 ha drSql server 2012 ha dr
Sql server 2012 ha dr
 
MySQL for Oracle DBA -- Rocky Mountain Oracle User Group Training Days '15
MySQL for Oracle DBA -- Rocky Mountain Oracle User Group Training Days '15MySQL for Oracle DBA -- Rocky Mountain Oracle User Group Training Days '15
MySQL for Oracle DBA -- Rocky Mountain Oracle User Group Training Days '15
 
Clustered Architecture Patterns Delivering Scalability And Availability
Clustered Architecture Patterns Delivering Scalability And AvailabilityClustered Architecture Patterns Delivering Scalability And Availability
Clustered Architecture Patterns Delivering Scalability And Availability
 
Design, Deploy, and Optimize SQL Server on AWS - AWS Online Tech Talks
Design, Deploy, and Optimize SQL Server on AWS - AWS Online Tech TalksDesign, Deploy, and Optimize SQL Server on AWS - AWS Online Tech Talks
Design, Deploy, and Optimize SQL Server on AWS - AWS Online Tech Talks
 
Design, Deploy, and Optimize SQL Server on AWS - June 2017 AWS Online Tech Talks
Design, Deploy, and Optimize SQL Server on AWS - June 2017 AWS Online Tech TalksDesign, Deploy, and Optimize SQL Server on AWS - June 2017 AWS Online Tech Talks
Design, Deploy, and Optimize SQL Server on AWS - June 2017 AWS Online Tech Talks
 
Jdbc Best Practices - DB2/ IDUG - Orlando, May 10, 2004
Jdbc Best Practices - DB2/ IDUG - Orlando, May 10, 2004Jdbc Best Practices - DB2/ IDUG - Orlando, May 10, 2004
Jdbc Best Practices - DB2/ IDUG - Orlando, May 10, 2004
 
Moves Like Jagger - Upgrading to SQL Server 2012 (SQLBits XI Edition)
Moves Like Jagger - Upgrading to SQL Server 2012 (SQLBits XI Edition)Moves Like Jagger - Upgrading to SQL Server 2012 (SQLBits XI Edition)
Moves Like Jagger - Upgrading to SQL Server 2012 (SQLBits XI Edition)
 
20141021 AWS Cloud Taekwon - Startup Best Practices on AWS
20141021 AWS Cloud Taekwon - Startup Best Practices on AWS20141021 AWS Cloud Taekwon - Startup Best Practices on AWS
20141021 AWS Cloud Taekwon - Startup Best Practices on AWS
 
Mastering Chaos - A Netflix Guide to Microservices
Mastering Chaos - A Netflix Guide to MicroservicesMastering Chaos - A Netflix Guide to Microservices
Mastering Chaos - A Netflix Guide to Microservices
 
MySQL Webinar 2/4 Performance tuning, hardware, optimisation
MySQL Webinar 2/4 Performance tuning, hardware, optimisationMySQL Webinar 2/4 Performance tuning, hardware, optimisation
MySQL Webinar 2/4 Performance tuning, hardware, optimisation
 
QConSF2016-JoshEvans-MasteringChaosANetflixGuidetoMicroservices-compressed.pdf
QConSF2016-JoshEvans-MasteringChaosANetflixGuidetoMicroservices-compressed.pdfQConSF2016-JoshEvans-MasteringChaosANetflixGuidetoMicroservices-compressed.pdf
QConSF2016-JoshEvans-MasteringChaosANetflixGuidetoMicroservices-compressed.pdf
 
Azure SQL - more or/and less than SQL Server
Azure SQL - more or/and less than SQL ServerAzure SQL - more or/and less than SQL Server
Azure SQL - more or/and less than SQL Server
 
Why MySQL
Why MySQLWhy MySQL
Why MySQL
 
GWAB 2015 - Data Plaraform
GWAB 2015 - Data PlaraformGWAB 2015 - Data Plaraform
GWAB 2015 - Data Plaraform
 

Mehr von Mark Broadbent

Enter the Dragon - SQL 2014 on Server Core PASS Summit 2014 Edition
Enter the Dragon -  SQL 2014 on Server Core PASS Summit 2014 EditionEnter the Dragon -  SQL 2014 on Server Core PASS Summit 2014 Edition
Enter the Dragon - SQL 2014 on Server Core PASS Summit 2014 Edition
Mark Broadbent
 
READPAST & Furious: Locking
READPAST & Furious: Locking READPAST & Furious: Locking
READPAST & Furious: Locking
Mark Broadbent
 
Orders of-magnitude-scale-out-your-sql-server-data-slideshare
Orders of-magnitude-scale-out-your-sql-server-data-slideshareOrders of-magnitude-scale-out-your-sql-server-data-slideshare
Orders of-magnitude-scale-out-your-sql-server-data-slideshare
Mark Broadbent
 

Mehr von Mark Broadbent (14)

Persistence Is Futile - Implementing Delayed Durability
Persistence Is Futile - Implementing Delayed DurabilityPersistence Is Futile - Implementing Delayed Durability
Persistence Is Futile - Implementing Delayed Durability
 
Lockless in Seattle - Using In-Memory OLTP for Transaction Processing
Lockless in Seattle -  Using In-Memory OLTP for Transaction ProcessingLockless in Seattle -  Using In-Memory OLTP for Transaction Processing
Lockless in Seattle - Using In-Memory OLTP for Transaction Processing
 
SharePoint is from Mars, SQL Server is from Venus (SQL Server for SharePoint ...
SharePoint is from Mars, SQL Server is from Venus (SQL Server for SharePoint ...SharePoint is from Mars, SQL Server is from Venus (SQL Server for SharePoint ...
SharePoint is from Mars, SQL Server is from Venus (SQL Server for SharePoint ...
 
lock, block & two smoking barrels
lock, block & two smoking barrelslock, block & two smoking barrels
lock, block & two smoking barrels
 
Enter the Dragon - SQL 2014 on Server Core PASS Summit 2014 Edition
Enter the Dragon -  SQL 2014 on Server Core PASS Summit 2014 EditionEnter the Dragon -  SQL 2014 on Server Core PASS Summit 2014 Edition
Enter the Dragon - SQL 2014 on Server Core PASS Summit 2014 Edition
 
Being Buck Woody - PASS Summit 2014 Edition
Being Buck Woody - PASS Summit 2014 EditionBeing Buck Woody - PASS Summit 2014 Edition
Being Buck Woody - PASS Summit 2014 Edition
 
Enter The Dragon - SQL 2014 on Server Core - SQLSaturday #341 Porto Edition
Enter The Dragon - SQL 2014 on Server Core - SQLSaturday #341 Porto EditionEnter The Dragon - SQL 2014 on Server Core - SQLSaturday #341 Porto Edition
Enter The Dragon - SQL 2014 on Server Core - SQLSaturday #341 Porto Edition
 
Ye Olde Cluster Curiosity Shoppe
Ye Olde Cluster Curiosity ShoppeYe Olde Cluster Curiosity Shoppe
Ye Olde Cluster Curiosity Shoppe
 
SQLSaturday #188 Lisbon - READPAST & Furious: Transactions, Locking and Isola...
SQLSaturday #188 Lisbon - READPAST & Furious: Transactions, Locking and Isola...SQLSaturday #188 Lisbon - READPAST & Furious: Transactions, Locking and Isola...
SQLSaturday #188 Lisbon - READPAST & Furious: Transactions, Locking and Isola...
 
READPAST & Furious - Transactions, Locking and Isolation. PASS Summit 2012 Ed...
READPAST & Furious - Transactions, Locking and Isolation. PASS Summit 2012 Ed...READPAST & Furious - Transactions, Locking and Isolation. PASS Summit 2012 Ed...
READPAST & Furious - Transactions, Locking and Isolation. PASS Summit 2012 Ed...
 
PASS 2012 "Moves Like Jagger" - Upgrading to SQL Server 2012
PASS 2012 "Moves Like Jagger" - Upgrading to SQL Server 2012PASS 2012 "Moves Like Jagger" - Upgrading to SQL Server 2012
PASS 2012 "Moves Like Jagger" - Upgrading to SQL Server 2012
 
READPAST & Furious: Locking
READPAST & Furious: Locking READPAST & Furious: Locking
READPAST & Furious: Locking
 
Orders of-magnitude-scale-out-your-sql-server-data-slideshare
Orders of-magnitude-scale-out-your-sql-server-data-slideshareOrders of-magnitude-scale-out-your-sql-server-data-slideshare
Orders of-magnitude-scale-out-your-sql-server-data-slideshare
 
Thinking outside the box, learning a little about a lot
Thinking outside the box, learning a little about a lotThinking outside the box, learning a little about a lot
Thinking outside the box, learning a little about a lot
 

Kürzlich hochgeladen

+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
?#DUbAI#??##{{(☎️+971_581248768%)**%*]'#abortion pills for sale in dubai@
 

Kürzlich hochgeladen (20)

Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdf
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
HTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesHTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation Strategies
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Advantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessAdvantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your Business
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 

SQL Server AlwaysOn for Dummies SQLSaturday #202 Edition

  • 1. SQL Server AlwaysOn for Dummies Mark Broadbent Principal SQL Consultant SQLCloud SQLCLOUD.CO.UK
  • 2. About Mark Broadbent “Possibly the hardest drinking DBA on the planet” “30 billion times more intelligent than a live mattress” Email: mark.broadbent@sqlcambs.org.uk Twitter: retracement Blog: http://tenbulls.co.uk PASS UK Regional Mentor Event Lead to the UK’s first ever SQLSaturday (Cambridge) Event #2nd due on Friday 27th Sept 2013 (pre-con) 28th Sept (Community day) http://www.sqlsaturday.com/228/eventhome.aspx Cambridgeshire PASS Chapter UG Leader http://sqlcambs.org.uk
  • 3. SQLSaturday Cambridge 2013 27th (pre-con) and 28th (free) September http://www.sqlsaturday.com/228 Queen’s College, Cambridge CB3 9ET What is the air-speed velocity of an unladen swallow?
  • 4. Agenda Windows Server Failover Clustering & Quorum AlwaysOn Availability Groups AlwaysOn Failover Clustered Instances Introduction to AlwaysOn 3 2 1 4
  • 6. AlwaysOn Technologies*1 *1 According to my interpretation! AlwaysOn Availability Groups AlwaysOn Failover Clustered Instances Database Mirroring Scalable Shared Database Replication
  • 8. Dr. Evil Senior Microsoft Windows Clustering Program Manager
  • 9. Don’t let the terms confuse you! Cluster Node Cluster Server Node Server Cluster Group Role Service or Application Virtual Server Failover Cluster Clustered Instance SQL Server Server Resources (take your pick) Quorum Client Network Private Network Interconnect Internal Network Public Network... LAN SAN Shared Storage Disk Cluster Storage Active/Passive Single Instance Multi Instance N+n Cluster Majority Votes Availability Group Replica Readonly Replica
  • 10. AlwaysOn Clustered Instances Provide… • Abstraction of SQL instance • High availability of Instance name • Instance and related services failover as a unit • Instance components such as jobs and logins not a consideration • Distributed Transaction Support BUT • Shared data with single point of failure per instance. • Complex to administrate
  • 11. Availability Groups Provide… • Abstraction at the databases level • Failover as a single Unit • High availability of “Instance” (listener) name • All the benefits of DB Mirroring ….and less of the problems (FS is supported) BUT • Connected replicas are potentially single point of failure (i.e user error – deletion of records) • Complex (arguably less than FCI) to administrate • Instance level components not failed over –contained dbs partially come to the rescue • No Distributed Transaction support for failover
  • 13. Windows Server Failover Clustering The foundation of AlwaysOn
  • 14. “The Magic” of Clustering Clustered “Application” Cluster Nodes The “magic” of clustering is the ability for the cluster to ensure only one set of services, executables and resources are alive on one node for a clustered application at any one time. A clustered application will be installed onto each node
  • 15. “The Magic” of Clustering Clustered “Application” Cluster Nodes failover
  • 16. “The Magic” of Clustering Clustered “Application” Cluster Nodes failover
  • 17. Storage Network Internal Network A Basic Windows Cluster Public (or Client) Network Shared (or Asymmetric) Storage Quorum The Cluster Group Cluster Node Cluster Service
  • 19. Quorum Models Node majority (no witness) Node majority with witness (disk or file share) No majority (disk witness only) +Node weighting Dynamic weighting -new to Windows 2012
  • 20. DEMO Taking a look at our Cluster
  • 22. Installation Create and install your clustered instance on the first cluster node For all other nodes install executables on every other node
  • 23. Clustered Instances Node A Node B SQL Server Instance A Role (formerly known as Cluster Group) Network Name
  • 24. Clustered Instances failoverNode A Node B SQL Server Instance A Role (formerly known as Cluster Group) Network Name
  • 26. Availability Group consists of… Listener (Name and IP) Availability Group Resource Availability Group Databases SQL Instance Components Wndows Cluster Resources Replica/s Availability Cluster Group Mirroring Endpoints Availability Group Listener (Name and IP) Do not flippin’ touch!
  • 27. Transaction Logs Secondary Replica SQL Server Instance A Transaction Logs Primary Replica SQL Server Instance A Availability Groups Transaction Logs Redo Sync/ Async Secondary Replica SQL Server Instance B Listener
  • 28. Transaction Logs Secondary Replica SQL Server Instance A Availability Groups Transaction Logs Sync/ Async Secondary Replica SQL Server Instance B Listener Redo Transaction Logs Primary Replica SQL Server Instance B
  • 29. Availability Groups and Readable Secondaries • 5 Replicas • 2 Synchronous, others Asynchronous • 1 Read-Write • 4 either Read-only, Read-Intent or No Access
  • 31. ReadOnly Routing • Set connection string property ApplicationIntent=ReadOnly • Must connect to a listener. • Modify Secondary Replica Roles with read only routing url. • Modify Primary Replica Roles with read only routing list.
  • 32. In Summary… • It is not all Butterflys and Unicorns so choose the HA solution appropriate to your requirements. • Failover Clustering is a very mature technology but requires specialist skill and understanding. It does not provide scalability. • Availability Groups partially rely on Windows Clustering but are slightly easier to setup and manage. They also provide reporting query scalability.
  • 33. Tha mo bhàta-foluaimein loma-làn easgannan for attending this session and SQLSaturday #202 in Edinburgh Thank you!