OLCSTAT data set

The global OLCSTAT data set, which z/OS® assigns to IMS, is a basic sequential access method (BSAM) data set that supports one record of variable size. You can allocate and deallocate the OLCSTAT data set dynamically. Unlike the MODSTAT data set, the OLCSTAT data set does not need to be continuously available when your IMS system is running.

OLCSTAT data set attributes

Before the OLCSTAT can be allocated, you must define the data set attributes. The following table shows the recommended attributes for the OLCSTAT data set, to allow up to 65 IMS records.

Table 1. Recommended attributes for the OLCSTAT data set
Data set attribute Value
DSORG Sequential
RECFM V
LRECL 5204
BLKSIZE 5208

If you do not define these attributes, when IMS attempts to allocate the OLCSTAT data set, that allocation fails.

After you define these attributes, you must name the data set by using the OLCSTAT parameter in the DFSCGxxx PROCLIB data set member.

OLCSTAT data set format

The OLCSTAT data set consists of a header and any number of IMS records, with the following formats:

  • OLCSTAT format for VERS=1
    hlenhverivermstr  OLCINP modifyid MODBLKSz x IMSACBb x FORMATc x
    ilenrveriverims   prepare_timestamp commit_timestamp
  • OLCSTAT format for VERS=2
    hlenhverivermstr  OLCINP modifyid MODBLKSz x IMSACBb x FORMATc x
    MOLCstate MOLCtoken MOLCid
    ilenrveriverims   prepare_timestamp commit_timestamp

The header information includes the master of the last online change phase, an online change in progress lock, the modify ID, the active MODBLKS DD name, the active IMSACB DD name, the active FORMAT DD name, and the libraries that were changed with the last online change. The header is initialized by the Global Online Change utility (DFSUOLC0).

hlen
The OLCSTAT data set header record length. The header record is the first line.
hver
The OLCSTAT data set header version.
iver
IMS version.
mstr
IMS ID of the IMS system that was the master of the last online change phase (prepare, commit, or abort.
ilen
The OLCSTAT data set IMS record length. The OLCSTAT data set contains zero, one or more OLCSTAT data set IMS records.
rver
The OLCSTAT data set IMS record version.
iver
IMS version.
ims
IMS ID.

OLCSTAT data set header

The following example shows a sample OLCSTAT data set header for Version 2.

RECORD SEQUENCE NUMBER - 1
000000  00000080 00000002 F1F0F1F0 40404040   40404040 40404040 40404040 
000020  F0F0F0F1 40D4D6C4 C2D3D2E2 C140D540   C9D4E2C1 C3C2C140 D540C6D6 
000040  C140D540 D4D6D3C3 C3D4D7E3 40BF88D7   940BE91E 82402006 283F2321 
000060  028D4040 40404040 40404040 40404040   40404040 40404040 40404E40 
000080  00000050 00000001 F1F0F1F0 40404040   C9D4E2F1 40F2F0F0 F6F2F8F3 
0000A0  F0F5F2F7 4060F0F7 7AF0F040 F2F0F0F6   F2F8F340 F2F3F2F1 F0F3F440 
0000C0  F0F04040 40404040 40404040 4040404E                              


F0F0F0F0   *........1010                0000*
D9D4C1E3   *0001 MODBLKSA N IMSACBA N FORMAT*
03465440   *A N MOLCCMPT ..P..Z.. ......... *
40404040   *..                        +     *
40F2F3F2   *...&....1010    IMS1 2006283 232*
60F0F77A   *0527 -07:00 2006283 2321034 -07:*
           *00             +                *
                                             

IDC0005I NUMBER OF RECORDS PROCESSED WAS 1                               
IDC0001I FUNCTION COMPLETED, HIGHEST CONDITION CODE WAS 0                
IDCAMS  SYSTEM SERVICES                                           TIME: 1

Each IMS record contains information about an IMS that is current with the online change libraries. The IMS either participated in the last online change, or cold started since the last online change. If no IMS has cold started yet, the OLCSTAT data set contains no IMS records.

You must also run the Online Change Copy utility (DFSUOCU0) as one step in the process of preparing an IMS or an IMSplex for an online change. The DFSUOCU0 utility copies a source library with your new definitions to a target library. In an IMSplex where IMS systems are not cloned and the libraries are not shared, you might need to run the DFSUOCU0 utility on every IMS system in the IMSplex. In an IMSplex where IMS systems are cloned and the libraries are shared, you might need to run the DFSUOCU0 utility only once on one IMS.SDFSRESL data set at the highest IMS level.

The DFSUOCU0 utility can copy the contents of the staging library to a target library that is specified as a parameter. The utility supports a target library value of G, which means that the library target is the active library determined by the utility, using the OLCSTAT data set. The target is the library that is not currently in use by the IMS systems in the IMSplex. If the new target library G is specified, the DFSUOCU0 utility reads the OLCSTAT data set to determine the target library. The global online change commands, INITIATE OLC PHASE(PREPARE), followed by INITIATE OLC PHASE(COMMIT), change the inactive library to an active library.