Skip to content

Local cache cleaning/expiry takes a really long time and cache quota is not strict

Summary

I'm working on a machine with limited local disk space, and have set a cache quota of 80GB. Below is my user configuration (~/.config/buildstream.conf)

cache:
  quota: 80G

Now, when I approached this cache, I hit a clean up job at 82 GB which took ~57 minutes to complete and reduced the cache to ~40 GB

Log below:

$ cat ~/.cache/buildstream/logs/cleanup/cleanup.4801.log 
[--:--:--] START  : cleanup
[00:57:11] SUCCESS: cleanup

The issues

  1. The clean up only occurred when my cache hit 82GB, is this expected behaviour? Or do we need our caching to be more strict?
  2. 57 minutes of cleanup time for 40GB is way too long. I suspect many users will set much larger quotas than 80 GB. Currently, for my use-case, I am better off removing the entire cache and rebuilding what I need.
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information