Code Monkey home page Code Monkey logo

system-addons-plugins-op5-check_vmware_api's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

system-addons-plugins-op5-check_vmware_api's Issues

fc paths vsphere 6.5

I have detected that with vsphere 6.5 we can't monitor storage paths from fc luns, how can I recover this features with latest vsphere?

Thanks

Threshold error

Hello there

Im facing this problem

/usr/lib/nagios/plugins/check_vmware_api.pl -H myvmwarehost.local -u 'monitor' -p '************' -t 30 -l 'service' -s TSM -w tsm_running:1 -c TSM_running:1

Getting message:
invalid range definition 'tsm_running:0' at /usr/share/perl5/vendor_perl/Monitoring/Plugin/Threshold.pm line 50.

Whats the correct format of threshol for services runing or not?

Check Device Latency throwing Criticals on USB port

./check_vmware_api2.pl -H 10.10.10.200 -u user -p pass -l io -s device -w 100 -c 150
CHECK_VMWARE_API2.PL CRITICAL - io device latency=166 ms | io_device=166ms;100;150

When we investigate we find this is vmhba32 which is associated with the USB/SD port. Is there a way to exclude this? It doesn't really seem relevant here. I did try --exclude vmhba32 but that did nothing.

VMWare UNKNOWN results can't be black listed.

results such as

  1. UNKNOWN[watchdog] Status of BIOS 1 OS Watchdog Time 65 --- 0.34.1.113: Cannot report on the current health state of the element
  2. UNKNOWN[memory] Status of BIOS 1 MSR Info Log 65 --- 0.34.1.40: Cannot report on the current health state of the element

can not be black listed via -x

service check timed out on upgraded Debian stretch

Hello,
today i upgraded my Debian server with Nagios Core to stretch version. Everything works fine except check_vmware_api plugin.
All checks ends with status "service check timed out after 60.01 seconds".

Can you help me please? I havn´t any idea whats wrong :( I have installed Nagios 4.3.2 with vsphere cli 6.5.0 (this version works fine on previous version of Debian).

Thanks, petr

Add suport to ESXi 6.0 u2

hi,

Now we are using check_vmware_api 0.7.1 to monitor vcenter and esxi 5.1 u3
and is working great with perl SDK 5.1

Now I'm trying to use with a ESXi cluster with 6.0 u2 (vcenter and esxi
hosts) but with this versión we have problems with this versions.
Errors detected are unknow and timeout result after 60 seconds, and running
from cli we detected that every check need more than 8 seconds, and with
5.1 is less tan 2 seconds. After this we have detected that if we add more tan 4
services then check begin to return unknow and timeout errors, and with
less that 4 services then works.

We have tried upgrading vsphere 6.0 u2 SDK but then is not working any
check (5.1 and 6.0). also tried to upgrade check vmware_api to latest
versions gorm git but error persist

It seems that ESXi 6.0 u2 is not supported with latest version...

How can I monitor correctly esxi and vcenter 5.1 and 6.0 with
check_vmware_api?

First Implementation - A few issues

HI folks, great tool, and thanks for all he hard work. However I have a few issues I hope you can help with:

#1 Doesn't work as Nagios user or any non root user [works with sudo in the nagios command]:
CHECK_VMWARE_API.PL CRITICAL - Server version unavailable at 'https://mvcenter.com:443/sdk/vimService.wsdl' at /usr/share/perl5/VMware/VICommon.pm line 734, <AUTH_FILE> line 2.

#2 Check runtime on a host gives the following [then prints the proper output other than "overall status=red"]:
Use of uninitialized value $subcommand in string ne at /usr/lib64/nagios/plugins/check_vmware_api.pl line 1898.
CHECK_VMWARE_API.PL OK - 6/6 VMs up, overall status=red, connection state=connected, maintenance=no, All 122 health checks are Green, no config issues | vmcount=6units;; health_issues=0;; config_issues=0;;

Check_vmware_api fails to run

Ubuntu 16.04.1 LTS
Nagios Core 4.3.4

trying to run

root@tgcs017:/usr/local/nagios/libexec# ./check_vmware_api.pl -H Myhost-8
Can't locate Monitoring/Plugin/Functions.pm in @inc (you may need to install the Monitoring::Plugin::Functions module) (@inc contains: /etc/perl /usr/local/lib/x86_64-linux-gnu/perl/5.22.1 /usr/local/share/perl/5.22.1 /usr/lib/x86_64-linux-gnu/perl5/5.22 /usr/share/perl5 /usr/lib/x86_64-linux-gnu/perl/5.22 /usr/share/perl/5.22 /usr/local/lib/site_perl /usr/lib/x86_64-linux-gnu/perl-base .) at ./check_vmware_api.pl line 39.

