Servicegroup Negate
Posted: Thu Jun 12, 2014 8:35 pm
Wanted to create a static config file and define a servicegroup in it, like so:
What the end result is, I want every service to belong to this servicegroup EXCEPT the services that belong to "system" servicegroup. When I verify it says
I get the same thing if I instead try and ! the individual services. I know I could go through and add every defined service to the service group I want, but I would rather it be automatic like I was trying. When the datacenter isn't primary they want to disable notifications for all services in this new service group. Can anyone think of what I am doing wrong or suggest another method. From what I am seeing, doesn't look like you can use ! in servicegroup definitions.
Code: Select all
define servicegroup{
servicegroup_name non_system
alias everything except system
members *
servicegroup_members !system
}Code: Select all
Error: Could not find member group '!system' specified in servicegroup 'non_system' (config file '/usr/local/nagios/etc/static/non_system.cfg', starting on line 1)