[arv-mount] avoid excessive memory consumption of idle arv-mounts
I noticed several arv-mounts killed
$ dmesg | grep 'Out of' [11983650.641067] Out of memory: Kill process 101941 (python3) score 420 or sacrifice child [11983650.708218] Out of memory: Kill process 101941 (python3) score 420 or sacrifice child [11983651.444473] Out of memory: Kill process 101941 (python3) score 420 or sacrifice child
then I noticed that some simple "ls" on the keep mount will make a load of 1 and it was unable to exit. them memory ballooning is caused by 90 days old arv-mounts that had no use in the last 89 days.
Is there a way to shrink the memory usage in arv-mount that are idle?
#5 Updated by Peter Amstutz 10 months ago
Separately from the soft memory limits it uses to clear the cache, it keeps the last 4 collections hot in the cache (regardless of how much memory they take up). We could release those if the mount has been idle for a while, but only if the kernel cache has forgotten them as well.
If we had stable inode numbering (#12664) then we could release things from the cache regardless of whether the kernel is still hanging on to it or not.
We could greatly reduce the overall footprint with incremental manifest loading (#12314), but that comes with complexity costs.