IBM Books

DB2 Replication Guide and Reference


Collecting Data with BUILDDB

Enter the following commands to collect Version 1 registration and subscription information from the servers in your replication environment:

  1. Set db2dbdft=mig_db
    

  2. ASNMIG BUILDDB mig_db serv_list
    

    Where:

    mig_db
    Name of the migration database where you want to store the global control tables. The database must already exist before you can enter a value for this parameter. This is a required parameter.

    serv_list
    List of databases from which you want to gather Version 1 replication information. You can use an asterisk (*), in addition to one required database alias name, as a wildcard if you want BUILDDB to add to the list of servers as it runs. This is a required parameter.

BUILDDB puts a collection trace into the BUILDDB.TRC file, and puts SQL statements that must be executed in DB2 into the BUILDDB.SQL file. After completing this action, you must execute this file using the DB2 -TF command to create the migration global control tables and insert rows to these tables. The SQL statements for creation of these tables appear in the BUILDDB.SQL file only if one or more of the tables does not exist.

When you specify the wildcard character, *, in your replication network, BUILDDB examines all of the replication definitions for the servers provided and found in the userid.IBMSNAP_ROUTING, userid.IBMSNAP_REF_CNTL, userid.IBMSNAP_TRAIL, and userid.ASN. timestampPC tables. The migration database contains global control tables that store registration and subscription details for these servers. When you run BUILDDB, it is recommended that you specify that all servers (source, target, control) be processed together. This will ensure that the prepare and analysis steps will include all information.

BUILDDB.SQL creates a new version of migration analysis data in your migration database every time you run it. The ASN.VERSION_CONTROL table contains the version and timestamp history of when you last executed BUILDDB.


[ Top of Page | Previous Page | Next Page | Table of Contents | Index ]

[ DB2 List of Books | Search the DB2 Books ]