How to solve Grafana zabbix alert nodata problem when working with time series data

126 Views Asked by At

I've been trying to Grafana zabbix alerts for memory usage,in percentage for a while. I am working with time series data and I get nodata error.

First, I created an alert rule with zabbix. I am trying to get the memory usage data. For that, I use 2 queries. First one is avaliable memory for all hosts:

  1. A for avaliable memory. I get top 5 data. There is no problem
  2. T for total memory I get top 5 data. Also no problem
  • Then I add 2 expressions in order to reduce time series data to numbers. A2 is for reduced avaiable memory, T2 for reduced total memory.

I can also get data with any problem at this phase. But you can observe that I have different host metrics for two data.

A2, reduced avaliable memory T2, reduced total memory

I then add a math expression for calculating percentage, then I use that as an input for my treshold value. But when I did that, a problem occures:

nodata problem

I can see that it is because my metrics are from two different hosts, so it doesn't calculate.

I can see that it is because my metrics are from two different hosts, so it doesn't calculate. I tried it for the same host data, it works fine. Also searched all possible solutions through here and couldn't solve the problem.

What can I do ? Can I write a query or condition to compare two different host names, then if that condition is true, calculate the percentage? Or is that any other way around to calculate the percentage? Thank you.

0

There are 0 best solutions below