Knowledge Base Article

Home Page > Knowledge Base > Spira Platform

Home Page > Knowledge Base > Spira Platform > SpiraPlan

Home Page > Knowledge Base > Spira Platform > SpiraTeam

Home Page > Knowledge Base > Spira Platform > SpiraTest

Article What to do When a SpiraTest/Plan/Team Upgrade Fails?

by Adam S on Friday, June 3, 2016

When you upgrade an older version of SpiraTest, SpiraPlan or SpiraTeam (hereafter referred to as Spira) from an older version to the latest version, the installer has to upgrade the application and database at the same time. This article provides some solutions to cases where the installer throws an error or fails to upgrade the database for some reason.

Background

When you run the Spira installer it has to do the following tasks:
  1. Backup the old version's database into a flat XML file format
  2. Uninstall the program files
  3. Install the new program files
  4. Create a new format database from the previously backed-up database

Where does the Installer Store its Files?

During the backup (step 1) and migration phases (step 4) the installer will use the C:\Users\[Username]\AppData\Local\Inflectra folder to store the flat XML files that contain the data from your database. If you don't have a lot of space on your C: drive, you can set the Windows environment variable TST_WORKING_FOLDER to a different folder that it will use instead:

set TST_WORKING_FOLDER=D:\MyFolder

What Happens if an Error Occurs During Database Upgrade

Sometimes during the installation if there is an error that prevents the migration being successful, you will get an error during the upgrade process.

If this happened on step 1 (the backup to XML phase) then the solution is easy, just address the error (e.g. provide more disk space, etc.) and retry the upgrade since your old database will still be in place.

If however the upgrade occurred during the migration phase (step 4) you will no longer have a working database, since it will have been partially migrated. However there will be a full copy of the XML files. So you can either:
  1. Delete the database, restore the old version from your backup and try the upgrade again
  2. Use the special standalone database upgrade tool to upgrade the database to v5.0 and then just do a clear install of Spira 5.0 and use this migrated database.

Attached to this KB article are zip files containing the different standalone database upgrade tools for various versions of Spira. Please download the version corresponding to the version of the system you are upgrading to and then unzip the folder.

Inside the unzipped folder will be a file called BuildCustomActions.exe, please click on that:


When it appears, enter in your database information, you will need the SQL Server SysAdmin (SA) account for this to work correctly:


Then click [Restore from XML] to restore your Spira SQL Server database from the backed-up XML files. Please make sure that a database with the same name does not already exist or it will fail.

How to do a Database Migration Standalone

Sometimes customers will want to do a test upgrade of their Spira database without actually upgrading their installation. This can be done very easily by taking a recent backup of their current Spira database and installing it on a test server. Then they can download and extract the Standalone Migration Tool attached to this article that matches the version of Spira that they want to upgrade to.

Then unzip the migration tool zipfile into a folder and run the contained BuildCustomActions.exe file:



Then enter in your SQL Server name / instance as well as a valid SQL Server login/password that has access to the database being upgraded as well as the ability to create new SQL Server databases on that server (we recommend the built-in SA login):



Now click [Backup to XML] to make a complete backup of the Spira database to XML.

Then delete the old version of the Spira database from your SQL Server instance.

Now click [Restore to XML] and the newer version of the Spira database will be created and populated with your data.
Attachments
Article Info
Last Updated: 6/3/2016
Article ID: KB208
# Views: 822
Powered by KronoDesk v1.1.0.15 | © Copyright Inflectra Corporation 2011-2016 | Licensed to Inflectra Corporation.