The instructions to set this plugin up are for cent os

the yum install command fails

I used apt-get install

root@tgcs017:/usr/local/nagios/libexec# sudo apt-get install openssl-devel perl-ibXML perl-MIME-Lite perl-MIME-Types perl-MailTools perl-TimeDate uuid libuuid pect perl-Test-Simple perl-Monitoring-Plugin perl-Class-Accessor perl-Config-Tiny
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package openssl-devel
E: Unable to locate package perl-Archive-Zip
E: Unable to locate package perl-Class-MethodMaker
E: Unable to locate package uuid-perl
E: Unable to locate package perl-SOAP-Lite
E: Unable to locate package perl-XML-SAX
E: Unable to locate package perl-XML-NamespaceSupport
E: Unable to locate package perl-XML-LibXML
E: Unable to locate package perl-MIME-Lite
E: Unable to locate package perl-MIME-Types
E: Unable to locate package perl-MailTools
E: Unable to locate package perl-TimeDate
E: Unable to locate package libuuid
E: Unable to locate package perl-Data-Dump
E: Unable to locate package perl-uuid
E: Unable to locate package libuuid
E: Unable to locate package perl-Data-Dump
E: Unable to locate package perl-UUID
E: Unable to locate package cpan
E: Unable to locate package libxml2-devel
E: Unable to locate package perl-libwww-perl
E: Unable to locate package perl-Test-MockObject
E: Unable to locate package perl-Test-Simple
E: Unable to locate package perl-Monitoring-Plugin
E: Unable to locate package perl-Class-Accessor
E: Unable to locate package perl-Config-Tiny
root@tgcs017:/usr/local/nagios/libexec#

Tried yum also
root@tgcs017:/usr/local/nagios/libexec# sudo yum install openssl-devel perl-Archive-Zip perl-Class-MethodMaker uuid-perl perl-SOAP-Lite perl-XML-SAX perl-XML-NamespaceSupport perl-XML-LibXML perl-MIME-Lite perl-MIME-Types perl-MailTools perl-TimeDate uuid libuuid perl-Data-Dump perl-uuid libuuid perl-Data-Dump perl-UUID cpan libxml2-devel perl-libwww-perl perl-Test-MockObject perl-Test-Simple perl-Monitoring-Plugin perl-Class-Accessor perl-Config-Tiny
There are no enabled repos.
Run "yum repolist all" to see the repos you have.
You can enable repos with yum-config-manager --enable
root@tgcs017:/usr/local/nagios/libexec# yum repolist all
repolist: 0
root@tgcs017:/usr/local/nagios/libexec#

Hardware checks

Is it possible to check the HW via this check? We recently got alerts on a cisco host that has a pair of FlexFlash SD cards for ESX in a RAID1. However we never got any alerts via this api check.
I found a HW check, but unfortunately the hosts are on a segregated network from the monitoring server, so was unable to proceed with that one.

nagios configuration

Hi,

I installed the plugin but one library is missing.

[root@ardc01nagios check_vmware_api]# ./check_vmware_api.pl -H IP-f check_vmware_api.auth -l cpu -s usage -w 80 -c 90
Can't locate Net/SSL.pm in @inc (@inc contains: /root/perl5/perlbrew/perls/perl-5.16.3/lib/site_perl/5.16.3/x86_64-linux /root/perl5/perlbrew/perls/perl-5.16.3/lib/site_perl/5.16.3 /root/perl5/perlbrew/perls/perl-5.16.3/lib/5.16.3/x86_64-linux /root/perl5/perlbrew/perls/perl-5.16.3/lib/5.16.3 .) at ./check_vmware_api.pl line 44.
BEGIN failed--compilation aborted at ./check_vmware_api.pl line 44.
You have new mail in /var/spool/mail/root

Can you please help to resolve this?.

After ESXi minor version update: "Cannot complete login due to an incorrect user name or password"

Hi,

check_vmware_api.pl 0.7.1, after minor VMware version update (still ESXi 5.5) I get the following error when running any check:
VMware check UNKNOWN - Error: Cannot complete login due to an incorrect user name or password.

Edit: -vvv and --trace=255 only add an empty line, tcpdump shows some traffic going to the server and it replying. (not sure what the trace level should be, tried 1, 4, 256 also)

Remove script name from output

Not really an important issue, but is it possible to remove the script name from the output of the script?

At the moment I set the variable $PROGNAME to "ESXI" so the output isn't that long.

But I would like to completely remove the scriptname from the output, so that the first thing in the Status information in nagios is "OK|CRITICAL|WARNING" or whatever the status might be.

Any help would be appreciated

unknown runtim health after upgrade 6.7

Hello

After migration in 6.7 I encounter this problem:

