IBM Support

Defragmenting DASD Can Improve Performance on a System That Has Fragmentation

Troubleshooting


Problem

This document describes STRDSKRGZ command.

Symptom

Fragmentation on the disk drives, system may receive CPI0999

Diagnosing The Problem

A Directory Threshold Collection can be used to get a disk-by-disk analysis of the fragmentation on the drives

Resolving The Problem

The Start Disk Reorganization (STRDSKRGZ) command allows the user to start the disk reorganization function for one or more auxiliary storage pools (ASPs). The user specifies a time limit that the function is to run for each ASP being reorganized. A CPI1470 message will be sent to the system history (QHST) log when the reorganization function is started for each ASP. This can be performed by issuing STRDSKRGZ, <PF4> and then by entering the desired parameters and pressing <Enter>.

Unused space will be collected together within the ASP. This allows future large disk allocations to be done more efficiently.  The Start Disk Reorganization (STRDSKRGZ) command does not have to be run in restricted state. The reorganization is handled as a task by SLIC that runs as a low-level background type of job. It will perform the reorganizations of the specified ASPs as time is available.

Note 1: Restriction: You must have *ALLOBJ special authority to use this command.

Note 2: STRDSKRGZ does not move temporary storage
Note 3:  The STRDSKRGZ by default will not reorg SSD drives. This is to preserve the SSD life. An occasional reorg is not a concern, but a weekly reorg would more drastically decrease the SSD drive lifespan. If you have SSD and need to STRDSKRGZ, then you will need the following PTF applied:

        7.2 MF66947 (Included on Cumulative C0114720)

        7.3 MF66962 (Included on Cumulative C0128730)

        7.4 MF66964 (Included on Cumulative C0121740)

        Which will provide the following macros:

        smsetdefragssd [SSD will be included in the defragmentation]

        smresetdefragssd [Reset to Default. SSD will not be included in the defragmentation]

        smgetdefragssd [Display if SSD will be included or will not be included in the defragmentation]

        1. STRSST and sign in

        2. Option 1. Start a service tool

        3. Option 4. Display/Alter/Dump

        4. Option 1. Display/Alter storage

        5. Option 2. Licensed Internal Code (LIC) data

        6. Option 14. Advanced analysis

        7. Enter a 1=Select on the top blank line for the Option and smgetdefragssd for the Command, then press Enter

        8. [leave Options blank] and press enter

        9. If you have SSD and they are not included, then follow the above steps but using the macro command smsetdefragssd [leave the options blank]

 *Note 4: This setting smsetdefragssd will persist through an IPL but will NOT survive an upgrade or potentially future code updates. For this reason, always check the smgetdefragssd before running a disk reorg if you have SSD drives.





Example text of the CPI1470:

Message . . . . :   Disk reorganization successfully started for ASP &1.    
Cause . . . . . :   Disk reorganization has been successfully started for ASP
  &1.  It will run until the time limit has expired, the ASP has been        
  completely reorganized, or the function is stopped by the user.            


Message CPI1473 is issued to note that all reorganizations have been started, as shown in this example:
Message . . . . :   Disk reorganization started for all configured ASPs    
Cause . . . . . :   Disk reorganization has been started for all ASPs        
 configured on the system. It will run until the time limit has expired, the
 ASP has been completely reorganized, or the function is stopped by the user.


Message CPI1472 will be sent to QHST reporting the completion of the reorganization for each affected ASP, as shown in this example:                                                                                
 Message . . . . :   Disk reorganization for ASP &1 ended.                      
Cause . . . . . :   The disk reorganization function for ASP &1 has been      
  ended.  The function had ending code &2. The ending codes and their meanings
  are as follows:                                                              
    1 - The ASP is completely reorganized.                                    
    2 - The time specified for reorganization has expired.                    
    3 - The user requested that reorganization be ended.                      
    4 - The reorganization  function could not be started.                    
    5 - The reorganization function cannot be started on an ASP that consists of only one unit.                                                            
    6 - The reorganization function ended unexpectedly.  
                     

Message CPF1888
Message . . . . :   Disk reorganization for ASP &1 already started.
Cause . . . . . :   The disk reorganization function for ASP &1 has already been started.

Message CPF1890
Message . . . . :   *ALLOBJ authority required for requested operation.
Cause . . . . . :   *ALLOBJ special authority is required for the requested operation.

Message CPF1891
Message . . . . :   Disk reorganization cannot be started on an ASP with only one unit.  
Cause . . . . . :   The disk reorganization function for ASP &1 cannot be started. ASP &1 contains only one unit.

Message CPF0999
Message . . . . :   Function check detected in module &1.
Cause . . . . . :   A function check occurred in a program in QSYSARB, QSYSARB3, QSYSARB4, QSYSARB5, or QPFRADJ job.
 

[{"Type":"MASTER","Line of Business":{"code":"LOB68","label":"Power HW"},"Business Unit":{"code":"BU070","label":"IBM Infrastructure"},"Product":{"code":"SWG60","label":"IBM i"},"ARM Category":[{"code":"a8m0z0000000CRjAAM","label":"Disk Information"}],"ARM Case Number":"","Platform":[{"code":"PF012","label":"IBM i"}],"Version":"6.1.0;and future releases"}]

Historical Number

14860924

Document Information

Modified date:
21 January 2025

UID

nas8N1018156