<p>%alertname% returned with a <b>%state%</b> state at <b>%time%</b></p>
<p>The alert was processed with the following thresholds:<br>
<ul>
<li>Lookback period: %lookback%</li>
<li>Warning: %warning%</li>
<li>Critical: %critical%</li>
</ul>
</p>
<p>
Here is the full alert output:
<div style="padding: 10px; background-color: #F9F9F9;">%output%</div>
</p>
<p>
Output from log: %last10alertlogs%.</p>
<p>See the last %lookback% in the <a href="%url%">Nagios Log Server dashboard</a>.</p>
<p>Nagios Log Server</p>
Alertname Alert returned with a CRITICAL state at Mon, 09 Dec 2019 07:03:11 -0800
The alert was processed with the following thresholds:
• Lookback period: 5m
• Warning: 0
• Critical: 0
Here is the full alert output:
CRITICAL: 1 matching entries found |logs=1;0;0
Output from log:
@timestamp 2019-12-09T15:02:50.766Z
message
@version 1
tags
host <IP>
port 50818
type productname_multiline
alert_names
.
See the last 5m in the Nagios Log Server dashboard.
Nagios Log Server
So if I'm looking at this correctly, the "message" field in the Output Email isn't populated. That, along with the rest of the fields in that code block are populated by the %output% macro from the template.
Can you show a screenshot of the log entry that triggered this alert? I'm wondering if it's just not pulling in the right field.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Be sure to check out our Knowledgebase for helpful articles and solutions!
mbellerue wrote:So if I'm looking at this correctly, the "message" field in the Output Email isn't populated. That, along with the rest of the fields in that code block are populated by the %output% macro from the template.
Can you show a screenshot of the log entry that triggered this alert? I'm wondering if it's just not pulling in the right field.
Okay, thank you for those! First thing to try would be to go to your template and put your %output% macro in quotes. I'm wondering if the greater than/less than signs are throwing it off.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Be sure to check out our Knowledgebase for helpful articles and solutions!
By "log" they mean the log entry that is coming in to Log Server. In the Email Templates page, there is a View Macros button which has good descriptions for each of the macros.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Be sure to check out our Knowledgebase for helpful articles and solutions!
mbellerue wrote:By "log" they mean the log entry that is coming in to Log Server. In the Email Templates page, there is a View Macros button which has good descriptions for each of the macros.
Give that explanation, should I use %lastalertlog% as opposed to %last10alertlogs%?
mbellerue wrote:You can definitely give it a try. Also make sure you only have one of those. Apparently they can't both be used in the same email template.
Hello,
I tried using the "lastalert" macro, but had no success.
Is there anything else I should try? Having the message in the email is critical to our monitoring.
Can you show me a screenshot of one of the logs that is triggering the email, as well as a screenshot of your alert configuration? We should also grab a system profile. You can PM those to me if you want.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Be sure to check out our Knowledgebase for helpful articles and solutions!