Immediate Check of service?

Mike Koponick mkoponick at redhawk.info
Wed Feb 8 22:47:46 CET 2006


Bob,

Thanks for the check_stale script. I was wondering why it would force an
immediate check more than anything else. From what I understand from
your e-mail and some other reading, it will force a check because of the
type of check command that is being used in my services.cfg. If I
replace say, check_ping with check_stale, it won't try to PING the host,
but rather send this nice (or not so nice) notification that it has not
heard anything for "x" amount of time.

I assume however that if something is wrong, say a node is down or ?? I
will receive a notification that the host is down or ???

OK, if I have that straight, maybe life is better.

Thanks!

Mike

-----Original Message-----
From: Sloane, Robert Raymond [mailto:sloane at ku.edu] 
Sent: Wednesday, February 08, 2006 12:22 PM
To: Mike Koponick
Subject: RE: [Nagios-users] Immediate Check of service?

> I don't mind that fact that it comes up "stale", but why 
> force an immediate check of the service? Is there a way to 
> turn this office since I'm in "Passive Mode" anyway?

The theory is that if you don't receive any passive data from the
service, then there is a problem, and your "active check" is actually
just a script that will inform you of the problem.  If you don't want to
be notified when nothing is received for a while, then turn off
freshness checking. Otherwise use something like:

checkcommands.cfg:

define command {
command_name    check_stale
command_line    $USER1$/check_stale $SERVICEDESC$ $HOSTNAME$
}

check_stale script:

#!/bin/sh

echo "Service $1 on Host $2 has not reported its status"
exit 2

and then use check_stale as the check_command for the passive service.
-- 
Bob Sloane, University of Kansas Computer Center, Lawrence, KS, 66045
Email:sloane at ku.edu http://www.ku.edu/home/sloane Phone:(785)864-0444
 

> -----Original Message-----
> From: nagios-users-admin at lists.sourceforge.net 
> [mailto:nagios-users-admin at lists.sourceforge.net] On Behalf 
> Of Mike Koponick
> Sent: Wednesday, February 08, 2006 12:08 PM
> To: nagios-users at lists.sourceforge.net
> Subject: [Nagios-users] Immediate Check of service?
> 
> 
> Hello All,
> 
> I think this subject has been around the block a few times, 
> but I'm still confused.
> 
> I have a distributed model working in a "lab" environment but 
> I see the following message on the Central Server.
> 
> "nagios: Warning: The results of service 'check_ping' on host 
> 'Company-A-Switch-21' are stale by 60 seconds (threshold=420 
> seconds). I'm forcing an immediate check of the service."
> 
> 
> I currently am only using service checks, since (I think) it 
> make sense for the environment that I will be using the 
> distributed model. Host checks are disabled.
> 
> 
> The situation would be that the Central Server does not have 
> direct access to the remote network, but only receives data 
> from each remote sensor. 
> 
> Thanks in advance,
> 
> Mike
> 
> 
> 
> 
> Here is a snippet from my services configuration from the Central
> Server:
> 
> ##############################################################
> ##########
> ####
> 
> define  service {
>         host_name                       Company-A-Switch-21
>         service_description             check_ping
>         is_volatile                     1
>         check_command                   check-host-alive
>         max_check_attempts              1
>         normal_check_interval           2
>         retry_check_interval            1
>         active_checks_enabled           0
>         passive_checks_enabled          1
>         check_period                    24x7
>         parallelize_check               1
>         obsess_over_service             1
>         check_freshness                 1
>         freshness_threshold             420
>         event_handler_enabled           1
>         low_flap_threshold              0
>         high_flap_threshold             0
>         flap_detection_enabled          1
>         process_perf_data               1
>         retain_status_information       1
>         retain_nonstatus_information    1
>         contact_groups                  Support
>         notification_interval           0
>         notification_period             24x7
>         notification_options            w,u,c,r
>         notifications_enabled           1
>         register                        1
>         }
> 
> ##############################################################
> ##########
> ####
> 
> Here is a snippet from my services configuration from the 
> remote sensor:
> 
> ##############################################################
> ##########
> ####
> 
> define  service {
>         host_name                       Company-A-Switch-21
>         service_description             check_ping
>         is_volatile                     0
>         check_command                   check_ping!100.0,20%!500.0,60%
>         max_check_attempts              2
>         normal_check_interval           2
>         retry_check_interval            1
>         active_checks_enabled           1
>         passive_checks_enabled          0
>         check_period                    24x7
>         parallelize_check               0
>         obsess_over_service             1
>         check_freshness                 0
>         event_handler_enabled           0
>         flap_detection_enabled          1
>         process_perf_data               0
>         retain_status_information       1
>         retain_nonstatus_information    1
>         contact_groups                  Support
>         notification_interval           99
>         notification_period             24x7
>         notification_options            w,u,c,r,f
>         notifications_enabled           0
>         register                        1
>         }
> 
> ##############################################################
> ##########
> ####
> 
> 
> -------------------------------------------------------
> This SF.net email is sponsored by: Splunk Inc. Do you grep 
> through log files for problems?  Stop!  Download the new AJAX 
> search engine that makes searching your log files as easy as 
> surfing the  web.  DOWNLOAD SPLUNK! 
> http://sel.as-us.falkag.net/sel?cmd=k&kid3432&bid#0486&dat1642
> _______________________________________________
> 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: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid3432&bid#0486&dat1642
_______________________________________________
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