Plugin Issues

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
radams
Posts: 6
Joined: Tue Sep 10, 2013 1:14 pm

Plugin Issues

Post by radams »

Any plugin I install I get this message. I am new with this application and I really don't know what else to do. Can someone help?

./check_jmx4perl -H
Can't locate Nagios/Plugin/Functions.pm in @INC (@INC contains: /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_jmx4perl line 6.
BEGIN failed--compilation aborted at ./check_jmx4perl line 6.
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: Plugin Issues

Post by lmiltchev »

You may have a missing perl module or you may have a path to the nagios plugins, defined incorrectly in the plugin. Open the plugin in a text editor, and look through the code. Hope this helps.
Be sure to check out our Knowledgebase for helpful articles and solutions!
radams
Posts: 6
Joined: Tue Sep 10, 2013 1:14 pm

Re: Plugin Issues

Post by radams »

Thanks for the prompt response. This is the first plugin I installed, do I have to install something else before this?
radams
Posts: 6
Joined: Tue Sep 10, 2013 1:14 pm

Re: Plugin Issues

Post by radams »

But this is happening to all plugins I try to install.. here is another one

./check_wmi_plus.pl
Can't locate Number/Format.pm in @INC (@INC contains: /usr/lib/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 55.
BEGIN failed--compilation aborted at ./check_wmi_plus.pl line 55.
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: Plugin Issues

Post by lmiltchev »

It seems like this is a different perl module that you need to install... If you are not sure how to install perl modules, please, review the following link:

http://www.cpan.org/modules/INSTALL.html
Be sure to check out our Knowledgebase for helpful articles and solutions!
slansing
Posts: 7698
Joined: Mon Apr 23, 2012 4:28 pm
Location: Travelling through time and space...

Re: Plugin Issues

Post by slansing »

Have you tried any non perl plugins? As this is a perl specific error. You might be missing the following plugin, can you run the following and try to run the plugin again?:

Code: Select all

yum install perl-Number-Format.noarch
radams
Posts: 6
Joined: Tue Sep 10, 2013 1:14 pm

Re: Plugin Issues

Post by radams »

I am still having the same issue after installing the module.. I have tried multiple modules..

[root@nagiosxi libexec]# ./check_linux_stats.pl -H
Can't locate Sys/Statistics/Linux.pm in @INC (@INC contains: /usr/local/nagios/libexec /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_linux_stats.pl line 33.
BEGIN failed--compilation aborted at ./check_linux_stats.pl line 33.
[root@nagiosxi libexec]# ./check_jmx4perl -H
Can't locate Nagios/Plugin/Functions.pm in @INC (@INC contains: /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_jmx4perl line 6.
BEGIN failed--compilation aborted at ./check_jmx4perl line 6.
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: Plugin Issues

Post by lmiltchev »

All of the various plugins that you have been trying are perl plugins, and you need to have the required perl modules installed for each one. I would recommend sticking to one plugin, installing the required modules, testing it, etc. until you make it work.

I doubt you have issues with ALL plugins...
Have you tried any non perl plugins?
For example:

Code: Select all

./check_users -w 3 -c 5
Be sure to check out our Knowledgebase for helpful articles and solutions!
radams
Posts: 6
Joined: Tue Sep 10, 2013 1:14 pm

Re: Plugin Issues

Post by radams »

Issue resolved by installing cpan and a few other modules.. Thanks
slansing
Posts: 7698
Joined: Mon Apr 23, 2012 4:28 pm
Location: Travelling through time and space...

Re: Plugin Issues

Post by slansing »

Great, locking up.
Locked