You can try parent_end_notify. –
only runs on the master (easier to maintain)
# This script:
#
receives 5 parameters:
#
CLIENT - the client
hostname
#
POLICY - the policy
label
#
SCHEDULE - the schedule label
#
SCHEDULE_TYPE - the type of schedule: FULL INCR UBAK
UARC
#
STATUS - the backup
status for this job
#
STREAM - the backup
stream number for this job always -1
#
must be executable by the root user
# should
exit with 0 upon successful completion
You just
have to put in If statements for each think you want to monitor
My example
Runs when
the Parent of the Hot Catalog backup finishes
if [ $2 =
"Hot_Catalog_Backup" ]
then
OUTF=/usr/openv/netbackup/bin/PARENT_END_CALLED.Hot_Catalog_Backup
if [ -s $OUTF ]
then
/bin/rm -rf $OUTF
fi
if [ ! -f $OUTF ]
then
touch $OUTF
fi
echo ${dateStr}
"-----------------------------" >> $OUTF
echo ${dateStr}
" CLIENT: $1" >>
$OUTF
echo ${dateStr}
" POLICY: $2" >>
$OUTF
echo ${dateStr}
" SCHEDULE: $3" >> $OUTF
echo ${dateStr}
"SCHEDULE TYPE: $4" >> $OUTF
echo ${dateStr}
" STATUS: $5" >>
$OUTF
echo ${dateStr}
" STREAM: $6" >>
$OUTF
echo ${dateStr}
"-----------------------------" >> $OUTF
/usr/sbin/rdist -f
/usr/sysadmin/scripts/Data/Rdist_Dist_Netbackup_PROD >> $OUTF
cat $OUTF | mail -s
"Netbackup parent end notify for Catalog" someonewhocares AT mycompany DOT com
fi
From:
veritas-bu-bounces AT mailman.eng.auburn DOT edu
[mailto:veritas-bu-bounces AT mailman.eng.auburn DOT edu] On Behalf Of Scott
Jacobson
Sent: Wednesday, November 11, 2009 9:25 AM
To: nbu
Subject: [Veritas-bu] Notify batch file - End of Job
Env: 6.5 Master
(Windows)
I've looked again in
goodies and admincmd for a script or batch file that can monitor by policy (or
by server name) a backup's completion and then send an e-mail to notify a
non-administrative user.
Anyone have
something they've created and are willing to share that would do this?