Splunk Search

percent of results per bin

tp29
Engager

Hi all,

New to splunk, running out of ideas, please help!

I have created a search to show:

| bin span=10m _time

| stat count by _time

This gives me two columns - the time interval in 10 minutes bins, and the number of results within that bin.

What I would like to do is expand on this search and show the % of bins over a time range that have > =10 results 

 

cheers

0 Karma
1 Solution

ITWhisperer
SplunkTrust
SplunkTrust
| bin span=10m _time
| stat count by _time
| stats count(eval(count>=10)) as count10plus count as total
| eval percent=100*count10plus/total

View solution in original post

ITWhisperer
SplunkTrust
SplunkTrust
| bin span=10m _time
| stat count by _time
| stats count(eval(count>=10)) as count10plus count as total
| eval percent=100*count10plus/total

tp29
Engager

That works perfectly.
Thank you very much 🙏

0 Karma
Get Updates on the Splunk Community!

What's New in Splunk Enterprise 9.4: Features to Power Your Digital Resilience

Hey Splunky People! We are excited to share the latest updates in Splunk Enterprise 9.4. In this release we ...

Take Your Breath Away with Splunk Risk-Based Alerting (RBA)

WATCH NOW!The Splunk Guide to Risk-Based Alerting is here to empower your SOC like never before. Join Haylee ...

SignalFlow: What? Why? How?

What is SignalFlow? Splunk Observability Cloud’s analytics engine, SignalFlow, opens up a world of in-depth ...