Lowering the share level of a database

Given the following initial and target configurations, use this scenario to lower the share level of a database.

  • Initial configuration
    • dbx is authorized for update access to an online IMS system (IMSA).
    • dbx is authorized for read-only access to another online IMS system (IMSB).
  • Target configuration
    • dbx is authorized for exclusive control by IMSA.

Follow these steps to lower the share level:

Procedure

  1. Prevent all IMS systems from obtaining access with the following command: CHANGE.DB DBD(dbx) NOAUTH
  2. Suspend activity on dbx and close dbx in both IMS systems with one of the following commands:
    • /DBRECOVERY DB dbx NOFEOV
    • UPDATE DB STOP(ACCESS) OPTION(FEOV)
  3. Allow processing in IMSA with the following command:
    CHANGE.DB DBD(dbx) AUTH
    /START DATABASE dbx ACCESS=EX
    /START PGM
    /START TRAN

    The database is not protected from other IMS systems until IMSA schedules an application program with a PSB that is sensitive to the database. In order to lock out all other IMS systems, therefore, IMSA must be the first IMS system to obtain the authorization to process the database with exclusive access.

    IMSA accepts the change of access intent only if the target database is not authorized.

You can also achieve the same results by modifying the sharing level of the database in the RECON data set instead of changing the access intent of IMSA. Omit the /START DATABASE command with the ACCESS= keyword and perform the following step before step 3:

  • Request DBRC to enforce exclusive control:
    CHANGE.DB DBD(dbx) SHARELVL(0)

    In this case, DBRC grants database authorization at the requested level, and IMSA owns the database exclusively.