Beginner problem with WMI installation

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Locked
TotoLeHeros
Posts: 5
Joined: Tue Apr 25, 2017 6:32 am

Beginner problem with WMI installation

Post by TotoLeHeros »

Hi everybody,

My name is Thomas and I from France.
First, sorry for my English and my level in Linux :oops: . I'm a also a begginer in the word of Nagios.

I work on a studient project of monitoring, with Nagios and Check_mk (OMD with Centos 6)

For the moment all the configuration work great with basic plugins of nagios and I check my network devices (router, switch) with SNMP on Check_mk.

I want to monitor Windows Servers without agent. I look for WMI check. Is that the best solution in your opinion ?
If yes, I have got a problem with the installation ...

I follow instructions of that : http://www.edcint.co.nz/checkwmiplus/In ... nalSession
and that : https://alexnogard.com/monitorer-window ... -centreon/

but it doesn't work ...

I usually have this message :

Code: Select all

[root@svr-nagios1 plugins]# ./check_wmi_plus.pl -d -d | head -n 20
Can't locate utils.pm in @INC (@INC contains: /usr/lib64/nagios/plugins /usr/local/lib64/perl5 /usr/local/share/perl5 /usr/lib64/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib64/perl5 /usr/share/perl5 .) at ./check_wmi_plus.pl line 313.
BEGIN failed--compilation aborted at ./check_wmi_plus.pl line 313.
Is there a great and recent tuto or someone to explain me how to install this plugin.
I think, I've got problem with the path of plugin with OMD installation and perl ?... But I don't know how to do.

Thank you.
TotoLeHeros
Posts: 5
Joined: Tue Apr 25, 2017 6:32 am

Re: Beginner problem with WMI installation

Post by TotoLeHeros »

I finally find the right path ... for pearl
But there's an other problem witch Perl

Code: Select all

[root@svr-nagios1 plugins]# ./check_wmi_plus.pl -d -d | head -n 20
Warning - one or more of your Perl Modules are out of date and this may cause plugin problems. If you are having any problems with Check WMI Plus you must upgrade your Perl Modules before contacting support (since they'll just tell you to upgrade!). You can override this warning at your peril by using the --IgnoreMyOutDatedPerlModuleVersions command line option or the "$ignore_my_outdated_perl_module_versions" setting in the conf file (/etc/check_wmi_plus/check_wmi_plus.conf). Version Information on the next line.
MODULE_NAME           INSTALLED_VERSION  STATUS DESIRED_VERSION
Config::IniFiles                   2.94      ok       2.58
Perl Version                   5.010001      ok       5.01
Getopt::Long                       2.49      ok       2.38
DateTime                           0.53     BAD       0.66
Number::Format                     1.75      ok       1.73
Data::Dumper                      2.161      ok      2.125
Scalar::Util                       1.47      ok       1.22
Storable                           2.20     BAD       2.22
With CPAN I upgrade DateTime and Storable, without problem but the command give the same message error ?

Any idea ?

Thanks
User avatar
mcapra
Posts: 3739
Joined: Thu May 05, 2016 3:54 pm

Re: Beginner problem with WMI installation

Post by mcapra »

Try this:

Code: Select all

or the "$ignore_my_outdated_perl_module_versions" setting in the conf file (/etc/check_wmi_plus/check_wmi_plus.conf)
I think it should be ok to change this setting to 1 like so:

Code: Select all

$ignore_my_outdated_perl_module_versions=1
See if that fixes the problem. I think the module versions on your machine currently should be fine.
Former Nagios employee
https://www.mcapra.com/
TotoLeHeros
Posts: 5
Joined: Tue Apr 25, 2017 6:32 am

Re: Beginner problem with WMI installation

Post by TotoLeHeros »

Thank you for this answer.

The plugin work with the argument --IgnoreMyOutDatedPerlModuleVersions.
If it's not possible to soluce the problem, I will be used this solution.

With CPAN I download and install DateTime, and now it's OK.
It doesn't work for Storable ??

It's just to have a good configuration.

Code: Select all

[root@svr-nagios1 plugins]# ./check_wmi_plus.pl -d -d | head -n 20
Warning - one or more of your Perl Modules are out of date and this may cause plugin problems. If you are having any problems with Check WMI Plus you must upgrade your Perl Modules before contacting support (since they'll just tell you to upgrade!). You can override this warning at your peril by using the --IgnoreMyOutDatedPerlModuleVersions command line option or the "$ignore_my_outdated_perl_module_versions" setting in the conf file (/etc/check_wmi_plus/check_wmi_plus.conf). Version Information on the next line.
MODULE_NAME           INSTALLED_VERSION  STATUS DESIRED_VERSION
Config::IniFiles                   2.94      ok       2.58
Perl Version                   5.010001      ok       5.01
Getopt::Long                       2.49      ok       2.38
DateTime                           1.42      ok       0.66
Number::Format                     1.75      ok       1.73
Data::Dumper                      2.161      ok      2.125
Scalar::Util                       1.47      ok       1.22
Storable                           2.20     BAD       2.22
Thanks
User avatar
mcapra
Posts: 3739
Joined: Thu May 05, 2016 3:54 pm

Re: Beginner problem with WMI installation

Post by mcapra »

I've known of a few others who have run into this specific problem with Storable. It seems to be related to CentOS/RHEL 5/6 machines, but I never verified that.

There's nothing in check_wmi_plus.pl that actually needs the 2.22 version of Storable. 2.20 works just as well.
Former Nagios employee
https://www.mcapra.com/
TotoLeHeros
Posts: 5
Joined: Tue Apr 25, 2017 6:32 am

Re: Beginner problem with WMI installation

Post by TotoLeHeros »

Thanks for your help mcapra.

The plugin actually work great with Storable 2.20.

Regards

Thomas
User avatar
mcapra
Posts: 3739
Joined: Thu May 05, 2016 3:54 pm

Re: Beginner problem with WMI installation

Post by mcapra »

Awesome! Did you have additional questions regarding check_wmi_plus, or can we close this thread and mark the issue as resolved?
Former Nagios employee
https://www.mcapra.com/
TotoLeHeros
Posts: 5
Joined: Tue Apr 25, 2017 6:32 am

Re: Beginner problem with WMI installation

Post by TotoLeHeros »

Hi,

You can close the post.

Thanks.

Thomas
Locked