Splunk Search

Single value visualization

orca
Explorer

I understand as per docs single value timechart command is required to put sparkline and trendline. However If I am doing the availability % of my service for example "last 24 hours" and it failed once then my sparkline shows one fall but number always shows as 100% because timechart picks the stats over latest bucket while rendering the number.

Currently in Splunk its like:

Screen Shot 2021-01-07 at 11.19.52 PM.png

 

 

But ideally I would like to show it as 

Screen Shot 2021-01-07 at 11.21.07 PM.png

my search:

index=network sourcetype=nt:logs | stats count(eval('Summary.Error.Code'!="")) as failed_count count as total_count by Test,_time
| eval availability = 100 - ((failed_count/total_count)*100)
| table Test _time availability
| timechart avg(availability) by Test

Any help is appreciated.

Labels (1)
0 Karma
Get Updates on the Splunk Community!

Unlock Database Monitoring with Splunk Observability Cloud

  In today’s fast-paced digital landscape, even minor database slowdowns can disrupt user experiences and ...

Purpose in Action: How Splunk Is Helping Power an Inclusive Future for All

At Cisco, purpose isn’t a tagline—it’s a commitment. Cisco’s FY25 Purpose Report outlines how the company is ...

[Upcoming Webinar] Demo Day: Transforming IT Operations with Splunk

Join us for a live Demo Day at the Cisco Store on January 21st 10:00am - 11:00am PST In the fast-paced world ...