cancel
Showing results for 
Search instead for 
Did you mean: 

Job logging scripting

AntonioVargas
Level 4

Hi to all,

as most of you know, the backup info sent by mail to clients in Netbackup includes several mails by backup. It sends one mail when the backup starts, one by job (one job by backup selection) and another when the backup finishes. For example, one backup can generate 10 jobs and one mail by job will be sent. My objective is to try to avoid this, creating a script in awk (my master/media server is solaris) that agregates all the info in one backup in only one e-mail. Have anyone tried this before? is there a workaround or the scripting solution is the best?

 

thanks in advance

3 REPLIES 3

Omar_Villa
Level 6
Employee

you can create a script with a: bperror -problems -U -backstat -by_statcode -hoursago 24 and send the output to an email, in my opinion this is the fastest way to see which clients fail and with what kind of error, because you can tell if there is an external issue that is impacting your backups has if you have a lot of 219's it can be an STU issue or many 41's can be a problem with a switch who went down, is very functional give a try.

 

 

regards

AntonioVargas
Level 4

Hi Omar,

it's seems to be a good idea but the question here is that i want to separate the error notifications in order to send not to my mail but to each client mail, depending on the client host that fails. If host A fails a mail should be sent to host A administrator, and so on... a script with bperror command will get all errors regardless of the client that returns the error, right?

Omar_Villa
Level 6
Employee
then you will need to use bp_exit_notify, the bad part here that will go to everyone on the list, so you in order to split this you will need to create a file with the hosts names and contacts per host, then run build the script from here and for every error you get you can send this to a local file with bp_exit_notify and then call the script who grabs the corresponding data and send the email, but directly without tweaking NBU scripts there is no such an option.