cancel
Showing results for 
Search instead for 
Did you mean: 

Email Notification

Cullen_Schar
Level 3
I had Netbackup 5.1 running on Solaris 8, but have recently upgraded to Netbackup 6.0 MP3 running on Solaris 10. When I was using 5.1, I received email notifications every time a catalog or data backup finished. With 6.0, I receive email notification when the catalog backup finishes but not when data backups finish. Has the way the email notifications work changed with 6.0? Is there any way to get the notifications when data backups finish?

Thanks
13 REPLIES 13

Cullen_Schar
Level 3
Let me clarify. I do receive emails for data backups that were initiated by a policy that uses a schedule, but not for backups that were initiated by UNIX cron.

zippy
Level 6
Cullen,

What are the lines in cron? Veritas changed dramatically from 5.1 to 6.x, the systax for your Cron backups needs to be modified.

JD

Dennis_Strom
Level 6
I agree. Can you post up your cron job?

How to configure and backup NetBackup catalogs from command line.
http://support.veritas.com/docs/239811Message was edited by:
Dennis Strom

zippy
Level 6
Dennis,

This is going down the "pointless tunnel" its dark in here.

JD

Dennis_Strom
Level 6
I agree and was actually excited to have a unix problem to look at. Scripting can be fun.

Cullen_Schar
Level 3
The cron job calls a UNIX script that performs backups of databases using SQL BackTrack. The backups are working and the script has not changed. But with Netbackup 5.1, each time a backup finished for one of the databases in the script I received an email from the Netbackup server stating that the backup completed successfully. After upgrading to Netbackup 6.0, I do not receive the email notifications. I do receive email notifications though for backups that were initiated using a schedule in a Netbackup policy.

Is there a way to get email notifications for every successful backup?

Let me know if you still want to see the UNIX script, but the UNIX script does not use any Netbackup commands.

Dennis_Strom
Level 6
Sure post the script.

One other question. Using the Admin Console under Netbackup Management -> Host Properties -> Clients -> Properties in the Universal Settings is your email address in the Admin Email address box?

Cullen_Schar
Level 3
Yes, my email address is in the Admin Email address box.

Here is the UNIX script to backup the databases.

#!/bin/ksh
####Script to backup databases to ADIC using SQL BackTrack####

####Setup Environment Variables####
server=TESTSRV1
export SYBHOME=/home/sybase
export SYBASE=/sybase/1253
export SYBASE_OCS=OCS-12_5
export SYBASE_ASE=ASE-12_5
export SYBINS="$SYBASE/ASE-12_5/install"
export SYBIN=$SYBASE/OCS-12_5/bin

####Setup SQL-BACKTRACK Environment Variables####
export DTBASE=/bmc/datatools57
export DT_SBACKTRACK_HOME=$DTBASE/sbacktrack_64bit-5.7.00.0
export DT_SBACKTRACK_PATH=$DTBASE/NB$server/$server

dbamail=schar

logdir=$SYBHOME/logs/backups/db

today=`date +%Y%m%d_%H:%M:%S`

dblist="testdb1 testdb2 testdb3"

####Starting Backup Database####
for db in $dblist
do
logfile=$logdir/Backup_"$db"_$today.log
print "Start Dump at `date`\n" > $logfile
$DT_SBACKTRACK_HOME/bin/dtsbackup $DT_SBACKTRACK_PATH/$db -no_prompt -tasks 3 -no_incremental >> $logfile

retcode=`cat $logfile|grep "highest return code was 0" |wc -l`
if
then
mailx -s "CRITICAL ERROR : Database Backup Problem : Database : $db" $dbamail < $logfile > /dev/
null 2>&1
fi
done

Dennis_Strom
Level 6
does mailx work from the command line on the client?
does $SYBHOME/logs/backups/db/Backup_"$db"_$today.log exist on the client?

Cullen_Schar
Level 3
Yes, mailx works and the log file exists.

My question isn't with the mail being generated from the script, but with the email notification that is sent by the Netbackup server after a backup completes.

Dennis_Strom
Level 6
Yeah, the script looks good. It must be some issue where Netbackup6.0 does not send out messages for jobs started from cron but does for jobs started through a schedule. I apologize for not being able to help. The only critique I have for the script is the path is not defined for the print command so it is possible that print will not be found but I think you mentioned that you replaced that with echo so that is cool. Dunno I am stumped.

Cullen_Schar
Level 3
Thanks Dennis for looking into it!

zippy
Level 6
Cullen,

Try to give points to the folks that help, in this case Dennis.

Cool.

JD