<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=ISO-8859-1">
<TITLE>Intelligent way to apply MANY service dependancys?</TITLE>
<META content="MSHTML 6.00.2900.2627" name=GENERATOR></HEAD>
<BODY>
<DIV><SPAN class=537280516-27062005><FONT face=Arial color=#0000ff size=2>I
think you will want to look at 'service cluster monitoring'</FONT></SPAN></DIV>
<DIV><SPAN class=537280516-27062005><FONT face=Arial color=#0000ff
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=537280516-27062005><FONT face=Arial color=#0000ff size=2><A
href="http://nagios.sourceforge.net/docs/2_0/clusters.html">http://nagios.sourceforge.net/docs/2_0/clusters.html</A></FONT></SPAN></DIV>
<DIV><SPAN class=537280516-27062005><FONT face=Arial color=#0000ff
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=537280516-27062005><FONT face=Arial color=#0000ff
size=2></FONT></SPAN> </DIV>
<BLOCKQUOTE>
<DIV class=OutlookMessageHeader dir=ltr align=left><FONT face=Tahoma
size=2>-----Original Message-----<BR><B>From:</B> Ray Ward
[mailto:ray.ward@mapfusion.com]<BR><B>Sent:</B> Friday, June 24, 2005 2:13
PM<BR><B>To:</B> nagios-users@lists.sourceforge.net<BR><B>Subject:</B>
[Nagios-users] Intelligent way to apply MANY service
dependancys?<BR><BR></FONT></DIV><!-- Converted from text/rtf format -->
<P><FONT face=Arial size=2>Hi, I have been using Nagios for a long time but
have just switched to Nagios v2.0b3 and I'm re-working my config files a
little bit. A large portion of my monitoring is done via the NRPE plugins. And
a large portion of the NRPE checks are common across all of the machines. So
my structure is as follows...I have all of the Sun servers in a hostgroup
SUN-Servers, I have definitions for about 8 common NRPE checks that are
assigned to the SUN-Servers hostgroup. So far so good, with very little in the
way of definitions I have 100's of checks defined. Now to my problem, I would
like to define a service dependancy for all NRPE services to be dependant on
one check_nrpe_daemon check. So when the daemon is down I don't receive
multiple alerts for every NRPE check. So I'd like to get the equivalent of
this:</FONT></P>
<P><FONT face=Arial size=2>define servicedependency{</FONT>
<BR> <FONT face=Arial
size=2>dependent_host_name
DBDEV</FONT> <BR> <FONT face=Arial
size=2>dependent_service_description / Root Slice</FONT>
<BR> <FONT face=Arial
size=2>host_name
DBDEV</FONT> <BR> <FONT face=Arial
size=2>service_description
Check NRPE</FONT> <BR> <FONT
face=Arial
size=2>inherits_parent
1</FONT> <BR> <FONT face=Arial
size=2>execution_failure_criteria
o,w,u,c,p</FONT> <BR> <FONT
face=Arial size=2>notification_failure_criteria o,w,u,c,p</FONT>
<BR><FONT face=Arial size=2>}</FONT> </P>
<P><FONT face=Arial size=2>For every common NRPE service for every host in the
SUN-Servers group. Now if I use the SUN-Servers hostgroup in the
servicedependency definition it makes every NRPE service dependant on EVERY
host's NRPE Daemon...this obviously isn't what I want. The best solution I have
to this problem is to NOT send notifications for UNKNOWN service checks for
every NRPE check except the daemon check. But I'd like to know if there's a
better way to apply service dependany's in this situation. Thanks in advance
for any help.</FONT></P>
<P><FONT face=Arial size=2>PS. Below I've included the relevant entries for
one host/NRPE check definitions.</FONT> </P>
<P><FONT face=Arial size=2>Ray,</FONT> </P><BR><BR><BR>
<P><FONT face=Arial size=2>define service {</FONT> <BR><FONT face=Arial
size=2>
use
generic-diskcheck</FONT> <BR><FONT face=Arial
size=2>
hostgroup_name
SUN-Servers</FONT> <BR><FONT face=Arial
size=2>
service_description
Check NRPE</FONT> <BR><FONT face=Arial
size=2>
check_command
check_nrpe_daemon</FONT> <BR><FONT face=Arial size=2>}</FONT> </P>
<P><FONT face=Arial size=2>define service {</FONT> <BR><FONT face=Arial
size=2>
use
generic-diskcheck</FONT> <BR><FONT face=Arial
size=2>
hostgroup_name
SUN-Servers</FONT> <BR><FONT face=Arial
size=2>
service_description
/ Root Slice</FONT> <BR><FONT face=Arial
size=2>
check_command
check_nrpe!check_disk1!</FONT> <BR><FONT face=Arial size=2>}</FONT> </P>
<P><FONT face=Arial size=2>define service{</FONT> <BR><FONT face=Arial
size=2>
name
generic-diskcheck</FONT> <BR><FONT face=Arial
size=2>
use
generic-service</FONT> <BR><FONT face=Arial
size=2>
is_volatile
0</FONT> <BR><FONT face=Arial
size=2>
check_period
24x7</FONT> <BR><FONT face=Arial
size=2>
max_check_attempts
3</FONT> <BR><FONT face=Arial
size=2>
normal_check_interval
10</FONT> <BR><FONT face=Arial
size=2>
retry_check_interval
1</FONT> <BR><FONT face=Arial
size=2>
contact_groups
office-admins</FONT> <BR><FONT face=Arial
size=2>
notification_interval
1440</FONT> <BR><FONT face=Arial
size=2>
notification_period
8x5</FONT> <BR><FONT face=Arial
size=2>
notification_options
w,u,c,r</FONT> <BR><FONT face=Arial
size=2>
register
0</FONT> <BR><FONT face=Arial size=2>}</FONT> </P>
<P><FONT face=Arial size=2>define service{</FONT> <BR><FONT face=Arial
size=2>
name
generic-service</FONT> <BR><FONT face=Arial
size=2>
active_checks_enabled
1</FONT> <BR><FONT face=Arial
size=2>
passive_checks_enabled
1</FONT> <BR><FONT face=Arial
size=2>
parallelize_check
1</FONT> <BR><FONT face=Arial
size=2>
obsess_over_service
1</FONT> <BR><FONT face=Arial
size=2>
check_freshness
0</FONT> <BR><FONT face=Arial
size=2>
notifications_enabled
1</FONT> <BR><FONT face=Arial
size=2>
event_handler_enabled
1</FONT> <BR><FONT face=Arial
size=2>
flap_detection_enabled
1</FONT> <BR><FONT face=Arial
size=2>
process_perf_data
1</FONT> <BR><FONT face=Arial
size=2>
retain_status_information 1</FONT>
<BR><FONT face=Arial size=2>
retain_nonstatus_information 1</FONT> <BR><FONT face=Arial
size=2>
register
0</FONT> <BR><FONT face=Arial
size=2> }</FONT> </P>
<P><FONT face=Arial size=2>define hostgroup{</FONT> <BR><FONT face=Arial
size=2> hostgroup_name
SUN-Servers</FONT> <BR><FONT face=Arial
size=2>
alias All SUN
Solaris Servers</FONT> <BR><FONT face=Arial size=2>}</FONT> </P>
<P><FONT face=Arial size=2>define host{</FONT> <BR><FONT face=Arial
size=2>
name
generic-dev-host</FONT> <BR><FONT face=Arial
size=2>
parents
MFSW_SVR01</FONT> <BR><FONT face=Arial
size=2>
notifications_enabled
1</FONT> <BR><FONT face=Arial
size=2>
event_handler_enabled
1</FONT> <BR><FONT face=Arial
size=2>
flap_detection_enabled
1</FONT> <BR><FONT face=Arial
size=2>
process_perf_data
1</FONT> <BR><FONT face=Arial
size=2>
retain_status_information 1</FONT>
<BR><FONT face=Arial size=2>
retain_nonstatus_information 1</FONT> <BR><FONT face=Arial
size=2>
check_command
check-host-alive</FONT> <BR><FONT face=Arial
size=2>
max_check_attempts
10</FONT> <BR><FONT face=Arial
size=2>
notification_interval
60</FONT> <BR><FONT face=Arial
size=2>
notification_period
8x5</FONT> <BR><FONT face=Arial
size=2>
notification_options
d,u,r</FONT> <BR><FONT face=Arial
size=2>
hostgroups
DEV-Servers,Office,SUN-Servers</FONT> <BR><FONT face=Arial
size=2>
contact_groups
office-admins</FONT> <BR><FONT face=Arial
size=2>
register
0</FONT> <BR><FONT face=Arial
size=2> }</FONT> </P>
<P><FONT face=Arial size=2>define host {</FONT> <BR><FONT face=Arial
size=2>
use
generic-dev-host</FONT> <BR><FONT face=Arial
size=2>
host_name
DBDEV</FONT> <BR><FONT face=Arial
size=2>
alias
Development ColdFusion & Oracle</FONT> <BR><FONT face=Arial
size=2>
address
dbdev.mapfusion.com</FONT> <BR><FONT face=Arial size=2>}</FONT> </P>
<P><FONT face=Arial>_______________________________</FONT> <BR><FONT
face=Arial>Ray Ward</FONT> <BR><FONT face=Arial>System Administrator</FONT>
<BR><FONT face=Arial>MapFusion Technologies Inc.</FONT> <BR><A
href="mailto:ray.ward@mapfusion.com"><U><FONT face=Arial
color=#0000ff>mailto:ray.ward@mapfusion.com</FONT></U></A> <BR><A
href="http://www.mapfusion.com/"><U><FONT face=Arial
color=#0000ff>http://www.mapfusion.com</FONT></U></A> <BR><FONT
face=Arial>_______________________________</FONT> <BR><FONT
face=Arial>NOTICE:</FONT> <BR><FONT face=Arial>This message is intended only
for the use of the individual or entity to which it is addressed; and it,
including any attachments, may contain information that is privileged,
confidential and exempt from disclosure under applicable law. If the reader of
this message is not the intended recipient, or the employee or agent
responsible for delivering the message to the intended recipient, you are
hereby notified that any disclosure, dissemination, distribution or copying of
this communication is strictly prohibited. If you have received this
communication in error, please delete it from your system without copying or
forwarding it and notify us by telephone (905-709-1925) or by return e-mail
immediately. MapFusion Corp. and its affiliated companies do not accept
responsibility or liability for any loss or damage arising in any way from
your receipt or use or for any errors or omissions in the contents of this
communication. </FONT></P>
<P><FONT face=Arial></FONT>
</P><BR>______________________________________________________________________<BR>This
email has been scanned by the MessageLabs Email Security System.<BR>For more
information please visit http://www.messagelabs.com/email
<BR>______________________________________________________________________<BR></BLOCKQUOTE></BODY></HTML>