Influxdb Container not releasing memory after query is done from grafana

Hi team,

I’m currently facing problem with influxdb container version = influxdb:1.8-alpine
It’s keep restarting when I use grafana to query data more than 7 days
The behavior I’ve seen currently is when I use grafana to query for 7days timerange then I’ve monitor memory usage on influxdb VM using htop. The memory usage from 3-4gb start increasing until it exceed 100% and the influxdb container just died and restart (docker-compose restart always policy), it’s not releasing the memory even the query is done, even I switch grafana to any other page. The memory keep growing and growing

This is not happen when I usually querying for less than 7days as of now (3hrs- 2days are find for example).

This screenshot shows that the memory keep growing even the 7days query is acually finished loading

This screenshot shows that the container died when memory of VM is 100%

any idea how to prevent this or which configuring do I missed?

Hello @Siwapong,
Oof yes InfluxDB is notorious for consuming all available memory.
That’s one of many reasons why v3 was created. As well as eventually providing more operator control for certain version of v3.

Here’s a resource that might be valuable to you though:

Thanks for a quick response, I’m running on docker and as I’ve seen that the version 1.x still keep pushing the update(last couple days ago for the latest update), not sure if there is a fix on this yet? also is it possible that we move to v2.7 instead of v3 because there are less document and less community discussion with v3