OLREORG with REFGROUP=0 requires the Data Space Option (DSOP) attribute set to 4 or 5 instead of the default value of 1. This is done using the steps below.
This reorganization makes use of empty blocks; therefore, the area must contain at least 30% free space.
The default DSOP attribute for Disk Backup and Restore tables does not support Online Reorg (OLREORG) with REFGROUP=0 (it has value 1).
This process requires PTF RO90201 for Disk Backup and Restore 12.5 to change the DSOP value from 1 to 4 (RANDOM FOR OLREORG). Because this utility makes use of empty blocks, it is necessary that there is at least 20-30% free space in the area being reorganized.
//SYSIN DD *
CXXMAINT DBID=<dbid>,AREA=DMS,OPTION=ALTER,DSOP=4
/*
Execute DBUTLTY DATASCAN to rebuild the space index:
//SYSIN DD *DATASCAN DBID=<dbid>,AREA=DMS,OPTION=REBUILD_SPACE_INDEX
/*
//SYSIN DD *
ACCESS DBID=<dbid>,STATUS=OFF,USERS=WAIT
COMM DBID=<dbid>,OPTION=CLOSE
ACCESS DBID=<dbid>,STATUS=WRITE
COMM OPTION=CONSOLE,OPTION2='OPEN_BASE<dbid>'
/*
//SYSIN DD *
OLREORG DBID=<dbid>,TABLE=<ttt>,REFGROUP=0
/*The initial OLREORG execution for a table can exceed 24 hours depending on row volume and data fragmentation levels. The OLREORG job can be cancelled or stopped via a REQABORT command and resubmitted at a later time.
The reorganization process generates log area (LXX) records for every row movement, resulting in multiple SPILL requests. Execute SPILL jobs immediately to prevent the Multi-User Facility (MUF) from suspending update activity.
References