Re: [Nagios-users] Active and Passive checks of the same service

2008-08-23 Thread Taylor Dondich
That's exactly what I described.  Altho the docs don't describe
toggling active checks on/off, which is the requirement here.  You can
still do the same using the external commands process.

Taylor

On Sat, Aug 23, 2008 at 12:16 AM, Thomas Guyot-Sionnest <[EMAIL PROTECTED]> 
wrote:
> -BEGIN PGP SIGNED MESSAGE-
> Hash: SHA1
>
> On 22/08/08 03:45 PM, Taylor Dondich wrote:
>> So a nice round-about way of doing it would be to disable active
>> checks on the service initially.  Then when your passive check script
>> detects a problem, not only does it send nagios a passive check
>> RESULT, but it also sends a command to enable active checks on that
>> service.  Then your active check script, when it determines the
>> problem has resolved itself, could also send nagios itself a command
>> to disable active checks on that service.  Fun way to do it.
>>
>> Information on the commands you need, their description, and sample
>> shell scripts which execute them, are at:
>>
>> http://www.nagios.org/developerinfo/externalcommands/commandlist.php
>>
>
> I would rather implement the "adaptive monitoring" part using
> eventhandlers. I there's even a section in Nagios doc about adaptive
> monitoring.
>
> Don't miss the list of external commands neither; they're available here:
> http://www.nagios.org/developerinfo/externalcommands/
>
> Some of them are very useful for altering the monitoring logic.
>
> - --
> Thomas
> -BEGIN PGP SIGNATURE-
> Version: GnuPG v1.4.6 (GNU/Linux)
> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
>
> iD8DBQFIr7kw6dZ+Kt5BchYRAhW0AJ4iIj/mYdtG1m9wYAHwcjyNRK5+pgCg+Yva
> d3+4EueprfHxB84t7qXtovY=
> =KAlq
> -END PGP SIGNATURE-
>



-- 
Taylor
Check out my Shortcut with O'Reilly Press:
Network Monitoring with Nagios:
http://oreilly.com/catalog/9780596528195/index.html

-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
___
Nagios-users mailing list
Nagios-users@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


Re: [Nagios-users] Active and Passive checks of the same service

2008-08-23 Thread Thomas Guyot-Sionnest
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On 22/08/08 03:45 PM, Taylor Dondich wrote:
> So a nice round-about way of doing it would be to disable active
> checks on the service initially.  Then when your passive check script
> detects a problem, not only does it send nagios a passive check
> RESULT, but it also sends a command to enable active checks on that
> service.  Then your active check script, when it determines the
> problem has resolved itself, could also send nagios itself a command
> to disable active checks on that service.  Fun way to do it.
> 
> Information on the commands you need, their description, and sample
> shell scripts which execute them, are at:
> 
> http://www.nagios.org/developerinfo/externalcommands/commandlist.php
> 

I would rather implement the "adaptive monitoring" part using
eventhandlers. I there's even a section in Nagios doc about adaptive
monitoring.

Don't miss the list of external commands neither; they're available here:
http://www.nagios.org/developerinfo/externalcommands/

Some of them are very useful for altering the monitoring logic.

- --
Thomas
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFIr7kw6dZ+Kt5BchYRAhW0AJ4iIj/mYdtG1m9wYAHwcjyNRK5+pgCg+Yva
d3+4EueprfHxB84t7qXtovY=
=KAlq
-END PGP SIGNATURE-

-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
___
Nagios-users mailing list
Nagios-users@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


Re: [Nagios-users] Active and Passive checks of the same service

2008-08-22 Thread Taylor Dondich
For this functionality, to make it easier, you may want to make
wrapper scripts which do the actual command sending to nagios, but a
command parameter to that script could be the actual check command to
run (the script), along with any other command parameters.  That way
you're not writing duplicate scripts for all your plugins.

-- 
Taylor
Check out my Shortcut with O'Reilly Press:
Network Monitoring with Nagios:
http://oreilly.com/catalog/9780596528195/index.html

On Fri, Aug 22, 2008 at 1:00 PM, Douglas K. Rand
<[EMAIL PROTECTED]> wrote:
> Taylor> So a nice round-about way of doing it would be to disable
> Taylor> active checks on the service initially.  Then when your
> Taylor> passive check script detects a problem, not only does it send
> Taylor> nagios a passive check RESULT, but it also sends a command to
> Taylor> enable active checks on that service.  Then your active check
> Taylor> script, when it determines the problem has resolved itself,
> Taylor> could also send nagios itself a command to disable active
> Taylor> checks on that service.  Fun way to do it.
>
> "Fun"  Clearly a word with many meanings.  :)
>
> Thanks for the tip, I never considered that approach. I'll give it a
> shot.
>

