<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[Syslog Parser - How to parse the actual syslog message in the alert?]]></title><description><![CDATA[<p dir="auto"><s>Have setup a syslog parser that generates an event. Then I created an event processing policy that looks for that event and then it triggers an action (in this case, SLACK notification)</s></p>
<p dir="auto"><s>In this case it's a "login failure" message, and in the syslog message it includes the user account and IP address trying to login.<br />
I'm getting the notification come through just fine, but it doesn't include the syslog text. I need that to be parsed through the event chain so I can see exactly what the message said</s></p>
<p dir="auto"><s>I'm not sure what parameter to add, and where exactly to add it? Do I add it to the Event, the Action? or the Event Processing Policy?</s></p>
<p dir="auto">Edit: Nevermind figured it out. It's at the bottom of this page for anyone wondering <a href="https://www.netxms.org/documentation/adminguide/log-monitoring.html" rel="nofollow ugc">https://www.netxms.org/documentation/adminguide/log-monitoring.html</a></p>
<blockquote>
<p dir="auto">Consider the following line is received via syslog, or added to a monitored file:</p>
<p dir="auto">24.04.2015 12:22:15 1 5 system,error,critical login failure for user testUser from 11.2.33.41 via ssh<br />
We can extract username and login method from the syslog message, and pass it as parameters to an event with the following rule:</p>
<p dir="auto">&lt;match&gt;system,error,critical login failure for user (.*) from .* via (.*)&lt;/match&gt;<br />
&lt;event&gt;10000&lt;/event&gt;<br />
Username will be sent to the event as %1, IP address will not be sent, and login method will be sent as %2.</p>
</blockquote>
<p dir="auto">I actually did want to match the IP address so I changed the 'match' field in the syslog parser to "system,error,critical login failure for user (.*) from (.*) via (.*)"</p>
<p dir="auto">Then I change the Event Configuration to "Login Failure: %1 - %2 (%3)"<br />
And the Action to have text "%n - %m %M" which ultimately results in a message such as the below when failing a login attempt</p>
<p dir="auto">Office Router - Login Failure: SpamUser - 1.2.3.4 (ssh)</p>
]]></description><link>https://forum.netxms.org/topic/5767/syslog-parser-how-to-parse-the-actual-syslog-message-in-the-alert</link><generator>RSS for Node</generator><lastBuildDate>Fri, 13 Nov 2026 20:02:23 GMT</lastBuildDate><atom:link href="https://forum.netxms.org/topic/5767.rss" rel="self" type="application/rss+xml"/><pubDate>Thu, 20 Dec 2018 04:43:41 GMT</pubDate><ttl>60</ttl></channel></rss>