Windows NRPE

Check Hyper-V 2012 health – BPA & VM

Description:

Check Hyper-V health through NRPE by:
-Executing and retrieving BPA Results
-Checking not running VM
-Checking not operational normally VM

Warning and Critical state are triggered on sum of:
-Number of BPA issues
-Number of VM in bad shape

You can provide a list of VM to ignore (models…).

A BPA refresh scan is triggered on every call, but in async. So the result will be read on next plugin execution.

Performance graph are provided for:
-VM not running
-VM issues
-BPA Errors
-BPA Warning

*** Need Windows Server 2012, as using Hyper-V PowerShell modules***

Latest version also available on github:
https://github.com/mathieuchateau/nsclient-plugins/

Current Version

0.2

Last Release Date

2016-02-16

Compatible With

  • Nagios 3.x

License

GPL


Project Files
Project Notes
Version 0.2: -Fix for non english servern thanks to Alexander Koch ############################################### Tested Setup: Monitoring Box: -Centos 6.4 x64 -Nagios 3.4.4 -check_nrpe 2.13 -Centreon 2.4.2 -nsclient++ 0.4.1 x64 & x86 -Windows Server 2012 *** Need Windows Server 2012, as using Hyper-V PowerShell modules*** ############################################### Scripts arguments The script accept 3 arguments: -excludeVM (separated by commas) -maxWarn (Warning if above, 1 by default) -maxCrit (Critical if above, 5 by default) ############################################### Local execution example (backslash are removed by this site): . .lotp_check_vm.ps1 WARNING: 'VM Not Running:'2 'VM issues:'0 BPA Error:1 BPA Warning:12|VM_Not_Running=2 VM_issues=0 BPA_Error=1 BPA_Warning=12 NRPE execution: [root~]# /usr/lib64/nagios/plugins/check_nrpe -H myHyperV -n -c check_hyper-v WARNING: 'VM Not Running:'2 'VM issues:'0 BPA Error:1 BPA Warning:12|VM_Not_Running=2 VM_issues=0 BPA_Error=1 BPA_Warning=12 [root~]# ############################################### Installation: On Windows Servers: -copy script in folder C:/Program Files/NSClient++/scripts -enable powershell script execution without signed : Set-ExecutionPolicy RemoteSigned -Add to nsclient.ini: [/settings/external scripts/wrapped scripts] check_hyper-v=lotp_check_hyper-v.ps1 -excludeVM $ARG1$ -maxWarn $ARG2$ -maxError $ARG3$ ############################################### Configuration: For example, on Centreon: -Add a new command: $USER1$/check_nrpe -H $HOSTADDRESS$ -n -t 60 -c check_vm -a $ARG1$ $ARG2$ $ARG3$
Reviews (1) Add a Review
It works
by damned, May 31, 2017

and that's good, but there's a typo, change: if($excludeVM -ne "" to if($excludeVM -ne "")



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 (1)
Favorites
0
Views
47,734