influxdata / influxdata/influxdb
Memory usage keeps increasing after upgrading to 1.8.4 (tsi1)
- Dominant language
- Rust
- Stars
- 31.7k
- Forks
- 3.7k
- Avg merge
- 13h 37m
- Merged PRs (30d)
- 8
Description
After upgrading from 1.7.4 (inmem) to 1.8.4 (tsi1), memory usage keeps increasing.
Before upgrade:

After upgrade:

Environment info:
```
# cat /etc/redhat-release
CentOS Linux release 7.9.2009 (Core)
# uname -srm
Linux 3.10.0-1160.15.2.el7.x86_64 x86_64
# influxd version
InfluxDB v1.8.4 (git: 1.8 bc8ec4384eed25436d31045f974bf39f3310fa3c)
# nproc
4
# free -m
total used free shared buff/cache available
Mem: 15866 14041 165 254 1660 1262
Swap: 16023 61 15962
> show series cardinality
cardinality estimation
----------------------
181564
```
Same issue happen in an equivalent environment but with 56k as series cardinality and 8GB RAM
Restart influxdb doesn't fix (memory usage remain the same and keep increasing)
[influxdb_conf.txt](https://github.com/influxdata/influxdb/files/6136622/influxdb_conf.txt)
[iostat.txt](https://github.com/influxdata/influxdb/files/6136623/iostat.txt)
[profiles.tar.gz](https://github.com/influxdata/influxdb/files/6147215/profiles.tar.gz)
Contributor guide
Research direction
Start by reviewing profiles.tar.gz, influxdb_conf.txt, and iostat.txt, then reproduce the upgrade from 1.7.4 (inmem) to 1.8.4 (tsi1) in the reported CentOS environment. Done means identifying and fixing the cause of steadily increasing memory usage, including the case where restarting influxdb does not reduce it.
Written by the indexing model from the issue text.
Assessment
- Domain
- databases
- Issue type
- Bug
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100