question about hostgroups

Seth Simmons ssimmons at cymfony.com
Fri Dec 12 18:58:12 CET 2008


So you have ServerA ServerB and ServerC as part of Hostgroup1.

You have services defined for the Hostgroup, but you want to exclude ServerC from that one service.

In the service command, exclude ServerC by putting a ! in front of it.

 

Example:

 

define service{

          use                                           local-service         

          hostgroup_name                          Hostgroup1

          host_name                                 !ServerC

          service_description                       SSH

          check_command                          check_ssh

          max_check_attempts                    2

          check_interval                             10

          retry_interval                              5

          check_period                               24x7

          notification_interval                      60

          first_notification_delay                  0

          notification_period                        24x7

          contacts                                     nagiosadmin

          notification_options                       c,w,r

          }

 

All hosts in Hostgroup1 get checked for ssh except ServerC.

 

 

From: Arnar Þórarinsson [mailto:art at flugstodir.is] 
Sent: Friday, December 12, 2008 12:51 PM
To: nagios-users at lists.sourceforge.net
Subject: [Nagios-users] question about hostgroups

 


hi all, 
Say I have a hostgroup defined that has serveral services attached to it, like a typical linux server so its easy to add a server, just assigned it to this hostgroup and all the basic stuff come in automaticly. 
Now lets say that I'm adding a new host and I want him to have all the same services as every other linux server except for one services, can I somehow tell nagios not to apply that services check to this host ? 

Thanks in advance for any help you may provide.

Cheers 

Arnar 

Thessi tolvupostur og vidhengi hans geta innihaldid 
trunadarupplysingar og er eingongu aetladur theim sem hann er 
stiladur a. 
Oheimil medferd tolvuposts thessa og vidhengja hans getur 
vardad 
skadabota- og refsiabyrgd samkvaemt logum um fjarskipti. Efni 
tolvupostsins og vidhengja er a abyrgd sendanda ef thad tengist 
ekki starfsemi Flugstoda ohf. Ef Thu ert ekki skradur 
mottakandi og hefur fengid skeytid vegna mistaka, vinsamlegast 
hafdu strax samband vid sendanda. 

------------


This e-mail and its attachments is intended only for the person or
entity to which it is addressed and may contain confidential 
and/or privileged material. Any review, retransmission, 
dissemination or other use of, or taking of any action in 
reliance upon, this information by persons or entities other than 
the intended recipient is prohibited. 
If you received this in error, please contact the sender and 
delete the material from any computer.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.monitoring-lists.org/archive/users/attachments/20081212/c4803b4c/attachment.html>
-------------- next part --------------
------------------------------------------------------------------------------
SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada.
The future of the web can't happen without you.  Join us at MIX09 to help
pave the way to the Next Web now. Learn more and register at
http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/
-------------- next part --------------
_______________________________________________
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