Reporting

Alert on anomalous growth of thruput per sourcetype

IgorB
Path Finder

I want to create a scheduled search that will be able to trigger an alert if a there's a sourcetype that has a thruput much higher than the average for that sourcetype for a given time period.

Rational: be able eliminate license violations by identifying "peaking" sourcetypes in a timely manner

It's quite easy to see the peaks on a timechart, e.g.

index=_internal group=per_sourcetype_thruput | timechart per_second(kb) by series

gkanapathy
Splunk Employee
Splunk Employee

Depending exactly what you're trying to do, there are many ways to do this. The simplest is to use trendline/streamstats:

index=_internal group=per_sourcetype_thruput 
| bucket _time span=5m
| stats sum(kb) as kb by _time,series
| makecontinuous _time span=5m 
| streamstats global=f current=f window=24
    avg(kb) as moving_avg_kb
    stdev(kb) as stdev_kb
  by series

And then alert conditionally:

| where kb > (moving_avg_kb+(0.5*stdev_kb))

Of course, there is much tuning on what you consider to be "allowable" peaks and over what period of time. (e.g., the above will not catch a source growing slowly over a two-hour or longer period) More complex requirements are going to require either more searches or much more complex ones.

Get Updates on the Splunk Community!

Updated Team Landing Page in Splunk Observability

We’re making some changes to the team landing page in Splunk Observability, based on your feedback. The ...

New! Splunk Observability Search Enhancements for Splunk APM Services/Traces and ...

Regardless of where you are in Splunk Observability, you can search for relevant APM targets including service ...

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 ...