Install and Configure Windows Failover Cluster for SQL Server


In this article, we’ll install and configure Windows Failover Cluster for SQL Server.

In my environment, I have following setup:

Article Covers

  • Install Windows Server Features on both Windows Server 2012 R2 Nodes
  • Configure iSCSI Target Disks for Windows Cluster
  • Connect iSCSI Target Disks on both Cluster Nodes
  • Create Cluster Role
Step 1: Install Windows Server Features on both Windows Server 2012 R2 Nodes
  • Open Server Manager -> Add Roles and features.
  • Add the below Features and Sub-Features -> Click Next.

    • .NET Framework 3.5 Features
      • .NET Framework 3.5 (includes .NET 2.0 and 3.0)
    • Failover Clustering

                Click Add Features when prompted with the “Add features that are required for Failover Clustering?”

Step 2:  Configure iSCSI Target Disks for Windows Cluster
  • Open Server Manager on your domain controller -> Add Roles and features.
  • Add iSCSI Target Server Role under File and Storage Services -> Click Next and Finish Install.
  • Open Server Manager -> Click on File and Storage Services -> On Pop up Window select iSCSI.

         Click on “To create an iSCSI virtual disk, start the New iSCSI Virtual Disk Wizard

  • Select iSCSI virtual disk location, I have selected C drive you can select a different volume.
  • Enter iSCSI virtual disk name.
  • Enter iSCSI virtual disk size and select the option “Dynamically expanding”. I have kept the size to 15 GB you can increase or decrease size based on volume free space.
  • Select “New iSCSI target” and Click “Next”.
  • Enter “New iSCSI Virtual Disk” name and Click “Next”.
  • Now we need to add the servers or nodes which can access the Virtual Disks. Click on Add.
  • Browse and add Cluster Node 1 Server Name. Click Ok. Similarly add the Cluster Node 2 and Click Ok.
  • Click “Next” once both nodes are added.
  • On Enable Authentication, leave both checkboxes blank. Click “Next”.
  • Click on “Create” on Confirmation Page.
  • After Virtual Disk 1 is created. Follow the same process and create Virtual Disk 2. You can find both Disks under specified location.
Step 3: Connect iSCSI Target Disks on both Cluster Nodes
  • Our iSCSI virtual disks are not connected so we need to connect it on both cluster nodes.
  • Open Server Manager on both Nodes, Click on iSCSI Initiator.
  • Click on Yes to start Microsoft iSCSI services.
  • Enter IP address for server where ISCSI virtual disk are located. Click on Quick Connect.
  • Click on Connect for both Virtual Disks. You will find status changed from “Not Connected” to “Connected” for both Disks. Click on Done.
  • Click Ok to close the iSCSI Initiator Properties box.
  • Now open Run -> Type “diskmgmt.msc”

  • You will find Disk 1 & 2 Offline. So right click both disks and bring them Online.
  • Now right click both disks and Initialize them.
  • Using available disk we will create two volumes for Quorum and SQL. Right Click Disk 1 and Select “New Simple Volume” for Quorum Disk. Click Next. 
  • Enter the Volume Size. Click Next.
  • Assign a Drive Letter for Volume.Click Next.
  • Select “Format this volume with the following settings”: 

    File System: NTFS

    Allocation unit size: Default

    Volume Label: Quorum Disk

    Check the option “Perform a quick format”. Click Next and Finish.
  • Right Click Disk 2 and Select “New Simple Volume “for SQL Disk. Perform same steps as above.
  • You can find both disks created.

  • You will find both Disks on Node 2 server however with different drive letters. So we need to change drive letters and keep it same as we have on Node 1.

             Quorum Disk Drive Letter should be “Q”

              SQL Disk Drive Letter should be “S”

  • Open Run -> Type “diskmgmt.msc”
  • Select Disk 1 -> Right Click -> Select “Change Drive Letter and Paths…” option. Assign the Drive letter “Q” for Quorum.
  • Perform the same for Disk 2 and Assign the Drive letter “S” for SQL.
Step 4: Create Cluster Role
  • Open Failover Cluster Management Snap-In on Node 1. Click on “Create Cluster” -> Next.

  • Add both Windows Server Node 1 & 2 that you want to have in the cluster.

  • Select the option “No, I do not require support from Microsoft for this cluster” for Validation. In case, you want to run validation tests then select first option.
  • Provide a Cluster Name and IP address on next wizard.

  • Review the configuration and click next
  • Click Finish to close the Wizard.

Once Cluster is created, you will find Cluster Object created in Active Directory Users and Computers.

We are done with Installing and Configuring Windows Failover Cluster on both nodes. Now we need to install SQL Server Roles on both nodes by running the SQL Server Setup. You can refer to link for installing SQL Server role with standalone and Failover feature.

You may also like...

Leave a Reply

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