Create tablespaces for a logging database on Db2 on z/OS

If you are using IBM® Db2 on z/OS®, a database administrator must run a script to create a set of tablespaces required for the logging database. The script must be modified to replace the placeholder parameters with ones that are appropriate for your environment.

Ensure that you use the name convention for Db2 on z/OS. For example, all names of parameters must start with a letter and the length must not exceed 6 characters. For more information, see the Db2 Knowledge Center.

Procedure

  1. Connect to the database as a user with privileges to create and drop tablespaces and to allow execution of SQL statements.
  2. Go to the install_location/configuration/schemas/logging/db2zos directory.
  3. Open the LS_tablespace_db2zOS.sql script file and use the following table to help you to replace the generic parameters with ones appropriate for your environment.
    Table 1. Tablespace parameter names and descriptions for a logging database on Db2 on z/OS

    Parameter Name

    Description

    IPFSCRIPT_DATABASE

    The name of the logging database.

    IPFSCRIPT_STOGROUP

    The name of the storage group.

    IPFSCRIPT_TABLESPACE

    The name of the tablespace that contains the base tables in the logging database.

    This tablespace is not for Auxiliary tables.

    IPFSCRIPT_LS_ID

    The instance identifier for the audit database. This value must not be longer than two characters.

    IPFSCRIPT_BP

    The name of the 8 k buffer pool that is allocated for regular objects.

    IPFSCRIPT_USERNAME

    The user account that accesses the logging database.

    Not all of the parameters listed are in the script, but may be added in the future.

  4. Save and run the script.
  5. Grant the IBM Cognos® user rights to the tablespaces that were created when you ran the script file:
    • Open the LS_rightsGrant_db2zOS.sql script file.
    • Replace the parameter values with those that are appropriate for your environment.

      Tip: Ensure you use the same values that you used when you created the buffer pools and user account.

    • Save and run the LS_rightsGrant_db2zOS.sql script.

Results

The logging database is created.