RV: SAME PROBLEM !!! check_tcp works from CLI, not in nagios

Gramajo, Gabriel gramajo at saman.com.uy
Fri May 7 20:12:58 CEST 2004


 
SAMAN Casa Central 
Rambla Dr. Baltasar Brum 2772 
11800 Montevideo, Uruguay 
Tel: (+598-2) 208 1421* 
Fax: (+598-2) 203 4087 
Web: www.saman.com.uy 
  

I´ve the same problem.  And nagios apparently seems to be scheduling check commands but don´t do anything at all.  What could be going wrong ?

A/P Gabriel Gramajo
SAMAN Computación
Montevideo - Uruguay
Dir.:  Rbla. Baltasar Brum 2772
Tel.:  2081421 / 232
E-Mail:  gramajo at saman.com.uy
 
"Es propio de hombres de cabezas medianas embestir contra todo aquello que no les cabe en la cabeza." - Antonio Machado



-----Mensaje original-----
De: nagios-users-admin at lists.sourceforge.net [mailto:nagios-users-admin at lists.sourceforge.net] En nombre de Marc Powell Enviado el: Viernes, 07 de Mayo de 2004 12:27 p.m.
Para: Anthony Lieuallen; nagios-users at lists.sourceforge.net
Asunto: RE: [Nagios-users] check_tcp works from CLI, not in nagios


Anthony Lieuallen <mailto:Anthony at PromoHut.com> wrote:
> Excerpts from services.cfg, checkcommands.cfg, the CLI, and the nagios
> page below. I have numerous services (check_ dns, tcp, smtp, ping) all 
> set up and working, except this particular tcp (_telnet) check fails, 
> but works from the command line.
> I'm stumped.
> 
> define service {
>         host_name               XXXHOSTNAMEHEREXXX
>         service_description     telnet
>         check_command           check_telnet
>         max_check_attempts      4
>         normal_check_interval   12
>         retry_check_interval    1
>         check_period            always
>         notification_interval   0
>         notification_period     always
>         notification_options    w,u,c,r
>         contact_groups          admin
> }
> 
> # 'check_telnet' command definition
> define command{
>         command_name    check_telnet
>         command_line    $USER1$/check_tcp -H $HOSTADDRESS$ -p 23
>         }
> 
> t-bone at 602744 [/usr/local/nagios/etc]# ../libexec/check_tcp -H
> XXXHOSTNAMEHEREXXX -p 23
> TCP OK -   0.031 second response time on port 23|time=  0.031
> 
> Current Status:   CRITICAL  (Has been acknowledged)
> Status Information: Connection refused by host Current Attempt: 4/4
> State Type: HARD Last Check Type: ACTIVE

You do know that Nagios isn't using the host_name but rather the host_address as it appears in the host definition when executing the service check, right? Have you tried using that and running check_tcp as the nagios user as opposed to root? It seems to me that there is a discrepency between those two addresses and the host_address doesn't have anything listening on port 23.

--
MArc


-------------------------------------------------------
This SF.Net email is sponsored by Sleepycat Software
Learn developer strategies Cisco, Motorola, Ericsson & Lucent use to deliver higher performing products faster, at low TCO. http://www.sleepycat.com/telcomwpreg.php?From=dnemail3
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null 
  
  


-------------------------------------------------------
This SF.Net email is sponsored by Sleepycat Software
Learn developer strategies Cisco, Motorola, Ericsson & Lucent use to deliver
higher performing products faster, at low TCO.
http://www.sleepycat.com/telcomwpreg.php?From=osdnemail3
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null





More information about the Users mailing list