Dashboards & Visualizations

How to get the max of p90 over a month ?

rahul_n
Explorer

Hi. 

I am trying to find max value of p90 over a month for 1 API.

The query I use for finding stats: 

 

<basic splunk query> 
| search API = API1
| stats p90(processing_time) as 90%_time by API 

 

where processing_time is the time which would display the time used for finding p90.

 

Can someone help me with the query to find the max value of p90 calculated over a month ? 

So that I can use that value to generate some kind of alerts.

 

Any help is greatly appreciated. Thanks.

Labels (5)
0 Karma
1 Solution

tscroggins
Influencer

@rahul_n 

How are you binning your data for the initial set 90th percentile calculations? By day? By host? You can use bin, stats, timechart, etc. in various combinations to achieve your desired outcome. Here's one example with data initially binned by day:

<basic splunk query> 
| search API = API1
| bin _time span=1d
| stats p90(processing_time) as p90_processing_time by _time API
| stats max(p90_processing_time) as 90%_time by API

View solution in original post

tscroggins
Influencer

@rahul_n 

How are you binning your data for the initial set 90th percentile calculations? By day? By host? You can use bin, stats, timechart, etc. in various combinations to achieve your desired outcome. Here's one example with data initially binned by day:

<basic splunk query> 
| search API = API1
| bin _time span=1d
| stats p90(processing_time) as p90_processing_time by _time API
| stats max(p90_processing_time) as 90%_time by API

rahul_n
Explorer

Thanks @tscroggins for the solution.

0 Karma
Career Survey
First 500 qualified respondents will receive a $20 gift card! Tell us about your professional Splunk journey.
Get Updates on the Splunk Community!

Tech Talk Recap | Mastering Threat Hunting

Mastering Threat HuntingDive into the world of threat hunting, exploring the key differences between ...

Observability for AI Applications: Troubleshooting Latency

If you’re working with proprietary company data, you’re probably going to have a locally hosted LLM or many ...

Splunk AI Assistant for SPL vs. ChatGPT: Which One is Better?

In the age of AI, every tool promises to make our lives easier. From summarizing content to writing code, ...