ADSM-L

Re: FW: checkin <vol> checklabel=barcode search=bulk

2004-02-04 15:34:32
Subject: Re: FW: checkin <vol> checklabel=barcode search=bulk
From: Jeffrey Renicker <renicker AT US.IBM DOT COM>
To: ADSM-L AT VM.MARIST DOT EDU
Date: Wed, 4 Feb 2004 15:33:59 -0500




The code I use to list the I/O station slots is:

/usr/bin/tapeutil -f /dev/smc0 inventory | grep -p Station | egrep
'Station|Volume' | awk '{
if($1 == "Import/Export") ioslot=$4;
if($1 == "Volume") {
      if(NF == 4) volser=$4;
      else volser="-open-";
      print ioslot, volser;
}}'

The tapeutil command to move a tape is:

/usr/bin/tapeutil -f /dev/smc0 move <fromslot> <toslot>

For example:  /usr/bin/tapeutil -f /dev/smc0 move 773 1037



You can get the slot numbers, and volsers in them, with the command:
/usr/bin/tapeutil -f /dev/smc0 inventory



To find an open slot just look for a slot with a blank "Volume Tag".

One little hitch, however.  If a tape is currently mounted, the "tapeutil
inventory" command will show a
slot as open ("Volume Tag" is blank), but TSM will have it reserved for the
mounted tape.  So what I did
in my script is to check the TSM device configuration file for each open
slot that I find and if that slot number
appears in it then I skip that slot and go on to the next one.


Jeff Renicker




                                                                       
             Ted Byrne                                                 
             <ted.byrne@ADELPH                                         
             IA.NET>                                                    To
             Sent by: "ADSM:           ADSM-L AT VM.MARIST DOT EDU            
             Dist Stor                                                  cc
             Manager"                                                  
             <[email protected]                                     Subject
             .EDU>                     Re: FW: checkin <vol>           
                                       checklabel=barcode search=bulk
                                                                       
             02/04/2004 01:01                                          
             PM                                                        
                                                                       
                                                                       
             Please respond to                                         
             "ADSM: Dist Stor                                          
                 Manager"                                              
                                                                       
                                                                       




><snip> Here's the logic of the script I wrote to "fix" to the
>problem:
>
>1. Use the tapeutil command to list the tapes in the I/O convenience
slots.
><snip>

Jeff,

Can you share the tapeutil command(s) you use to retrieve this information?

Thanks,

Ted

GIF image

GIF image

GIF image