Hi Team,
I have a huge clustered environment and have a document that shows all the Physical Node Names in the clusters. But unfortunately we do not have the Virtual Server Names. I know, we can only connect to SQL through Virtual Name so I would like to know if there is an automated way to find the Virtual Cluster Names (or SQL Server Name). Like using PowerShell or other programming languages. I have tried looking at several forums but did that did not help.
Some points to think:
1) I know we can look it up by opening Failover Cluster Manager (FCM) but I have hundreds of servers. So that doesn't really help :(
2) I have tried Get-ClusterResource cmdlet in Powershell, it gives all the resources that are running but not the name. Like it gives "SQL Server (MSSQLSERVER)" and not the name.
3) Also I know we can find out using tsql command, SELECT SERVERPROPERTY('SERVERNAME') but again I cannot connect to SQL without the Virtual Name :)
I am pretty sure there should me a way to find it out using scrips since we are able to know it using GUI (FCM).
Really appreciate your help !!