Migrating an SQL database
This topic provides instructions for migrating an SQL Server database by using the Data Migration Manager. This topic contains the following sections:
Before you begin
Back up the BMC Server Automation database.
- The migration process uses the database system ID information in the _template deployment to identify the database to migrate. In addition, the configurations from each existing deployment are processed, so each deployment present in the Deployments directory should have the correct configuration. Certain deployments are transitory and can be removed before an upgrade as they are not needed for normal operation.
- _install, _postmig, _util can be removed from the deployments directory if present, and provided that an installation, postmigration process, or blcontent process is not being run.
- _launcher is for the Application Server Launcher. This does not include database configuration information. _spawner and _pxe both include database configuration information. The _template deployment is used to create new deployments, including those used during migration.
Before migrating the database, ensure that the database configuration information in the present deployments of the Application Server is current and correct. To check the values, use the blasadmin utility and specify each deployment (except _launcher) name and validate that the 'Database' section information is correct and the 'FileServer' section is also correct. If the database section is incorrect, then one or both of the following commands will produce an error.
- blasadmin -s <deloyment name> show database all (for the _pxe deployment use blasadmin -s _pxe show pxe all)
- blasadmin -s <deployment name> show file all
If these commands return an error, use the blasadmin utility to correct the configuration so that those commands return correctly.
- To run the data migration manager in an interactive mode (recommended) on Linux and UNIX platforms, install the X Windows system (X11) and the xorg-x11-libs library on the computer on which you plan to run the BMC BladeLogic Data Migration Manager. You must also have the DISPLAY variable set appropriately.
- To run the data migration manager in a non-interactive mode on Linux and UNIX platforms, run the migration manager with the following options '-DmigRunCLI=true -DmigRunNonDefaultUIorCLI=true'. For example:
./blmigration_mgr -DmigRunCLI=true -DmigRunNonDefaultUIorCLI=true /path/to/external/files - To speed up the migration process, archive logging should not be used while BMC BladeLogic Data Migration Manager is executing.
To migrate your SQL database by using BMC BladeLogic Data Migration Manager
Back up the BMC Server Automation file server storage location. For example, copy the entire contents of the storage location to a directory other than the current storage location.
- Obtain the most recent version of external-files.zip and extract its contents. For a description of this file, see Downloading-the-installation-files.
Using the files extracted from external-files.zip, copy the /db_scripts/ <db_type>/upgrade directory into a directory on your Application Server.
- On the Application Server, use the cd command to navigate to the <installDirectory>/NSH/bin directory for BMC Server Automation.
Launch BMC BladeLogic Data Migration Manager by entering one of the following commands:
The [confluence_table-plus] macro is a standalone macro and it cannot be used inline. Click on this message for details.
Where <path_to_migration_directory> is the path to the migration directory that you copied to the Application Server in step 3. For example, if you extracted the version 8.2 SP1 externalfiles.zip under the tmp directory, then the path to the migration directory would be :(Windows)
C:\tmp\8.2-SP1-external-files\bl_8.2.01\db_scripts\sqlserver\upgrade\
(Linux and UNIX)
/tmp/8.2-SP1-external-files/bl_8.2.01/db_scripts/sqlserver/upgrade/
BMC BladeLogic Data Migration Manager creates the stored tasks needed for the data migration and then launches the BMC BladeLogic Data Migration Manager console.
- Click Run Migration.
- When migration completes, check the blmigration.log.
Where to go from here
You might need to perform the following tasks (in the specified order):
- If you are upgrading to an 8.3.x service pack (later than 8.3.00), run a set of SQL Update scripts to upgrade the BMC Server Automation database to the service pack level compatible with the Application Server, as described in Running-the-SQL-update-scripts.
- If you are migrating from a pre-8.0 version of BMC Server Automation, migrate the compliance rules and discovery signatures stored in the core BMC Server Automation database as described in Migrating-compliance-rules-discovery-signatures-and-smart-group-conditions.
Related topics