Reporting

How to identify accelerated saved searches that are rarely or never invoked?

Ricapar
Communicator

Over the years we've allowed a lot of users to create and save their own searches, as well as allowing them to enable search acceleration on those searches.

All of those saved and accelerated searches are now starting to make an impact on performance.

I'd like to identify saved searches that have search acceleration turned on, but the searches are never or rarely invoked, and/or the acceleration summary is never used.

Any suggestions on how to approach this?

Flynt
Splunk Employee
Splunk Employee

You might be able to use |rest to accomplish this. Something like

index=_audit action=search [|rest /servicesNS/-/-/saved/searches|where auto_summarize=1 |table title|rename title as query]

Note that you'll need to have admin access to do this.

A quick explanation -

index=_audit action=search

will show you what searches have been called.

|rest /servicesNS/-/-/saved/searches|where auto_summarize=1 |table title|rename title as query

Check the saved searches endpoint for all users and all apps (- is wildcard in the API). Get only those that are accelerated (auto_summarize=1) and return just the title to the subquery.

This is how I check on my own instance anyway. You can do your stats or whatever from here, including finding out what users use them more often, etc. If you want to find which ones are not invoked you can join left with the list of summarized searches.

I do it this way -

|rest /servicesNS/-/-/saved/searches|where auto_summarize=1 |table title |join type=left title [search index=_audit action=search [|rest /servicesNS/-/-/saved/searches|where auto_summarize=1 |table title|rename title as query]|rex field=search ".*savedsearch(?<title>[^']+)"|eval title=trim(title)|stats count by title]

** Make sure you set your timepicker to a reasonable value (IE don't do it over ALL TIME)

Get Updates on the Splunk Community!

Routing logs with Splunk OTel Collector for Kubernetes

The Splunk Distribution of the OpenTelemetry (OTel) Collector is a product that provides a way to ingest ...

Welcome to the Splunk Community!

(view in My Videos) We're so glad you're here! The Splunk Community is place to connect, learn, give back, and ...

Tech Talk | Elevating Digital Service Excellence: The Synergy of Splunk RUM & APM

Elevating Digital Service Excellence: The Synergy of Real User Monitoring and Application Performance ...