Available Media In Scratch Pool - Veritas Net Backup

This is a discussion on Available Media In Scratch Pool - Veritas Net Backup ; Hi, I would like to check the number of cartridges available in my scratch pool for all my my tape libraries through UNIX command line. Please assist. Regards....

+ Reply to Thread
Results 1 to 5 of 5

Thread: Available Media In Scratch Pool

  1. Available Media In Scratch Pool


    Hi,

    I would like to check the number of cartridges available in my scratch pool
    for all my my tape libraries through UNIX command line.

    Please assist.

    Regards.

  2. Re: Available Media In Scratch Pool

    Have you tried the available_media script in the goodies folder?

    JR

    On 3 Aug 2005 07:52:27 -0500, "Kamarulzaman Ali"
    wrote:

    >
    >Hi,
    >
    >I would like to check the number of cartridges available in my scratch pool
    >for all my my tape libraries through UNIX command line.
    >
    >Please assist.
    >
    >Regards.



  3. Re: Available Media In Scratch Pool


    The given command is work.

    TQ JR for your assistant.


    Jeff Redington wrote:
    >Have you tried the available_media script in the goodies folder?
    >
    >JR
    >
    >On 3 Aug 2005 07:52:27 -0500, "Kamarulzaman Ali"
    > wrote:
    >
    >>
    >>Hi,
    >>
    >>I would like to check the number of cartridges available in my scratch

    pool
    >>for all my my tape libraries through UNIX command line.
    >>
    >>Please assist.
    >>
    >>Regards.

    >



  4. Re: Available Media In Scratch Pool

    Kamarulzaman Ali wrote, in part, on 8/3/2005 8:52 AM:
    > I would like to check the number of cartridges available in my scratch pool
    > for all my my tape libraries through UNIX command line.


    I suspect you can easily adapt the following little program that prints
    the number of tapes in each pool ...

    #!/bin/bash
    # This is a subset of the tapeusage program
    # from Mark Donaldson - veritas-bu - 2003-08 wts@maine.edu
    # uses vmquery from NBU
    #

    # set -x

    PROGNAME=`basename $0`
    TMP2=/var/tmp/$PROGNAME.tmp2.$$
    VMQUERY=/opt/openv/volmgr/bin/vmquery


    #Create list of tapes & pools
    $VMQUERY -w -a | awk 'NR>3 && $12!="None" {print $1"\t"$12}' >$TMP2

    for pool in `awk '{print $2}' $TMP2 | sort -u`
    do
    count=`awk 'BEGIN {sum=0} {if ($2=="'$pool'") {sum++}} END {print
    sum}' $TMP2`
    echo "${pool}:${count}"
    done

    rm -f $TMP2

    exit

  5. Re: Available Media In Scratch Pool


    "Kamarulzaman Ali" wrote:
    >
    >Hi,
    >
    >I would like to check the number of cartridges available in my scratch pool
    >for all my my tape libraries through UNIX command line.
    >
    >Please assist.
    >
    >Regards.



    easiest way is to use Veritas's available_media script. I've built quite
    a few NetBackup scripts around available_media for the last 5years, most
    of which are pretty much unchanged since the days if NetBackup 3.1.1..

    In my case i use an L60 tape robot with LTO1 tapes, so i can use -

    available_media | grep AVAILABLE

    - however that will list ALL scratch tapes, whether they're in a robot or
    offsite or wherever, so i run this automatically in 2 different scripts -


    available_media | grep AVAILABLE | grep TLD

    that's for tapes within a robot

    and

    available_media | grep AVAILABLE | grep NONE

    that's for tapes anywhere else...

    hope that helps a little..
    if you do a search you will find umpteen scripts that can do stuff like this
    and search for FULL tapes etc etc (i've submitted a fair few scripts myself)

+ Reply to Thread