You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
Every week or so, I should manually restart the loki containers, as the storage fills up even though it's seemingly "empty". This is happening in two clusters. This is happening since a long time (I've been upgrading Loki many times and the problem still persists), but I cannot say for sure when it all started.
~ ❯ k exec -it loki-stack-0 -c loki -- du -hs /var/loki
543.1M /var/loki
Notice there's already a lot of difference between the real space used and the used space by deleted files.
~ ❯ k exec -it loki-stack-1 -c loki -- lsof +L1
1 /usr/bin/loki 10 /var/loki/data/retention/deletion/delete_requests/delete_requests
1 /usr/bin/loki 42 /var/loki/tsdb-shipper-active/wal/s3_2024-09-24/1731576632/00000000
1 /usr/bin/loki 54 /var/loki/wal/00061847
1 /usr/bin/loki 55 /var/loki/tsdb-shipper-active/multitenant/index_20041/1731575732-loki-stack-1-1713781691510093445.tsdb
1 /usr/bin/loki 57 /var/loki/tsdb-shipper-active/wal/s3_2024-04-16/1731576632/00000000
1 /usr/bin/loki 67 /var/loki/wal/checkpoint.061846.tmp/00000000
1 /usr/bin/loki 71 /var/loki/tsdb-shipper-cache/index_20041/fake/1731576863927558043-compactor-1731533767289-1731576608650-a2e01e88.tsdb
... # Just a lot of sockets and pipes more
Let's investigate all these files:
~ ❯ k exec -it loki-stack-1 -c loki -- ls -lash /var/loki/data/retention/deletion/delete_requests/delete_requests
16.0K -rw-rw-r-- 1 loki loki 16.0K May 7 2024 /var/loki/data/retention/deletion/delete_requests/delete_requests
~ ❯ k exec -it loki-stack-1 -c loki -- ls -lash /var/loki/tsdb-shipper-active/wal/s3_2024-09-24/1731576632/00000000
72.0K -rw-r--r-- 1 loki loki 68.0K Nov 14 09:44 /var/loki/tsdb-shipper-active/wal/s3_2024-09-24/1731576632/00000000
~ ❯ k exec -it loki-stack-1 -c loki -- ls -lash /var/loki/wal/00061847
89.3M -rw-r--r-- 1 loki loki 89.3M Nov 14 09:44 /var/loki/wal/00061847
~ ❯ k exec -it loki-stack-1 -c loki -- ls -lash /var/loki/tsdb-shipper-active/multitenant/index_20041/1731575732-loki-stack-1-1713781691510093445.tsdb
64.0K -rw-r--r-- 1 loki loki 62.4K Nov 14 09:30 /var/loki/tsdb-shipper-active/multitenant/index_20041/1731575732-loki-stack-1-1713781691510093445.tsdb
~ ❯ k exec -it loki-stack-1 -c loki -- ls -lash /var/loki/tsdb-shipper-active/wal/s3_2024-04-16/1731576632/00000000
ls: /var/loki/tsdb-shipper-active/wal/s3_2024-04-16/1731576632/00000000: No such file or directory
command terminated with exit code 1
~ ❯ k exec -it loki-stack-1 -c loki -- ls -lash /var/loki/wal/checkpoint.061846.tmp/00000000
ls: /var/loki/wal/checkpoint.061846.tmp/00000000: No such file or directory
command terminated with exit code 1
~ ❯ k exec -it loki-stack-1 -c loki -- ls -lash /var/loki/tsdb-shipper-cache/index_20041/fake/1731576863927558043-compactor-1731533767289-1731576608650-a2e01e88.tsdb
5.5M -rw-r--r-- 1 loki loki 5.5M Nov 14 09:34 /var/loki/tsdb-shipper-cache/index_20041/fake/1731576863927558043-compactor-1731533767289-1731576608650-a2e01e88.tsdb
Let me know if I should provide any more info to properly debug this
The text was updated successfully, but these errors were encountered:
Describe the bug
Every week or so, I should manually restart the loki containers, as the storage fills up even though it's seemingly "empty". This is happening in two clusters. This is happening since a long time (I've been upgrading Loki many times and the problem still persists), but I cannot say for sure when it all started.
A Grafana Champion in the official forum encouraged me to open this bug issue: https://community.grafana.com/t/du-and-df-showing-different-usage/134459
To Reproduce
Steps to reproduce the behavior:
values.yaml
file:Expected behavior
Loki should stop keeping deleted files open, so that I don't need to be manually restarting the container
Environment:
Screenshots, Promtail config, or terminal output
Repeating the steps from my grafana forum post. It's been 28h running and these are the results:
Notice there's already a lot of difference between the real space used and the used space by deleted files.
Let's investigate all these files:
Let me know if I should provide any more info to properly debug this
The text was updated successfully, but these errors were encountered: