Alerting

Custom Subject for Splunk Alert

vamsi202
Engager

I'm configured an Alert to send mail whenever Error type is triggered in windows event log. I need to customize subject for that alert like server name, event type, event ID in mail.

For Example: Alert triggered for 'ServerName' with 'Event Type' and 'Event ID'

Below is the search im using.

index="wineventlog" source="wineventlog:application" SourceName="MSSQLSERVER" Type=Error
[|inputlookup inv where client_group="*SQLServer Admin*"
|fields name
|rename name as host]
| table _time,host,EventID,Type,Message
| sort _time desc

Labels (1)
0 Karma
1 Solution

rnowitzki
Builder

Hi @vamsi202 ,

You can reference fields from the search with $result.fieldname$

See https://docs.splunk.com/Documentation/Splunk/latest/Alert/EmailNotificationTokens

Hope this helps.

BR

Ralph

--
Karma and/or Solution tagging appreciated.

View solution in original post

0 Karma

rnowitzki
Builder

Hi @vamsi202 ,

You can reference fields from the search with $result.fieldname$

See https://docs.splunk.com/Documentation/Splunk/latest/Alert/EmailNotificationTokens

Hope this helps.

BR

Ralph

--
Karma and/or Solution tagging appreciated.
0 Karma

vamsi202
Engager

That worked. Thanks a lot

0 Karma
Get Updates on the Splunk Community!

Introducing the 2024 SplunkTrust!

Hello, Splunk Community! We are beyond thrilled to announce our newest group of SplunkTrust members!  The ...

Introducing the 2024 Splunk MVPs!

We are excited to announce the 2024 cohort of the Splunk MVP program. Splunk MVPs are passionate members of ...

Splunk Custom Visualizations App End of Life

The Splunk Custom Visualizations apps End of Life for SimpleXML will reach end of support on Dec 21, 2024, ...