Basic script to follow when retrieving files from a tape
Find & Load Volume With MDMS:
$ PIPE MDMS SHOW VOLUME /FULL > TAPES.TXT
$ MDMS INVEOTRY JUKEBOX MSL_SITEB_LTO7 !force the tape drive to do an inventory check
$ MDMS SHOW VOLUME !show all of the tapes
$ MDMS SHOW VOLUME QXXXXX !show information of the desired tape
$ MDMS SHOW DRIVE !show the drives available
$ MDMS LOAD VOLUME QXXXXX /DRIVE=MGAXX !set the tape as a drive, pick correct location
Find & Load Tape Without MDMS:
$ ALLOCATE MKBXXX: !allocates the tape to the system
From this point $2$MGAXX is the same as MKBXXX
$ SHOW DEVICE $2$MGAXX: !show the device
$ MOUNT $2$MGAXX: /OVER=ID !mount the device with existing header
$ DIR /DATE $2$MGAXX:[000000] !check the contents of the tape and date written
The .BCK files are the names of the disks eg PRDCOMMON is DSA1:
$ DISMOUNT $2$MGAXX: /NOUNLOAD !dismount the tape without unloading
$ MOUNT $2$MGAXX: /FOREIGN !mount the tape so it can be copied
$ TYPE CLUS$STARTUP:ENCRYPT_KEYS.COM !show the encryption details (optional)
$ SET MAG $2$MGAXX: /rewind !rewind the tape
$ BACKUP /LIST $2$MGAXX:[000000]<saveset>.BCK /SAVESET !list the desired area
$ DIR /SIZE !check the desired area's size
$ HOME !make sure the directory is the desired copy location
$ CREATE /DIRECTORY [.XXXXXXXXXXX] !make a directory in the desired location
$ SET DEF [.XXXXXXXXXXX] !change directory to new directory
$ DIR !make sure directory is empty
$ SET MAG $2$MGAXX: /REWIND !rewind the tape
$ BACKUP $2$MGAXX:[000000]<saveset>.BCK /SAVESET - !select the desired saveset on tape
-$ /SELECT=[<directory>]*.*;* - !select the desired folder or files on tape
-$ <location>:[<directory>]*.*;* - !select the target location for restoration
-$ /ENCRYPT=(NAME=<encryption name>,ALGORITHM=<algorithm>) !add the encryption (optional)
$ DIR /SIZE /DATE !check that the files have been copied
$ SET MAG $2$MGAXX: /REWIND !rewind the tape
$ DISMOUNT $2$MGAXX /NOUNLOAD !dismount the tape
$ MDMS UNLOAD DRIVE MGAXX !unload the tape
$ MDMS SHOW DRIVE !check that the tape is not loaded
$ MDMS SET VOLUME QXXXXX /AVAILABLE !mark the tape avilable
$ MDMS SET VOLUME XXXXXX /UNAVAILABLE !mark the tape unavailable
$ MDMS SHOW VOLUME QXXXXX !check that the tape is available