Veritas-bu

Re: [Veritas-bu] Tape drive monitoring?

2009-09-15 08:46:29
Subject: Re: [Veritas-bu] Tape drive monitoring?
From: "Jeff Lightner" <jlightner AT water DOT com>
To: "Carlos Alberto Lima dos Santos" <carlos_listas AT yahoo.com DOT br>, <VERITAS-BU AT MAILMAN.ENG.AUBURN DOT EDU>
Date: Tue, 15 Sep 2009 08:42:58 -0400
We've used this little perl script for years and run it from NRPE plugin for 
our Nagios monitoring system.   It doesn't require NPRE/Nagios though.

#!/usr/bin/perl
#
######################################################################################################
# 122002jda
# This script checks the current state of the L700 tape drives
######################################################################################################

# ----------------------------------------Variable 
initialization----------------------------------- #
$STATE_OK = 0;
$STATE_WARNING = 1;
$STATE_CRITICAL = 2;
$STATE_UNKNOWN = 3;

$ENV{'PATH'}="";
$ENV{'ENV'}="";
$ENV{'BASH_ENV'}="";
# ----------------------------------------Execute the system 
cmds----------------------------------- #
$OUT = "/tmp/$$vmoprcmd$$.out";
$list = qx(/usr/openv/volmgr/bin/tpconfig -dl > $OUT);

open(LST,$OUT) || die "Couldn't open $OUT.\n";
  while(<LST>) {
       @format = split(/\s+/,$_);
        if ($format[2] eq "Name") {
                $DriveName = $format[3];
        }
        if ($format[1] eq "Index") {
                $DriveIndex = $format[2];
        }
        if ($format[2] eq "DOWN") {
                print "Drivename: $DriveName DriveIndex: $DriveIndex Is DOWN\n";
                $clean = qx(/usr/bin/rm $OUT);
                exit $STATE_CRITICAL;
        }
   }
close LST;
$clean = qx(/usr/bin/rm $OUT);
print "Drive Status OK\n";
exit $STATE_OK;

-----Original Message-----
From: veritas-bu-bounces AT mailman.eng.auburn DOT edu 
[mailto:veritas-bu-bounces AT mailman.eng.auburn DOT edu] On Behalf Of Carlos 
Alberto Lima dos Santos
Sent: Monday, September 14, 2009 9:24 PM
To: VERITAS-BU AT MAILMAN.ENG.AUBURN DOT EDU
Subject: Re: [Veritas-bu] Tape drive monitoring?


     look the command vmoprcmd on NetBackup command guide.


====================================
Carlos Alberto L. dos Santos (TOCA)
Eng. de Computação - Puc-Campinas(SP) - Brasil
carlos_listas AT yahoo.com DOT br
------------------------------------------------


--- Em seg, 14/9/09, Gravizi, Thomas <Thomas_Gravizi AT steris DOT com> 
escreveu:

> De: Gravizi, Thomas <Thomas_Gravizi AT steris DOT com>
> Assunto: [Veritas-bu] Tape drive monitoring?
> Para: "VERITAS-BU AT MAILMAN.ENG.AUBURN DOT EDU" <VERITAS-BU AT 
> MAILMAN.ENG.AUBURN DOT EDU>
> Data: Segunda-feira, 14 de Setembro de 2009, 17:22
> 
> 
> 
>  
>  
> 
> 
> 
> 
> 
> 
>  
> 
> 
> 
> Greetings all, 
> 
>    
> 
> We are currently running NBU 6.5.3 on Solaris
> 10, and experienced
> an issue where all of our tape drives on our StorageTek
> L700 went into AVR mode
> this past weekend.  Can someone give me some insight on
> how I can monitor the
> tape drives to notify me when this happens again?  Are
> there scripts out there
> which I can use, or something in NBU which I can
> enable? 
> 
>    
> 
> Thanks, 
> 
>    
> 
> Thomas Gravizi 
> 
> UNIX Systems Administrator 
> 
> Enterprise Operations 
> 
> STERIS Corporation - Mentor, OH 
> 
> thomas_gravizi AT steris DOT com
> 
> 
> 440.392.7630 - phone 
> 
> 440.350.7078 - fax 
> 
>   
> 
> 
> 
>  
> 
> 
> 
> -----Anexo incorporado-----
> 
> _______________________________________________
> Veritas-bu maillist  -  Veritas-bu AT mailman.eng.auburn DOT edu
> http://mailman.eng.auburn.edu/mailman/listinfo/veritas-bu
> 


      
____________________________________________________________________________________
Veja quais são os assuntos do momento no Yahoo! +Buscados
http://br.maisbuscados.yahoo.com
_______________________________________________
Veritas-bu maillist  -  Veritas-bu AT mailman.eng.auburn DOT edu
http://mailman.eng.auburn.edu/mailman/listinfo/veritas-bu
 
Please consider our environment before printing this e-mail or attachments.
----------------------------------
CONFIDENTIALITY NOTICE: This e-mail may contain privileged or confidential 
information and is for the sole use of the intended recipient(s). If you are 
not the intended recipient, any disclosure, copying, distribution, or use of 
the contents of this information is prohibited and may be unlawful. If you have 
received this electronic transmission in error, please reply immediately to the 
sender that you have received the message in error, and delete it. Thank you.
----------------------------------
_______________________________________________
Veritas-bu maillist  -  Veritas-bu AT mailman.eng.auburn DOT edu
http://mailman.eng.auburn.edu/mailman/listinfo/veritas-bu