DRAFT - Migrating Stash to another server

Migrating Stash to another server

On this page

Still need help?

The Atlassian Community is here for you.

Ask the community

Error rendering macro 'viewport-redirect'

null

This page...

... describes how to move your Stash installation from one physical machine to a different machine.

If you want to migrate Stash to a different DBMS...

... read Using the Database Migration Wizard instead.

If you're upgrading Stash...

... read the Stash upgrade guide too. You can upgrade Stash either before or after you migrate Stash.

For most scenarios, the overall procedure involves the following 4 steps, although your situation may not require all of these:

1. Prepare for the migration

In preparation for migrating Stash to another server, check that you have done the following:

  • Confirm that the operating system, database, other applicable platforms and hardware on the new machine will comply with the requirements for Stash.
  • Check for any known migration issues in the Stash Knowledge Base.
  • Alert users to the forthcoming Stash service outage.
  • Ensure that users will not be able to update existing Stash data during the migration. You can do this by temporarily changing the access permissions for Stash.
  • Make sure you have created a user in Stash (not in your external user directory) that has System Administrator global permissions so as to avoid being locked out of Stash in case the new server does not have access to your external user directory.

2. Back up Stash

  1. Back up Stash. See Data recovery and backups for detailed information.

  2. Stop Stash. See Starting and stopping Stash.

3. Restore Stash to the different machine

If you want Stash to use the same DB as before, refer to...

If you want Stash to connect to a new DB instance, refer to...

 

See Data recovery and backups for detailed information.

  1. Set up an instance of the same version of Stash on the new machine by doing one of the following:
    • Install Stash using the Stash installer, if available for your version. See Running the Stash installer. At the 'Select Stash Home' step, browse to the newly restored Stash home directory (as defined by the STASH_HOME variable – see Stash home directory).
    • Either install Stash manually from a downloaded archive file (see Install Stash from an archive file), or make an archive of the old Stash installation directory and copy it across to the new machine. In either case, you'll need to redefine the value for STASH_HOME, using the new location of your copied home directory. See Stash home directory for more information.
  2. If you are continuing to use the Stash embedded database, you should now be able to start Stash on the new machine and have all your data available. Once you have confirmed that the new installation of Stash is working correctly, revert the access permissions for Stash to their original values.
  3. If you moved the Stash data by performing a database export and import, carry on to Step 4 below to update the stash-config.properties file in the <Stash home directory>.

4. Update the Stash configuration

If you moved the Stash data by performing a database export, you must update the stash-config.properties file in the <Stash home directory> with the changed configuration parameters for the database connection.

The configuration parameters are described in Stash config properties.

Once the configuration parameters are updated, you should be able to start Stash on the new machine and have all your data available. 

Once you have confirmed that the new installation of Stash is working correctly, revert the access permissions for Stash to their original values.

Last modified on Oct 6, 2017

Was this helpful?

Yes
No
Provide feedback about this article
Powered by Confluence and Scroll Viewport.