Did you know that SQL Server Availability Groups can be a great solution for disaster recovery? Availability groups have become well known for their high availability capabilities, and for good reason: they work well, they remove some of clustering’s limitations, and they are fairly straightforward to setup. Extending an availability group to multiple sites for disaster recovery becomes more complicated. A lot of moving parts have to come together for it to work properly – SQL Server, Windows, Active Directory, and DNS all get involved in this advanced configuration. In this session, we’ll discuss some of the factors that complicate a multi-site availability group deployment, and we’ll walk through a multi-site deployment so you can see how it’s done.
2. About Me
Email: ed@leightondick.com
Blog: edleightondick.com
Twitter: @eleightondick
3. JOIN ME AGAIN
OCTOBER 25-28
Where Data Professionals
Connect, Share, and Learn
I’M SPEAKING
Extending Applications
Securely Using Service
Broker
Contact your Local or Virtual Chapter for their unique
discount to SAVE $150!
8. Availability Groups
Uses Windows Server Failover Cluster
No shared storage
Up to 4 secondary replicas (8 in 2014)
Secondary replicas can be readable
Backups can be offloaded to secondary replica
Synchronous or asynchronous
Automatic or manual failover
Can be geographically distributed
Can be combined with other HA/DR methods
9. Limitations
Operates at database level
Practical limit to number of databases per AG
Worker Thread Exhaustion
Licensing
Enterprise Edition required for full functionality
Basic Availability Groups (SQL 2016 Standard Edition)
Must license all servers
… Except those used strictly for disaster recovery
10. SQL 2016 Enhancements
Basic Availability Groups
Automatic failover to 3 synchronous replicas
Direct seeding
Improved transport performance
Failover on database health
Load-balancing on read-only replicas
SSIS catalog can participate
Columnstore indexes supported
DTC supported (Windows Server 2016+)
Domain-independent AG (Windows Server 2016+)
Group Managed Service Accounts supported
Encrypted databases fully supported
Encrypted endpoints
18. Prerequisites
Separate subnet/NICs for heartbeat traffic
IPs on all subnets
Public – One per server
Heartbeat – One per server
Cluster – One per subnet
Listener – One per subnet
FQDNs
Cluster
Listener
19. Prerequisites
Open ports
TCP/UDP Port Description
TCP 1433 SQL – AG Listener
TCP 5022 SQL – AG/DBM Endpoint
TCP/UDP 3343 Cluster Network Communication
TCP 135 Cluster DCOM
UDP 137 Authentication
ICMP Ping
TCP/UDP 49152-65535 Dynamic Ports (Configurable)
20. Prerequisites
File share for initial data synchronization
Service account (SQL)
Active Directory/DNS security
Cluster machine account (domaincluster$)
Mechanism for synchronizing server objects
Jobs
Logins
23. Special Considerations
Synchronous or asynchronous?
Synchronous
High availability
No data loss is acceptable
WAN latency must be low
Asynchronous
Disaster recovery
Distributed reporting
Data loss must be acceptable
Hybrid
24. Special Considerations
Do you need automatic failover?
Latency must be low (<1 sec roundtrip)
CrossSubnetDelay (Def 1000, Max 5000)
CrossSubnetThreshold (Def 5, Max 120)
Usually reserved for high availability scenarios
25. Special Considerations
IP Handling
Works best with SQL Server Native Client v11 or
SQL Server ODBC v11
Other drivers cannot support MultiSubnetFailover
property
Manual adjustments required
Slower reconnection after failover
31. SQL 2016: Distributed Availability Groups
Benefits
Joins independent availability groups
More efficient
Enables rolling upgrades
Limitations
No automatic failover
Must have same group of databases
Must configure using T-SQL
33. Troubleshooting
SQL Server
Availability Group Dashboard
Extended Events
Special session for availability groups
DMVs (sys.dm_hadr_*)
Instance log
Third-party SQL utilities
SQL Sentry Performance Advisor
Idera Diagnostic Manager
34. Troubleshooting
Windows
Logs – Application, System
Cluster logs
Including cluster.log
PerfMon
SCOM
Network utilities
iperf
Packet trace (Wireshark)
35. Review
Availability groups can be a great
disaster recovery solution!
Additional considerations when multiple
subnets are involved
Network latency
Firewall configuration
Active Directory configuration
DNS configuration
36. Any Questions?
Email: ed@leightondick.com
Blog: edleightondick.com
Twitter: @eleightondick
Thank you for attending!
Please remember to
fill out your comment cards