Timeout while attempting connection

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
agutierrezps
Posts: 7
Joined: Tue Jul 30, 2013 5:12 pm

Timeout while attempting connection

Post by agutierrezps »

Hello everyone,

I been kinda stressed these last weeks due to some Nagios Issues.

You see. I have been recieving this "Timeout while attempting connection" or "Service check timed out after 240.01 seconds". As you may see i have set the timeout to 240 (nagios.cfg, nrpe.cfg, command.cfg "check_nrpe command") but i still get these frustating errors.

Any idea what could be happening ???

My nagios version is 4.0.8 and nrpe is 2.7.


Regards.
tmcdonald
Posts: 9117
Joined: Mon Sep 23, 2013 8:40 am

Re: Timeout while attempting connection

Post by tmcdonald »

Can you post the relevant service and command definitions for the services that are receiving these errors? And have you checked the standard things like firewall being open, able to ping the device, etc?
Former Nagios employee
agutierrezps
Posts: 7
Joined: Tue Jul 30, 2013 5:12 pm

Re: Timeout while attempting connection

Post by agutierrezps »

Hello,

This is my service definition, i use it for all my alarms definition.

define service{
host_name Test1
service_description Test1
check_period 24x7
check_command check_nrpe3!check_test
notification_period 24x7
normal_check_interval 15
retry_check_interval 5
max_check_attempts 3
notification_options w,c,r,u
notification_interval 0
}


and this is the command definition

define command{
command_name check_nrpe3
command_line $USER/check_nrpe -H $HOSTADDRESS$ -c $ARG1$ -p 5666 -t 240
}


Regards.
User avatar
Box293
Too Basu
Posts: 5126
Joined: Sun Feb 07, 2010 10:55 pm
Location: Deniliquin, Australia
Contact:

Re: Timeout while attempting connection

Post by Box293 »

Can you show us your nrpe.cfg file that has the check_test command defined.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
agutierrezps
Posts: 7
Joined: Tue Jul 30, 2013 5:12 pm

Re: Timeout while attempting connection

Post by agutierrezps »

Hello,

Here it is:

command_timeout=240

command[check_test]=/home/agutierrezps/test.sh
User avatar
Box293
Too Basu
Posts: 5126
Joined: Sun Feb 07, 2010 10:55 pm
Location: Deniliquin, Australia
Contact:

Re: Timeout while attempting connection

Post by Box293 »

So what is this /home/agutierrezps/test.sh script doing actually?

What happens on the remote server when you run it as Nagios?

Code: Select all

su nagios
/home/agutierrezps/test.sh
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Locked