1) UNKNOWN[other] Status of System Management Software 1 Low Security Jmp: Cannot report on the current health state of the element 2) UNKNOWN[other] Status of System Management Software 1 Phy Presence Jmp: Cannot report on the current health state of the element 3) UNKNOWN[Storage] Status of Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D DMI2 #0: Cannot report on the current status of the physical element 4) UNKNOWN[Storage] Status of Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D PCI Express Root Port 1 #1: Cannot report on the current status of the physical element 5) UNKNOWN[Storage] Status of Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D PCI Express Root Port 3 #3: Cannot report on the current status of the physical element 6) UNKNOWN[Storage] Status of Intel Corporation C610/X99 series chipset PCI Express Root Port #1 #28: Cannot report on the current status of the physical element 7) UNKNOWN[Storage] Status of Intel Corporation C610/X99 series chipset PCI Express Root Port #4 #28: Cannot report on the current status of the physical element 8) UNKNOWN[Storage] Status of Intel Corporation C610/X99 series chipset PCI Express Root Port #5 #28: Cannot report on the current status of the physical element 9) UNKNOWN[Storage] Status of Intel Corporation C610/X99 series chipset LPC Controller #31: Cannot report on the current status of the physical element 10) UNKNOWN[Storage] Status of Renesas Technology Corp. SH7758 PCIe-PCI Bridge [PPB] #0: Cannot report on the current status of the physical element 11) UNKNOWN[Storage] Status of Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Map/VTd_Misc/System Management #5: Cannot report on the current status of the physical element 12) UNKNOWN[Storage] Status of Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D IIO Hot Plug #5: Cannot report on the current status of the physical element 13) UNKNOWN[Storage] Status of Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D IIO RAS/Control Status/Global Errors #5: Cannot report on the current status of the physical element 14) UNKNOWN[Storage] Status of Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D I/O APIC #5: Cannot report on the current status of the physical element 15) UNKNOWN[Storage] Status of Intel Corporation C610/X99 series chipset SPSR #17: Cannot report on the current status of the physical element 16) UNKNOWN[Storage] Status of Intel Corporation Wellsburg AHCI Controller #17: Cannot report on the current status of the physical element 17) UNKNOWN[Storage] Status of Intel Corporation C610/X99 series chipset USB xHCI Host Controller #20: Cannot report on the current status of the physical element 18) UNKNOWN[Storage] Status of Intel Corporation C610/X99 series chipset MEI Controller #1 #22: Cannot report on the current status of the physical element 19) UNKNOWN[Storage] Status of Intel Corporation C610/X99 series chipset MEI Controller #2 #22: Cannot report on the current status of the physical element 20) UNKNOWN[Storage] Status of Intel Corporation C610/X99 series chipset USB Enhanced Host Controller #2 #26: Cannot report on the current status of the physical element 21) UNKNOWN[Storage] Status of Intel Corporation C610/X99 series chipset USB Enhanced Host Controller #1 #29: Cannot report on the current status of the physical element 22) UNKNOWN[Storage] Status of Intel Corporation Wellsburg AHCI Controller #31: Cannot report on the current status of the physical element 23) UNKNOWN[Storage] Status of Intel Corporation C610/X99 series chipset SMBus Controller #31: Cannot report on the current status of the physical element 24) UNKNOWN[Storage] Status of Intel Corporation C610/X99 series chipset Thermal Subsystem #31: Cannot report on the current status of the physical element 25) UNKNOWN[Storage] Status of Avago (LSI) MegaRAID SAS Invader Controller #0: Cannot report on the current status of the physical element 26) UNKNOWN[Storage] Status of Intel Corporation Ethernet Server Adapter I350-T2 #0: Cannot report on the current status of the physical element 27) UNKNOWN[Storage] Status of Intel Corporation Ethernet Server Adapter I350-T2 #0: Cannot report on the current status of the physical element 28) UNKNOWN[Storage] Status of Matrox Electronics Systems Ltd. G200eR2 #0: Cannot report on the current status of the physical element 29) UNKNOWN[Storage] Status of Renesas Technology Corp. SH7758 PCIe End-Point [PBI] #0: Cannot report on the current status of the physical element 30) UNKNOWN[Storage] Status of Broadcom Corporation NetXtreme BCM5719 Gigabit Ethernet #0: Cannot report on the current status of the physical element 31) UNKNOWN[Storage] Status of Broadcom Corporation NetXtreme BCM5719 Gigabit Ethernet #0: Cannot report on the current status of the physical element 32) UNKNOWN[Storage] Status of Broadcom Corporation NetXtreme BCM5719 Gigabit Ethernet #0: Cannot report on the current status of the physical element 33) UNKNOWN[Storage] Status of Broadcom Corporation NetXtreme BCM5719 Gigabit Ethernet #0: Cannot report on the current status of the physical element 34) UNKNOWN[Storage] Status of Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Map/VTd_Misc/System Management #5: Cannot report on the current status of the physical element 35) UNKNOWN[Storage] Status of Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D IIO Hot Plug #5: Cannot report on the current status of the physical element 36) UNKNOWN[Storage] Status of Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D IIO RAS/Control Status/Global Errors #5: Cannot report on the current status of the physical element 37) UNKNOWN[Storage] Status of Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D I/O APIC #5: Cannot report on the current status of the physical element 38) UNKNOWN[Storage] Status of Renesas Technology Corp. SH7758 PCIe Switch [PS] #0: Cannot report on the current status of the physical element 39) UNKNOWN[Storage] Status of Socket 1 Level-2 Cache: Cannot report on the current status of the physical element 40) UNKNOWN[Storage] Status of Socket 1 Level-3 Cache: Cannot report on the current status of the physical element 41) UNKNOWN[Storage] Status of Socket 2 Level-1 Cache: Cannot report on the current status of the physical element 42) UNKNOWN[Storage] Status of Socket 2 Level-2 Cache: Cannot report on the current status of the physical element 43) UNKNOWN[Storage] Status of Socket 2 Level-3 Cache: Cannot report on the current status of the physical element | Alerts=43;;

