Notification on OK-state

Israel Brewster israel at frontierflying.com
Thu Feb 12 20:26:11 CET 2009


On Feb 12, 2009, at 7:05 AM, sri.lumpa at free.fr wrote:

> There is still a small  problem though... With that method, every  
> service with obsess_over_service enabled will execute the command,  
> and every command defined as ocsp_command in nagios.cfg will be  
> executed by services enabling obsess_over_service :s.
>
> Well... don't know if ther is a better way and it works so I keep it  
> for now...

Well, since you are writing the OCSP command script, you should be  
able to have the script itself "Filter" for hosts you want, i.e if  
$HOSTNAME$=hostA or hostB, etc then run script, otherwise, do nothing.  
Course, that isn't exactly how you do it, as I don't know off the top  
of my head how you pass the hostname to the script (although I'm sure  
you can), and that is not valid code anyway, but hopefully you get the  
idea. On the other hand, that might be more trouble than it is worth :)
-----------------------------------------------
Israel Brewster
Computer Support Technician
Frontier Flying Service Inc.
5245 Airport Industrial Rd
Fairbanks, AK 99709
(907) 450-7250 x293
-----------------------------------------------

>
>
> ----- Mail Original -----
> De: "Marc Powell" <marc at ena.com>
> À: "Nagios Users" <nagios-users at lists.sourceforge.net>
> Envoyé: Jeudi 12 Février 2009 16:51:14 GMT +01:00 Amsterdam /  
> Berlin / Berne / Rome / Stockholm / Vienne
> Objet: Re: [Nagios-users] Notification on OK-state
>
>
> On Feb 12, 2009, at 8:45 AM, sri.lumpa at free.fr wrote:
>
>> Thank you very much for the lead. It helped me a lot and.
>>
>> I followed your advice and I used the ocsp_command directive from
>> the nagios.cfg with a script printing into the file nagios.cmd the
>> external command SEND_CUSTOM_SVC_NOTIFICATION and it works fine now.
>
> ... and that is an interesting trick as well ;) I wouldn't have
> thought to send the notification that way.
>
> --
> Marc
>
>
> ------------------------------------------------------------------------------
> _______________________________________________
> 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
>
> ------------------------------------------------------------------------------
> _______________________________________________
> 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


------------------------------------------------------------------------------
_______________________________________________
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