Splunk Search

How do I make a rolling weekly percentage?

altinCamp
New Member

I'm new to splunk, but I need to figure out how to count the number of error codes of a certain type over a rolling 7 day span going back to the start of the year. so from 01/01/2020 to current date of search. broken down into rolling 7 day averages... so if its Wednesday it goes back to Thursday of the previous week, if it thursday it goes back to friday of the previous week and it goes all the way back to the beginning of the year but broken out into 7 day periods.  Is this possible with Splunk? 

Error_Code = "x" | timechart count span = 1d is as far as i've gotten

 

Labels (3)
0 Karma

ITWhisperer
SplunkTrust
SplunkTrust
Error_Code = "x" 
| bin _time span=1d
| stats count by _time
| autoregress count p=1-6
| eval sevendaycount=count+count_p1+count_p2+count_p3+count_p4+count_p5+count_p6
0 Karma
Get Updates on the Splunk Community!

See just what you’ve been missing | Observability tracks at Splunk University

Looking to sharpen your observability skills so you can better understand how to collect and analyze data from ...

Weezer at .conf25? Say it ain’t so!

Hello Splunkers, The countdown to .conf25 is on-and we've just turned up the volume! We're thrilled to ...

How SC4S Makes Suricata Logs Ingestion Simple

Network security monitoring has become increasingly critical for organizations of all sizes. Splunk has ...