Limiting size of cache using in hard drive

My issue is:

I need access to a lot of videos (average 5gb each) from Box, in different PCs, but the limit of space in HD is 100Gb.
The process is something like that.
A user on PC 1 opens any videos he wishes for his project, and those need to be cacheable for 1 month (720h). Each project occurs every 3 or 5 days, but in practice, the oldest project is not more needed to be on the cache.
So if a new project needs to cache on video but the limit of 100gb has been reached, I need to dump the oldest video cache to download the new one.

My command is:

rclone mount YonkeBox: Y: --log-file "c:/rclone/logs/reclone.log" -v --cache-dir "C:/rclone/cache" --vfs-cache-mode full --vfs-fast-fingerprint --no-modtime --vfs-disk-space-total-size=100G --vfs-cache-max-age=780h --vfs-read-ahead=3G

I can't understand how --vfs-disk-space-total-size works.
That show me in the Drive Mounted on Windows that it has only 100Gb of size, but the cache folder (c:/rclone/cache) blows that at least those reach 720h.

Any ideas???

And another situation I can't be tried, is the hypothesis that when the limit has been reached the new videos won't be cached.

Tks.

--vfs-disk-space-total-size is for providing (or overriding) the total space reported to unix/Windows as being available on the remote, e.g. for a free Box account you might set --vfs-disk-space-total-size 10G so it appears as a 10GB external drive and so you avoid going over the free quota.

—vfs-cache-max-size 100G is what you want. I know eviction based on oldest atime or similar was discussed but not sure if it’s there yet.

It is, rclone notes the time of last access/use and evicts the oldest if exceeding the max size.

1 Like

footlooseboss

Really I was confounding --vfs-disk-space-total-size with --vfs-cache-max-size.

But the misunderstood was because I thinked the --vfs-cache-max-size determinate the max size of each file on folder, and not the total size off the cache folder.

I made some tests here, and it's apparently that is solved.

And YES. Like @Ole confirm below, when the limit of size cache has been reached the Rclone delete the oldest file accessed, proved in log file using --vv.

The nirvana will be if the Rclone delete the oldest accessed chunk than the full file, but it's solve all my needs at this time.

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