ADSM-L

Re: Calculating MaxScratch vs Allocate Volume

2005-04-22 12:24:36
Subject: Re: Calculating MaxScratch vs Allocate Volume
From: Christopher Zahorak <chris AT UWINDSOR DOT CA>
To: ADSM-L AT VM.MARIST DOT EDU
Date: Fri, 22 Apr 2005 12:23:02 -0400
I use the mtlib command to display the tapevolumes currently in the
library and then "grep" out the entries that have the "scratch" number of
101 and then finally use the unix word count command -> "wc -l" to perform
the count for me.

mtlib -l /dev/lmcp0 -qI | grep 101 | wc -l


see the mtlib help files for clarification on above.

Chris.



Christopher S. Zahorak, BCS
Sr. AIX and Tivoli Administrator

University of Windsor
IT Services, Rm 203
401 Sunset Avenue
Windsor, Ontario
N9B 3P4
P: (519)253-3000 ext. 2762
F: (519)973-7083
email: chris AT uwindsor DOT ca




"Hart, Charles" <charles.hart AT MEDTRONIC DOT COM>
Sent by: "ADSM: Dist Stor Manager" <ADSM-L AT VM.MARIST DOT EDU>
22/04/2005 11:57 AM
Please respond to
"ADSM: Dist Stor Manager" <ADSM-L AT VM.MARIST DOT EDU>


To
ADSM-L AT VM.MARIST DOT EDU
cc

Subject
Calculating MaxScratch vs Allocate Volume






When I run the following slect

SELECT STGPOOLS.STGPOOL_NAME, STGPOOLS.MAXSCRATCH,
Count(STGPOOLS.MAXSCRATCH) as "Allocated_SCRATCH" FROM STGPOOLS
STGPOOLS, VOLUMES VOLUMES WHERE VOLUMES.STGPOOL_NAME =
STGPOOLS.STGPOOL_NAME AND ((STGPOOLS.DEVCLASS='3592TAPE')) GROUP BY
STGPOOLS.STGPOOL_NAME, STGPOOLS.MAXSCRATCH

I get the following out put

Server STGPOOL_NAME MAXSCRATCH
Allocated_SCRATCH
 MSPSTG3 TAPE_APP_BACKUP                                  20   58
 MSPSTG3 TAPE_ARCHIVE                                            40    30
 MSPSTG3 TAPE_ARCHIVE_COPY                               80    39
 MSPSTG3 TAPE_BACKUP_COPY                                250  193
 MSPSTG3 TAPE_DB_BACKUP                                  18    18



My question is how do I subtract "Allocated_SCRATCH Col from the
MaxScratch Col so I can see what the Acutal Scratch Remaining is.  The
plan is to have this be out put to a txt file that can be picked up by
our monitoring system so we can auto genertae a help desk ticket.  I
have searched around (here and the web) and can't seem to find a good
example.

Any insight would be great!!!!!!