I am running Nagios 3.x on Centos. I created a service definition to check for a running mysqld processes, via ssh. I want to use the single check for both a production and a staging system, but I only want to get emailed if the production check fails. For the staging I want to know via the web interface but that is it. I do have a hostgroup defined for “production” and “staging” and the hosts are in the appropriate ones.
From reading through the docs and google searches it looks like I need to duplicate the service check, one for staging with its own notifcation settings and another for production? I want to minimize creating duplicate contacts, contact groups, etc. Is there a way to control service notification based on hostgroup or some other way? I’ve started to look at creating a custom notification command to handle it, but wanted to check if there is a better way.