check_esxi_hardware.py is a Nagios plugin to monitor the hardware of ESX and ESXi servers.
Refer to the following post to install Icinga, PNP4Nagios, and NagiosQL on FreeBSD.
Install the software
# cd /usr/ports/ports-mgmt/portmaster # make clean all install # make clean # rehash # portmaster lang/python # # fetch -o pywbem-0.7.0.tar 'http://sourceforge.net/projects/pywbem/files/pywbem/pywbem-0.7/pywbem-0.7.0.tar.gz/download' # tar xf pywbem-0.7.0.tar # cd pywbem-0.7.0 # /usr/local/bin/python setup.py install # # portmaster -d misc/rpl # rehash # # fetch -o /usr/local/libexec/icinga/check_esxi_hardware.py http://www.claudiokuenzler.com/nagios-plugins/check_esxi_hardware.py # rpl /usr/bin/python /usr/local/bin/python /usr/local/libexec/icinga/check_esxi_hardware.py # chmod 555 /usr/local/libexec/icinga/check_esxi_hardware.py
Usage example
define command { command_name check_esxi_hardware command_line $USER1$/check_esxi_hardware.py -H $HOSTADDRESS$ -U user -P password -p register 1 } define service { hostgroup_name esxi-servers service_description ESXi Hardware use service-pnp,generic-service check_command check_esxi_hardware process_perf_data 1 register 1 } define hostgroup { hostgroup_name esxi-servers alias ESXi Servers register 1 } define host { host_name myesxi hostgroups esxi-servers use host-pnp,generic-host register 1 }