When you start an enterprise server, a CICS transaction called JCL1 runs to delete old spool files. You can configure how often this happens and how long spool files are kept for.
Note: This process does not run automatically. You need to configure it using the PTLPI process. You also need to configure the CICS region to use spool housekeeping. SSTM is mandatory to enable support for the spool queue.
The housekeeping process involves the following programs: DFHZJCL1, DFHZJCL3, MVSP0027. The validation program described in the previous section starts the transaction JCL1, which runs the program DFHZJCL1. This program does the following:
- LINKS to DFHZJCL3 to get the Housekeeping Frequency (i.e. how often spool housekeeping should be run) and the Housekeeping Retain Period (i.e. how long spool files should be kept prior to automatic deletion).
- CALLS MVSP0027 passing the Housekeeping Retain Period. MVSP0027 deletes any spool files older than the retain period.
- STARTS JCL1 after the interval specified in Housekeeping Frequency
- Displays messages on the console saying that the spool housekeeping has:
- started: SPOOL CLEAN-UP started
and
- finished (successfully or not ): SPOOL CLEAN-UP ended normally, maximum retain period is 6 days.
Note:
The preferred way of running Spool Housekeeping is using JCL, as described in this help. The job can then be scheduled to reflect the realities of the customer's environment.
You can also run spool housekeeping using a CICS trancode. To do this:
- Define the CICS trancode for JCL1 that points to program DFHZJCL1.
To set that this trancode runs automatically upon server startup, add the group that contains that trancode to the startup list.