Using MIGRATE and IMPORT for data movement
EXPORT, MIGRATE, and IMPORT make the task of moving the data between Db2 subsystems simpler and more accurate, and support all BMC AMI Copy formats (including cabinet copies).
If your migration uses the MIGRATE command, the BMC AMI Copy EXPORT runs on the target system and the BMC AMI Recover MIGRATE runs on the source system. BMC AMI Recover uses the OBIDs from the EXPORT. Optionally, log from the source system can be used with the MIGRATE command.
This copy migration feature requires one of the following valid passwords:
- A Recovery Management for Db2 solution password
- A BMC Database Administration for DB2 solution password
The benefits of data migration with the BMC AMI Copy EXPORT and BMC AMI Recover MIGRATE/IMPORT features include:
- Supports importing copies that use BMC proprietary formats
- Does not require that you manage data sets to keep up with current copies
- Does not require that you know the OBIDs from the source system
- Imports applications and object sets as a single unit
- Does not require the import of unchanged objects
- Supports the use of older EXPORT files to back-date imports
- Provides a less error-prone, and therefore, more accurate data migration (for example, less likely to use the wrong data set name or OBIDs).
If you use BMC AMI Change Manager for Db2 with the Copy Migration feature (EXPORT and IMPORT commands only, not the MIGRATE command), you achieve the following benefits:
- Simplifies the data movement process
- Requires less JCL, and therefore, less JCL management
- Supports DSNUM values other than 0
- Supports multiple imports and multitasking
- Ability to use migration resources stored in BMCXCOPY, such as cabinet and OCC image copies
BMC AMI Copy EXPORT file
The BMC AMI Copy EXPORT file provides a method for transferring all types of BMC AMI Copy and IBM copies between Db2 subsystems.
The EXPORT file contains information to streamline the import recovery process with a minimum of user-supplied knowledge and intervention. The MIGRATE or IMPORT command of BMC AMI Recover is used to complete the transfer and integration of data using the copies.
The latest SYSCOPY and BMCXCOPY rows and metadata for the selected spaces are written to the designated sequential file. The metadata describes each object with the information needed to translate OBIDs on the target system and to do checks during importing.
The EXPOUT option on the BMC AMI Copy OUTPUT command indicates that BMC AMI Copy will create an EXPORT file for migration.
BMC AMI Recover MIGRATE and IMPORT commands
To initiate the import process, at a minimum you must specify the MIGRATE or IMPORT command with a USING clause. If table name ambiguity exists, you can add the CHANGE ... FROM ... TO clause. When all the tables on each target space match all the tables on one and only one space in the BMC AMI Copy EXPORT file, you do not need to specify the CHANGE ... FROM ... TO clause. Additionally, a SYNC option on the IMPORT command allows you to specify whether you want to migrate all spaces or only change spaces.
For BMC AMI Recover MIGRATE and IMPORT command syntax, see MIGRATE-command and IMPORT-command.
MIGRATE and IMPORT limitations
The EXPORT/MIGRATE or IMPORT copy migration feature has the following limitations:
- No support for incremental copies
- No support for copies of the Db2 catalog
No support for specifying DSNUM
EXPORT looks for the most recent copy. If the copy is a DSNUM 0 copy, EXPORT uses that copy. If the copy is a DSNUM n copy, EXPORT looks for DSNUM n copies for all partitions or data sets.
- For IMPORT, BMC AMI Recover recovers indexes that are included in the IMPORT file and rebuild other indexes, unless you specify INDEXES NO. If the source and target table spaces are not at the same version, BMC AMI Recover will not rebuild the indexes. You will need to run REPAIR VERSIONS or use the UPDATE VERSIONS option, and then rebuild the indexes in a separate step.