Hi,<br><br>Thanks all. The following works best:<br><br>define service {<br>       ....<br>       check_freshness                 1<br>
        freshness_threshold             300<br>
        check_command                  check_dummy<br>}<br><br>define command{<br>        command_name check_dummy<br>        command_line $USER1$/check_dummy 2 "Stale data: The server has not responded."<br>}<br>
<br><br>
<br><div class="gmail_quote">On Fri, Jan 8, 2010 at 4:30 PM, Getchell, Kristoffer M <span dir="ltr"><<a href="mailto:K.Getchell@kingston.ac.uk">K.Getchell@kingston.ac.uk</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div class="im">Hi<br>
<br>
Could you enable freshness checking and set the check command to something that sets the status to critical (for example you could write an external command into the external command queue)?  So long as passive results were received within the freshness threshold, the check command won't be executed, so the status you see will be what is reported by the passive check result.  If no passive check results are received you will then be notified of a critical situation as the freshness check command would then be executed and return a critical alert.<br>

<br>
To this end, I would redefine your passive service command as follows:<br>
<br>
</div><div class="im">define service {<br>
        use                             passive_service<br>
      service_description                 HW Sensors<br>
      hostgroup_name                  hgp_webservers, hgp_db, hgp_search, hgp_image<br>
      check_command                   check_dummy<br>
      active_checks_enabled           0<br>
      passive_checks_enabled          1<br>
</div>        check_freshness                 1<br>
<div class="im">        freshness_threshold               300<br>
        check_command                   issue_critical_alert    ; this command is run only if the service results are "stale"<br>
}<br>
<br>
Kind regards,<br>
<br>
<br>
<br>
<br>
Kris<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
</div><div class="im">From: Pankaj [mailto:<a href="mailto:penguinhead@gmail.com">penguinhead@gmail.com</a>]<br>
Sent: 08 January 2010 07:30<br>
To: Nagios Mailinglist<br>
Subject: [Nagios-users] non sticky passive checks<br>
<br>
</div><div><div></div><div class="h5">Hi,<br>
<br>
I've configured passive service checks and am reporting back the results using nsca. I would like to turn the alerts to be critical after 5 minutes if the monitored servers fail to send any results. Currently the check continues to remain in the last state. How can I achieve this?<br>

<br>
>>>>>>>>>>> service_common.cfg<br>
 define service{<br>
                use                    generic_service<br>
                name                   passive_service<br>
                active_checks_enabled  0<br>
                passive_checks_enabled 1                               <br>
                flap_detection_enabled 0<br>
                register               0                               <br>
                is_volatile            0<br>
                check_period           24x7<br>
                max_check_attempts     1<br>
                normal_check_interval  5<br>
                retry_check_interval   1<br>
                check_freshness        0<br>
                contact_groups         admins <br>
                check_command          check_dummy!0<br>
                notification_interval  120<br>
                notification_period    24x7<br>
                notification_options   w,u,c,r<br>
                stalking_options       w,c,u<br>
}<br>
<br>
define service {<br>
                use                             passive_service<br>
                service_description       HW Sensors<br>
                hostgroup_name                  hgp_webservers, hgp_db, hgp_search, hgp_image<br>
                check_command                   check_dummy<br>
                active_checks_enabled           0<br>
                passive_checks_enabled          1<br>
}<br>
<br>
define command{<br>
        command_name check_dummy<br>
        command_line $USER1$/check_dummy $ARG1$<br>
}<br>
<br>
<br>
--<br>
( 2b || ! 2b )<br>
<br>
</div></div><div class="im">This email has been scanned for all viruses by the MessageLabs Email<br>
Security System.<br>
<br>
This email has been scanned for all viruses by the MessageLabs Email<br>
Security System.<br>
<br>
</div><div><div></div><div class="h5">------------------------------------------------------------------------------<br>
This SF.Net email is sponsored by the Verizon Developer Community<br>
Take advantage of Verizon's best-in-class app development support<br>
A streamlined, 14 day to market process makes app distribution fast and easy<br>
Join now and get one step closer to millions of Verizon customers<br>
<a href="http://p.sf.net/sfu/verizon-dev2dev" target="_blank">http://p.sf.net/sfu/verizon-dev2dev</a><br>
_______________________________________________<br>
Nagios-users mailing list<br>
<a href="mailto:Nagios-users@lists.sourceforge.net">Nagios-users@lists.sourceforge.net</a><br>
<a href="https://lists.sourceforge.net/lists/listinfo/nagios-users" target="_blank">https://lists.sourceforge.net/lists/listinfo/nagios-users</a><br>
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue.<br>
::: Messages without supporting info will risk being sent to /dev/null<br>
</div></div></blockquote></div><br><br clear="all"><br>-- <br>( 2b || ! 2b )<br>