Here's my masterserver backup_exit_notify.cmd for Netbackup 3.1.5 on NT4
(still haven't been allowed to upgrade yet!)
This sends an email to a different person for each machine backed-up - the
owner of each netbackup client is usually different.
It sends a email stating the name of the machine and the status code for
failure.
It sends a different email stating the name of the machine and the files
missed if status1.
If required emails can be sent on success (status0) as well, but this is
very boring.
I use 'blat' - freeware, command line smtp emailer.
The file is attached, but I've not seen attachments on this group before, so
here's some highlights taken from various parts of the file.
@if %1 == machine1.xxxxxxxxx.com set recipient=
personA AT xxxxxxxxx DOT com
@if "%5" == "0" goto EmailSuccess
@if "%5" == "1" goto EmailStatus1
@blat %OUTF% -t %recipient% -s "Netbackup Successful for %1" -q
@blat %OUTF% -t %recipient% -c Netbackup_Administrator AT xxxxxxxxx DOT com
-s
"Netbackup FAILED for %1 Status %5 " -q
@D:\veritas\netbackup\bin\admincmd\bperror -client %1 -hoursago 24 -problems
-U -columns 400 >> D:\bob\stats\problems\clients\%1.txt
@blat D:\bob\stats\problems\clients\%1.txt -t %recipient% -c
Netbackup_Administrator AT xxxxxxxx DOT com -s "Netbackup Missed some files on
%1"
-q
Bob
-----Original Message-----
From: Zufall, Ken [mailto:KZufall AT officemax DOT com]
Sent: 15 January 2001 18:36
To: 'mtole AT pwi DOT com'; veritas-bu AT mailman.eng.auburn DOT edu
Subject: RE: [Veritas-bu] email alerts
Create a bpend_notify script for each class (and schedule, if desired), and
put the following in:
if [[ $5 -gt 1 ]]; then
cat $OUTF|mailx mail_id
fi
We use mailx, you can use just about anything you like. Doesn't work for
user-directed backups, or for status 196. Haven't seen any other holes in
this yet.
Ken Zufall
Technical Analyst
Phone: 216.471.3613
Pager: 440.303.1656
Fax: 216.491.4051
"It's not the most intellectual job, but I do have to know all the letters."
Vanna White
-----Original Message-----
From: Matthew Tole [mailto:matt_tole AT yahoo DOT com]
Sent: Monday, January 15, 2001 1:25 PM
To: veritas-bu AT mailman.eng.auburn DOT edu
Subject: [Veritas-bu] email alerts
I have a customer running NBU 3.4, who would like to
setup paging or notification for an exit status of
anything other than 0 or 1 rather than the blanket
email notification. Has anyone setup something like
this before? Anyone have suggestions as to how I can
set it up without to much scripting?
Thanks in andvance
MT
=====
Matthew Tole
Systems Engineer
PWI Technologies
W(425)576-2153 CLR(425)445-6361
__________________________________________________
Do You Yahoo!?
Get email at your own domain with Yahoo! Mail.
http://personal.mail.yahoo.com/
_______________________________________________
Veritas-bu maillist - Veritas-bu AT mailman.eng.auburn DOT edu
http://mailman.eng.auburn.edu/mailman/listinfo/veritas-bu
_______________________________________________
Veritas-bu maillist - Veritas-bu AT mailman.eng.auburn DOT edu
http://mailman.eng.auburn.edu/mailman/listinfo/veritas-bu
This e-mail, its content and any files transmitted with it are intended solely
for the addressee(s) and are confidential and may be legally privileged.
Access by any other party is unauthorised without the express prior written
permission of the sender. If you have received this e-mail in error you may
not copy, disclose to any third party or use the contents, attachments or
information in any way. Please destroy it and contact the sender via the
Thomson Financial switchboard on (44) 207 369 7000 or via e-mail return.
Internet communications are not secure unless protected using strong
cryptography. This e-mail has been prepared using information believed by the
author to be reliable and accurate, but Thomson Financial does not accept
responsibility for the timeliness, accuracy or completeness of the information
provided or for any changes to this e-mail, howsoever made, after it was sent.
[The content of this e-mail and files transmitted with it is (c) TFSL - 2000]
begin 600 backup_exit_notify.cmd
M0%)%30T*0%)%32`C(R,C(R,C(R,C(R,C(R,C(R,C(R,C(R,C(R,C(R,C(R,C
M(R,C(R,C(R,C(R,C(R,C(R,C(R,C(R,C(R,C(R,C(R,C(R,C(R,C(R,C(R,C
M#0I`4D5-(",C(R,C(R,C(R`@("!!;6UE;F1E9"!B>2!"3T(@3$%74D5.0T4@
M("!J=6UP0&=L;V)A;&YE="YC;RYU:R`@("`C(R,C(R,C(R,C(R,C(R,-"D!2
M14T@(R,C(R,C(R,C(R,C(R,C(R,C(R,C(R,C(R,C(R,C(R,C(R,C(R,C(R,C
M(R,C(R,C(R,C(R,C(R,C(R,C(R,C(R,C(R,C(R,C(R,C(R,C(PT*0%)%30T*
M0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