Splunk Search

I need to group results based on a threshold

mkwan0
New Member

I am running a query against a webserver access log. I need to group all responses greater than 5 seconds, and determine what percentage of all responses are in the above 5 second group. Any thoughts?

Tags (1)
0 Karma

mkwan0
New Member

Ayn, thanks

I had come up with this
earliest=-y latest=now | timechart count(eval(serve_request_time_sec<5)) As WithinSLA, count(eval(serve_request_time_sec>5)) As OverSLA

Now I just need to divide the OverSLA group by OverSLA+WithinSLA. Is there a way to do that within Stats or Timechart

As you probably guessed, I am fairly new to Splunk, and reading documentation as I go.

0 Karma

Ayn
Legend

You could use stats with eval for this:

... | stats count(eval(response_time>=5)) as slow_response_count
0 Karma
Get Updates on the Splunk Community!

Webinar Recap | Revolutionizing IT Operations: The Transformative Power of AI and ML ...

The Transformative Power of AI and ML in Enhancing Observability   In the realm of IT operations, the ...

.conf24 | Registration Open!

Hello, hello! I come bearing good news: Registration for .conf24 is now open!   conf is Splunk’s rad annual ...

ICYMI - Check out the latest releases of Splunk Edge Processor

Splunk is pleased to announce the latest enhancements to Splunk Edge Processor.  HEC Receiver authorization ...