Limited support This version of the product is in limited support. However, the documentation is available for your convenience. You will not be able to leave comments. Click here to view the documentation for the current version.

Transferring data between environments



The Data Transfer tool, available with a BMC Digital Workplace installation is a set of multiple scripts that work in conjunction to export and import BMC Digital Workplace data between different BMC Digital Workplace environments, such as:

  • From a preproduction environment to a production environment
  • In a multitenant environment, between two tenants, so that both tenants have the same data

By using the tool, you can transfer all existing tenant-specific data from the business and system database schemas between source and target BMC Digital Workplace environements. Along with the BMC Digital Workplace data, the tool also transfers the BMC Remedy with Smart IT (Smart IT) data stored in the same database schemas.

Scenario for using the BMC Digital Workplace Data Transfer tool

Allen, an administrator at Calbro Services, is working on deploying BMC Digital Workplace in his organization. In a preproduction environment, he has configured the BMC Digital Workplace application according to the organization's needs. The validation testing is successful and a Go-Live is approved. Allen now wants to configure MyIT in the production environment exactly like the preproduction environment. Instead of manually configuring BMC Digital Workplace in the production environment or manually copying all data between environments, Allen chooses to use the BMC Digital Workplace Data Transfer tool to perform the task. By using the tool, Allen is able to seamlessly transfer all data to the production environment.

Note

The following video shows an older version of BMC Digital Workplace. The previous product name was MyIT. Although there might be minor changes in the UI, the overall functionality remains the same.

The following video (4:25 min) shows the process of exporting and importing data from aBMC Digital Workplace source tenant to a target tenant.

icon_play.png https://youtu.be/-ROfSFVKmqo

Before you begin

  • Ensure that you have permissions to access the databases on the source and target MyIT environments.
  • Locate the BMC Digital Workplace Data Transfer tool scripts in the MyIT_Home\SmartIT_MyIT\data-transfer\scripts directory, where MyIT_Home is the BMC Digital Workplace installation directory. The default BMC Digital Workplace installation location is as follows:
    • (Windows) C:\Program Files\BMC Software\Smart_IT_MyIT\
    • (Linux) /opt/bmc/Smart_IT_MyIT/
  • If you are running the data transfer from a computer other than the MyIT host computer, copy the entire contents of the \data-transfer directory to your local computer.
  • Ensure that the Social and MyITTomcat services are not being used during the data transfer.
  • Ensure that users do not create new data in the source database when data export is in progress. Otherwise, the newly created data might not be included in the data export.

To transfer data between environments


The following graphic shows the sequential steps in the data transfer process. Click each link to go to the specific section.

Data transfer steps.png

For information about issues you might have during data transfer, and the corrective actions, see Troubleshooting-data-transfer-issues.

Step 1: Export data from the source tenant database

  1. In the \scripts directory, locate the the set_env.bat or set_env.sh scripts.
  2. Using a text editor such as Notepad, edit the set_env.bat or set_env.sh script and enter the values for the different variables.

    Variables to be set in the set_env.bat or set_env.sh file


    The set_env.bat  or set_env.sh scripts include a brief description of each variable.

  3. Save and close the set_env.bat  or set_env.sh script.
  4. Edit the \SmartIT_MyIT\data-transfer\connection\db_type.connection.properties file and specify required database information of the source database.

    Database information to be specified in the db_type.connection.properties file


    For MS SQL database type:

    For Oracle database type:

     

  5. Save and close the db_type.connection.properties file.
  1. From the CLI console, navigate to the \scripts directory and run the appropriate command:

    • To export all data, run the data_dump.sh or data_dump.bat script.
    • To export only selected data, as specified in the export_type variable in the set_env.bat or set_env.sh script, run the run_export.bat or run_export.sh script.

    Note

    If you run the command again with the --overwrite option, it will overwrite the existing output file, or create a new output file if not already present.

    Depending on the file name you set in the output_file_path variable, an output file, file_name.zip file is created. The tool uses this file for importing the data in the target database. 

Step 2: Import the data to the target tenant database

Tips

For faster data import, run the data import step on the target database server.

  1. In the \scripts directory, locate  the the set_env.bat or set_env.sh script.
  2. Using a text editor such as Notepad, edit the set_env.bat or set_env.sh script and enter the values for the different variables.

    Variables to be set in the set_env.bat or set_env.sh file


  3. Save and close the set_env.bat or set_env.sh script.
  4. Edit the \connection\db_type.connection.properties file and specify the required database information of the target database.

    Database information to be specified in the db_type.connection.properties file

    For MS SQL database type:

    For Oracle database type:

     

  5. Save and close the db_type.connection.properties file.
  6. From the CLI console, navigate to the \scripts directory and run the run_import.bat or run_import.sh command.
    The tool transfers the data to the target database.

Step 3: Verify the data transfer

  1. Run SQL queries to verify that the data in the migrated tables in the source and target databases match.
  2. Login to the BMC Digital Workplace application on both source and target servers and verify that all required data is available in the UI.

List of tables associated with export_type values

The export_type variable in the set_env.bat or set_env.sh script contains a comma-separated list of values that define which database tables you transfer between the source and target databases. You can specify the value of this variable and then use the run_export.bat or run_export.sh script to transfer selected data between the source and target databases. The following table lists the valid values for the export_type variable and the database tables that correspond to each value: