Several contact groups

Hello,

I have the following contacts.cfg file:

define contact{
contact_name nagiosadmin ; Short name of user
use generic-contact ; Inherit default values from generic-c
ontact template (defined above)
alias Nagios Admin ; Full name of user
service_notification_period 24x7
host_notification_period 24x7
host_notification_options d,u,r
service_notification_options w,u,c,r
service_notification_commands notify-service-by-email
host_notification_commands notify-host-by-email
email [email protected] ; <<***** CHANGE THIS TO YOUR EMAIL ADDRESS ******
}

define contact{
contact_name production
use generic-contact
alias Alertes production
service_notification_period 24x7
host_notification_period 24x7
host_notification_options d,u,r
service_notification_options w,u,c,r
service_notification_commands notify-service-by-email
host_notification_commands notify-host-by-email
email [email protected]
}

define contactgroup{
contactgroup_name admins
alias Nagios Administrators
members nagiosadmin
}

define contactgroup{
contactgroup_name production_grp
alias Nagios Administrators
members production , nagiosadmin
}

in a host configuration file, I have:

define host{
use generic-host
host_name Ligne3
alias Automate Ligne 3
address 192.168.2.160
contact_groups production_grp
check_command check-host-alive
}

when ligne3 is down, NAGIOS uses the ‘admins’ contact group for the notification and not the production_grp contact group!!!

Why?

Any idea???

Thanks

Didier :?

Check the config with the -v switch. abnd try to stop and start nagios again. (check no nagios thread survives the stop command).
do not use restart.