0

Is there a way to use hostgroups within a check_cluster --service check?

I've only seen examples that list out each host in the cluster individually like this:

define service{
    ...

    check_command   check_service_cluster!"Foo Cluster"!0!1!$SERVICESTATEID:host1:DNS Service$,$SERVICESTATEID:host2:DNS Service$,$SERVICESTATEID:host3:DNS Service$
    ...

}

But this seems very unwieldy for large clusters. Is there a way to pass it a whole hostgroup directly, $SERVICESTATEID:dns_hostgroup?

0

There is no way to use hostgroups or servicegroups with this plugin, unfortunately.

However: new versions of the plugins support using an extra config ("ini") file. So you could write a script to take a host/servicegroup, look up everything in it, and generate a conf file from that.

Or, you might want to look at check_multi instead. It's much better at this sort of thing, and it's easy to generate its conf via a script.

  • last release 2011/11 – Ilja Oct 22 '15 at 15:44

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.