MSCS Server Decluster Windows 2003 + SQL2005
In this article, I will describe my experience in converting an “iron” MSCS cluster to a virtual server.
Our cluster has been operating since 2008, many tasks have accumulated, including critical ones, and it was unrealistic to raise a new server. In addition, worn-out equipment was about to fail. There was only one way out for us - server virtualization in our data center, on VMware. And for me the task was set - to get away from clustering. Having studied a bunch of information on the network, I did not find a suitable step-by-step instruction, so I decided to compose my own.
The initial state was as follows:
- MSCS cluster on Windows 2003 Enterprise edition SP2. Two nodes in Active \ Passive mode;
- SQL Server 2005 Standard Edition in cluster mode
- Several WWW / FTP sites on IIS, not in cluster mode. Each of the 32 Web sites has one IP Address cluster resource. Roughly speaking, additional IPs were hung on the network card. The sites only worked on the intranet;
- 9 logical data disks; 152 file share resources; all data is stored on a disk array;
- The configured task scheduler, through it some programs specific to our industry were launched.
For preliminary preparation and testing of the server, we created a virtual "laboratory".
We connected three machines to an isolated virtual network: a virtual copy of the active node of the cluster, a virtual copy of the domain controller and a regular machine with Windows 7, on which we will all test. Several disks with SQL databases, www / ftp sites, network folders, and a quorum disk were converted in advance to VMDK.
We start the machines, configure network cards with the same TCP / IP parameters as in a real network. We connect the disks to our server, assign the appropriate letters, and reboot. After that, the cluster should start. By the way, in single-node mode, the cluster immediately started working, but we no longer need it, all the more there is a risk that such a configuration will not work correctly in a virtual environment.
Now you need to save the network card settings and network resource settings, as After removing the cluster service, they will have to be manually restored. I previously prepared dump of TCP / IP settings using the netsh command. I planned to create network resources anew, with the "net share" command. Perhaps there is a way to backup the network ball settings, but I did not find it.
So, we have the ip.cfg file and shares.txt (net share command list). We do Snapshot in order to roll back in case of failure.
- After starting the virtual copy, the second cluster node will be unavailable. Delete it with the Evict Node team.
Such a message may appear, here without options, click OK.
- Next, we configure SQL. We need it to start normally. The instructions found on the Internet suggest that you make copies of the databases, delete the clustered Instance, then install the Standalone Instance. I found a simpler way through the registry:
Delete the branches
HKEY_LOCAL_MACHINE \ SOFTWARE \ Microsoft \ Microsoft SQL Server \ MSSQL.1 \ Cluster
HKEY_LOCAL_MACHINE \ SOFTWARE \ Microsoft \ Microsoft SQL Server \ MSSQL.2 \ Cluster Change the
HKEY_LOCAL_MACHINE \ SOFTWARE \ Microsoft \ Microsoft SQL Server \ MSSQL.1 \ Setup \ SqlCluster = 0
HKEY_LOCAL_MACHINE \ SOFTWARE \ Microsoft \ Microsoft SQL Server \ MSSQL.2 \ Setup \ SqlCluster = 0
In the SQL Server configuration manager, we set the services to autostart.
- We include services WWW Publishing Service, Task Scheduler for autorun. Previously, they were launched manually only on the active node.
- Delete the last node from the cluster. After that, cluster resources such as IP address and File Share are permanently deleted from the system.
- So that users can then work normally with network folders, we again make the registry edit:
In the registry key HKEY_LOCAL_MACHINE \ System \ CurrentControlSet \ Services \ LanmanServer \ Parameters we
add the DWORD parameter "DisableStrictNameChecking", with a value of 1
- Restoring network settings:
Netsh exec c: \ ip.cfg
- We restore network resources from the text file shares.txt. Just copy the commands and paste into cmd. I tried to make a bat nickname, but there was a problem with the display of Russian characters in resource descriptions.
- Reboot the server. After that, we check the operation of all ftp-, www-, share-resources in our laboratory.
If everything is in order, then the virtual server is ready to move to a regular network.
Briefly about the transition
The nuances here may be different, but the principle is the same: you need to disable the iron cluster, transfer resources and settings to the new server and enable it. In my case, resources are IP addresses, logical drives with data, network balls.
We did not completely remove the iron cluster from the network and AD, so that in case of failure, everything could be returned back.
- Disconnect the iron cluster from the network and from the drives. IP addresses are freed.
- The total amount of data is 1.5 TB, so it will not work to transfer all the disks to VMDK at once, the information is constantly updated. We decided to temporarily connect them to a virtual server as RDM, thereby reducing downtime during the transition. As experience has shown, it is better to connect them to a turned off machine. After starting, you need to assign the same letters to these disks as on the old cluster, for example, we have SQL server databases started from drive S.
- We include the virtual server in the general network, we reboot.
After the reboot, FTP, WWW services, and SQL correctly worked. All actions took a little less than an hour.
Some time later, a glitch appeared with network balls, when some users cannot log into them using the old cluster name. Possible fixes:
- Check compliance with paragraph 5 of the instructions.
- Delete old WINS server entries for cluster name
- When you deploy the MSCS cluster, in AD, in addition to the accounts of the first and second nodes, a third account is created with the cluster name: its description is “Server cluster virtual network name account”. This account needs to be done disable.
- In DNS, an alias is made for the name of the cluster on the first node.
At the moment, the virtual server is working properly. No glitches are observed. Now you can safely celebrate the New Year version 2015. Thank you all for your attention.