Dashboards & Visualizations

Ordering Chart's Bars

jsven7
Communicator

I'm charting disk space. Per host my chart has two bars that represent the instance (c: and d:). There is a space between each set that is like a visual delimiter for hosts.

index=os host="host1" OR host="host2" OR host="host3" object="LogicalDisk" counter="% Free Space" instance ="C:" OR instance ="D:" 
| eval percent_used=100-Value 
| chart latest(percent_used) by host, instance

How do I make the chart display a specified static order of hosts (pair of bars)?

Tags (1)
0 Karma

mayurr98
Super Champion

hey

have you tried looking at the visualisation for | chart latest(percent_used) over host by instance
Also try this

 index=os host="host1" OR host="host2" OR host="host3" object="LogicalDisk" counter="% Free Space" instance ="C:" OR instance ="D:" 
 | eval percent_used=100-Value 
 | stats  latest(percent_used) by host, instance | eval host=host." ".instance | fields- intance

let me know if this helps!

0 Karma
Get Updates on the Splunk Community!

Introducing Splunk Enterprise 9.2

WATCH HERE! Watch this Tech Talk to learn about the latest features and enhancements shipped in the new Splunk ...

Adoption of RUM and APM at Splunk

    Unleash the power of Splunk Observability   Watch Now In this can't miss Tech Talk! The Splunk Growth ...

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