Splunk Search

Splunk Alert search time latest=-5m@m OR latest=now

Flenwy
Explorer

Hello everyone,

I'm currently setting up a lot of alarms in Splunk, and a question has arisen regarding what is better in terms of time.

We've considered two scenarios:

  1. latest=-5m@m
  2. latest=now

If I run the alarm every 5 minutes, I naturally want to avoid having "gaps" in my search. 
I thinks both options will work but iam not 100% sure.

I appreciate any insights on this.

Thank you.

Labels (1)
Tags (1)
0 Karma
1 Solution

ITWhisperer
SplunkTrust
SplunkTrust

It depends on what your earliest is and how quickly your events are indexed, and what timestamps are used on your events.

For example, some systems such as Apache HTTPD often log with a timestamp which represents when the request was received, but it is only written when the response is sent, so an event which takes more than say 5 minutes, may not show up in your search if you are only looking back 5 minutes every 5 minutes.

View solution in original post

Flenwy
Explorer

Hello @ITWhisperer,

thank you a lot for this good explanation.
Now i know where to look at.

Kind regards,
Flenwy

0 Karma

ITWhisperer
SplunkTrust
SplunkTrust

It depends on what your earliest is and how quickly your events are indexed, and what timestamps are used on your events.

For example, some systems such as Apache HTTPD often log with a timestamp which represents when the request was received, but it is only written when the response is sent, so an event which takes more than say 5 minutes, may not show up in your search if you are only looking back 5 minutes every 5 minutes.

Get Updates on the Splunk Community!

OpenTelemetry for Legacy Apps? Yes, You Can!

This article is a follow-up to my previous article posted on the OpenTelemetry Blog, "Your Critical Legacy App ...

UCC Framework: Discover Developer Toolkit for Building Technology Add-ons

The Next-Gen Toolkit for Splunk Technology Add-on Development The Universal Configuration Console (UCC) ...

.conf25 Community Recap

Hello Splunkers, And just like that, .conf25 is in the books! What an incredible few days — full of learning, ...