Splunk Search

How do I find matching events that occurred in the last 15 minutes?

vwilson3
Path Finder

I'm pretty new to Splunk and am learning every day. I have this search and I have to create an alert if more than 2 of these events happen in 15 minutes. For now, our alerts have to run once every hour. I've tried using "span", but that breaks up the hour into 15 minute blocks by time, not from the time the event occurred. Here's my search (sorry, had to remove specific data... you understand):

index=myindex field1="xxx" field2="222" |eventstats count by field3 |where count>2 |table _time host field1 field2 field3 field4 field5

Any tips, tricks, suggestions are greatly appreciated.

Tags (1)
0 Karma

nrduren1115
Explorer

Check out the timechart command. It lets you split by time and a certain field. You can specify how long you want the buckets to be as well. Below is the documentation.

http://docs.splunk.com/Documentation/Splunk/7.2.0/SearchReference/Timechart

0 Karma
Get Updates on the Splunk Community!

CX Day is Coming!

Customer Experience (CX) Day is on October 7th!! We're so excited to bring back another day full of wonderful ...

Strengthen Your Future: A Look Back at Splunk 10 Innovations and .conf25 Highlights!

The Big One: Splunk 10 is Here!  The moment many of you have been waiting for has arrived! We are thrilled to ...

Now Offering the AI Assistant Usage Dashboard in Cloud Monitoring Console

Today, we’re excited to announce the release of a brand new AI assistant usage dashboard in Cloud Monitoring ...