Worker commands run - Nagios Xi Don´t

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
rpatricio
Posts: 22
Joined: Thu Nov 29, 2018 1:31 pm

Worker commands run - Nagios Xi Don´t

Post by rpatricio »

Hi all,

I created a worker to help xi on some network checks, but some checks runs perfectly on command line and on the service when I am going to test the command on XI runs perfectly also, but on service status, xi shows a different message, as it is a plugin problem.

Images are attached.

Can someone help me on this question?
You do not have the required permissions to view the files attached to this post.
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Worker commands run - Nagios Xi Don´t

Post by scottwilkerson »

Do you have multiple Socket.pm files on the system? It seems like you may have multiple perl paths with possible conflicting versions

Code: Select all

locate Socket.pm
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
rpatricio
Posts: 22
Joined: Thu Nov 29, 2018 1:31 pm

Re: Worker commands run - Nagios Xi Don´t

Post by rpatricio »

Hi Scott,

this is the output of the locate Socket.pm on the worker machine:

/home/nagios/perl5/lib/perl5/x86_64-linux-thread-multi/Socket.pm
/home/nrpe2/.cpan/build/Socket-2.027-RZ8sge/Socket.pm
/home/nrpe2/.cpan/build/Socket-2.027-RZ8sge/blib/lib/Socket.pm
/home/nrpe2/perl5/lib/perl5/x86_64-linux-thread-multi/Socket.pm
/home/oracle/perl5/lib/perl5/x86_64-linux-thread-multi/Socket.pm
/root/.cpan/build/IO-1.39-0/blib/lib/IO/Socket.pm
/root/.cpan/build/IO-1.39-0/lib/IO/Socket.pm
/root/.cpan/build/Socket-2.027-0/Socket.pm
/root/.cpan/build/Socket-2.027-0/blib/lib/Socket.pm
/root/.cpan/build/Socket-2.027-RZ8sge/Socket.pm
/root/.cpan/build/Socket-2.027-RZ8sge/blib/lib/Socket.pm
/root/perl5/lib/perl5/x86_64-linux-thread-multi/Socket.pm
/root/perl5/lib/perl5/x86_64-linux-thread-multi/IO/Socket.pm
/usr/lib64/perl5/IO/Socket.pm
/usr/lib64/perl5/vendor_perl/Socket.pm
/usr/local/lib64/perl5/Socket.pm
------------------------------------------------------------------------------------

This is the output of Locate socket.pm on Nagios XI machine:

/usr/lib64/perl5/IO/Socket.pm
/usr/lib64/perl5/vendor_perl/Socket.pm


As I don´t understand so much about perl, would you help me figure out, what should I do to fix this error?
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Worker commands run - Nagios Xi Don´t

Post by scottwilkerson »

This is connecting to a worker machine and running another command?

looking at the worker machine it looks like someone installed a bunch of different version which would really throw things off

You are likely going to have to run the following on each of the Socket.pm files to determine which are the wrong version (2.027), and then I would suggest moving them to a temp location that won't be picked up as part of the path

Code: Select all

grep VERSION /path/to/file
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
rpatricio
Posts: 22
Joined: Thu Nov 29, 2018 1:31 pm

Re: Worker commands run - Nagios Xi Don´t

Post by rpatricio »

This is connecting to a worker machine and running another command?

Yes, worker is executing the command, and nagios xi is showing the result.

looking at the worker machine it looks like someone installed a bunch of different version which would really throw things off

You are likely going to have to run the following on each of the Socket.pm files to determine which are the wrong version (2.027), and then I would suggest moving them to a temp location that won't be picked up as part of the path

I will try do it, and let you know.
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Worker commands run - Nagios Xi Don´t

Post by scottwilkerson »

rpatricio wrote:I will try do it, and let you know.
Sounds good
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
Locked