NetBackup

NetBackup latest backup status check

Description:

*** This script is for MS-Windows environment ***

This PowerShell script works with NSClient++ on MS-Windows environment.

You can check the latest backup status of NetBackup within 24 hours.
This script is written in the MS-PowerShell, is used for Windows NetBackup Master server.

Current Version

1.1

Last Release Date

2011-06-01

Compatible With

  • Nagios 2.x
  • Nagios 3.x

License

GPL


Project Files
Project Notes
<< Distribution Files >> 1. check_nbu_backstat.ps1 <-- this script 2. nbuerror.csv <-- CSV file << How To Install >> [check_nbu_backstat.ps1 Settings] 1. Copy "check_nbu_backstat.ps1" and "nbuerror.txt" into the scripts folder of NSClient++(ex. C:Program FilesNSClient++scripts). 2. Modify / Check the values of $nbuBin and $statFile if you need. 3. Modify / Add the "RETURN CODE TABLE SETTING" in the "searchRtnStat" function if you need. [NSClient++ Settings] 4. Add the following setting in the [Wrapped Scripts] in the section in the "NSC.ini". check_nbu_backstat=check_nbu_backstat.ps1 $ARG1$ 5. Enable the settings in the "NSC.ini". - port=5666 - command_timeout=60 - allow_arguments=1 - allow_nasty_meta_chars=1 - script_dir=scripts - socket_timeout=30 - allowed_hosts=xxx.xxx.xxx.xxx/xx 6. Restart the "NSClient++" service. [Nagios Settings] 7. Add the following setting to Nagios "commands". $USER1$/check_nrpe -H $HOSTADDRESS$ -c check_nbu_backup -a $ARG1$ 8. Add new Nagios "service" to check status of the backup job. * The backup client name that you want to check the latest backup status have to be set to $ARG1$ in the "service" setting. << Evaluation Environment >> - NetBackup 7.x - Windows Server 2003, 2008
Reviews (2) Add a Review
Power Shell and NSclient...
by Napsty, November 30, 2011

Very good once it works, but complicated to get it running! I finally got it running by using this line in the [NRPE Handlers] section: check_nbu_backstat=cmd /c echo scriptscheck_nbu_backstat.ps1 $ARG1$ | powershell.exe -command -



clariification reqd. - command configuration in nsc.ini
by santoshkp, October 31, 2011

Thanks for the script. I am facing some issues when running this script from a path where path name contains a space (eg; C:Program FilesNSClient++scripts). My entry is like as follows in nsc.ini file at "NRPE handler section). Entry in NRPE handle section: check_nbu_backup=cmd /c echo & 'C:Program FilesNSClient++scriptscheck_nbu_backstat.ps1' $ARG1$ $ARG2$; exit $LastExitCode | powershell.exe -command - On executing the command from collector: [root@inblr-gitotest1 libexec]# ./check_nrpe -H inhyd-gitos2 -c check_nbu_backup -a "-nbuClient" "test" getting the output as "ECHO is on. The filename, directory name, or volume label syntax is incorrect." If one will go by your instaructions, the standalone run of the script wants 2 arguments ( 1 option - "-nbuClient" and [nbu client name - let be named as "test"). If this is the case then how can be command in NSC.ini file will be with one argument as (check_nbu_backstat=check_nbu_backstat.ps1 $ARG1$ ). If i am configuring the way you mentioned then the PS script is not invoked by the nrpe. Please guide if i am doing anything wrong here. let me know if u need any more details here. Thanks, Santosh



Add a Review

You must be logged in to submit a review.

Thank you for your review!

Your review has been submitted and is pending approval.

Recommend

To:


From:


Thank you for your recommendation!

Your recommendation has been sent.

Project Stats
Rating
4 (4)
Favorites
0
Views
106,209