Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

script for tape drive monitoring 2

Status
Not open for further replies.

thepallace

Technical User
Jun 8, 2004
48
US
Hello,

Is anyone has a script to monitor the tape drive status when it goes offline and send a real time alert.

Thanks in Advance,
JAQ
 
Nothing incredibly clever, but it works a treat - we have 6 drives, so if any of the 6 are in a state other than normal (TLD) then send a mail. I've got this running in cron every 10mins

#! /bin/ksh
#

if [ `/usr/openv/volmgr/bin/vmoprcmd|grep hcart|grep " TLD"|grep -c " TLD"` -lt 6 ] ; then /usr/openv/volmgr/bin/vmoprcmd|grep -v PEND|grep -v "<"|grep -v STATUS|grep -v Drive|grep -v " TLD" |/usr/ucb/mail -s "There are DOWN or unavailable
NetBackup tape drives @`date +%d/%m-%H:%M`" emailaddy@somewhere.co.uk

else
echo

fi


p.s. i use a very similar script to monitor for pending restore requests, ie when a required tape is not in the robot, it will sit waiting for eons, so every 10mins i check for pending requests & then send an email

Oh and just thought of another - have a similiar script that checks for busy drives, ie if all 6 are in use it sends a mail; helps to idenfity bottlenecks, though this doesn't shout much due to lots of multiplexing

Rich
 
If you are running Solaris or any other flavor of Unix, I have a script that monitors the drives on all media servers. It is started at system boot up and awakens itself every 15 minutes if no previous errors were found or every 5 minutes if any drives had failed. It will also send an e-mail notifying you of the error condition.

I will be posting it shortly on my website .
 
Hi bswip, Can you you post your script. I have 6 solaris media server on our environment.

Thanks Again,
JAQ
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top