How to rename a SQL Failover Cluster Instance when SELECT @@SERVERNAME and Cluster Manager Servername differs?
**The Background** This is all about a SQL Failover Clustered Instance. A client of mine have a consolidated environment hosted on a MS Cluster (Win2008 R2). This cluster needed to be moved to another site, and to simplify things and minimize downtime, we moved all instances/databases as-is to the new site, keeping the SQL Network Names. **The Action** In order to being able to do this and keeping the instance name without having to resort to aliases, we first renamed the server name in Cluster Manager in the original environment (with a prefix, like OLD_Server1) and then shut the Virtual server completely down. We then performed a scripted install in the target environment, keeping the original Virtual server name and then robocopied all files from the old to the new environment. **The Result** From the application point of view, the new environment was a complete clone to the old (before the name change), no drives or paths or names were changed. The only thing that had changed was the underlying ip-address, and since all applications use the Network name, everything worked like clockwork. **The Question** But there was a side effect that I didn't count. The Server name in Cluster Manager in the old and new environment differs (OLD_Server1 and Server1 respectively). You might remember that the last thing we did on the old environment was to rename the Server name in Cluster Manager, thus renaming the Virtual Server. Now, when I query the *new* instance for @@SERVERNAME, it reports OLD_Server1\\SQL1. When I query for Serverproperty('Servername'), it reports Server1\\SQL1. If I query for Serverproperty('Machinename'), it reports Server1. The Server name (Virtual server name) in Cluster manager is Server1. Luckily enough, since the name corresponding to the DNS ip address is correct (i.e. the same name as before the change), all applications are happy. But I don't want this discrepancy between the Virtual server name and @@SERVERNAME. So how do we change this? According to MS, ("How to: Rename a Failover Cluster Instance") the process for renaming can't be used, simply because the Virtual Server name is correct already. And if I look into MS "How to: Rename a Computer...Stand-Alone Instance..." the proposed way of renaming a named instance is sp_dropserver 'OLD_Server1\SQL1' GO sp_addserver 'Server1\SQL1' GO Does anyone have knowledge if the method of renaming a stand-alone named instance is applicable to the situation outlined above? Any insight would be deeply appreciated.
I think that's your ticket. It's exactly how we rename our DR servers during our annual failover test. It only changes the name that the SQL Server instance calls itself. It will have no impact on the cluster.