Monday, December 7, 2015

Clustered Instance Patch Failure - The Cluster Group Cannot Be Determined

I recently ran into an issue where I was unable to apply a cumulative update to one node of a Failover Clustered Instance (FCI) of SQL Server 2014.  The Summary log from the CU install had the following error:
The cluster group cannot be determined for the instance name 'MSSQLSERVER'.  This indicates there is a problem with the product registry setting for ClusterName, with product discovery, or the cluster resources.

This particular FCI was a DR cluster and we had renamed the network name resource for the instance to match the production server it was replacing.  I believe the instance name in the registry should automatically change when you change the network name, but in our case it did not do so.

To find the correct name, I launched Failover Cluster Manager and then expanded the cluster name and selected Roles in the left-hand pane.  From there I selected the Resources tab at the bottom of the center page.  
Note: I'm running Windows Server 2012 R2.  If you are on Windows Server 2008 (or 2008 R2), you'll need to expand Services and applications in the left-hand pane and then select the specific service you are looking for.  

In the Resources list, I found the Server Name resource and made note of the value specified there.

Next is just a simple matter of updating the registry value.  I launched Registry Editor (RegEdit.exe) and navigated to HKLM > Software > Microsoft > Microsoft SQL Server > MSSQL12.MSSQLSERVER > Cluster
Note: MSSQL12.MSSQLSERVER will vary based on SQL version (SQL 2012 is "MSSQL11") and instance name ("MSSQLSERVER" is the default instance and named instances are the actual instance name instead of "MSSQLSERVER").

Within the Cluster key I updated the value of ClusterName to match what was specified in Failover Cluster Manager:

I then ran the CU install again and it completed successfully!  So far this is a good Monday!