Output of all MAREN catalog entries for a tape file
From the MAREN catalog all volumes under the user's own ID (USER-ID=*OWN is the default value) to which the file SAMPLE.TAPESET.1 has been written or for which at least this file name is contained in the MAREN catalog entry are to be output:
//show-volume-attributes volume=*all,user-id=*all,file-name=sample.tapeset.1(version=*all,type-of-vol=*any) |
Five versions of the SAMPLE.TAPESET.1 tape file exist on the following tapes (yyyy=year):
- version 0 (*LATEST) on SAV009;
- version -1 on SAV006, SAV010, SAV007 and SAV008 (multivolume file);
- version -2 on SAV003, SAV004 and SAV005 (multivolume file);
- version -3 on SAV002;
- version -4 on SAV001.
Output of all MAREN catalog entries for a file version
All the tapes (TYPE-OF-VOL=*ANY) under the user's own user ID are to be output for the last version but one (VERSION=-1) of the SAMPLE.TAPESET.1 file:
//show-volume-attributes volume=*all,user-id=*all,file-name=sample.tape.set.1(version=-1,type-of-vol=*any) |
In the case of this file version, the first tape, for which VOLUME-SEQUENCE=1 (column VSEQ), is duplicated (archive number SAV006 and SAV010). On the basis of the creation date (CREATION-DATE and CREATION-TIME) it is possible to establish that the tape with the archive number SAV006 comes from an aborted job, whereas the tape with the archive number SAV010 with the later creation date was written in a restart.
Export of all current tapes for a file version
The tapes (TYPE-OF-VOLUMES=*VALID) required for the further processing of the last version but one (VERSION=-1) of the SAMPLE.TAPESET.1 file are to be exported and made available to be picked up at a location described as MAILBOX 4411
:
//export-volume volume=*by-file(file-name=tape.file,version=-1,type-of-volume=*valid),export-address='mailbox 4411' |
Output of tapes that are no longer required for a file version
Tapes that are no longer required are to be output for the last version but one (VERSION=-1) of the SAMPLE.TAPESET.1 file. These were written when the file was created but are no longer required in further processing (TYPE-OF-VOLUMES= *OBSOLETE) because they have been replaced by other tapes in a restart.
//show-volume-attributes volume=*all,user-id=*all,file-name=sample.tape.set.1(version=-1,type-of-vol=*obsolete) |
Release of tapes that are no longer required for a file version
Since the tapes written for the last version but one (VERSION=-1) of the SAMPLE.TAPESET.1 file but replaced in a restart are no longer required, they are to be released prematurely. For this purpose, the release date (FREE-DATE) and, where applicable, the file expiration date (EXPIRATION-DATE) are set to the current date:
//modify-tape-set-attributes select=*by-attr(f-name=sample.tapeset.1,version=*all,type-of-vol=*obs),prot=*par(free-date=0,expir-date=0) |