Emulate --vfs-cache-mode full for "off"

First of all,
--vfs-cache-mode full enables jelly/emby playback at 4 seconds after clicking.
--vfs-cache-mode off starts after 7-10 seconds

Factors that I used to make it as similar as possible,

  1. Same google drive remote
  2. same .mkv files used
  3. same network
  4. same client/server
  5. direct playback/no transcode

After getting curious, I've tested it with a bunch of settings with all combinations on --vfs-cache-mode off ,
e.g.

  • vfs-read-chunk-size=1M,32M,500M,1G,5G

  • vfs-read-chunk-size-limit off,0,32M,64M,500M,1G

  • drive-chunk-size 8M,32M,64M,256M

  • using everything at default, nothing changed.

I've come to a conclusion that the problem is not coming from the flags, rather vfs off and full. I've tried vfs full on different devices,

  1. 5200rpm usb 3.0 drive
  2. 5200rpm usb 2.0 drive
  3. 5200rpm sata
  4. samsung 860evo SSD 3.0 drive
  5. samsung 860evo SSD sata drive.
  6. samsung 970 evo nvme
  7. ramdisk
  8. Samsung evo microsd

All of them gives me around 4 seconds playback after clicking, give or take. So the cache location speed doesn't matter at all.

So it begs to question, how do I make vfs off emulate vfs full and anything it does without caching to give the 4 second time.

If anyone has an answer or a better setting I haven't tried please go ahead, coz i've tried all of them on this forum.

Disclamer: this "4 second" thing is totally subjective due to my wifi connection to my clients. So it might be 1 second to you or 10 seconds. Though the problem is definitely there.

If you want to use the Help and Support template to figure out what your issue is, that's probably better as you might have something else going on as you more likely have a configuration issue.

You could call it help by all means. But what I'm seeing is different though, i've tried all possible config, tried hundreds of combinations.

If you have the golden config please help, since I saw your config has transitioned to vfs full.

Not sure there is a golden config as everyone's use case is different.

I use the config I already posted/shared here.

I can't help trouble shoot a "doesn't work and I tried a lot".

If you fill out help and support template, share a log and we're happy to step through it and see what the issue is.

I think emulating vfs off as "full" needs to be a feature.

From what I can see, vfs full gives a burst start of download 20MB/s for a solid 5 second.

vfs off works differently where it downloads 20MB/s then moves up and down before the 5 second.

To fix what? You aren't even sure what issue you are having and trying to figure out a feature request to solve an unknown?

The whole concept of full is caching to disk. If you use off, it basically doesn't cache to disk. What feature are you trying to request?

From what I can see, vfs full gives a burst start of download 20MB/s for a solid 5 second.

vfs off works differently where it downloads 20MB/s then moves up and down before the 5 second.

So back to my original point as without a log, you don't know why you get that behavior.

The reason you get that behavior is what Emby or Plex does when they play a file.

Plex and Emby open and close a file 3 times before actually playing it.

You see a burst with full because it keeps the file on disk and reads ahead from cache stored locally and continues to grab the file as it plays forward.

You don't see a burst with off because the buffer-size is dropped each time a file is closed so off has to open the file, read ahead in the buffer, close the file. It does that 3 times which with cloud storage is slow.

All this is shown in the rclone.log with debug.

I see, this is the feature I was talking about. Something in between full and off. Where you cache to a local disk as buffer rather than downloading/streaming the buffer.
A 1GB ramdisk would be good here.

vfs-cache-mode full does cache to disk so you'd point it wherever you want. The implementation does not use chunks though as it uses sparse files which means you need enough cache for the number of files you want to use at the same time.

So if you have 4 10GB files, you'd need 40GB if they all played at the same time.

There are no plans to change how that works as the implementation just went live with sparse files as a design choice with that not being the same way the old cache backend worked with chunks.

Of course, this is what I like about the new sparse implementation. I tried "sparsing" a 50gb file on a 32gb microsd, and the file plays back fine until it hit the limit.

So with that in mind, a feature to use this sparsing in a way like buffer do to local would be beneficial for plex/emby users.

To play a 50GB file, you need 50GB cache as that's how the caching works now with the design choice of having a file based cache rather than a chunk based cache.

There isn't anything to request/change as it would require a completely new implementation, which I am doubtful would happen.

It already exists as that's vfs-cache-mode full and many folks are using it. You'd just need a small cache disk for storage.

Got it, just thought it was a missing feature you could implement that's all. It's much different than I thought Thanks for clarifying.

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