Grafana crashes when querying too much data

#1

For some reason when I try to query two full days worth of data, InfluxDB/Grafana crashes. I get the following error message in chrome:

Has anyone else ran into this problem? I have tried increasing Chrome’s cache size but it doesn’t seem to fix the problem.

Thanks to all of those who reply in advance.

#2

Chrome (not Grafana) crashes - probably you are hitting some Chrome app limits (probably memory and OS has killed tab process). Don’t select RAW data, but use time aggregation, so you browser won’t need to process a lot of datapoints.

#3

@jangaraj
Hi. Thank you for the response. Care to explain more about using Time Aggregation?

#4
#5

@jangaraj
Interesting. I am grouping by the time filter when building my queries.

#6

Show us the query you are using

#7

@clanlaw

Here is the query:

SELECT "28V output current" * "28V output voltage" AS "28V Output Power", "Battery Current" * "Battery Voltage" AS "Battery Power", "I BOP" * "V BOP" AS "BOP Power", "Battery charge status" FROM "power" WHERE ("machine_id" =~ /^$machine_id$/) AND $timeFilter
#8

There doesn’t seem to be a GROUP BY clause there as in the docs linked to earlier.

#9

When I added it to my query I don’t get any data points. Here is my updated query:

SELECT "28V output current" * "28V output voltage" AS "28V Output Power", "Battery Current" * "Battery Voltage" AS "Battery Power", "I BOP" * "V BOP" AS "BOP Power", "Battery charge status" FROM "power" WHERE ("machine_id" =~ /^$machine_id$/) AND $timeFilter GROUP BY time(24h)

#10

Try GROUP BY time($interval)
If still no joy see what is shown in the Query Inspector in the query editor window.

#11

Here is what is shows:

Not sure why I am still not getting any data points. When I get rid of the GROUP BY clause I am ale to get the data points.

#12

What do you see if you expand the one element returned (at the bottom).

#13

Oh, you havn’t told it what to do with the grouping, you need to specify mean or other aggregation
SELECT mean("CAT 1") FROM ...
or max or min or whatever you want.