returned an invaled return code 255

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
ariarlet
Posts: 61
Joined: Wed Apr 22, 2015 11:04 am

returned an invaled return code 255

Post by ariarlet »

Hello


The result on Nagios is:
The command (check_log3) returned an invaled return code: 255

In the check_log3 decribe:

If the code returns non-zero, it is counted towards the alerts threshold

In the others server 0 problems

Why whappens?


ty
jolson
Attack Rabbit
Posts: 2560
Joined: Thu Feb 12, 2015 12:40 pm

Re: returned an invaled return code 255

Post by jolson »

What exactly are you trying to check? Is this an NRPE check to see whether or not the logstash service is running - or is this an alert threshold check that you set up through the Nagios Log Server monitoring wizard?
Twits Blog
Show me a man who lives alone and has a perpetually clean kitchen, and 8 times out of 9 I'll show you a man with detestable spiritual qualities.
ariarlet
Posts: 61
Joined: Wed Apr 22, 2015 11:04 am

Re: returned an invaled return code 255

Post by ariarlet »

I'm checking error logs remotely.
jolson
Attack Rabbit
Posts: 2560
Joined: Thu Feb 12, 2015 12:40 pm

Re: returned an invaled return code 255

Post by jolson »

What command are you using to check these error logs?

Are you using Nagios Core or Nagios XI?
Twits Blog
Show me a man who lives alone and has a perpetually clean kitchen, and 8 times out of 9 I'll show you a man with detestable spiritual qualities.
ariarlet
Posts: 61
Joined: Wed Apr 22, 2015 11:04 am

Re: returned an invaled return code 255

Post by ariarlet »

yes the error logs


but the others servers this run while in other servers not run
User avatar
tgriep
Madmin
Posts: 9177
Joined: Thu Oct 30, 2014 9:02 am

Re: returned an invaled return code 255

Post by tgriep »

Could you post how the command is run on a server that passes and on the one that fails?
Be sure to check out our Knowledgebase for helpful articles and solutions!
ariarlet
Posts: 61
Joined: Wed Apr 22, 2015 11:04 am

Re: returned an invaled return code 255

Post by ariarlet »

In console nagios
./check_nrpe -H [HOST] -p 5666 -c check_log3

result:
The command (check_log3) returned and invalid return code:255


nsclient.ini:
check_log3 = [PATH]\check_log3.pl -p "unable to extend table by" -l [Path]prueba.log -c 1
jolson
Attack Rabbit
Posts: 2560
Joined: Thu Feb 12, 2015 12:40 pm

Re: returned an invaled return code 255

Post by jolson »

What you should do here is open NSClient in test mode and re-run the check_nrpe command.

To start NSClient in test mode, you will need to stop it first. How to do so will depend on the version of NSClient installed. For the newest version:

Code: Select all

*start command prompt as admin*
cd [PATH TO NSClient]
net stop nscp
nscp.exe test
When testing mode has been initialized, run your check_nrpe command from Nagios:

Code: Select all

./check_nrpe -H [HOST] -p 5666 -c check_log3
Do you see any errors?
Twits Blog
Show me a man who lives alone and has a perpetually clean kitchen, and 8 times out of 9 I'll show you a man with detestable spiritual qualities.
ariarlet
Posts: 61
Joined: Wed Apr 22, 2015 11:04 am

Re: returned an invaled return code 255

Post by ariarlet »

If i run server local


the result is:

D:\Strawberry\perl\bin>.\perl.exe check_log3.pl -p "unable to extend table by" -l D:\oracle\product\10.2.0\admin\ENETVAE\bdump\alert_enetvae.log -c 1
Use of :unique is deprecated at D:\oracle\product\10.2.0\db_1\perl\5.8.3\lib/MSWin32-x86-multi-thread/Config.pm line 39.
Use of :unique is deprecated at D:\oracle\product\10.2.0\db_1\perl\5.8.3\lib/MSWin32-x86-multi-thread/Config.pm line 80.
Perl lib version (v5.8.3) doesn't match executable version (v5.16.0) at D:\oracle\product\10.2.0\db_1\perl\5.8.3\lib/MSWin32-x86-multi-thread/Config.pm line 32.
Compilation failed in require at D:\oracle\product\10.2.0\db_1\perl\5.8.3\lib/MSWin32-x86-multi-thread/lib.pm line 6.
BEGIN failed--compilation aborted at D:\oracle\product\10.2.0\db_1\perl\5.8.3\lib/MSWin32-x86-multi-thread/lib.pm line 6.
Compilation failed in require at check_log3.pl line 240.
BEGIN failed--compilation aborted at check_log3.pl line 240.
jolson
Attack Rabbit
Posts: 2560
Joined: Thu Feb 12, 2015 12:40 pm

Re: returned an invaled return code 255

Post by jolson »

Please see the following thread: http://community.activestate.com/forum/ ... ility-perl
Oracle 10g ships with it's own Perl. When you install Oracle, it sets PERL5LIB to point at the Oracle Perl. This will result in ActivePerl attempting to run modules from the Oracle lib directory. Perl 5.12 and Perl 5.8 are binary incompatible.
By the looks of it, Oracle's perl is throwing the exception you see. I recommend attempting the fix described in the above link.
Twits Blog
Show me a man who lives alone and has a perpetually clean kitchen, and 8 times out of 9 I'll show you a man with detestable spiritual qualities.
Locked