Follow these steps to fix Tape read and write errors - video tutorial

Follow these steps to identify and fix faulty tapes.

List unavailable tapes
  q volume access=readonly  and q volume access=unavailable

This will give you list of tapes that have been put in this state, probably because the system has identified an error. However, a tape will be marked as unavailable if TSM tried to mount it and it is not in library. 

Look for tapes which have errors
  select volume_name, read_errors,write_errors from volumes
  where (read_errors > 0 or write_errors > 0) 

This will give a list of tapes that have reported read and write errors. If you have a lot of these, consider upping the thresholds so you can concentrate on tapes with a lot of errors first.

To fix a problem, run the audit command
  AUDIT VOLUME volser FIX=YES

If a part of a tape is faulty, the audit command will try to fix it. If cannot fix a problem file, and a copy exists on another tape, then you need to use the RESTORE VOLUME command. If there is no copy, then the AUDIT command just deletes the entry from the database.

Also Read: Monitoring and Managing Tape Volumes

If the tape is hopelessly trashed, and you do not have a copy, the only answer the 'delete volume discard=yes' command. However, its always worth trying a MOVE DATA command first to see if you can rescue something from the tape. 

What happens if a tape is accidentally overwritten by another application?

If you have a copy pool, you can restore the tape, otherwise you have to tell TSM to throw the data away.

To restore the volume, use the command
  restore volume volname preview=yes

and look at actlog after this process finishes. It will show you all the copytapes needed to recreate the primary tape. Get all these tapes back from your offsite copy group, and run the command again without the preview=yes. The old tape will be marked as destroyed and the data copied to a new tape. The old volume will then be deleted once all the data is restored.

Also Read: Restoring damaged Storagepool volumes

To discard the data use the command
    DELETE VOL volname DISCARDDATA=YES

 or if that fails

    AUDIT VOL volname FIX=YES

and the active data will be backed up again on the next run. Of course, if this is older backup versions, then they are gone forever. 

If a tape appears to be assigned to a remote server and the remote server knows nothing about it, you can delete it from the volume history, and so free the tape up for reuse. This particular use of the delete volhist command appears to be undocumented, but it works. 
delete volhist todate=today type=remote volume=volumename force=yes

Also Read: Limitations of using TSM Tape Drive Encryption

Find More Tape troubleshooting videos on Youtube channel


0 Comment to "Follow these steps to fix Tape read and write errors - video tutorial"

Post a Comment