+ All Categories
Home > Technology > Ionut hrubaru, bogdan lazarescu sql server high availability

Ionut hrubaru, bogdan lazarescu sql server high availability

Date post: 01-Jul-2015
Category:
Upload: codecampiasi
View: 151 times
Download: 1 times
Share this document with a friend
Description:
CodeCampIasi25Oct2014
25
SQL Server High Availability and Disaster Recovery using AlwaysOn Availability Groups Ionuţ Hrubaru: [email protected] Bogdan Lăzărescu: [email protected] Dragoş Eşanu: [email protected] Iaşi, 25.10.2014
Transcript
Page 1: Ionut hrubaru, bogdan lazarescu   sql server high availability

SQL Server High Availability and Disaster Recovery using

AlwaysOn Availability Groups

Ionuţ Hrubaru: [email protected] Lăzărescu: [email protected]ş Eşanu: [email protected]

Iaşi, 25.10.2014

Page 2: Ionut hrubaru, bogdan lazarescu   sql server high availability

Agenda

HA/DR concepts

SQL Server HA/DR technologies

AlwaysOn Availability Groups

Demo

Page 3: Ionut hrubaru, bogdan lazarescu   sql server high availability

HA/DR

What does it mean?

Business continuity management

Quantifying downtime: RPO/RTO

Planning

Page 4: Ionut hrubaru, bogdan lazarescu   sql server high availability

HA/DR

Disaster recovery (DR) involves a set of policies and procedures to enable the recovery or continuation of vital technology infrastructure and systems following a natural or human-induced disaster.

Page 5: Ionut hrubaru, bogdan lazarescu   sql server high availability

Business Continuity Plan

Policies, processes and procedures Possible options and decision-making responsibility

Human resources and facilities Information technology

PPT Process

People

Technology

Page 6: Ionut hrubaru, bogdan lazarescu   sql server high availability

High Availability

Minimize the impact of downtime Business impact SLA

𝐴𝑐𝑡𝑢𝑎𝑙𝑢𝑝𝑡𝑖𝑚𝑒𝐸𝑥𝑝𝑒𝑐𝑡𝑒𝑑𝑢𝑝𝑡𝑖𝑚𝑒

×100%

Number of 9’s Availability Percentage Total Annual Downtime

2 99% 3 days, 15 hours3 99.9% 8 hours, 45 minutes4 99.99% 52 minutes, 34 seconds5 99.999% 5 minutes, 15 seconds

Page 7: Ionut hrubaru, bogdan lazarescu   sql server high availability

High Availability

Planned vs. Unplanned Maintenance Downtime = direct & indirect costs ROI and opportunity cost

High Availability

For isolated server failuresWindows crash, RAID controller failure, SQL or Windows patch fails, C drive full, bad memory chip, wrong box unplugged

For widespread outagesData center power or network outage, domain controller failure, SAN failure, fire, quake, zombies in the data center

Disaster Recovery “Oops” Deletions

For human T-SQL errorsDELETE without a where clause, bug in stored procedure for updates, end user needing a restore due to human error

Source: brentozar.com

Page 8: Ionut hrubaru, bogdan lazarescu   sql server high availability

Technologies

Page 9: Ionut hrubaru, bogdan lazarescu   sql server high availability

Log Shipping

Page 10: Ionut hrubaru, bogdan lazarescu   sql server high availability

Pros and Cons

Pros Cons

Multiple servers Manual failover

Cheap Backup dependent

Reporting Data loss

Protection against user mistakes

Use case

DR

Easy configuration

Low cost

Larger RTO

Page 11: Ionut hrubaru, bogdan lazarescu   sql server high availability

Mirroring

Page 12: Ionut hrubaru, bogdan lazarescu   sql server high availability

Pros and Cons

Pros Cons

Automatic failover 2 servers (databases) only

Standard edition (sync) Secondary database inaccessible

Transparency Possible performance issues (sync)

Cheap (sync) Deprecated (2012)

Use case

HA (sync mode) – same datacenter

Easy configuration

Low cost

RPO/RTO close to zero

Page 13: Ionut hrubaru, bogdan lazarescu   sql server high availability

Replication

Page 14: Ionut hrubaru, bogdan lazarescu   sql server high availability

Pros and Cons

Pros Cons

Read-write secondary dbs Manual failover

Standard edition Complex setup

Multiple servers Performance (transactional)

Disconnected architecture – multi master (merge)

Use case

Scale out

Offline processing

It’s about making data available, not redundant

Page 15: Ionut hrubaru, bogdan lazarescu   sql server high availability

Failover Cluster

Page 16: Ionut hrubaru, bogdan lazarescu   sql server high availability

Pros and Cons

Pros Cons

Instance level protection Shared storage SPOF

Multi server cluster Expensive

Automatic failover Complex setup

Transparency to the application

Use case

HA

Page 17: Ionut hrubaru, bogdan lazarescu   sql server high availability

Typical HA/DR Topology

Page 18: Ionut hrubaru, bogdan lazarescu   sql server high availability

AlwaysOn

Features AlwaysOn Failover Cluster Instances (FCIs) AlwaysOn Availability Groups

Layers of protection Infrastructure (WSFC) SQL Server instance level (FCI) Database level (Availability Groups) Client connectivity (VNN => AG Listener)

Page 19: Ionut hrubaru, bogdan lazarescu   sql server high availability

Availability Groups

Multiple databasesScale out

Non shared storageAutomatic page repair

Page 20: Ionut hrubaru, bogdan lazarescu   sql server high availability

Pros and Cons

Pros Cons

Built upon mirroring Rather complex setup

Multiple databases Performance (sync)

Scale out

Use case

HA

DR

Scale reads

Page 21: Ionut hrubaru, bogdan lazarescu   sql server high availability

Comparison

High Availability and Disaster RecoverySQL Server Solution

Potential Data Loss (RPO)

Potential Recovery Time (RTO)

Automatic Failover

Readable Secondaries

AlwaysOn Availability Group - synchronous-commit Zero Seconds Yes 0 - 4

AlwaysOn Availability Group - asynchronous-commit Seconds Minutes No 0 - 4

AlwaysOn Failover Cluster Instance NA Seconds-to-minutes Yes NA

Database Mirroring - High-safety (sync + witness) Zero Seconds Yes NA

Database Mirroring - High-performance (async) Seconds Minutes No NA

Log Shipping Minutes Minutes-to-hours No Not duringa restore

Backup, Copy, Restore Hours Hours-to-days No Not duringa restore

Page 22: Ionut hrubaru, bogdan lazarescu   sql server high availability

Demo

Page 23: Ionut hrubaru, bogdan lazarescu   sql server high availability

Topology

Page 24: Ionut hrubaru, bogdan lazarescu   sql server high availability

Q&A

linkedin.com/groups/DBA-Lounge-4929632

Page 25: Ionut hrubaru, bogdan lazarescu   sql server high availability

Thank you!


Recommended