Alerting

Range map is not working properly in Splunk 6.5.3

ashikuma
Explorer

Range map is not working properly in Splunk 6.5.3. Below is my search query, When value is above 90 then it says green color which is correct, and when value is below 90 then other two defined (elevated & severe) are not working, if its (health field) range is between the two values then it's color getting merged, like green color is default there and when red color should come then it's getting merged and color showing is black

my search|rangemap field=Health low=90-100 elevated=70-89 severe=0-69

please do needful, is this due to decimal values which is coming for health field?
I tried to remove decimal values and kept above same range but still didn't work.

Tags (1)
0 Karma

niketn
Legend

@ashikuma can you try the following?
Set specific value for | eval Health= as per your use case. Currently it calculates a random percent with two digits precision.

| makeresults
| fields - _time
| eval Health=round((random()/random())*100,2), Health=case(Health>100,100,Health<0,0,isnull(Health),0,true(),Health)
| rangemap field=Health low=90-100 elevated=70-89.99 severe=0-69.99 default=severe

What is the reason for rangemap? If you are looking for Single value coloring with rangemap, you should better use UI Edit > Format Visualization> Color> Use Color> Color By Value option. Refer to documentation: https://docs.splunk.com/Documentation/Splunk/latest/Viz/SingleValueFormatting#Migration_for_rangemap...

____________________________________________
| makeresults | eval message= "Happy Splunking!!!"
0 Karma
Get Updates on the Splunk Community!

Introducing the 2024 Splunk MVPs!

We are excited to announce the 2024 cohort of the Splunk MVP program. Splunk MVPs are passionate members of ...

Splunk Custom Visualizations App End of Life

The Splunk Custom Visualizations apps End of Life for SimpleXML will reach end of support on Dec 21, 2024, ...

Introducing Splunk Enterprise 9.2

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