Notifiactions question

Arno Lehmann al at its-lehmann.de
Wed Jul 23 11:53:39 CEST 2008


Hello,

23.07.2008 11:20, Marc Torres wrote:
> Hi all,
> 
> I'm quite newbe to nagios, and I'm trying to configure notifications
> for services according to host contacts. I mean, I would like to
> configure contacts (or contact groups) only in the hosts definitions,
> and then when a monitorized service at that host has a hard state
> change, the notification gets send to the contact configured at the
> host definition.

You could do this with custom variables.

You set the data you need for the notifications in the host as, for 
example,

_NOTIFICATIONMAIL

and create a new notification script that uses this address (if 
defined) instead of the default supplied by the Nagios configuration.

Arno

> My problem is that I've got one hostgroup which has all hosts related
> to it.  The services are configured for that hostgroup (all the hosts
> run the same services), this way I'm monitoring the same services in
> all hosts. But according to [1], I've to configure a contact or a
> contactgroup at least for the service, and here comes my problem.
> 
> I would like not to share the same contacts for the same service in
> the different hosts, I would like to configure different contacts for
> the same service in different hosts. The contact should be the same
> configured in the host definition, so my question is if its possible
> to configure nagios to send service notification at destinations
> configured at hosts definition instead of service definition.
> 
> I've read almost all the docs from [2]. But I didn't found a easy way
> to achieve it. The only solution that comes to my mind is to create a
> template for each service and then create a service for each host that
>  inherits from the template and has the same contact of the host, but
> this is hard to achieve as I may have hundreds of hosts.
> 
> Cheers,
> 
> Marc.
> 
> [1]  http://nagios.sourceforge.net/docs/3_0/objectdefinitions.html#service
> [2]  http://nagios.sourceforge.net/docs/3_0/toc.html

-- 
Arno Lehmann
IT-Service Lehmann
www.its-lehmann.de

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