# \--vfs-cache-max-size doesn't work

**URL:** <https://forum.rclone.org/t/vfs-cache-max-size-doesnt-work/13100>\
**Category:** Suspected Bug\
**Created:** [November 26, 2019, 10:11am UTC](https://forum.rclone.org/t/vfs-cache-max-size-doesnt-work/13100 "2019-11-26T10:11:28Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![CloudGet](https://forum.rclone.org/user_avatar/forum.rclone.org/cloudget/32/3273_2.png) [@CloudGet](https://forum.rclone.org/u/CloudGet)\
**Post date:** [November 26, 2019, 10:11am UTC](https://forum.rclone.org/t/vfs-cache-max-size-doesnt-work/13100/1 "2019-11-26T10:11:28Z")

</div>

I have a setup of S3 (Scaleway) \>\> crypt  
mounting string:

> rclone mount s3crypt: /s3/s3 --allow-other --max-read-ahead 64M --log-file "/s3/logs/rclone-s3crypt.log" --log-level NOTICE --fast-list --tpslimit 240 --transfers 16 --buffer-size 64M --multi-thread-cutoff 5G --poll-interval 8640h --dir-cache-time 8640h --no-gzip-encoding --stats 24h --stats-one-line --vfs-case-insensitive --vfs-cache-mode full **--vfs-cache-max-size 12G** --vfs-cache-max-age 8640h --vfs-cache-poll-interval 8640h --vfs-read-chunk-size 64M --cache-dir /s3/cache/ --write-back-cache --ignore-case-sync --ignore-errors --streaming-upload-cutoff 64M --gid 33 --uid 33 --umask 0002 --config /s3/rclone.conf --daemon

## Debian 10 Fuse3

**problem:**  
Vfs cache folder always goes over specified max size of 12G. Even after 12h+ of time it stays 17G - 20G etc... Could the --write-back-cache be the problem? as from my previous rclone use without it and some other tags, there were no such issues.

atm I have set the cron to clear older files ther.

---

<div class="post-metadata">

**Author:** ![ncw](https://forum.rclone.org/user_avatar/forum.rclone.org/ncw/32/18_2.png) [@ncw](https://forum.rclone.org/u/ncw)\
**Post date:** [November 26, 2019, 10:25am UTC](https://forum.rclone.org/t/vfs-cache-max-size-doesnt-work/13100/2 "2019-11-26T10:25:26Z")

</div>

The `--vfs-cache-max-size` can be exceeded if there are in-use files. In-use can be files that are open or being uploaded. Is it likely that there are \> 12G of files open?

You've got `--vfs-cache-mode full` which guarantees files are downloaded first before opening. Did you try `--vfs-cache-mode writes`?

---

<div class="post-metadata">

**Author:** ![CloudGet](https://forum.rclone.org/user_avatar/forum.rclone.org/cloudget/32/3273_2.png) [@CloudGet](https://forum.rclone.org/u/CloudGet)\
**Post date:** [November 26, 2019, 10:32am UTC](https://forum.rclone.org/t/vfs-cache-max-size-doesnt-work/13100/3 "2019-11-26T10:32:24Z")

</div>

There are surely no files being opened for longer that 30min~ , however I have Resilio sync listing the folder regularly.  
I will give `--vfs-cache-mode writes` a try, but I had some issues in the past with it when working with word documents on windows and linux.

---

<div class="post-metadata">

**Author:** ![system](https://forum.rclone.org/uploads/default/original/2X/3/39ad3235f6ffec76ccd0c81616bd55697b4c300d.png) [@system](https://forum.rclone.org/u/system)\
**Post date:** [February 24, 2020, 10:32am UTC](https://forum.rclone.org/t/vfs-cache-max-size-doesnt-work/13100/4 "2020-02-24T10:32:25Z")

</div>

Closed on February 24, 2020, 10:32am UTC

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.
