Page 1 of 1

Emails not sent out to contact group

Posted: Tue Jun 14, 2016 11:35 am
by w-bao
I set up a parent contact group 'CQ Web' with a child contact group 'TTS-OPS' and a couple of individual contacts/users. The child contact group only has 1 contact which is an email distribution list. When an alert about a host was triggered, an email was sent out to individual contacts but not to the email distribution list. BTW, I did a test email from Nagios XI to email distribution list which went through.

From /var/log/messages, it seems to have tried the child contact group 'TTS-OPS'
Jun 10 01:34:38 sv-monmgt3-tts nagios: HOST NOTIFICATION: TTS-OPS;vm-cqpub0-web;UP;xi_host_notification_handler;OK - vm-cqpub0-web: rta 2082.171ms, lost 40%
Jun 10 01:34:38 sv-monmgt3-tts nagios: HOST NOTIFICATION: c-peng-adm;vm-cqpub0-web;UP;xi_host_notification_handler;OK - vm-cqpub0-web: rta 2082.171ms, lost 40%
Jun 10 01:34:38 sv-monmgt3-tts nagios: HOST NOTIFICATION: d-beaudet-adm;vm-cqpub0-web;UP;xi_host_notification_handler;OK - vm-cqpub0-webv: rta 2082.171ms, lost 40%

But from /var/log/maillog, there is no entry for TTS-OPS.
Jun 10 01:34:43 sv-monmgt3-tts postfix/smtp[86973]: 0364D17FF59: to=<D-Beaudet@xxx>, relay=xxx[172.20.60.47]:25, delay=2.3, delays=0.07/0.01/0.01/2.2, dsn=2.6.0, status=sent (250 2.6.0 <[email protected]> [InternalId=12728] Queued mail for delivery)
Jun 10 01:34:43 sv-monmgt3-tts postfix/qmgr[2837]: 0364D17FF59: removed
Jun 10 01:34:44 sv-monmgt3-tts postfix/smtp[86976]: 22AB017FF5A: to=<C-Peng@xxx>, relay=xxx[172.20.60.47]:25, delay=3.2, delays=0.03/0.01/0.01/3.1, dsn=2.6.0, status=sent (250 2.6.0 <[email protected]> [InternalId=12729] Queued mail for delivery)
Jun 10 01:34:44 sv-monmgt3-tts postfix/qmgr[2837]: 22AB017FF5A: removed

Questions:
-Why is the child contact group not working?
-Is nested contact group allowed?
-Does any contact have to be a user? Can a contact be a email distribution list?

Re: Emails not sent out to contact group

Posted: Tue Jun 14, 2016 12:43 pm
by rkennedy
To answer your questions first -
-Why is the child contact group not working?
-Is nested contact group allowed?
-Does any contact have to be a user? Can a contact be a email distribution list?
1. Not sure yet.
2. Yes.
3. Yes, depending how you're sending notifications out. Nagios doesn't care if your email address assigned is for a distribution group, or an individuals email.

A few questions for you -
- Is the member of 'TTS-OPS' a contact or user?
- Can you post a screenshot of your Admin -> Manage Email Settins page?

Re: Emails not sent out to contact group

Posted: Tue Jun 14, 2016 2:02 pm
by w-bao
To answer your questions:
- Is the member of 'TTS-OPS' a contact or user?
A contact, not a user.

- Can you post a screenshot of your Admin -> Manage Email Settins page?
Attached.

Re: Emails not sent out to contact group

Posted: Tue Jun 14, 2016 3:17 pm
by rkennedy
Try creating them as a user rather then a contact, and it should work.

On a side note - as for your Email Settings page, it looks like you're using Sendmail, but you have SMTP settings configured. Are you trying to send mail out through the local machine or SMTP?

Re: Emails not sent out to contact group

Posted: Wed Jun 15, 2016 7:49 am
by w-bao
Ok. I will give a try.

I tried with SMTP, but it didn't work. Sendmail works.

Re: Emails not sent out to contact group

Posted: Wed Jun 15, 2016 10:21 am
by rkennedy
What error do you receive when trying to send a test notification using SMTP?

Can you post your /usr/local/nagiosxi/tmp/phpmailer.log file for us to look at? This should have some information regarding errors if any occurred.

Re: Emails not sent out to contact group

Posted: Thu Jun 16, 2016 2:42 pm
by w-bao
I created a user account with the same email address and it works now. So apparently, even if we just need to receive email alerts only, we still need to create a user account. A contact doesn't work.

Re: Emails not sent out to contact group

Posted: Thu Jun 16, 2016 3:18 pm
by mcapra
Did you need additional assistance with this issue?

Re: Emails not sent out to contact group

Posted: Fri Jun 24, 2016 10:43 am
by w-bao
No, I'm good now. Thanks!