[icinga-users] Hosts are not moved into new groups via assign where clause in icinga 2

Gaston Gloesener gaston.gloesener at web.de
Mon Aug 4 23:30:55 CEST 2014


Ø  Uhm, might it be because you mix up the vars?

Ø   

 

Oops, you are right of course, but that is not the problem, unfortunately. 

 

First I used the vars.type variable. As this did not work I modified it to “host_type” just in case “type” would be reserved for some special purpose. I did not find anything in the docs that would suggest this could be the case, but one never knows J. Unfortunately when copying the file contents to the mail it was not yet modified in the groups.conf file.

 

The current settings are:

 

object HostGroup "network-switches" {

  display_name = "Network Switches"

 

  assign where host.vars.host_type == "switch"

}

 

object Host "switch22" {

  import "generic-switch"

 

  address = "10.1.0.22"

 

  vars.os = "Netgear"

  vars.sla = "24x7"

  vars.host_type = "switch"

}

 

 

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.icinga.org/pipermail/icinga-users/attachments/20140804/2f033445/attachment-0001.html>


More information about the icinga-users mailing list