Alerting with NoData results in DataSourceError

I’m having issues that seem to have started with an update of Grafana (I’m running v9.1.2 now).
I have multiple alerts which are expected to see NoData coming from InfluxDB as a datasource.
This is an example of such an alert:

When I’m running those queries I get:

failed to execute conditions: can only reduce type series, got type noData

As said: I’m expecting to get a noData but for some reason Grafana doesn’t treat this as a noData alert anymore (it did work perfectly in older versions!) but tries to transform the noData inside of die Classic condition which fails and results in a DataSourceError which obviously isn’t the result I’m expecting.
I first thought this would be due to the use of classic condition but when I try to use “Reduce” and “Math” to get the same effect I get the exact same issue.

Does somebody know if this is a but that was introduced in one of the last versions or how to circumvent this behavior?

I’m still trying to figure out why this doesn’t work anymore.
It seems like with a change somewhere between 9.0 and 9.1.3 alerting on time series data that might be not existing is impossible.
I can’t use “Reduce” or “Classic Condition” as this might result in an error when I have no data but I also can’t use “Math” directly as the result from InfluxDB is a time series when data is available which also results in an error. So can please someone from the developers at Grafana tell me if this a bug or if I’m missing something here?

1 Like

I’m also running grafana 9.3.2 with influxdb 1.8.10 and am also seeing this DataSourceError emails. I was just trying to initially set my environment up and add alerts for AIX and RHEL servers and these email alerts started coming out of the system. I’m not sure what is causing this either.

Hi @hernanj2,
Data source error indicates that Grafana can’t connect to the data source (e.g. database is down, no permission to read…). Can you query the database from grafana (e.g create a panel)?

If not:
Test connection to data source from grafana:

Configuration -> Datasources -> <datasource name> -> Re-enter URL/username/password and click Save & Test

Check that user have read permission on databases:

influx auth list
influx dbrp list

Best regards,
ldrascic

I think there is some sort of regression bug?

Hi! You are on quite an old version of Grafana. We have fixed a number of bugs around NoData since then. Could you upgrade to the latest version of Grafana 9.3 and see if the issue is still present?