Reclaim Spool Storage (RCLSPLSTG)

The Reclaim Spool Storage (RCLSPLSTG) command reclaims unused storage for spooled files that have not been used for more than the number of days specified by the user. Spooled files are stored with database file members on the system. When a spooled file is deleted, the member is emptied but not deleted. Therefore, the member can be reused for the next spool file created. Reusing empty members improves the performance time when creating new spooled files. The RCLSPLSTG command deletes unused and empty database members in the specified ASP group. The QRCLSPLSTG system value can be set to automatically delete unused and empty database members in primary or secondary ASPs. This command uses synchronous processing. More information about synchronous processing is in the Recovering your system book, SC41-5304.

Restriction: If *ALL or a specific ASP group is specified for the ASPGRP parameter, the user must have use (*USE) authority to all ASP device descriptions in the ASP group and the status of the ASP group must be AVAILABLE.

Parameters

Keyword Description Choices Notes
DAYS Days 1-366, *NONE Required, Positional 1
ASPGRP ASP group Name, *SYSBAS, *ALL, *, *CURASPGRP Optional

Days (DAYS)

Specifies an interval in days. If existing spool storage has not been used to create new spooled files in the number of days specified, it will be deleted.

This is a required parameter.

*NONE
No interval is used. All unused spool storage is deleted. No storage will remain for creating new spooled files. This will lengthen the time it takes to create a new spooled file.

Note: Using this value can have adverse effects on system performance. More information is in the Files and file systems category in the IBM i Information Center at http://www.ibm.com/systems/i/infocenter/.

1-366
Specify the number of days. The specified number of days is measured to the second.

ASP group (ASPGRP)

Specifies the auxiliary storage pool (ASP) group that contains the unused database members to delete.

*SYSBAS
Unused database members which are found in the system ASP (ASP 1) and all defined basic user ASPs (ASPs 2-32) are deleted.
*ALL
Unused database members which are found in the system ASP (ASP 1), all defined basic user ASPs (ASPs 2-32) and all primary and secondary ASPs are deleted.
*
Unused database members which are found in the ASPs that are currently part of the thread's library name space are deleted. This includes the system ASP (ASP 1), all defined basic user ASPs (ASPs 2-32), and if the thread has an ASP group, the primary and secondary ASPs in the thread's ASP group.
*CURASPGRP
Unused database members which are found in the primary and secondary ASPs in the thread's ASP group are deleted. If no ASP group is associated with the thread, an error will be issued.
name
Specify the name of an ASP group. Unused database members which are found in the primary and secondary ASPs of the specified ASP group are deleted.

Examples

Example 1: Delete Unused Database Members in the System ASP (ASP 1) and All Defined Basic User ASPs (ASPs 2-32)

RCLSPLSTG   DAYS(30)

This command reclaims all unused storage for spooled files in the system auxiliary storage pool (ASP 1) and all defined basic user ASPs (ASPs 2-32) that have remained unused for more than 30 days. When storage has been unused for 1 second over 30 days it is reclaimed because a date and time stamp is placed on the storage area.

Example 2: Delete Unused Database Members in the Current User's ASP Group

RCLSPLSTG   DAYS(*NONE)  ASPGRP(*CURASPGRP)

This command reclaims all unused storage for spooled files in the current user's ASP group.

Example 3: Deleting All Unused Database Members

RCLSPLSTG   DAYS(*NONE)  ASPGRP(*ALL)

This command deletes all unused database members on the system.

Example 4: Deleting All Expired Spooled Files in the System ASP (ASP 1) and All Defined Basic User ASPs (ASPs 2-32)

RCLSPLSTG   DAYS(*NONE)  ASPGRP(*)

This command reclaims all unused storage for spooled files in the system auxiliary storage pool (ASP 1), all defined basic user ASPs (ASPs 2-32), and if the thread has an ASP group, the primary and secondary ASPs in the thread's ASP group.

Error messages

*ESCAPE Messages

CPF9825
Not authorized to device &1.
CPFB8E9
ASP group &1 not set for thread &2.