<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
  </head>
  <body text="#000000" bgcolor="#ffffff">
    Hi,<br>
    Can anyoune help me understand what is wrong with those definitions?
    Please.<br>
    <br>
    <br>
    <pre class="moz-signature" cols="72">
 
</pre>
    <br>
    On 10/31/2011 10:33 AM, Cosmin Neagu wrote:
    <blockquote cite="mid:4EAE5D59.9090107@omnilogic.ro" type="cite">
      <meta content="text/html; charset=ISO-8859-1"
        http-equiv="Content-Type">
      Actually, i have another one in the same situation, when executed
      manualy, it is working:<br>
      <br>
      <i>nagios@mon2:/usr/local/nagios/libexec$ ./check_catalyst_mem.pl
        -s 172.31.0.100 -C xxx -w 30 -c 20<br>
        OK:  I/O: valid, Used: 25189592B Free: 41919272B (62%)!
        Processor: valid, Used: 114067808B Free: 801243696B
        (87%)!|WARING <= 30%, CRITICAL <= 20%</i><br>
      <br>
      But, when i define a service for it, it does not do the checking
      corectly: Status Critical and null status information:<br>
      <br>
      <br>
      <i>define command {<br>
                command_name check_catalyst_mem<br>
                command_line $USER1$/check_catalyst_mem.pl -s
        $HOSTADDRESS$ $ARG1$<br>
        }<br>
        <br>
        define service {<br>
                use                     generic-service<br>
                host_name               VSS6509<br>
                service_description     Memory<br>
                check_command           check_catalyst_mem!-C xxx -w 30
        -c 20<br>
        }</i><br>
      <br>
      What's wrong with this definitions and why nagios does not check
      corect?<br>
      <br>
      <br>
      <pre class="moz-signature" cols="72"> Cosmin Neagu

</pre>
      <br>
      On 10/31/2011 10:22 AM, Cosmin Neagu wrote:
      <blockquote cite="mid:4EAE5AA9.2070300@omnilogic.ro" type="cite">
        <meta http-equiv="content-type" content="text/html;
          charset=ISO-8859-1">
        Hello,<br>
        I'm trying to monitor bgp session, and i came upon the following
        script check_bgp.<br>
        When i run it manually, it checks the bgp session OK:<br>
        <br>
        <i>nagios@mon2:/usr/local/nagios/libexec$ ./check_bgp.pl -H
          X.X.X.X -C xxx -p Y.Y.Y.Y<br>
          OK - Y.Y.Y.Y (AS12345) state is established(6). Established
          for 69d9h34m43s. Last error "Hold Timer Expired".<br>
        </i><br>
        <br>
        But, when i define the command, and add a service for it, it
        does not work. In nagios, i get CRITICAL status and <i>null</i>
        Status information.<br>
        Using nagios 3.2.3<br>
        <br>
        <br>
        <br>
        <br>
        <i>define command {<br>
                  command_name check_bgp<br>
                  command_line $USER1$/check_bgp.pl -H $HOSTADDRESS$
          $ARG1$<br>
          }</i><br>
        <i>define service {<br>
                  use                             generic-service<br>
                  host_name                  EDGE<br>
                  service_description     eBGP to AS12345 <br>
                  check_command           check_bgp!-C abcd -p Y.Y.Y.Y<br>
          }</i><br>
        <br>
        So, what am i doing wrong? I have about 300 diferent services,
        and all checks works fine, this is the first time when a script
        works when invoked manually but not when invoked by nagios.
        Please help.<br>
        <br>
        <br>
        <br>
        <pre class="moz-signature" cols="72">-- 
 Cosmin Neagu

</pre>
      </blockquote>
      <pre wrap="">
<fieldset class="mimeAttachmentHeader"></fieldset>
------------------------------------------------------------------------------
Get your Android app more play: Bring it to the BlackBerry PlayBook 
in minutes. BlackBerry App World&#153; now supports Android&#153; Apps 
for the BlackBerry&reg; PlayBook&#153;. Discover just how easy and simple 
it is! <a class="moz-txt-link-freetext" href="http://p.sf.net/sfu/android-dev2dev">http://p.sf.net/sfu/android-dev2dev</a>
</pre>
      <pre wrap="">
<fieldset class="mimeAttachmentHeader"></fieldset>
_______________________________________________
Nagios-users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Nagios-users@lists.sourceforge.net">Nagios-users@lists.sourceforge.net</a>
<a class="moz-txt-link-freetext" href="https://lists.sourceforge.net/lists/listinfo/nagios-users">https://lists.sourceforge.net/lists/listinfo/nagios-users</a>
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null</pre>
    </blockquote>
  </body>
</html>