How to delete tapes from the DLm
Summary: DLm users may require working with temporary volumes or for other reasons require deleting tapes from the DLm. This can be achieved with a special run of DLMSCR.
Instructions
Delete tapes from the DLm using mainframe Job Control Language (JCL).
The TYPE=RMMDV is a DLm-specific parameter that functions regardless of the tape management system used on the mainframe.
Example to delete a single tape, 010077. In this example, 010077 is an 'active' tape:
//JOBCARD .
//SCR EXEC PGM=DLMSCR,
// PARM='DEV=2E20,TYPE=RMMDV,NODSNCHK'
//STEPLIB DD DISP=SHR,DSN=your.apf.auth.LOADLIB <-- apf authorized load library where DLMSCR resides.
//*DLMSCR DD DSN=your.dlm.input.SCRATCH,DISP=SHR <-- command input data set, but it s commented out.
//DLMSCR DD * <-- this dd * says use in stream input.
RMM DV 010077 FORCE
RMM DV 010077 FREE
RMM DV 010077 DELETE
//DLMLOG DD SYSOUT=*
The FORCE and FREE commands take some time to run, particularly the FREE. This is similar to the Virtual Tape Engine (VTE) space reclamation process.
Deleting an active DLm tape requires the FORCE and FREE commands before deleting.
Deleting a scratch DLm tape requires the FREE command if the tape has not been erased.
If volumes are deleted from the DLm and not being replaced, they should also be removed from the mainframe tape management system.
If deleted volumes are replaced (reinitialized) in the DLm, the mainframe tape management system may still need adjustments: either set the tape to scratch or delete and redefine it.
This special run of DLMSCR can use the other parm values such as IGNLCSRC, NODSNCHK, and so forth.