-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
___
Nagios-users mailing list
Nagios-users@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


Re: [Nagios-users] Active and Passive checks of the same service

2008-08-22 Thread Douglas K. Rand
Taylor> So a nice round-about way of doing it would be to disable
Taylor> active checks on the service initially.  Then when your
Taylor> passive check script detects a problem, not only does it send
Taylor> nagios a passive check RESULT, but it also sends a command to
Taylor> enable active checks on that service.  Then your active check
Taylor> script, when it determines the problem has resolved itself,
Taylor> could also send nagios itself a command to disable active
Taylor> checks on that service.  Fun way to do it.

"Fun"  Clearly a word with many meanings.  :)

Thanks for the tip, I never considered that approach. I'll give it a
shot.

-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
___
Nagios-users mailing list
Nagios-users@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


Re: [Nagios-users] Active and Passive checks of the same service

2008-08-22 Thread Taylor Dondich
So a nice round-about way of doing it would be to disable active
checks on the service initially.  Then when your passive check script
detects a problem, not only does it send nagios a passive check
RESULT, but it also sends a command to enable active checks on that
service.  Then your active check script, when it determines the
problem has resolved itself, could also send nagios itself a command
to disable active checks on that service.  Fun way to do it.

Information on the commands you need, their description, and sample
shell scripts which execute them, are at:

http://www.nagios.org/developerinfo/externalcommands/commandlist.php

-- 
Taylor
Check out my Shortcut with O'Reilly Press:
Network Monitoring with Nagios:
http://oreilly.com/catalog/9780596528195/index.html



On Fri, Aug 22, 2008 at 12:07 PM, Douglas K. Rand
<[EMAIL PROTECTED]> wrote:
> I'm trying to find a way to have a passive check of a service suffice
> as an active check of the same service. We are using Nagios 2.9.
>
> We have lots of filesystems we check via SNMP for both block and inode
> usage, and doing active checks for all of these overwhelms our
> server. So we run via cron a single process that goes and checks all
> these filesystems and submits them results via passive checks to
> Nagios. All this works fine.
>
> But what I'd like to do is if the passive check results in a problem
> that that'd kick the service into a SOFT problem state and then Nagios
> would re-check the service much more frequently (say every minute) up
> until max_check_attempts.
>
> My problem is that I can't seem to persuade Nagios to alter the
> scheduling of the active checks when passive checks come in. I'd like
> to have normal_check_interval set to 10 minutes, retry_check_interval
> set to 1, and have my cron that generates passive checks run every 5
> minutes. So that when everything is OK the passive checks take care of
> all the work and Nagios never fires off an active check unless the
> passive check results in a non-OK state, or the passive check fails
> for some reason.
>
> But regardless of how many passive check results are seen by the
> server, it always keeps scheduling and firing off those active checks
> regardless.
>
> -
> This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
> Build the coolest Linux based applications with Moblin SDK & win great prizes
> Grand prize is a trip for two to an Open Source event anywhere in the world
> http://moblin-contest.org/redirect.php?banner_id=100&url=/
> ___
> Nagios-users mailing list
> Nagios-users@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 the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
___
Nagios-users mailing list
Nagios-users@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


[Nagios-users] Active and Passive checks of the same service

2008-08-22 Thread Douglas K. Rand
I'm trying to find a way to have a passive check of a service suffice
as an active check of the same service. We are using Nagios 2.9.

We have lots of filesystems we check via SNMP for both block and inode
usage, and doing active checks for all of these overwhelms our
server. So we run via cron a single process that goes and checks all
these filesystems and submits them results via passive checks to
Nagios. All this works fine.

But what I'd like to do is if the passive check results in a problem
that that'd kick the service into a SOFT problem state and then Nagios
would re-check the service much more frequently (say every minute) up
until max_check_attempts.

My problem is that I can't seem to persuade Nagios to alter the
scheduling of the active checks when passive checks come in. I'd like
to have normal_check_interval set to 10 minutes, retry_check_interval
set to 1, and have my cron that generates passive checks run every 5
minutes. So that when everything is OK the passive checks take care of
all the work and Nagios never fires off an active check unless the
passive check results in a non-OK state, or the passive check fails
for some reason.

But regardless of how many passive check results are seen by the
server, it always keeps scheduling and firing off those active checks
regardless. 

-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
___
Nagios-users mailing list
Nagios-users@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