RCLSTG (Reclaim Storage)

RCLSTG Command syntax diagram

 

Purpose

The Reclaim Storage (RCLSTG) command corrects, where possible, objects that were incompletely updated (such as database files, libraries, device descriptions, directories, and stream files) and user profiles containing incorrectly recorded object ownership information. Any unusable objects or fragments are deleted.

This command reclaims all objects secured by an authorization list that is damaged or destroyed and assigns the objects to the authorization list QRCLAUTL.

Because the amount of time required to run this command varies with the number of objects in auxiliary storage, the system periodically sends messages to the work station where the command was specified.

The RCLSTG command can also be used to reclaim storage when, during an IPL, not enough storage is available to make the system fully operational. In that case, the system operator can specify the command immediately after receiving the message about insufficient storage.

If very little additional auxiliary storage is available, the system overhead required to run the RCLSTG command may need more than the remaining storage; in that case, the RCLSTG command fails.

Note: The RCLSTG command can be a long-running function, depending on the number and type of objects in the system, and the amount of damage to them. Because RCLSTG touches each object multiple times, having enough memory can significantly reduce the time required to run RCLSTG. Conversely, having too little memory can lead to storage thrashing which can significantly increase the time required to run RCLSTG. If database file objects are damaged, the keyed access paths may need to be rebuilt; that operation takes a substantial amount of time. If the RCLSTG command can be run at the user's discretion, the user may want to avoid the operation until the required time can be scheduled.

 

Restrictions

  1. This command is shipped with public *EXCLUDE authority and the QPGMR, QSYSOPR, QSRV, and QSRVBAS user profiles have private authorities to use the command.
  2. If option *SYSBAS is specified on the ASPDEV parameter, all subsystems must be inactive before the RCLSTG command can be specified. The End System (ENDSYS) or End Subsystem (ENDSBS) command with *ALL specified on the SBS parameter can be used to make the subsystems inactive. You must have job control (*JOBCTL) authority to use the ENDSBS or ENDSYS command.
  3. Only permanent objects in auxiliary storage are reclaimed; temporary objects are reclaimed by running a system initial program load (IPL).
  4. Before running the RCLSTG command after an IPL, you may need to wait several minutes for the IPL to complete. Use the Work with Active Jobs (WRKACTJOB) command to verify that no jobs are running.
  5. If option *SYSBAS is specified on the ASPDEV parameter, this job must be in the controlling subsystem and must be the only job active in the system.
  6. If an auxiliary storage pool (ASP) device or an ASP group is specified on the ASPDEV parameter, it cannot have active users or be in use by a different job. >

 

Optional Parameters

SELECT
Specifies the reclaim functions that are performed.

*ALL: All reclaim functions are performed.

*DBXREF: The database cross-reference table reclaim function is performed.

OMIT
Specifies the reclaim functions to be omitted from the reclaim operation.

*NONE: No reclaim functions are omitted.

*DBXREF: The database cross-reference table reclaim function is omitted.

ASPDEV
Specifies the auxiliary storage pool (ASP) to be reclaimed.

*SYSBAS: The system ASP and all basic ASPs are reclaimed. The system ASP has an ASP number of 1. Basic ASPs have ASP numbers of 2 through 32.

auxiliary-storage-pool-device-name: The specified ASP device is reclaimed. ASP devices have ASP numbers greater than 32. Reclaim storage for an ASP device can be run without being in restricted state. You can submit multiple jobs, each performing RCLSTG on a different ASP device, to reclaim multiple ASP devices in parallel.

Start ofchangeauxiliary-storage-pool-group-name: The primary ASP and all the secondary ASPs within the ASP group are reclaimed. The name of any ASP within the ASP group is accepted. Primary and secondary ASPs have ASP numbers greater than 32. Reclaim storage for an ASP group can be run without being in restricted state. You can submit multiple jobs, each performing RCLSTG on a different ASP group, to reclaim multiple ASP groups in parallel.End ofchange

Examples for RCLSTG

Example 1: Reclaim Storage of the System ASP and All Basic ASPs

RCLSTG

This command, specified interactively, locates all system objects created before the last initial program load (IPL). Objects without owners are given default owners, and those that are lost from their specified libraries are inserted into the QRCL library or the default library, or are deleted.

Objects that are lost from their specified directories are inserted into the '/QReclaim' directory (if the object was originally located in the root file system) or the '/QOpenSys/QReclaim' directory (if the object was originally located in the QOpenSys file system).

Lost objects that are deleted are certain user objects and certain OS/400 system objects that are damaged and not usable.

The QRCL library, which is created (when needed) by the RCLSTG command, is a permanent library.

The '/QReclaim' and '/QOpenSys/QReclaim' directories, which are created (when needed) by the RCLSTG command, are permanent directories; but if they contain no objects at the end of the operation because they were all reclaimed, the directories are deleted.

Example 2: Reclaim Storage to Reclaim the Database Cross-reference Table

RCLSTG   SELECT(*DBXREF)

This command reclaims the database cross-reference table.

Example 3: Reclaim Storage of the Entire System That Omits the Reclaim of the Database Cross-reference Table

RCLSTG   OMIT(*DBXREF)

This command performs all reclaim storage functions but omits the reclaim of the database cross-reference table.

Example 4: Reclaim Storage of an ASP device

RCLSTG   ASPDEV(MYASPDEV)

This command reclaims storage for the ASP device name MYASPDEV.

Error messages for RCLSTG

*ESCAPE Messages

CPF180B
Function &1 not allowed.
CPF180C
Function &1 not allowed.
CPF2119
Library &1 locked.
CPF2120
Cannot delete library &1.
CPF2126
Attempt to recover library &1 failed.
CPF2127
User profile &2 damaged.
CPF5729
Not able to allocate object &1.
CPF8201
User profile &1 does not exist or is damaged.
CPF8204
Commitment control cannot be active during reclaim storage.
CPF8205
Library &1 does not exist or is damaged.
CPF8209
System not in proper state to reclaim storage.
CPF8210
Reclaim storage failed for auxiliary storage pool device &2.
CPF8211
Library &1 damaged. RCLSTG command ended.
CPF8212
SELECT(*DBXREF) or OMIT(*DBXREF) invalid when reclaiming an User Defined File System (UDFS) ASP.
>
CPF8224
Duplicate object found while moving or renaming member.
CPF8251
RCLSTG command ended. Library &1 damaged.
CPF8252
Error occurred during rebuild of damaged library &1.
CPF9814
Device &1 not found.
CPFB8ED
Device description &1 not correct for operation.
>

*STATUS Messages

CPI8206
&1% of objects read from disk.>
CPI8210
Processing data base relationships.
CPI8212
Data base/library/directory recovery in progress.
CPI8213
Processing objects on the system.
CPI8214
All permanent objects have valid owners.
CPI8215
Object description verification in progress.
CPI8216
Final clean up in progress.
CPI8217
Mail Server Framework cleanup in progress.
CPI8218
Directory recovery in progress.
CPI8219
Directory cleanup in progress.
CPI8220
Message queue QSYSOPR in *HOLD delivery mode.
CPIA916
&1% of directories processed.
>