With the command:
/usr/lib/nagios/plugins/check_vmware_api.pl -H 192.168.xx.xx -u user -p password -l runtime -s health

Do you have a solution ?

Thank you

Feature request - port

Something I always had to add manually was a port number. This change/addition was useful because if you are monitoring "beyond" firewalls, it becomes necessary to use something other than the standard. Personally, I simply added a port option in the code and then allowed another argument in relation. Great update and thanks for the contribution to the community!

Getting error while command exeution

OS: Centos 7.2
I have issue with command execution
/usr/bin/perl: symbol lookup error: /usr/lib64/perl5/auto/Crypt/SSLeay/SSLeay.so: undefined symbol: Perl_Gthr_key_ptr

Ubuntu 16.04 multiple instaces issue

Hello
we have been using check_vmware_api on ubuntu 14 without any problem but, we recently upgraded to ubuntu 16.04, and we're having a concurrency problem.
Infact all nagios checks aren't working correctly anymore.
After doing some tests we noticed that the problem is maybe related to a concurrency execution.
To do this tests we just executed three simultaneous instances of check_vmware_api and we got the issue: the script hangs.

We have runned this tests with vsphere SDK version 5.1 6.0 and 6.5.

Ubuntu's perl version is 5.22.1

Thank you,

Error host does not exist

Hi,

I try to update my old Nagios server by setting up a new one. I've installed all prerequisites and i face a strange problem. It seems i'm authenticated but the api returns me an error :

[root@nagios plugins]# ./check_vmware_api.pl -H 192.168.1.10 -u nagios -p password-l runtime -s status
Use of uninitialized value in concatenation (.) or string at ./check_vmware_api.pl line 1895.
CHECK_VMWARE_API.PL CRITICAL - Host "" does not exist

If I change the password, i got an authentication error meaning the user password and ip are correct ....

Any help on this will be appreciated.

Login Event Spam

Good morning all,

I had previously used this plugin however our VMWare Team received a login event for every single service check performed. As we have many ESX hosts and performed a lot of checks we ended up producing millions of login events to the point they felt the performance of the VCenter Host was being impacted by the monitoring. Has this plugin been developed to hold a steady connection versus building a new one for each check?

Read only account to authenticate into ESX?

I created a local account on an ESX host with read-only access, and the checks fail to authenticate.

Is the only way to run the checks to use the "root" account on each ESX host?

Show warning or critical items only in the output

Is there is a way to show warning or critical items only in the output? I've added datastore usage check with 90% threshold but the output shows all data stores not just the ones breaching the threshold.

I would be nice if the output will show only items that are above defined warning and critical thresholds + usual perfdata for all items.

Show host in maintenance mode in a cluster

Hi,

Is it possible to query all hosts in maintenance mode in a specific cluster?

I have 100s of esx hosts in a cluster and would rather not to add a service check for each of them.

Thanks

Dom

problem running check in nagios

Centos 7, Nagios 4.3.4, Perl 5.10.1, VMware-vSphere-Perl-SDK-6.7

I can run the checks from the command line, with my nagios user, but when nagios run the checks, I get errors.

from cmd
./check_vmware_api -H [hostname] -u [username] -p [password] -l runtime -s con
CHECK_VMWARE_API OK - connection state=connected

from nagios
$USER1$/check_vmware_api -H $HOSTADDRESS$ -u [username] -p [password] -l runtime -s con
CHECK_VMWARE_API CRITICALHOST RUNTIME - unknown subcommand

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.