How to monitor and manage tape volumes in IBM Tivoli Storage Manager

I have seen many new IBM TSM administrators get confused about how Tivoli Storage Manager manages or tracks client data on removable media after tapes have been gone through different admin process (Reclamation & migration etc.), and the importance of checking in tape volumes with the SCRATCH status . This post is intended for newbies in Tivoli Storage Manager and if you are a PRO in TSM you might feel bored, so I recommend you to find other TSM links on this blog.

In Tivoli Storage Manager, you can control how removable media (ex: tapes) are used and reused. After Tivoli Storage Manager selects an available tape medium, that medium is used and eventually reclaimed according to the policy settings. Tivoli Storage Manager manages the data on the tape volumes, but it is the administrators job to manage the tape volumes. Managing tape volumes involves 
  • Creating a policy to expire data after a certain period of time 
  • Moving valid data onto new media
  • Reusing the empty media.

The volume history file (volhist.out) which is located in server/bin folder by default contains information about all the tape volumes used for client backups/archives, used for TSM database backups and exports for disaster recovery purposes. The process for reusing TSM DB backup & export tape volumes is slightly different from the process for reusing tapes containing client data backups.

Life cycle of removable media in IBM Tivoli Storage Manager

1) Initially, you label and check in the media using TSM LABEL and CHECKIN commands. Checking media into a manual library simply means storing them on some safe location. Checking media into an automated library involves adding them to the library volume inventory. For example, TSM commands to LABEL and CHECKIN LTO4 tapes into SCSI type library is shown below. You can label and checkin tape volumes as scratch/private by using single command.

label libvol <libraryname> search=bulk labelsource=barcode checkin=scratch waittime=0

The above command is used assuming all the tape volumes have barcode and are inserted into the I/O door slots of the library. If the tapes are already inside the library and needs relabeling, change parameter SEARCH=YES without WAITTIME=0 parameter.

2) If you plan to define specific tape volumes to a particular storage pool, then you should check in the tape volume with its STATUS=PRIVATE. Use of scratch volumes is more convenient in most cases. Remember, tapes which are checked in as private will not change to scratch automatically even there is no valid data in it. 

3) When a TSM client requests a backup/archive, TSM server choose the tape volumes depending upon the clients
  • Policy Domain definitions
  • Default or specific Management class definitions
  • Device type of specific storage pool defined in MGMTclass
  • If maximum number of scratch volumes that a server can request from the storage pool has been reached when the scratch volumes are selected.
  • Whether collocation is enabled for that storage pool. When collocation is enabled, the server attempts to place data for different client nodes, groups of client nodes, or client file spaces on separate volumes.

4) As the days goes by, client data on tape volumes changes as a result of
  • Deletion of metadata on TSM database due to Expiration process which results in expiration of client files on tape volumes.
  • Moving or deleting of file spaces by an administrator.
  • Automatic or manual reclamation of tape volumes. When the volume is reclaimed, any valid, unexpired data is moved to other volumes or possibly to another storage pool.
  • If collocation is enabled, where Tivoli Storage Manager attempts to keep data belonging to a single client node, group of client nodes, or client file space on a minimal number of removable media in a storage pool.

At this point, you can still know the new tape volume which contains a particular node data by using QUERY NODEDATA command, TSM server tracks and stores all the movement of clients backup files during TSM server internal processess in its database.

5) Once the volume becomes empty because of all valid data either expires or is moved to another volume, the volume is available for reuse unless a time delay has been specified for the storage pool. This empty volume changes to scratch status automatically if it is initially checked in as SCRATCH. Now this volume will be picked up and reused again for next client backups or for TSM server internal process.

6) Overtime, the tape volume will get old and may not be useful for any backups or processes. To determine the tape volume life span or tape volumes end of life, check the statistics on the volumes by querying the database. The statistics include the number of write passes on a volume. compare with the number of write passes recommended by the manufacturer and the number of errors on the volume. 

You can only see this information for the tapes which are in use by TSM server, because TSM database will not have tape volume details of an empty tapes which are not currently in use. For example

tsm: SERVER1>q vol JK2100L4 f=d

   Volume Name: JK2100L4
             Storage Pool Name: TAPEPOOL
      Device Class Name: TAPE
    Estimated Capacity: 2.7 T
     Scaled Capacity Applied: 
                      Pct Util: 100.0
Volume Status: Full
 Access: Read/Write
        Pct. Reclaimable Space: 0.0
               Scratch Volume?: Yes
               In Error State?: No
      Number of Writable Sides: 1
       Number of Times Mounted: 2
             Write Pass Number: 1
     Approx. Date Last Written: 11/08/13   09:19:18
        Approx. Date Last Read: 11/07/13   16:58:39
           Date Became Pending: 
        Number of Write Errors: 0
         Number of Read Errors: 0
               Volume Location: 
Volume is MVS Lanfree Capable : No
Last Update by (administrator): 
         Last Update Date/Time: 11/07/13   16:57:52
          Begin Reclaim Period: 
            End Reclaim Period: 
  Drive Encryption Key Manager: None

For the above tape, Write Pass Number is only 1, compare this info with manufacturers recommendation to determine the removable media life span.

You must move any valid data off a volume that has reached end of life. Then, if the volume is in an automated library, check out the volume from the library. If the volume is not a scratch volume, delete the volume from the database.

Important Points

  • Tape volumes which are checked in as PRIVATE will not automatically change to SCRATCH status when they become empty. You have to use UPDATE LIBVOL command to change it.
  • Tape volumes which are defined to a particular storage pool with DEFINE VOLUME command will not also change to SCRATCH status when they become empty. You have to first delete volume by using DELETE VOLUME command and then use UPDATE LIBVOL command to change it to scratch.
  • For efficient tape utilization, best practice is to always checkin tape volumes as scratch unless it is 100% required. So that TSM server can pick them for any client backups or TSM server internal processes. 

1 Response to "How to monitor and manage tape volumes in IBM Tivoli Storage Manager"

  1. Hi. How i can to know wich onsite tape volumes are needed to reclaim an offsite tape volume?