Veritas-bu

[Veritas-bu] Re: Listing tapes in a media server's media catalog

2004-08-10 09:35:24
Subject: [Veritas-bu] Re: Listing tapes in a media server's media catalog
From: jack.l.forester AT lmco DOT com (Jack Forester, Jr.)
Date: Tue, 10 Aug 2004 09:35:24 -0400
Ok, I hate responding to my own emails, but I think I have an idea:

Using vmquery, identify all tapes with an assigned date.
For each of those tapes, do this:

to get the media server that owns the tape, do:
bpimmedia -mediaid $VOLSER | grep IMAGE | awk '{print $2} | uniq

to suspend the tape, do:
bpmedia -suspend -ev $VOLSER -h $HOST

I left out some details (like how $VOLSER and $HOST get assigned), but 
does this sound like it will do what I want?

Jack Forester, Jr. wrote:

> We are going to be replacing our 9940A tape drives with 9940B tape 
> drives, and I will want to suspend all of the tapes that are currently 
> assigned to the media servers.  This is to prevent NBU from attempting 
> to use a tape written by the older drives in the new drives when doing a 
> backup.  The "B" drives can read tapes written by the "A" drives but 
> cannot append to them (as would be the case when doing a backup on a 
> partially used tape).
> 
> My experience shows that if a partially used "A" tape is used in a "B" 
> drive for a backup, NBU will find the tape "read only" and spit it out 
> and try another tape.  I want to avoid this tape search by suspending 
> all of our currently assigned tapes until the backups on those tapes 
> expire naturally.
> 
> How do I find a list of assigned tapes and the media servers they are 
> assigned to?  I'd like to write a single script that I run on the master 
> server to do all the tapes if possible.  I know I can use vmquery to 
> find out if a tape is assigned, but how, then, do you determine which 
> media server owns the tape so I can give bpexpdate all the information 
> it needs to suspend the tape?


-- 
Jack L. Forester, Jr.
UNIX Systems Administrator, Stf
Lockheed Martin Information Technology
(304) 625-3946

<Prev in Thread] Current Thread [Next in Thread>