0% found this document useful (0 votes)
36 views2 pages

Using Db2 Migration Service - IBM Documentation

The document discusses how to use the Db2 Migration Service to migrate databases and schemas between Db2 databases and cloud offerings. It provides examples of commands to migrate specific tables, schemas, and whole databases between on-premises and cloud environments using either the command line client or configuration files. Key steps include starting the Migration Server, using the migration_client script to run jobs, and specifying source and target connection details and objects to migrate.

Uploaded by

navdeepdecent
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
36 views2 pages

Using Db2 Migration Service - IBM Documentation

The document discusses how to use the Db2 Migration Service to migrate databases and schemas between Db2 databases and cloud offerings. It provides examples of commands to migrate specific tables, schemas, and whole databases between on-premises and cloud environments using either the command line client or configuration files. Key steps include starting the Migration Server, using the migration_client script to run jobs, and specifying source and target connection details and objects to migrate.

Uploaded by

navdeepdecent
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

2/17/24, 8:10 PM Using Db2 Migration Service - IBM Documentation

Using Db2 Migration Service


Last Updated: 2024-02-15

To use the Db2 Migration Service, users can either use the command line client or access it through a website.

Before you begin

Attention: The IBM® Db2 Migration Service is offered at this time as a technical preview. It is intended for use in non-production environments.

To use the Db2 Migration Service, you must first start the Migration Server, and then use Migration Client to send a migration job request. Running the M

Alternatively after the installation and if the default port number values were used, the Db2 Migration Service website is accessible under https://<m
the Db2 Migration Service is running.

Procedure
Run a migration job from the command line.
To run a migration job, use the migration_client script and provide the migration scenario, and the source and target environments details.

migration_client <migration_server_details> <subcommand_scenario> <subcommand_parameters>

Example
Example 1: Migrating two tables, TABLE1 and TABLE2, from one Db2 database to another Db2 database:

MIGRATION_CLIENT DB2_DB2 --THOSTS 10.0.0.1 --TUSER ADMIN2 --TPASS PASSWORD2 --TDB TDATABASE --SHOST 10.0.0.2 --SUSER ADMIN1 --SPASS PASSWORD1

Example 2: Migrating two tables, TABLE1 and TABLE2, from one Db2 database to another Db2 database. The tables are renamed to TABLE1A and TA

MIGRATION_CLIENT DB2_DB2 --THOSTS 10.0.0.1 --TUSER ADMIN2 --TPASS PASSWORD2 --TDB TDATABASE --SHOST 10.0.0.2 --SUSER ADMIN1 --SPASS PASSWORD1

Example 3: Migrating a whole schema. This scenario can be done by using the following command:

migration_client db2_db2 --shosts 10.0.0.1 --suser ADMIN1 --spass PASSWORD1 --sschema SOURCE_SCHEMA --sdb SDATABASE --thosts 10.0.0.2 --tuser

Example 4: Migrating to Db2 on Cloud. The following command can migrate the database and the schema to a cloud offering, in this case to Db2 on C

migration_client db2_db2cloud --shosts 10.0.0.1 --sport 50000 --suser ADMIN1 --spass PASSWORD1 --thost db2oncloud.ibm.com --tport 12345 --tus

Example 5: Migrating from one cloud offering to another cloud offering. This scenario can be done by using the following command:

migration_client db2_db2 --shost DB2ONCLOUD1.IBM.COM --sschema SSCHEMA --suser ADMIN1 --spass PASSWORD1 --sdb SDATABASE --sport 50001 --thos

Note: Using the db2_db2 option to migrate cloud instances, you need to enable SSL connections for both directions. This means specifying the
– --target-ssl True
– --source-ssl True
– Specifying an SSL port

If you are using the db2_db2cloud option, --target-ssl True is set by default.

Example 6: Migrating by acquiring the parameters from the text files:

migration_client db2_db2 @<filename> [@<filename>...]

Important: Filename must be prefixed with an @ symbol.

https://www.ibm.com/docs/en/db2/11.5?topic=service-using-db2-migration 1/2
2/17/24, 8:10 PM Using Db2 Migration Service - IBM Documentation
Example text file:

# Migration arguments

--thosts # Target hosts


10.0.0.1
--tuser # Target user
ADMIN2
--tpass # Target password
PASSWORD2
--tdb # Target database
TDATABASE
--shost # Source host
10.0.0.2
--suser # Source user
ADMIN1
--spass # Source password
PASSWORD1
--sdb # Source database
SDATABASE
--tables # List of tables to migrate
TABLE1
TABLE2
--truncate-table # Truncate target table

Example usage of the text file:

migration_client db2_db2 @conn.txt @other.txt

This functionality can be used with other scenarios as well.

Note: Using more than one file to acquire arguments from, arguments from all of these files are concatenated.

Parent topic:
IBM Db2 Migration Service

https://www.ibm.com/docs/en/db2/11.5?topic=service-using-db2-migration 2/2

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy