Monitoring Splunk

How to create a search to calculate top5 license consuming index for last 7 days?

umesh
Path Finder

Hi 

 

I wanted to get the details  of the top 5 indexes consuming high license seperated by date  for last 7 days in a single query.

16th -top 5 index --gb

17th -top 5 index --gb

18th top 5 index  --gb 

.........

Please help me with the above query 

 

Labels (3)
Tags (2)
0 Karma

richgalloway
SplunkTrust
SplunkTrust

The Monitoring Console has such a search.  See Indexing->License Usage->Historic License Usage.

Here is a slightly modified version of that search that should more close meet your requirements.

index=_internal source=*license_usage.log* type="Usage" earliest=-7d
| eval idx=if(len(idx)=0 OR isnull(idx),"(UNKNOWN)",idx) 
| bin _time span=1d 
| stats sum(b) as b by _time, idx 
| timechart limit=5 span=1d sum(b) AS volumeB by idx fixedrange=false 
| fields - _timediff 
| foreach "*" 
    [ eval <<FIELD>>=round('<<FIELD>>'/1024/1024/1024, 3)]
---
If this reply helps you, Karma would be appreciated.
Get Updates on the Splunk Community!

Index This | What did the zero say to the eight?

June 2025 Edition Hayyy Splunk Education Enthusiasts and the Eternally Curious!  We’re back with this month’s ...

Splunk Observability Cloud's AI Assistant in Action Series: Onboarding New Hires & ...

This is the fifth post in the Splunk Observability Cloud’s AI Assistant in Action series that digs into how to ...

Now Playing: Splunk Education Summer Learning Premieres

It’s premiere season, and Splunk Education is rolling out new releases you won’t want to miss. Whether you’re ...