BaldMansMojo / check_vmware_esx

chech_vmware_esx Fork of check_vmware_api.pl
GNU General Public License v2.0
124 stars 67 forks source link

check_vmware_esx and error Server version unavailable at 'https://IP:443/sdk/vimService.wsdl' #137

Closed emi65 closed 5 years ago

emi65 commented 6 years ago

Hi I use VMware::VIRuntime 6.5.0 and I got this error whith all checks

/opt/perl5/perlbrew/perls/perl-5.24.4/bin/perl check_vmware_esx -H 10.209.47.172 -u AAA -p PPP -S uptime Server version unavailable at 'https://10.209.47.172:443/sdk/vimService.wsdl' at /opt/perl5/perlbrew/perls/perl-5.24.4/lib/site_perl/5.24.4/x86_64-linux/VMware/VICommon.pm line 704.

Please could you help to solve the problem ? Thanks for your help Emilio

Napsty commented 6 years ago

@emi65 I just spent almost the whole day getting the plugin to run on Ubuntu Xenial (new Icinga 2 setup) and I've put this howto together: https://www.claudiokuenzler.com/blog/789/install-check_vmware_esx.pl-vmware-perl-sdk-6.7-ubuntu-xenial-icinga2 Hope it helps.

Daniel180878 commented 5 years ago

Hello,

i have the same Problem, did anything helped? I have looked at https://www.claudiokuenzler.com/blog/789/install-check_vmware_esx.pl-vmware-perl-sdk-6.7-ubuntu-xenial-icinga2 but did not find any help for this Problem...

Ubuntu 18.05 SDK: 6.5

regards,

Daniel

BaldMansMojo commented 5 years ago

I think it is fixed with one of the pull requests I have to merge. Remember: SDK 6.x isn't currently supported by me. All 6.x up to 6.5 were buggy.

Unfortunately I had no SDK 6.x system in the past) so I couldn't test anything with SDK 6.x (it wasn't possible to get it running on a Centos 6.x). But since two weeks I have some gearman workers with CentOS 7.x and so i will merge all the pull requests.

So stay tuned

Napsty commented 5 years ago

@Daniel180878 Use SDK 6.7 or newer, as I wrote in https://www.claudiokuenzler.com/blog/789/install-check_vmware_esx.pl-vmware-perl-sdk-6.7-ubuntu-xenial-icinga2

Daniel180878 commented 5 years ago

Got the same issue with 6.7

VamPikmin commented 5 years ago

What happens if you run as root?

BaldMansMojo commented 5 years ago

In the current official release SDK 6.x isn't supported because I wasn't able to get it installed without a lot of installing software by hand instead of packages on Centos 6.x. There are some pull requests handling SDK 6.x . Since some weeks I have some workers with SDK 6.x and I will release an update soon. meanwhile look at the pull requests an merge your own version.

uclara commented 5 years ago

Hi, Gerhard found an easy way to bring these vSphere SDK's into OMD, without the need of running the installer. Simply he extracts some files from the tarball and move them in the right place.

You can find the description here: https://labs.consol.de/de/omd/packages/check_vmware_esx/index.html

Ulli

BaldMansMojo commented 5 years ago

@uclare: Wrong threat. @Original question. Should work with latest release. If you still have prolems it is caused by your CIM Server. We had that problem massivly with the VMware version deliverd by Fujitsu. The problems were caused by the hardware agents. We disconnected the agents and check hardware health via management board.

Regards Martin

ulyszk commented 4 years ago

Hi Martin! Sorry for commenting to already closed issue, but it seems there is something strange. I was able run your VMWare check - and it is awesome. However I hit the problem with all in one version. I was not able to get in work.

I have to install many packages to avoid such problems like:

./icinga_plugin/vmware/check_vmware_esx-1.2.3/check_vmware_esx  -H vcenter01.si.net -f /etc/icinga2/auth/check.esxi.si.net -S runtime -s temp
Can't locate HTTP/Date.pm in @INC (you may need to install the HTTP::Date module) (@INC contains: /root/perl5/lib/perl5 /usr/local/lib/perl5/site_perl/5.30.1/x86_64-linux /usr/local/lib/perl5/site_perl/5.30.1 /usr/local/lib/perl5/5.30.1/x86_64-linux /usr/local/lib/perl5/5.30.1) at /root/icinga_plugin/vmware/check_vmware_esx-1.2.3/check_vmware_esx line 8528.
BEGIN failed--compilation aborted at /root/icinga_plugin/vmware/check_vmware_esx-1.2.3/check_vmware_esx line 8528.

First I tried from yum package (on CentOS7), later I do via cpan. Finally I always hit to the problem:

Server version unavailable at 'https://vcenter01.local:443/sdk/vimService.wsdl' at /usr/local/lib/perl5/5.30.1/VMware/VICommon.pm line 734.

as others already explained. I used SDK version 6.5.

What helped to me to used modularised versiopn of your tool. Of course I have to copy modules to a folder on Perl's path but after that It started to work without problem:

./icinga_plugin/vmware/check_vmware_esx-1.2.3/check_vmware_esx.pl  -H vcenter01.local -f /etc/icinga2/vc.auth -S runtime -s temp
OK: All 31 temperature checks are GREEN.
[...]

Maybe this helps for others, or maybe this is a bug in all-in-one version. Finally I did not used other tricks (like $ENV, or editing the Perl files) that others mentioned before.

BaldMansMojo commented 4 years ago

That's one reason why I don't like the "assembled" one. But for the module version there is a path to adopt in the central file.

I always recommend to test the SDK installation first before struggling around with the plugin.