Home Directory

Search Exchange

Search All Sites

Nagios Live Webinars

Let our experts show you how Nagios can help your organization.

Contact Us

Phone: 1-888-NAGIOS-1
Email: sales@nagios.com

Login

Remember Me

Directory Tree

Directory

doro

Reviews(1)
bydoro, December 7, 2015
Everything works with:

Ubuntu 14.04
Nagios Core 3.5.1-1ubuntu1
Perl 5.18.2
VMware Perl SDK: VMware-vSphere-Perl-SDK-5.5.0-1384587.x86_64.tar.gz

Path original VICommon.pm manually:

root@st:~/check_vmware_api# diff /usr/share/perl/5.18/VMware/VICommon.pm /usr/share/perl/5.18/VMware/VICommon.pm_orig
448d447
ssl_opts( SSL_verify_mode => 0 );
506c505
$ENV{PERL_NET_HTTPS_SSL_SOCKET_CLASS} = "Net::SSL";
530d528
ssl_opts( SSL_verify_mode => 0 );
2113d2110
ssl_opts( SSL_verify_mode => 0 );
root@st:~/check_vmware_api#




TEST:
Edit file generate_tests.pl:

root@st:~/check_vmware_api# time perl generate_tests.pl
CHECK_VMWARE_API.PL OK - Storages : 'local_datastore_1'(free)=907044.00 MB (95.86%), 'public_images'(free)=134284.75 MB (65.57%), 'vol258'(free)=281717.14 MB (62.34%) | local_datastore_1=907044.00MB;; public_images=134284.75MB;; vol258=281717.14MB;;
CHECK_VMWARE_API.PL UNKNOWN - vmhba0 (unknown); vmhba32 (unknown); vmhba33 (unknown); vmhba34 (unknown); vmhba35 (unknown); vmhba36 (unknown); | adapters=0units;;
CHECK_VMWARE_API.PL OK - Local ATA Disk (t10.ATA_____ST91000640NS________________________________________9XG4X7YW) ; | LUNs=1units;;
CHECK_VMWARE_API.PL OK - sata.vmhba0-sata.0:0-t10.ATA_____ST91000640NS________________________________________9XG4X7YW ; | paths=1units;;
CHECK_VMWARE_API.PL UNKNOWN - 0/6 adapters online, 1/1 LUNs ok, 1/1 paths active | adapters=0units;; LUNs=1units;; paths=1units;;
CHECK_VMWARE_API.PL OK - cpu usage=8.99 % | cpu_usage=8.99%;;
CHECK_VMWARE_API.PL OK - cpu usagemhz=2266.00 MHz | cpu_usagemhz=2266.00MHz;;
CHECK_VMWARE_API.PL OK - cpu usage=2266.00 MHz (8.99%) | cpu_usagemhz=2266.00MHz;; cpu_usage=8.99%;;
CHECK_VMWARE_API.PL OK - net usage=3352.00 KBps | net_usage=3352.00KBps;;
CHECK_VMWARE_API.PL OK - net receive=199.00 KBps | net_receive=199.00KBps;;
CHECK_VMWARE_API.PL OK - net send=3152.00 KBps | net_send=3152.00KBps;;
CHECK_VMWARE_API.PL OK - All 2 NICs are connected | OK_NICs=2;; Bad_NICs=0;;
CHECK_VMWARE_API.PL OK - net receive=199.00 KBps, send=3152.00 KBps, all 2 NICs are connected | net_receive=199.00KBps;; net_send=3152.00KBps;; OK_NICs=2;; Bad_NICs=0;;
CHECK_VMWARE_API.PL OK - connection state=connected
CHECK_VMWARE_API.PL OK - All 132 health checks are GREEN: Logging (3x); temperature (6x); fan (4x); Management Subsystem Health (4x); Memory (1x); CPU (2x); Software Components (87x); voltage (7x); power (6x); system (1x); Watchdog (4x); Battery (1x); Processors (6x); | Alerts=0;;
CHECK_VMWARE_API.PL UNKNOWN - Storage health status unavailable - make sure you have the "Storage Health" tab in your vSphere client | Alerts=0;;
CHECK_VMWARE_API.PL OK - All 6 temperature checks are GREEN: OK : [Device] Other 0 Inlet Temp --- Normal = 23 C, OK : Processor 1 PCH Temp --- Normal = 47 C, OK : Processor 1 DIMM ZONE 2 Temp --- Normal = 31 C, OK : Processor 1 DIMM ZONE 1 Temp --- Normal = 35 C, OK : Processor 1 CPU2 Temp --- Normal = 44 C, OK : Processor 1 CPU1 Temp --- Normal = 48 C | '[Device] Other 0 Inlet Temp --- Normal'=23C;; 'Processor 1 PCH Temp --- Normal'=47C;; 'Processor 1 DIMM ZONE 2 Temp --- Normal'=31C;; 'Processor 1 DIMM ZONE 1 Temp --- Normal'=35C;; 'Processor 1 CPU2 Temp --- Normal'=44C;; 'Processor 1 CPU1 Temp --- Normal'=48C;;
CHECK_VMWARE_API.PL CRITICAL - Provide sensor name as -o argument
Use of uninitialized value $addopts in string eq at ./check_vmware_api.pl line 2277.
Use of uninitialized value $addopts in string eq at ./check_vmware_api.pl line 2280.
CHECK_VMWARE_API.PL OK - maintenance=no
CHECK_VMWARE_API.PL OK - 8/8 VMs up: vpn(OK), vcenter-88-2(OK), XXXXXXXX.com(OK), XXXXXXXX.com(OK), XXXXXXXX.com(OK), XXXXXXXX.com(OK), XXXXXXXX.com(OK), XXXXXXXX.com(OK) | vmcount=8units;;
CHECK_VMWARE_API.PL OK - overall status=green
CHECK_VMWARE_API.PL OK - No config issues
Use of uninitialized value $subcommand in string ne at ./check_vmware_api.pl line 1898.
CHECK_VMWARE_API.PL OK - 8/8 VMs up, overall status=green, connection state=connected, maintenance=no, All 132 health checks are Green, no config issues | vmcount=8units;; health_issues=0;; config_issues=0;;
CHECK_VMWARE_API.PL OK - No VM's with cd/dvd devices | match=0;;
CHECK_VMWARE_API.PL OK - services : DCUI (up), TSM (down), TSM-SSH (up), lbtd (up), lsassd (down), lwiod (down), netlogond (down), ntpd (up), sfcbd-watchdog (up), snmpd (up), vmware-fdm (down), vprobed (down), vpxa (up), xorg (down)
CHECK_VMWARE_API.PL OK - io commands aborted=0 | io_aborted=0;;
CHECK_VMWARE_API.PL OK - io bus resets=0 | io_busresets=0;;
CHECK_VMWARE_API.PL OK - io read latency=0 ms | io_read=0ms;;
CHECK_VMWARE_API.PL OK - io write latency=0 ms | io_write=0ms;;
CHECK_VMWARE_API.PL OK - io kernel latency=0 ms | io_kernel=0ms;;
CHECK_VMWARE_API.PL OK - io device latency=0 ms | io_device=0ms;;
CHECK_VMWARE_API.PL OK - io queue latency=0 ms | io_queue=0ms;;
CHECK_VMWARE_API.PL OK - io commands aborted=0, io bus resets=0, io read latency=0 ms, write latency=0 ms, kernel latency=0 ms, device latency=0 ms, queue latency=0 ms | io_aborted=0;; io_busresets=0;; io_read=0ms;; io_write=0ms;; io_kernel=0ms;; io_device=0ms;; io_queue=0ms;;
CHECK_VMWARE_API.PL OK - mem usage=82.26 % | mem_usage=82.26%;;
CHECK_VMWARE_API.PL OK - mem usage=107788.05 MB | mem_usagemb=107788.05MB;;
CHECK_VMWARE_API.PL OK - swap usage=79.71 MB | mem_swap=79.71MB;;
CHECK_VMWARE_API.PL OK - overhead=1502.64 MB | mem_overhead=1502.64MB;;
CHECK_VMWARE_API.PL OK - overall=109290.69 MB | mem_overhead=109290.69MB;;
CHECK_VMWARE_API.PL OK - memctl=129.01 MB | mem_memctl=129.01MB;;
CHECK_VMWARE_API.PL OK - mem usage=107788.05 MB (82.26%), overhead=1502.64 MB, swapped=79.71 MB, memctl=129.01 MB | mem_usagemb=107788.05MB;; mem_usage=82.26%;; mem_overhead=1502.64MB;; mem_swap=79.71MB;; mem_memctl=129.01MB;;
CHECK_VMWARE_API.PL OK - mem usage=82.25 % | mem_usage=82.25%;;
CHECK_VMWARE_API.PL OK - mem usage=107773.45 MB | mem_usagemb=107773.45MB;;
CHECK_VMWARE_API.PL OK - swap usage=79.71 MB | mem_swap=79.71MB;;
CHECK_VMWARE_API.PL OK - overhead=1502.64 MB | mem_overhead=1502.64MB;;
CHECK_VMWARE_API.PL OK - overall=109290.69 MB | mem_overall=109290.69MB;;
CHECK_VMWARE_API.PL OK - memctl=129.01 MB | mem_memctl=129.01MB;;
CHECK_VMWARE_API.PL OK - mem usage=107788.05 MB (82.26%), overhead=1502.64 MB, swapped=79.71 MB, memctl=129.01 MB | mem_usagemb=107788.05MB;; mem_usage=82.26%;; mem_overhead=1502.64MB;; mem_swap=79.71MB;; mem_memctl=129.01MB;;
CHECK_VMWARE_API.PL OK - io commands aborted=0 | io_aborted=0;;
CHECK_VMWARE_API.PL OK - io bus resets=0 | io_busresets=0;;
CHECK_VMWARE_API.PL OK - io read latency=0 ms | io_read=0ms;;
CHECK_VMWARE_API.PL OK - io write latency=0 ms | io_write=0ms;;
CHECK_VMWARE_API.PL OK - io kernel latency=0 ms | io_kernel=0ms;;
CHECK_VMWARE_API.PL OK - io device latency=0 ms | io_device=0ms;;
CHECK_VMWARE_API.PL OK - io queue latency=0 ms | io_queue=0ms;;
CHECK_VMWARE_API.PL OK - io commands aborted=0, io bus resets=0, io read latency=0 ms, write latency=0 ms, kernel latency=0 ms, device latency=0 ms, queue latency=0 ms | io_aborted=0;; io_busresets=0;; io_read=0ms;; io_write=0ms;; io_kernel=0ms;; io_device=0ms;; io_queue=0ms;;
CHECK_VMWARE_API.PL OK - cpu usage=19.85 % | cpu_usage=19.85%;;
CHECK_VMWARE_API.PL OK - cpu usagemhz=5002.00 MHz | cpu_usagemhz=5002.00MHz;;
CHECK_VMWARE_API.PL OK - cpu usage=5002.00 MHz (19.85%) | cpu_usagemhz=5002.00MHz;; cpu_usage=19.85%;;
CHECK_VMWARE_API.PL CRITICAL - Storages : 'public_images'(free)=134284.80 MB (65.57%), 'local_datastore_1'(free)=907044.00 MB (95.86%), 'local_datastore_2' is not accessible, 'vol258'(free)=281650.31 MB (62.34%) | public_images=134284.80MB;; local_datastore_1=907044.00MB;; vol258=281650.31MB;;
CHECK_VMWARE_API.PL OK - 8/9 VMs up: debian8(DOWN), vcenter-88-2(UP), vpn(UP), XXXXXXXX.com(UP), XXXXXXXX.com(UP), XXXXXXXX.com(UP), XXXXXXXX.com(UP), XXXXXXXX.com(UP), XXXXXXXX.com(UP) | vmcount=8units;;
CHECK_VMWARE_API.PL UNKNOWN - 1/2 Hosts up: XX.XX.XX.XX(UNKNOWN), XX.XX.XX.XX(UP) | hostcount=1units;;
CHECK_VMWARE_API.PL OK - 1/1 Cluster green: cluster#1(GREEN) | clustercount=1units;;
CHECK_VMWARE_API.PL OK - XXXXXXXX.com(Running-Unmanaged), XXXXXXXX.com(Running-Unmanaged), XXXXXXXX.com(Running-Unmanaged), XXXXXXXX.com(Running-Unmanaged), XXXXXXXX.com(Running-Unmanaged), XXXXXXXX.com(Running-Unmanaged), vpn(Not running-Not installed), vcenter-88-2(Running-Unmanaged) | toolsok=0%;;
CHECK_VMWARE_API.PL UNKNOWN - Interxion MAD2 overall status=gray
CHECK_VMWARE_API.PL OK - No config issues | issues=0;;
CHECK_VMWARE_API.PL OK - 8/8 VMs up (1 templates), 1/2 Hosts up, Interxion MAD2 overall status=gray, no config issues | vmcount=8units;; hostcount=1units;; config_issues=0;;
CHECK_VMWARE_API.PL OK - No recommendations | recommendations=0;;
CHECK_VMWARE_API.PL OK - net usage=4352.00 KBps | net_usage=4352.00KBps;;
CHECK_VMWARE_API.PL OK - net receive=111.00 KBps | net_receive=111.00KBps;;
CHECK_VMWARE_API.PL OK - net send=3426.00 KBps | net_send=3426.00KBps;;
CHECK_VMWARE_API.PL OK - net receive=111.00 KBps, send=3426.00 KBps | net_receive=111.00KBps;; net_send=3426.00KBps;;

real 0m38.762s
user 0m29.331s
sys 0m2.007s
root@st:~/check_vmware_api#