Page 1 of 2
Monitoring VMware vCenter
Posted: Mon Aug 29, 2011 3:04 pm
by npietran
Good afternoon,
We are installing Nagios XI on RHEL 6 and would like to monitor VMware vCenter and vSphere servers.
Does anyone have and procedures that explain all of the steps required (including software prereqs) to monitor multiple vCenter/vSphere servers?
I have downloaded and installed the VMware vCenter/vSphere monitoring wizard. I am having difficulty in determining how to configure the file(s) that contain the username, password & server for logging in to the servers.
Thanks,
Nick P
Re: Monitoring VMware vCenter
Posted: Tue Aug 30, 2011 4:54 pm
by lmiltchev
Did you read our documentation on the topic? If you haven't, here is the link:
http://assets.nagios.com/downloads/nagi ... ios_XI.pdf
Hope this helps!
Re: Monitoring VMware vCenter
Posted: Fri Sep 02, 2011 11:53 am
by npietran
Yes, I have read the link. I have also installed the VI Perl Toolkit mentioned in the check_vmware.pl.
I am looking for information on how to monitor multiple VMware vCenter hosts. There is a configuration file under /usr/local/nagios/libexec that contains the hostname, username and password for the vCenter host. How do you configure this file when there are multiple vCenter hosts?
Thanks,
Nick P
Re: Monitoring VMware vCenter
Posted: Fri Sep 23, 2011 12:48 pm
by npietran
Can anyone assist me with configuring the monitoring of a vCenter host?
Thanks,
Nick P
Re: Monitoring VMware vCenter
Posted: Mon Sep 26, 2011 5:01 pm
by mguthrie
There's a community written wizard that might do what you need. Take a look and see if it does what you need.
http://exchange.nagios.org/directory/Ad ... rd/details
Re: Monitoring VMware vCenter
Posted: Mon Sep 26, 2011 7:26 pm
by jsmurphy
I've also been having issues with the VMware wizard, I'm using the provided nagios CentOS VM(2011R1.6)... following the instructions it says to install the x86_64 version of the tools when the VM is 32bit so you need the i386 SDK instead. This got me past the first hurdle of the plugin telling me that the SDK was not installed... However once I got to the guest selection tab on Step 3 it displays the SDK not installed error again.
I've double checked the permissions on getguests.pl:
# ls -l /usr/local/nagiosxi/html/includes/configwizards/vmware/scripts/getguests.pl
-rwxrwxr-x 1 nagios nagcmd 5187 May 3 2010 /usr/local/nagiosxi/html/includes/configwizards/vmware/scripts/getguests.pl
I then tried to run the check_esx3.pl manually:
# ./check_esx3.pl -H esxserver -u <user> -p <password> -l cpu
ESX3 CRITICAL - Server version unavailable at '
https://esxserver:443/sdk/vimService.wsdl'
I thought this might have something to do with running the 4.0 SDK when we have ESX 4.1 servers so I updated the SDK to 4.1 and ran it again:
# ./check_esx3.pl -H esxserver -u <user> -p <password> -l cpu
ESX3 CRITICAL - Server version unavailable at '
https://esxserver:443/sdk/vimService.wsdl' at /usr/lib/perl5/5.8.8/VMware/VICommon.pm line 545.
If I open a browser and manually browse to the
https://esxserver:443/sdk/vimService.wsdl I can see the return XML just fine... hopefully this helps some one diagnose the problem.
Edit: Oh and I still see the SDK not installed error on the Guest selection page after updating the SDK. I've also tried re-installing the SDK/ VM wizard module as recommended in the doc.
Re: Monitoring VMware vCenter
Posted: Tue Sep 27, 2011 11:21 am
by nscott
Are you sure the ESX vSphere SDK installed completely? It silently exits and doesn't say error, it just stops if it fails. What happens when you try to run the installer for the SDK?
Re: Monitoring VMware vCenter
Posted: Tue Sep 27, 2011 5:21 pm
by jsmurphy
Fairly sure it's installed correctly:
Do you accept? (yes/no) yes
Thank you.
In which directory do you want to install the executable files?
[/usr/bin]
Please wait while copying vSphere CLI files...
The installation of vSphere CLI 4.1.0 build-254719 for Linux completed
successfully. You can decide to remove this software from your system at any
time by invoking the following command:
"/usr/bin/vmware-uninstall-vSphere-CLI.pl".
This installer has successfully installed both vSphere CLI and the vSphere SDK
for Perl.
Enjoy,
--the VMware team
Re: Monitoring VMware vCenter
Posted: Fri Sep 30, 2011 2:07 pm
by nscott
Try manually running the plugin from the command line
/usr/local/nagiosxi/html/includes/configwizards/vmware/scripts/getguests.pl -H <your ESX> -u <user to login as> -p <password for said user>
If that doesn't roll, then the SDK is messed up. Once that rolls, then set the permissions properly (by allowing apache to execute it) and try it in Nagios XI.
Re: Monitoring VMware vCenter
Posted: Sun Oct 02, 2011 5:09 pm
by jsmurphy
Same deal as running the check_esx3.pl:
# ./getguests.pl -H <esx host> -u <user> -p <pw>
Server version unavailable at 'https://<esx host>:443/sdk/vimService.wsdl' at /usr/lib/perl5/5.8.8/VMware/VICommon.pm line 545.
results from manually browsing https://<esx host>:443/sdk/vimService.wsdl
In the above, as far as I can see there is no server version in the XML available on the ESX host.
Are there any versions of the SDK or ESX you are aware it doesn't actually work for? Does it work for both ESX and ESXi?