returned an invaled return code 255

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
jolson
Attack Rabbit
Posts: 2560
Joined: Thu Feb 12, 2015 12:40 pm

Re: returned an invaled return code 255

Post by jolson »

You're right - it is odd that it's working locally but not remotely. Have you tried restarting NSClient already?

Please open services.msc and find NSClient++ - restart the service and re-try the check from Nagios.
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 »

ooooh great now this run :D
but now you need another server than not read
jolson
Attack Rabbit
Posts: 2560
Joined: Thu Feb 12, 2015 12:40 pm

Re: returned an invaled return code 255

Post by jolson »

but now you need another server than not read
Could you please rephrase this sentence? I am not sure what you mean.
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 »

Now I have no servers that instead reads the logs locally if
jolson
Attack Rabbit
Posts: 2560
Joined: Thu Feb 12, 2015 12:40 pm

Re: returned an invaled return code 255

Post by jolson »

Do you have a server that reads logs remotely instead of locally - or something similar?

I'm still not 100% clear on what you're asking.
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 server have got logs.

Local this program is running but remot not run.

And the other server remot not run, this error is:

Code: Select all

COMMAND: /usr/local/nagios/libexec/check_nrpe -H [SERVER] -p 5666 -c check_log3 -t 30  -a -p "unable" -l "D:/alert_enetvae.log" -c 1 
OUTPUT: Plug-in error: time out after 15 seconds
Sorry my english is bad.
jolson
Attack Rabbit
Posts: 2560
Joined: Thu Feb 12, 2015 12:40 pm

Re: returned an invaled return code 255

Post by jolson »

Let's try giving your command a longer timeout:

Code: Select all

/usr/local/nagios/libexec/check_nrpe -H 10.82.4.115 -p 5666 -c check_log3 -t 30  -a -p "unable" -l "D:/alert_enetvae.log" -t 45 -c 1 
How does that work for you?
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 »

then not read the second -t but i write

Code: Select all

COMMAND: /usr/local/nagios/libexec/check_nrpe -H [HOST] -p 5666 -c check_log3 -t 30 -a -p "unable" -l "D:/alert_enetvae.log" -a -t 45 -a -c 1  
OUTPUT: Cannot read $ARG2$
jolson
Attack Rabbit
Posts: 2560
Joined: Thu Feb 12, 2015 12:40 pm

Re: returned an invaled return code 255

Post by jolson »

Sorry - I missed that you already had a timeout added. Here, try the following:

Code: Select all

/usr/local/nagios/libexec/check_nrpe -H [HOST] -p 5666 -c check_log3 -t 30 -a -p "unable" -l "D:/alert_enetvae.log" -a --no-timeout -a -c 1
This plugin will set an internal time-out alarm based on the $TIMEOUT
setting found in utils.pm. You can use the --no-timeout option to disable
this.
http://exchange.nagios.org/directory/Pl ... pl/details
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 »

thanks

but then this not read arg2 = D:/alert_enetvae.log but in server there are logs. And the other server i haver got same problem, local the program run good

Code: Select all

OUTPUT: Cannot read $ARG2$
Locked