In specific scenarios it makes sense to change the access method for the IMS primary database from VSAM/ESDS to OSAM (e.g. if the dataset is going to reach the 4GB limit for VSAM datasets).
This document lists the steps being necessary to convert from VSAM/ESDS to OSAM.
These are the steps being necessary to change the IMS database dataset access method from VSAM/ESDS to OSAM :
- run DBCOPY to take an Image Copy from the VSAM database
- run DBO Unload against the VSAM database using the old DBD
- change the DBD of the primary database using "OSAM" instead of "VSAM" on the DBD's ACCESS parameter
- if option "BLOCK" is used on the old DBD's DATASET parameter, change to option "SIZE" instead of "BLOCK"
(SIZE corresponds to the actual BLKSIZE of the physical dataset, no overhead will be added by IMS)
- always use an EVEN value for the SIZE option (to enable a dataset size of 8GB for OSAM - using an ODD value
would result in limiting the OSAM dataset to 4GB)
- re-gen the new DBD and all ACBs containing this DBD
- delete (or rename) the old VSAM dataset
- amend the IDCAMS step changing the "DEL/DEF CLUSTER" statements to "DELETE NONVSAM/ALLOCATE"
(to pre-allocate the OSAM dataset as sequential flat file - do NOT use DCB attributes, they will be allocated by IMS)
- include the appropriate OSAM buffers to any DFSVSAMP DD buffer allocations (instream as well as PDS member)
and to the DFSVSMxx PROCLIB member for online regions
(e.g. use IOBF=(24576,4) if SIZE=24576 has been used in the new DBD)
- run DBO Reload to build the OSAM database using the new DBD
- run DBCOPY to take an Image Copy from the new OSAM database
Because the old Recon entries (belonging to the VSAM database) are still present in DBRC, database recoveries to a
timestamp BEFORE changing the database to OSAM are still possible (but of course the OLD VSAM-DBD must be used
for this recovery run, a different database dataset should be used (to keep the current OSAM database), and the recovery
run entry should NOT be registered to DBRC).
If recoveries to the old VSAM database are not wanted anymore, the old Recon entries could be deleted by deleting/
redefining this database to DBRC after re-genning the new DBD (step 6.).