Veritas InfoScale™ 7.4.1 Installation and Upgrade Guide - Windows
- Preinstallation and planning
- About InfoScale licenses
- Installing the Veritas InfoScale products
- Upgrading to InfoScale products
- Performing the post upgrade tasks
- Administering the InfoScale product installation
- Uninstalling the InfoScale products
- Performing application upgrades in an InfoScale environment
- Upgrading Microsoft SQL Server
- Upgrading Oracle
- Upgrading application service packs in an InfoScale environment
- Appendix A. Services and ports
- Appendix B. Migrating from a third-party multi-pathing solution to DMP
Upgrading SQL Server 2012 or later to a compatible service pack
This section describes the tasks to upgrade any supported SQL Server version to a compatible service pack in an InfoScale DR environment.
Consider the following points before you proceed with the upgrade:
Ensure that you have installed and configured SQL Server.
Ensure that the logged on user has administrative privileges to the SQL instance that you want to upgrade.
Ensure that you have taken a recent backup of your system, user databases, and the SQL Server directories, from the shared storage.
Refer to the Microsoft documentation for prerequisites related to SQL Server Service Pack installation.
Consider a DR cluster setup with three nodes, Node A, Node B, and Node C. Node A and Node B are on the primary site and Node C is on the secondary site. The SQL Server service group is online on Node A.
You can upgrade any supported SQL Server version to a compatible service pack in any of the following ways:
In this procedure you upgrade SQL Server on the nodes at the primary site first and then on the nodes at the secondary site. This process involves moderate service group downtime, because you upgrade one cluster node at a time.
To upgrade SQL Server to a service pack, perform the following steps:
- Stop the replication between the primary and the secondary site.
If using Volume Replicator for replication, from the VEA Console, right-click the Secondary RVG and select Stop Replication from the menu that appears.
- On Node A where the SQL Server service group is online, take the SQLServer, MSOlap, and SQLServer-Agent resources offline.
Run the following command from the command prompt:
hares -offline [-parentprop] resource -sys system
Here, resource is the name of the SQL resource and system is the name of node where the SQL Server service group is online.
- From Services.msc, ensure that all the SQL services and the SQL services for which VCS resources are configured are stopped.
- Perform the following steps on the SQL Server service group on Node A (active node):
Bring the RegRep resource offline.
Type the following on the command prompt:
hares -offline [-parentprop] resource -sys system
Disable the RegRep resource.
Type the following on the command prompt:
hares -modify resource_name Enabled 0
Except the storage resources (MountV and VMDg), take all the resources offline.
Take a backup of the SQL Server directories from the shared storage.
Then freeze the service group.Type the following on the command prompt:
hagrp -freeze service_group [-persistent]
- Install the Microsoft SQL Server Service Pack on Node A.
- If a FILESTREAM resource is configured in the SQL Server service group, verify if a FILESTREAM share exists on the node and then delete it.
Run the following commands from the command prompt:
net share
This command lists all the shares on the node.
net share share_name /delete
Here, share_name is the name of the FILESTREAM share.
- Unfreeze the SQL Server service group.
Type the following on the command prompt:
hagrp -unfreeze service_group [-persistent]
- Fail over the service group to Node B and perform the following steps on Node B, in the given order:
Except the storage resources (MountV and VMDg), take all the resources offline.
Open the Services window, and ensure that all the SQL Server services and the ones for which VCS resources are configured are stopped.
Freeze the service group.
- Perform the following steps:
Rename the SQL Server folders on the shared storage and copy the backed up SQL Server directories to the shared storage.
Rename the SQL Server replication directory that is present under Registry Replication folder in the shared storage.
The SQL Server data files available on the shared storage are upgraded during the SQL upgrade on Node A. Before you begin to upgrade SQL on Node B, you must rename the folders containing the upgraded SQL data files and restore the initially backed up SQL Server directories. If you do not restore the initially backed up SQL Server directories, then the SQL upgrade on Node B may fail indicating that the SQL Server data files are already upgraded.
- Install the Microsoft SQL Server Service Pack on Node B.
- If a FILESTREAM resource is configured in the SQL Server service group, verify if a FILESTREAM share exists on the node and then delete it.
Run the following commands from the command prompt:
net share
net share share_name /delete
Here, share_name is the name of the FILESTREAM share.
- Unfreeze the service group on Node B and enable the RegRep resource.
Run the following commands from the command prompt:
hagrp -unfreeze service_group [-persistent]
hares -modify resource_name Enabled 1
- Bring the service group online on Node B.
- Start the replication between the primary and the secondary site.
- Switch the service group to a node on the DR site (Node C).
Type the following on the command prompt:
hagrp -switch service_group -site site_name
- Stop the replication between the primary and the secondary site again.
- Perform the following steps on Node C, in the given order:
Except the storage resources (MountV and VMDg), take all the resources offline.
Disable the RegRep resource and freeze the service group.
Rename the SQL folders on the shared storage and copy the backed up directories to the shared storage.
Install the Microsoft SQL Server Service Pack on Node C.
If a FILESTREAM resource is configured in the SQL Server service group, verify if a FILESTREAM share exists on the node and then delete it using the following commands:
net share
net share share_name /delete
Unfreeze the service group and enable the RegRep resource.
- Start replication between the primary and secondary site.
- Switch the service group back to Node B (last upgraded node) on the primary site.
Note:
You must bring the SQL service group online on Node B first. This is because the replication service group is online on Node B. You can then switch the SQL service group on any node on the primary site.
In this procedure you upgrade SQL Server on the passive nodes at both the sites first and then on the active node. This process involves less complexity and service group downtime.
Note:
This procedure is applicable only if the SQL Server database and the SQL Server analysis (OLAP) files are installed on shared storage on the active node and at the default location (on the C: drive) on the passive nodes.
To upgrade SQL Server to a service pack
- Freeze the SQL Server service group on Node A using the VCS Cluster Manager (Java Console).
On the Service Groups tab, right-click the service group and then click Freeze > Persistent. Save the configuration and leave the group frozen until all the nodes are updated.
Alternatively, run the following command on the command prompt:
hagrp -freeze service_group [-persistent]
- Back up the registry of the SQL Server database instance on the passive nodes, by following these steps sequentially:
Access the registry by using your preferred method to execute
regedit.exe
.Locate the SQL Server instance registry key:
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SQL Server\MSSQL11.instance
Right-click on the registry key and click Export.
Save the registry key.
Note:
While upgrading SQL Server 2014 or SQL Server 2016 to a service pack, the MSSQL11 value in the registry key changes to MSSQL12 or MSSQL13 respectively.
- Stop the replication between the primary and the secondary sites.
If VVR is used for replication, from the VEA Console right-click the Secondary RVG and select Stop Replication from the context menu.
- If you find any registry keys from the following list on nodes B and C, update them to point to the root directory. Note that instance represents the SQL Server instance that you are trying to upgrade.
HKLM\Software\Microsoft\Microsoft SQL Server\MSSQL11.instance\MSSQLServer\BackupDirectory
HKLM\Software\Microsoft\Microsoft SQL Server\MSSQL11.instance\MSSQLServer\DefaultLog
HKLM\Software\Microsoft\Microsoft SQL Server\MSSQL11.instance\MSSQLServer\Parameters\SQLArg0
HKLM\Software\Microsoft\Microsoft SQL Server\MSSQL11.instance\MSSQLServer\Parameters\SQLArg1
HKLM\Software\Microsoft\Microsoft SQL Server\MSSQL11.instance\MSSQLServer\Parameters\SQLArg2
HKLM\SOFTWARE\Microsoft\Microsoft SQL Server\MSAS11. instance\CPE\ErrorDumpDir
HKLM\SOFTWARE\Microsoft\Microsoft SQL Server\MSAS11. instance\Setup\DataDir
HKLM\Software\Microsoft\Microsoft SQL Server\MSSQL11.instance\MSSQLServer\DefaultData
HKLM\Software\Microsoft\Microsoft SQL Server\MSSQL11.instance\SQLServerAgent\ErrorLogFile
HKLM\Software\Microsoft\Microsoft SQL Server\MSSQL11.instance\SQLServerAgent\WorkingDirectory
HKLM\Software\Microsoft\Microsoft SQL Server\MSSQL11.instance\Setup\SQLDataRoot
For example, if the key HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SQL Server\MSSQL11.instance\MSSQLServer\BackupDirectory contains the value
F:\Test\MSSQL11.MSSQLSERVER\MSSQL\Backup
, change this value to point to the root directoryC:\Program Files\Microsoft SQL Server
.Therefore, updated value becomes
C:\Program Files\Microsoft SQL Server\MSSQL11.MSSQLSERVER\MSSQL\Backup
. - Complete the SQL Server service pack upgrade on nodes B and C, and reboot the server.
Do not fail over until the service pack installation on Node A is complete.
- On Node A, run the command hastop -local -force to stop the VCS services.
Doing so stops VCS, but leaves the storage and the SQL Server online. It also prevents VCS from taking any action on the resources when the installer restarts the service.
- Complete the SQL Server service pack upgrade on Node A, and verify that the services are back in the Started state.
- Run command hastart to start VCS services on Node A.
- Start the replication between the primary and secondary sites.
- Unfreeze the service group and test failover to nodes B and C.
Run the following command on the command prompt:
hagrp -unfreeze service_group [-persistent]
This completes the SQL Server upgrade to a service pack.