Wrapper Script for NetBackup

From Spaldam's Wiki
Jump to navigationJump to search
World History Wiki is Brought to you by:
S.J.'s Adventures

A wrapper script can be used by any compatible scheduling software to run NetBackup jobs and allow information to be reported back to to the scheduler for the NOC/SOC to follow. This will allow your DataCenter Operations team or tier 1 support to do preliminary troubleshooting with some advanced idea of what the problem might be.

With the schedulier being integrated into the ticketing system, when backups fail they can produce tickets to track failures and actions taken to remedy the failures. The output provided by a wrapper script gives instructions on how the Operations staff can address these tickets.
It's also a good idea for unaddressed tickets to have automatic escalations based criticality of the backup job.

A wrapper script can live at:


With links to it from:


The script produces the output for the schedules output to the ticketing system when the backup fails.

Example output:

+ /xxxx/bin/controlm/nb.LOC#D_Policy_Name.Daily
NetBackup Job Started on masterserver at 11/20/10 00:16:03
 . . .
NetBackup Job Done at 11/20/10 01:01:04
Final Status: 71 - none of the files in the file list exist

NOC, this is a MEDIUM Priority issue,

	Please complete the following steps:

1.	Insure to include this entire output in the associated ticket.
2.	Change the ticket's priority to "MEDIUM".
3.	Assign the ticket to "XXXXXX" Group.
4.	Send out an e-mail within 60 minutes using the following information:
	TO:      "XXXXX"
	CC:      "XXXXX"
	SUBJECT: "[Paste job name here] - [Paste ticket number here]"
	BODY:     Copy and paste everything below this line into the body of the email:

 This job ran between 11/20/10 00:16:03 - 11/20/10 01:01:04.
   It received an overall Status of:
	Error Code 71 -  none of the files in the file list exist

 This is considered to be a MEDIUM priority issue.

 Please check "Troubleshooting Steps" and "Problems Report" links
   listed below for possible fixes. - Troubleshooting info follows:
   (For assistance you may contact "XXXXXX")

 Network communications do not appear to be an issue.


 Jobs that did not complete successfully:

  Status    Client            JobID   Time       Note
  ---- ---------------------- ------- ---------- ---------------------
  71    sql50bkup           110957  1290186064 none of the files in the file list exist
     Troubleshooting Steps: http://xxxxxxx/cgi-nb/CheckErrorCode.pl?code=71
     Problems Report: http://xxxxxx/cgi-nb/JobRpt.pl?job=110957&LOC=LOC


 If able to fix the problem(s) causing backup(s) to fail...
  Have the Operators re-run backups based on the following instructions:

 Please note:

  If ticket is more than one day old,
    the job has most likely already run again.
       Check for additional failures, or a successful re-run.
       (See http://xxxxxxx/cgi-nb/ClientBackups.pl for recent backups)
   If found, close the older ticket(s) and relate it to the newest ticket.
       Send newest ticket to Operators
           with appropriate instructions for re-running the backup.

	For a list of instructions you can give to the Operators, please see:

End of E-mail Body - End of Operator Steps

Full Script Log located in this file:
Script End: 11/20/10 01:01:57 - version: 3.8.3

Depending on the sophistication of your scheduling system, and the ticketing system, you may be able to automate much of the above steps.

A wrapper script can also creates detailed logging such as:


Back to Configuration Standards for NetBackup