Add more Host Groups Nagios

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Add more Host Groups Nagios

Post by scottwilkerson »

In the hostgroups file WSTEST1 is set as a member of the web-server hostgroup AND in the WSTEST1 host definition you are setting citrix-servers in the hostgroups directive

Code: Select all

define hostgroup{
	hostgroup_name		web-servers		; The name of the hostgroup
	alias			web servers		; Long name of the group
	members			WSTEST1
		}

define host {
  host_name WSTEST1
  use windows-server
  alias WSTEST1
  address 10.xx.xx.x
  hostgroups citrix-servers
  max_check_attempts 3
  check_period 24x7
  check_command check-host-alive
  notification_interval 60
  notification_period 24x7
}
Former Nagios employee
Creator:
ahumandesign.com
enneagrams.com
DiegoAnjos
Posts: 49
Joined: Thu Feb 14, 2013 9:32 am

Re: Add more Host Groups Nagios

Post by DiegoAnjos »

WSTEST1 is duplicated:

hostgroups.cfg:

It is set as member of web-servers:

Code: Select all

define hostgroup{
	hostgroup_name	web-servers		; The name of the hostgroup
	alias			        web servers		; Long name of the group
	members			WSTEST1
}
And it on host definition the hostgroup is set as a citrix-servers member:

Code: Select all

define host {
  host_name WSTEST1
  use windows-server
  alias WSTEST1
  address 10.xx.xx.x
  hostgroups citrix-servers
  max_check_attempts 3
  check_period 24x7
  check_command check-host-alive
  notification_interval 60
  notification_period 24x7
}
Remove the hostgroups citrix-servers on host definition.

Hope it helps!
kyang

Re: Add more Host Groups Nagios

Post by kyang »

Based on @scottwilkerson and @DiegoAnjos suggested. Check their suggestions in your host.cfg regarding the hostgroups citrix-servers

Let us know if you have any more questions.
michaelpn
Posts: 54
Joined: Fri Jul 14, 2017 12:12 am

Re: Add more Host Groups Nagios

Post by michaelpn »

hi,
do I get an answer soon:) ?

Sorry I solved it myself. Many thanks :) It helped me.
Michael Pierre
Forenede Gruppeliv
2500 Valby
Copenhagen
Locked