Data backups should be kept available for a particular period of time.
The retention period is the period for which the save version in the directory file is to be protected against deletion using the PURGE statement. During the retention period the volume may not be overwritten, and consequently the data it contains may not be deleted. The retention period is defined in the SAVE or EXPORT statement using the RETPD operand.
The expiration date is reached when the retention period has elapsed, in other words
Expiration date = Creation date + Retention period (in days).
The expiration date is noted on the volume concerned, in the directory file and possibly in the MAREN catalog. In MAREN not only the retention period of the volume is noted, but also the name of the directory file. When the retention period has expired, the save is regarded as “obsolete” and can be deleted using the PURGE statement. When deletion takes place, MAREN is automatically informed and deletes the name of the directory file in the MAREN entry for the volume.
If, during an incremental save (SAVE statement with CHANGED=YES), it is detected that a files has not changed since it was last saved, it is entered in the directory file as Cataloged-Not-Saved (CNS). If the expiration date of the last save which this file contains is older than the expiration date of the current incremental save, the retention period of the last save is updated. The last save is thus assigned the same expiration date as the current incremental save; there is no danger that the file (of the save type FULL) saved earlier will be released before the incremental save (save type CNS).
When the retention period is automatically incremented as described, the expiration date is also incremented in the MAREN entry for the volume. The retention period cannot be updated on the volume itself. If MAREN is not being used, other applications can overwrite the tape.
The retention period is, however, not automatically incremented if the last backup of the file is too far in the past (i.e. more than a third of the retention period specified in the current save run, but at least 7 days). In this case the file concerned undergoes a full save (save type FULL) despite the incremental save with CHANGED=YES. This ensures continuous release of save versions and tapes up to the expiration date while guaranteeing reliable restorability.