Issue with contacts.cfg


(Troy Bennett) #1

Hello, I’m following the 2-way integration guide for Nagios and I’m running into an issue when I add the “pagerduty” user under my admin Contact groups and attempt to restart my nagios service it won’t start, but when I remove the user, save, and the attempt to start my nagios services it’s starting with no challenge. I’m unsure what formatting should be used when adding the user to the .cfg file.

Current Output:

define contactgroup{
contactgroup_name admins
alias Nagios Administrators
members nagiosadmin
do I just add a " ,pagerduty" after nagiosadmin to add a new user to the group? All help is appreciated. thank you.

(Demitri Morgan) #2

Hi Troy,

Correct, to add the user you would append ,pagerduty.

As for why this is causing problems: can you confirm that pagerduty_nagios.cfg is being loaded? Because, if that’s not the case, and you haven’t defined the pagerduty contact anywhere else (it is defined in that file), Nagios will probably quit with a configuration error.

You can verify your Nagios configuration and get more info about what might be preventing Nagios from starting properly using nagios -v [path to main configuration file] as described here:

Hopefully that helps!

(Troy Bennett) #3

Thank you Demitri. I was able to get it sorted.

(system) #4