Add Static Value in Kibana


(Seth S) #1

I'm simply trying to add the value 100 to be used as a threshold in graphs. Can someone please explain the process here? It seems extremely difficult to do this one simple task..


(Mark Walkom) #2

You cannot do this in KB at the moment, it has no concept of a threshold.


(Seth S) #4

Wow, with Kibana so limited that I can't even add a static value without having to do work in both Logstash and ES, I may just find another solution. That is absolutely ridiculous you can't simply add a static value.


(Mark Walkom) #5

What is the use case here?


(Seth S) #6

I'm monitoring metrics that are being passed into my ELK stack. I simply need to show a threshold on the graphs that metrics should not reach.


(Lee Drengenberg) #7

I haven't tried this but I'm thinking you could add a scripted field to your index with a hard-coded value.


(Lee Drengenberg) #8

Although I could add a scripted field with value of 100, I haven't figured out how to chart it along with some other fields value yet.


(Lee Drengenberg) #9

Check it out. I created several scripted fields at different values so I could use one in the appropriate scale for the value I was charting it against. I turned off the 'circles' checkbox in the options so my threshold line was smooth.

edited to show an 'upper' and 'lower' threshold


(Tanya Bragin) #10

@LeeDr nice trick! works great with line charts. For those of you trying this with Area charts, may not work as well, so we're still tracking an issue for it: https://github.com/elastic/kibana/issues/5037 Feel free to +1


(Seth S) #11

Thanks everyone. While scripted fields do the job somewhat, they don't appear to be the ideal solution.

Reason being that I am gathering data for more than one host, and when I create a scripted field (e.g. oneMillion in the example from @LeeDr), that same scripted field gets replicated for each host. Thus if I'm monitoring 100 nodes, that scripted field shows 100 times.

Any ideas that would stop this from replicating so often?


(system) #12