Splunk Search

How can I search for alerts that send emails to specific users in Splunk 6.6?

adexteracc
Explorer

Our setup has a quite a few alerts and we need to find all of the alerts that send email to a specific user. So far other than going through the alerts individually, I have not been able to find a way to search the alerts in this manner.

Tags (3)
0 Karma

putnamblake
Path Finder

I think the above answers are correct but this cleans things up and gives more info. As this is 2020, you the below search is not bound by Splunk 6.x or 7.x- it should work universally.

 

| rest /services/saved/searches
| search action.email.to=* action.email=1
| rename eai:acl.app as Application, title as "Alert Name", triggered_alert_count as "Times Triggered Conditions Met", splunk_server as Host, action.email.to as "Sent To"
| table Application, "Alert Name", "Times Triggered Conditions Met", Host, "Sent To"

 

 

Tags (3)

isoutamo
SplunkTrust
SplunkTrust

You must remember that there are also fields:

  • action.email.cc
  • action.email.bcc

Which you cannot get by REST.

And of course those can be a email aliases/mailing lists on mail server(s).

One way which show to you where splunk has sent alerts is query those from internal logs.

index=_internal source=*python.log sendemail "Sending email"

r. Ismo

jaxjohnny2000
Builder

Try this also.

| rest /services/saved/searches | search action.email=1 action.email.to=targetemail@targetdomain.com | table title action.email.to

0 Karma

micahkemp
Champion

Try this:

| rest /services/saved/searches | search action.email.to="<email address>" | table title action.email.to

adexteracc
Explorer

Doesn't look like that does the trick. I ran with the email address we were looking for and and a couple of others but was unable to get an results returned. Also ran the search with an asterisk for the email.to and found that the search didn't appear to return an email at all. Thank you for the suggestion.

0 Karma

wrangler2x
Motivator

This worked dandy for me.

0 Karma

micahkemp
Champion

Do you see any results for just | rest /services/saved/searches? And are you running the search on the splunk instance that has the alerts configured?

0 Karma
Get Updates on the Splunk Community!

What's new in Splunk Cloud Platform 9.1.2312?

Hi Splunky people! We are excited to share the newest updates in Splunk Cloud Platform 9.1.2312! Analysts can ...

What’s New in Splunk Security Essentials 3.8.0?

Splunk Security Essentials (SSE) is an app that can amplify the power of your existing Splunk Cloud Platform, ...

Let’s Get You Certified – Vegas-Style at .conf24

Are you ready to level up your Splunk game? Then, let’s get you certified live at .conf24 – our annual user ...