Linux – way to exclude specific hosts from a Nagios hostgroup

centos6linuxmonitoringnagios

I have a Nagios server which includes many hostgroups.
One of these hostgroups include a server which I'd like to exclude from being checked for one specific Nagios Check but I want it to keep being a member of the hostgroup so it may get checked for all the other checks that the hostgroup is checked for.
Is there an option of exclude or something like that which can help me achieve my goal?
Thanks

Best Answer

Haven't yet tried it with hosts, but with hostgroups, prefixing with a ! works. I use this for running a different load check on busy servers:

define host {
    use         physical-host
    host_name   busy-host.example.com
    alias       busy-host.example.com
    address     10.43.16.1
    hostgroups  linux,centos,ldap,http,busy
}

define host {
    use           physical-host
    host_name     normal-host.example.com
    alias         narmal-host.example.com
    address       10.43.1.1
    hostgroups    linux,centos,dns,proxy,ldap,hp,http,puppetmaster
}

define service {
    use                   generic-service
    hostgroup_name        linux,!busy
    service_description   Load
    check_command         check_snmp_load
}

define service {
    use                   generic-service
    hostgroup_name        busy
    service_description   Load
    check_command         check_snmp_load_busy
}