SQL Cluster on vSphere

Windows Clustering Types

  1. Network load balancing cluster: Filters and distributes TCP/IP traffic across a range of nodes
  2. Failover cluster (WSFC): Provides high availability for services, applications, and other resources
    • Examples:
      • Exchange servers
      • Hyper-V
      • SQL Servers
      • File Servers

Windows Server Failover cluster

(WSFC)

In a failover cluster, if one or more of the clustered servers (nodes) fails, other nodes begin to provide service.

Quorum Witness Types

  1. Disk witness; dedicated lun that stores a copy of the cluster database.
  2. File share witness: stores the cluster information in witness.log. Doesn’t store the copy of the cluster database.
  3. Cloud witness: Witness file stored in Azure Blob storage.

SQL deployments

Standalone vs Clustered

SQL Instances

  1. Default Instance
    1. A default instance on a standalone server has the same name as the underlying Windows Server
    2. A default instance on a cluster server has the same name as ___?
  2. Named Instance

SQL Server

Protection levels

Availability Features

Granularly

Storage

Notes

Always on FCI

Instance

Shared

Covers the entire instance.

Always on AG

Database

Non-Shared

Copy of a database can be

brought online on a separate server

Database mirroring

Database

Non-shared

Deprecated

Log Shipping

Database

Non-shared

Replication

Data

Non-shared

Ensures that data in a database

also exists in another database

SQL Cluster Types

  1. Always on Failover Clustering Instances ( FCI)
  2. Always on Availability Group

Note: “Always On” is a marketing term for sql cluster solution.

Clustered VMDK

Vs

RDMs

– With Clustered VMDKs feature introduced in vSphere 7, WSFC clusters can be created on vSphere without RDMs.

– Why was RDMs needed? WSFC clusters use SCSI-3 persistent reservation commands to clustered disk resources. The command locks the volume so that only the active node is allowed to write it. But VMFS intercepts and discards these commands for traditional virtual disk.Hence the need for RDM disks acting as a mapping device for the physical LUN

– What has changed with Clustered VMDKs?

Clustered VMDK allows SCSI-3 PR commands issued to virtual disks.

vSphere Options for Shared storage

vSphere version

Shared disk options

SCSI bus sharing

Storage Protocol / Technology

vSphere 7.0

Clustered VMDKs

physical

FC

vSphere 7.0

VMware vSphere® Virtual Volumes (vVols), RDM physical mode

physical

FC, FCoE, iSCSI

VMware Cloud on AWS

Clustered VMDKs

physical

N/A / vSAN

vSAN (vSphere 7.0)

Clustered VMDKs

physical

N/A / vSAN

SCSI Bus sharing

  • Virtual: Allows sharing vmdk between VMs on the same ESXi host
  • Physical: Allows sharing vmdk between VMs on different ESXi hosts

Multi-Writer Disk sharing

The multi-writer option allows VMFS-backed disks to be shared by multiple virtual machines.

By default, VMFS disables multiple virtual machines from opening and writing to the same virtual disk (.vmdk file).

Note: Multi-writer feature must not be used for a clustered disk resource for WSFC.

Failover Cluster with Clustered VMDKs

On VSAN

  1. SCSI Controllers: Two separate controllers
    1. A controller for Non-shared VMDKs
      1. Bus sharing: None
    2. Separate controller for shared VMDKs:
      1. Bus sharing: Physical
  2. Disks
    1. Non-shared VMDKs
      1. Multi-writer flag must NOT be used.
    2. Shared VMDKs
      1. Multi-writer flag must NOT be used.
      2. Eager Zeroed Thick Provisioning is not required.
  3. DRS anti affinity rules for VMs
  4. Reference: https://kb.vmware.com/s/article/74786

References

  1. https://blogs.vmware.com/apps/2020/01/microsoft-sql-server-and-vmware-vsphere-high-availability-features.html
  2. https://www.vmware.com/content/dam/digitalmarketing/vmware/en/pdf/solutions/vmware-vsphere-highly-available-mission-critical-sql-server-deployments.pdf
  3. https://www.vmware.com/content/dam/digitalmarketing/vmware/en/pdf/solutions/sql-server-on-vmware-best-practices-guide.pdf
  4. https://www.vmware.com/content/dam/digitalmarketing/vmware/en/pdf/solutions/vmw-vmdk-whitepaper-mmt.pdf
  5. https://docs.vmware.com/en/VMware-vSphere/7.0/com.vmware.vsphere.wsfc.doc/GUID-1A2476C0-CA66-4B80-B6F9-8421B6983808.html

Leave a Reply

Your email address will not be published. Required fields are marked *