Update database schemas

Database schemas that you used with the earlier source portal need to be updated for use with the new target portal. The migration process handles these updates for you automatically. However, if the portal uses IBM DB2 Universal Database™ for z/OSas the backend repository, you can choose to view the SQL scripts that the migration process uses to update the database schemas.

  1. To ensure that you connect to the appropriate database domains, review wkplc_dbdomains.properties and update the file as needed with the correct database parameters.

  2. DB2 for z/OS only: To generate the scripts that will be used to migrate the database schemas, run the following command from the WP_PROFILE/ConfigEngine:

    • Windows™: ConfigEngine.bat generate-db-migration-scripts

    • UNIX™: ./ConfigEngine.sh generate-db-migration-scripts

      WebSphere Portal stores the generated scripts in the WP_PROFILE/PortalServer/DBMigrationScripts/db_Type where db_Type is the DBMS that the portal uses. Each script file name reflects the domain name. For example:

        db2_zos/migrate_community_wp.db.impl.sql

        db2_zos/migrate_customization_wp.db.impl.sql

        db2_zos/migrate_jcr_wp.db.impl.sql

        db2_zos/migrate_release_wp.db.impl.sql

      An additional set of files is created to drop tables that were present in 6.0.x and might exist in 6.1.x installation if you have previously migrated from 6.0.x to 6.1.x. These files have the format dropV6legacyTables_db_domain_wp.db.impl. For example:

        db2_zos/dropV6legacyTables_community_wp.db.impl.sql

        db2_zos/dropV6legacyTables_customization_wp.db.impl.sql

        db2_zos/dropV6legacyTables_jcr_wp.db.impl.sql

        db2_zos/dropV6legacyTables_release_wp.db.impl.sql

      You can review these files to understand the schema updates that will be performed during migration.

      WebSphere Portal also saves copies of the generated scripts in WP_PROFILE/PortalServer/DBMigrationScripts/db_Type/templates; scripts in the /templates subdirectory are reserved for internal use and should not be run by users.

  3. DB2 for z/OS only: After validating the scripts generated in the previous step. You must run the scripts to make the schema changes. Do not attempt to use database tools to make the updates. The scripts are provided as a reference to show what changes will be made to the database. You must use the provided WebSphere Portal migration tooling to make the required schema changes.

    • Windows: ConfigEngine.bat upgrade-database

    • AIX®, i, Linux™, Solaris, and z/OS: ./ConfigEngine.sh upgrade-database

  4. DB2 for z/OS only: Update the database schemas.

    1. Table spaces that have a CHECK PENDING status can prevent migration from completing successfully. To determine which table spaces have a CHECK PENDING status, run the query shown below from the command line processor:

        SELECT DBNAME,NAME FROM SYSIBM.SYSTABLESPACE WHERE (STATUS = 'P') OR (STATUS = 'S');

    2. For each table space that the preceding query identifies, type the following command to remove the CHECK PENDING status:

        check data tablespace database_name.tablespace_name

        where tablespace_name and database_name are the respective names of each tablespace and the corresponding database. For more detailed instructions, refer to the Utility Guide and Reference for DB2 for z/OS.


Parent

Migrate a V6.1.x clustered portal


Previous

Retaining custom table spaces in a clustered portal


Next topic

Update the DB2 for z/OS driver

  Submitted by Thad Hinz on Jan 10, 2012 12:31:09 PM

Re: Updating database schemas

The above instructions are a bit confusing. Step 2 states "DB2 for z/OS only" and yet commands for Windows and Unix are provided. Can these scripts be used for Unix and Windows to manually update the database schemas, if needed?


+

Search Tips   |   Advanced Search