Email Notifications - Duration Macros Not Working in Emails

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
scomdco
Posts: 45
Joined: Fri Oct 04, 2019 3:18 pm

Email Notifications - Duration Macros Not Working in Emails

Post by scomdco »

I've configured our email notifications to also include the durations of the particular check, whether that's a host or a service, but either the macro is not being recognized, there's no value to give, or something else is the issue. Any assistance would be much appreciated,

I'm not sure if all macros from this page are supposed to work for the email notifications, i DID get the hostalias macro to successfully give output in the email after finding it in this list,

Let me know if i'm deciphering the column incorrectly, but it says they should work for notifications
https://assets.nagios.com/downloads/nag ... stduration
host.png
service.png
Here's how i have the email config,
emailconfig.png
i've reached the max for attachments, but here's the output i get in the email as text (disregard the issue that the alert is informing of):

Code: Select all

---- Respond above this line ----

***** Nagios XI Alert *****

Nagios has detected a problem with this service.

Notification Type: PROBLEM

Service: SQL Server
Host: REDACTED
Host Alias: REDACTED (this works)
Address: REDACTED
State: UNKNOWN
Info: UNKNOWN - The WMI query had problems. The error text from wmic is: [wmi/wmic.c:212:main()] ERROR: Retrieve result data.
Date/Time: 2020-01-22 15:48:25
Status Duration: %serviceduration%

Respond: REDACTED
Nagios URL: REDACTED

-----

To reply, keep the following data in your response email.

##REDACTED
You do not have the required permissions to view the files attached to this post.
User avatar
Box293
Too Basu
Posts: 5126
Joined: Sun Feb 07, 2010 10:55 pm
Location: Deniliquin, Australia
Contact:

Re: Email Notifications - Duration Macros Not Working in Ema

Post by Box293 »

I don't believe those macros are in the default notification command but can be added, please refer to the following documentation:

https://assets.nagios.com/downloads/nag ... iables.pdf
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Locked