Dashboards & Visualizations

how to add new parameter on timechart graph

sbhatnagar88
Path Finder

HI All,

Below is the code for calculating disk utilization where "Name" is being passed as token for drive name being selected by user from drop down. Code is working perfectly fine.

Requirement is when we hover mouse over the time chart line it displays date,time server name and disk utilization. Customer also wants to see the drive name when we hover mouse over the line specially when user selects "All" from the disk drop down .

Basically when "All" is selected so for what all disks utilization is being shown.

index=windows sourcetype=WinHostMon Type=Disk FreeSpaceKB=* TotalSpaceKB=* Name="$Name$"
[ inputlookup servers.csv
| search $host$ Environment=$Environment$
| fields host ]
| eval TotalSpaceGb = TotalSpaceKB/1024, FreeSpaceGb= FreeSpaceKB/1024
| eval UsedPercent= 100-round(FreeSpaceGb*100/TotalSpaceGb)
| eval UsedPercent = round(UsedPercent)
| timechart max(UsedPercent) as Value by host | eval Threshold = "90"

Tags (1)
0 Karma

sbhatnagar88
Path Finder

Any update would be highly appreciated...

0 Karma
Get Updates on the Splunk Community!

Splunk Observability for AI

Don’t miss out on an exciting Tech Talk on Splunk Observability for AI!Discover how Splunk’s agentic AI ...

Splunk Enterprise Security 8.x: The Essential Upgrade for Threat Detection, ...

Watch On Demand the Tech Talk, and empower your SOC to reach new heights! Duration: 1 hour  Prepare to ...

Splunk Observability as Code: From Zero to Dashboard

For the details on what Self-Service Observability and Observability as Code is, we have some awesome content ...