This article discusses how to migrate the database that is used by Microsoft SoftGrid from one computer that is running Microsoft SQL Server to another computer that is running SQL Server.
In this article, the computer that is running SQL Server and for which the SoftGrid Server is currently configured will be known as the "source server." The computer that is running SQL Server to which the database will be migrated will be known as the "target server."
We recommend that you follow these steps during a scheduled downtime.
Additionally, we recommend that you stop the SoftGrid Virtual Application Server service before you start the migration. If the SoftGrid Virtual Application Server service is not available to the SoftGrid Clients, the SoftGrid Clients will enter Minimal Disconnected Operation (MDO) mode. In this mode, the SoftGrid Clients will continue to stream applications that are completely loaded in cache. However, if the SoftGrid Virtual Application Server service is available but the migration is incomplete, the SoftGrid Clients may be unable to enter MDO. Therefore, the SoftGrid Clients will receive a "launch failure" notice.
Stopping the SoftGrid Virtual Application Server service
On the SoftGrid Virtual Application Server, click Start, point to All Programs, point to Administrative Tools, and then click Services.
Right-click the SoftGrid Virtual Application Server service. Then click Stop.
Backing up the SQL Server Desktop Engine database
Start SQL Server Enterprise Manager.
Connect to the source database server as the sa user by using password that was specified during the original installation of the SoftGrid Server.
Expand sql_server_name, and then click Databases.
Make a complete backup of the SOFTRICITY database
Documenting the SOFTRICITY database Users and Roles
Start SQL Server Enterprise Manager.
Connect to the source database server as the sa user by using the password that was specified during the original installation of the SoftGrid Server.
Expand sql_server_name, expand Databases, expand SOFTRICITY, and then click Users.
Note In this step, sql_server_name represents the actual name of the computer that is running SQL Server.
Document the Name value, the Login Name value, and the Database Role Memberships values for each user. For example, document the information that is in the following table.
Collapse this tableExpand this table
Name
Login Name
Database Role Memberships
dbo
sa
public db_owner
domain_name\SoftGrid administrators group
domain_name\SoftGrid administrators group
public SFTadmin
softricity
softricity
public SFTadmin SFTuser
A typical installation has three users. The Database Role Membership value can be located in the Properties dialog box for each user.
Restoring the source database to the target SQL Server
Start SQL Server Enterprise Manager.
Connect to the computer that is running SQL Server.
Expand sql_server_name. Then click Databases.
Create a database that is named "SOFTRICITY."
Restore the previously backed-up SOFTRICITY database to the newly created SOFTRICITY database
Registering Softricity Database Messages
Log on to the computer that is running SQL Server.
Re-creating the SQL Server users and assigning the Database Role Memberships
Start SQL Server Enterprise Manager.
Connect to the computer that is running SQL Server.
Expand sql_server_name, expand Databases, expand SOFTRICITY, and then click Users.
Note In this step, sql_server_name represents the actual name of the server.
Delete the domain_name\SoftGrid administrators group user.
Note In this step, domain_name\SoftGrid administrators group represents the domain name and group name.
Delete the Softricity user.
Add a database user. To do this, follow these steps:
Specify the following settings:
Login name: <new>
Name: click the ellipsis button (...) to select and add the group name
Click OK.
Locate and then select the domain_name, add the SoftGrid administrators group from step 4, and then click OK.
In the Database list, click SOFTRICITY. Then click OK.
Specify the following settings:
The login 'domain_name\SoftGrid administrators group' has not been granted access to their default database: 'SOFTRICITY' and therefore will be unable to gain access to the default database. Continue?: Yes
Login name: domain_name\SoftGrid administrators group
In the Database role membership window area, click to select the public check box and the SFTadmin check box in the Permit in Database Role column.
Click OK
Add a new database user. To do this, follow these steps:
Specify the following settings:
Login name: <new>
Name: softricity
Authentication: SQL Server Authentication
Password: the password that was specified during the original installation of the SoftGrid Server
Database: SOFTRICITY
Click OK.
Specify the following settings:
The login 'domain_name\SoftGrid administrators group' has not been granted access to their default database: 'SOFTRICITY' and therefore will be unable to gain access to the default database. Continue?: Yes
Confirm new password: the password that was specified during the original installation of the SoftGrid Server
Click OK.
Specify the following setting:
Login name: softricity
In the Database role membership window area: click to select the public check box, the SFTadmin check box, and the SFTuser check box. Then click OK.
Re-creating the Softricity SQL Server agent alerts and jobs
Start SQL Server Enterprise Manager.
Connect to the computer that is running SQL Server.
Expand sql_server_name, expand Management, expand SQL Server Agent, and then click Jobs.
Create a job. To do this, follow these steps:
Specify the following settings:
Name: Softricity Database (SOFTRICITY): Check Usage History
Category: Database Maintenance
Owner: sa
Description: This job calls a stored procedure in the associated SoftGrid database to cleanup usage data on a monthly basis.
Note In this value, "cleanup" is spelled as one word.
Click the Steps tab.
Click New.
Specify the following settings:
Step name: Check Usage History
Type: Transact-SQL Script (TSQL)
Database: SOFTRICITY
Command: type EXEC sp_SFTcheckusagehistory
Click the Advanced tab.
Specify the following settings:
On success action: Quit the job reporting success
Retry attempts: 4
Retry interval (minutes): 1440
Run as user: dbo.
Click OK.
Click the Schedules tab.
Click New Schedule.
Specify the following settings:
Name: Monthly Schedule
Schedule Type: Recurring
Click Change.
Specify the following settings:
Occurs: Monthly
Monthly: Day
Day: 1
Of every month(s): 1
Daily frequencies: Occurs once at
Occurs once at: 2:00:00 AM
Start date: today's date
Duration end date select No end date then select OK
Description: This job calls a stored procedure in the associated SoftGrid database to cleanup usage data. An alert triggered by an increase in the database data file(s) size calls this job.
Note In this value, "cleanup" is spelled as one word.
Clear the E-mail and Net send check box. Click OK.
Click the Notifications tab.
Specify the following setting:
Write to Windows application event log: Whenever the job completes
Click OK.
Create a job. To do this, follow these steps:
Specify the following settings:
Name: Softricity Database (SOFTRICITY): Monitor Alert/Job Status
Category: Database Maintenance
Owner: sa
Description: This job refreshes the alerts and other jobs associated with the SoftGrid database based on configuration data stored in the database. The job is run on a daily basis.
Click the Steps tab.
Click New.
Specify the following settings:
Step name: Refresh Database Jobs
Type: Transact-SQL Script (TSQL)
Database: SOFTRICITY
Command: EXEC sp_SFTrefreshjobs N'REFRESH'
Click OK.
Click New.
Specify the following settings:
Step name: Refresh Database Alerts
Type: Transact-SQL Script (TSQL)
Database: SOFTRICITY
Command: EXEC sp_SFTrefreshalerts N'REFRESH'
Click the Advanced tab.
Specify the following setting:
On success action: Quit the job reporting success
Click OK.
Click the Schedules tab.
Click New Schedule.
Specify the following settings:
Name: Daily Schedule
Schedule Type: Recurring
Click Change. Then specify the following settings:
Occurs: Daily
Every Day(s): 1
Daily frequencies: Occurs once at
Occurs once at: 1:00:00 AM
Start date: today's date
Duration end date: No end date
Click OK three times.
Enabling the SQL Server Agent service
On the computer that is running SQL Server, click Start, point to All Programs, point to Administrative Tools, and then click Services.
Right-click the SQLSERVERAGENT service, and then click Properties.
In the Startup type list, click Automatic. Then click OK.
Right-click the SQLSERVERAGENT service. Then click Start.
Reconfiguring the SoftGrid communication configuration files
Reconfigure the SoftGrid Virtual Application Server
On the SoftGrid Virtual Application Server, right-click Start, and then click Explore.
Locate the following folder:
C:\Program Files\Softricity\SoftGrid Server\conf
Locate the Server.conf file.
Use a text editor to change the host name that is between the <location> tag and the </location> tag to the host name of the computer that is running SQL Server.
Save the change, and then exit Windows Explorer.
Reconfigure the SoftGrid Management Server (if it is installed)
On the SoftGrid Management Server, right-click Start, and then click Explore.
Locate the following folder:
C:\Program Files\Softricity\SoftGrid Server\conf
Locate the Manager.conf file.
Use a text editor to change the host name that is between the <location> tag and the </location> tag to the host name of the computer that is running SQL Server.
Save the change, and then exit Windows Explorer.
Reconfigure the SoftGrid Management Web Service
On the SoftGrid Management Web Service server, right-click Start, and then click Explore.
Locate the following folder:
C:\Program Files\Softricity\SoftGrid Management Service
Locate the SftMgmt.udl file.
Right-click the file, and then click Properties.
Click the Connection tab.
In the Select or enter a server name box, type the name of the computer that is running SQL Server. Then click OK.
On the SoftGrid Management Web Service server, click Start, point to All Programs, point to Administrative Tools, and then click Data Sources (ODBC).
Click the System DSN tab.
Click SoftGridReporting System Data Source, and then click Configure.
In the Server box, type the host name of the computer that is running SQL Server.
Click Finish.
In the window that appears and that contains the message, "A new ODBC data source will be created with the following configuration," click OK.
Reset the SoftGrid Management Web Service
On the SoftGrid Management Web Service server, click Start, point to All Programs, point to Administrative Tools, and then click Services.
Stop and then start the World Wide Web Publishing service.
Reconfigure the database logging
Start the SoftGrid Management Console, and then connect to the SoftGrid Management Web Service.
Expand SoftGrid Systems, expand server_name, and then click Server Groups.
Right-click the name of the default server group, and then click Properties.
Click the Logging tab.
Modify the existing SQL database type by changing the name that is in the DNS Host Name box to the host name of the computer that is running SQL Server.
Click OK two times.
In the window that appears and that contains the message, "You must restart the SoftGrid Virtual Application Server services in this group for them to reflect the changes made," click OK.
Repeat steps 1 through 7 of this procedure for each database logging that is currently configured to log to the source database server.
Resetting the SoftGrid services
Restart the SoftGrid Virtual Application Server.
Note If the SoftGrid Management Server is the same server as the SoftGrid Virtual Application Server that was previously restarted, you can skip this step.
On the SoftGrid Virtual Application Server, click Start, point to All Programs, point to Administrative Tools, and then click Services.