Slow right-click response in Windows

Dear all,

My first post here so please excuse me for my mistakes if any. I'm using rclone + WinFSP + Google Drive for video streaming only. Everything works well so far, except that when I try to right-click a movie file, the context menu takes a long time to pop up.

Any help would be greatly appreciated. Thanks in advance.

What is the problem you are having with rclone?

When right-clicking a movie file (for example, when I want to assign the video to a different player than the default), the context menu takes about 15 seconds to pop up with the mouse cursor circling.

Note that it's not about Windows thumbnail caching, as I always turn off thumbnails. File listing is very quick - a folder with hundreds of videos loads within a few seconds.

What is your rclone version (output from rclone version)

I upgrade rclone daily from beta.rclone.org, so it's always the latest beta version.

Which OS you are using and how many bits (eg Windows 7, 64 bit)

Windows 10 Enterprise, 64 bit

Which cloud storage system are you using? (eg Google Drive)

Google Drive (G Suite)

The command you were trying to run (eg rclone copy /tmp remote:tmp)

My command is extremely simple - I was trying to narrow down the problem.

rclone cmount GoogleDrive: Z: --read-only

The rclone config contents with secrets removed.

As I mentioned, I tried to keep everything simple and as default if possible. The config file doesn't have anything other than my credentials.

[GoogleDrive]
type = drive
scope = drive
token = {...}

A log from the command with the -vv flag

Below is the log for when I (1) mounted the drive; (2) navigated to the video folder; (3) right-clicked a file named "20190626_WebDL.mp4" and waited for the context menu to pop up; (4) unmounted the drive. Feel free to use the filename to narrow down the relevant log block.

Welcome to the forum!

I did a quick search in the log file. It looks like the entire file is being downloaded to show the Windows context menu, and this may take some time for large files such as videos. You are downloading app. 130 MByte in the 10 seconds you are waiting. The upside may be that you video starts playing immediately, once you click play :smile:

What are the response times if you right click the same file twice? (I guess the second is quick)
What is the response time if you right click a very small file? (I guess it is quick)

hello and welcome to the forum,

  • not sure i ever saw a windows user using cmount instead of mount.
  • i would add the following to your command --vfs-cache-mode=full and test again.
  • also, try mounting as a network drive as documented here by adding --network-mode

Dear Ole,

Thank you for your reply and going through my tedious log file (much appreciated!). Yes - It does seem like the file is being downloaded when I invoke the context menu. It's not desirable because I'm using a Gigabit network (~120MB/s) - fast enough so that even if I double click the file to play it directly without that "pre-caching", it starts playing immediately. Considering my bandwidth, I also wonder if during the 10 seconds it downloads way more than 130MB (the whole file is 800MB), or downloads 130MB much slower than my bandwidth.

Anyway, to answer your two questions:

  1. Nope, the second right-click leads to the same waiting time.
  2. Yes, If I right click a much smaller file (like ~50MB) it is significantly faster.

you want to test using --vfs-cache-mode-full, that way rclone will only download the chucks requested instead of the whole file.

as for the click right mouse click, you can figure out which menu entry is the problem.
using one of best set of windows utilities - nirsoft
https://www.howtogeek.com/684164/how-to-fix-a-slow-context-menu-in-windows-10s-file-explorer/

Dear jojo,

Thank you for your reply as well. To answer your questions:

  1. For some reason I have a vague (and possibly false) impression that cmount is newer and more advanced than mount. In reality I haven't observed much difference. In this case both commands lead to the same waiting time, too.

  2. Adding --vfs-cache-mode=full reduces the waiting time to 3~5 seconds. Downside is that now the file is caching to my hard drive (while I prefer caching to the RAM). The log indicates that the file is being read to my hard drive while I'm waiting for the context menu:

2021/04/29 06:48:42 DEBUG : 1.mp4(0xc0001e8340): >openPending: err=<nil>
2021/04/29 06:48:42 DEBUG : vfs cache: looking for range={Pos:0 Size:32768} in [] - present false
2021/04/29 06:48:42 DEBUG : 1.mp4: ChunkedReader.RangeSeek from -1 to 0 length -1
2021/04/29 06:48:42 DEBUG : 1.mp4(0xc0001e8380): >close: err=<nil>
2021/04/29 06:48:42 DEBUG : /1.mp4: >Release: errc=0
2021/04/29 06:48:42 DEBUG : 1.mp4: ChunkedReader.Read at -1 length 4096 chunkOffset 0 chunkSize 134217728
2021/04/29 06:48:42 DEBUG : 1.mp4: ChunkedReader.openRange at 0 length 134217728
2021/04/29 06:48:42 DEBUG : 1.mp4: ChunkedReader.Read at 4096 length 8192 chunkOffset 0 chunkSize 134217728
2021/04/29 06:48:42 DEBUG : 1.mp4: ChunkedReader.Read at 12288 length 16384 chunkOffset 0 chunkSize 134217728
2021/04/29 06:48:42 DEBUG : 1.mp4: ChunkedReader.Read at 28672 length 32768 chunkOffset 0 chunkSize 134217728
2021/04/29 06:48:42 DEBUG : 1.mp4: ChunkedReader.Read at 61440 length 65536 chunkOffset 0 chunkSize 134217728
2021/04/29 06:48:42 DEBUG : 1.mp4(0xc0001e8340): >_readAt: n=32768, err=<nil>
2021/04/29 06:48:42 DEBUG : /1.mp4: >Read: n=32768
2021/04/29 06:48:42 DEBUG : /1.mp4: Read: ofst=819920896, fh=0x3
2021/04/29 06:48:42 DEBUG : 1.mp4(0xc0001e8340): _readAt: size=32768, off=819920896
2021/04/29 06:48:42 DEBUG : vfs cache: looking for range={Pos:819920896 Size:32768} in [{Pos:0 Size:61440}] - present false
2021/04/29 06:48:42 DEBUG : 1.mp4: ChunkedReader.RangeSeek from -1 to 819920896 length -1
2021/04/29 06:48:42 DEBUG : 1.mp4: ChunkedReader.Read at -1 length 4096 chunkOffset 819920896 chunkSize 134217728
2021/04/29 06:48:42 DEBUG : 1.mp4: ChunkedReader.openRange at 819920896 length 134217728
2021/04/29 06:48:42 DEBUG : 1.mp4: ChunkedReader.Read at 126976 length 131072 chunkOffset 0 chunkSize 134217728
2021/04/29 06:48:42 DEBUG : 1.mp4: ChunkedReader.Read at 258048 length 262144 chunkOffset 0 chunkSize 134217728
2021/04/29 06:48:42 DEBUG : 1.mp4: ChunkedReader.Read at 520192 length 524288 chunkOffset 0 chunkSize 134217728
2021/04/29 06:48:42 DEBUG : 1.mp4: ChunkedReader.Read at 1044480 length 1048576 chunkOffset 0 chunkSize 134217728
2021/04/29 06:48:42 DEBUG : 1.mp4: ChunkedReader.Read at 2093056 length 1048576 chunkOffset 0 chunkSize 134217728
2021/04/29 06:48:42 DEBUG : 1.mp4: ChunkedReader.Read at 3141632 length 1048576 chunkOffset 0 chunkSize 134217728
2021/04/29 06:48:42 DEBUG : 1.mp4: ChunkedReader.Read at 4190208 length 1048576 chunkOffset 0 chunkSize 134217728
2021/04/29 06:48:43 DEBUG : /descript.ion: Getattr: fh=0xFFFFFFFFFFFFFFFF
2021/04/29 06:48:43 DEBUG : /descript.ion: >Getattr: errc=-2
2021/04/29 06:48:43 DEBUG : /files.bbs: Getattr: fh=0xFFFFFFFFFFFFFFFF
2021/04/29 06:48:43 DEBUG : /files.bbs: >Getattr: errc=-2
2021/04/29 06:48:43 DEBUG : 1.mp4: ChunkedReader.Read at 5238784 length 1048576 chunkOffset 0 chunkSize 134217728
2021/04/29 06:48:43 DEBUG : 1.mp4: ChunkedReader.Read at 6287360 length 1048576 chunkOffset 0 chunkSize 134217728
2021/04/29 06:48:43 DEBUG : 1.mp4: ChunkedReader.Read at 7335936 length 1048576 chunkOffset 0 chunkSize 134217728
2021/04/29 06:48:43 DEBUG : 1.mp4: ChunkedReader.Read at 8384512 length 1048576 chunkOffset 0 chunkSize 134217728
2021/04/29 06:48:43 DEBUG : 1.mp4: ChunkedReader.Read at 9433088 length 1048576 chunkOffset 0 chunkSize 134217728
2021/04/29 06:48:43 DEBUG : 1.mp4: ChunkedReader.Read at 10481664 length 1048576 chunkOffset 0 chunkSize 134217728
2021/04/29 06:48:43 DEBUG : 1.mp4: ChunkedReader.Read at 11530240 length 1048576 chunkOffset 0 chunkSize 134217728
2021/04/29 06:48:43 DEBUG : 1.mp4: ChunkedReader.Read at 12578816 length 1048576 chunkOffset 0 chunkSize 134217728
2021/04/29 06:48:43 DEBUG : 1.mp4: ChunkedReader.Read at 819924992 length 8192 chunkOffset 819920896 chunkSize 134217728
2021/04/29 06:48:43 DEBUG : 1.mp4: ChunkedReader.Read at 819933184 length 16384 chunkOffset 819920896 chunkSize 134217728
2021/04/29 06:48:43 DEBUG : 1.mp4: ChunkedReader.Read at 819949568 length 32768 chunkOffset 819920896 chunkSize 134217728
2021/04/29 06:48:43 DEBUG : 1.mp4: ChunkedReader.Read at 819982336 length 65536 chunkOffset 819920896 chunkSize 134217728
2021/04/29 06:48:43 DEBUG : 1.mp4(0xc0001e8340): >_readAt: n=32768, err=<nil>
  1. Mounting as a network drive also reduces the waiting time to 3~5 seconds. Probably the best solution for me so far as it is caching to the RAM. The log indicates that the file is still being read while I am waiting:
2021/04/29 06:52:21 DEBUG : /1.mp4: Release: fh=0x3
2021/04/29 06:52:21 DEBUG : /1.mp4: >Release: errc=0
2021/04/29 06:52:21 DEBUG : 1.mp4: ChunkedReader.Read at 0 length 4096 chunkOffset 0 chunkSize 134217728
2021/04/29 06:52:21 DEBUG : 1.mp4: ChunkedReader.Read at 4096 length 8192 chunkOffset 0 chunkSize 134217728
2021/04/29 06:52:21 DEBUG : 1.mp4: ChunkedReader.Read at 12288 length 16384 chunkOffset 0 chunkSize 134217728
2021/04/29 06:52:21 DEBUG : 1.mp4: ChunkedReader.Read at 28672 length 32768 chunkOffset 0 chunkSize 134217728
2021/04/29 06:52:21 DEBUG : 1.mp4: ChunkedReader.Read at 61440 length 65536 chunkOffset 0 chunkSize 134217728
2021/04/29 06:52:21 DEBUG : /1.mp4: >Read: n=32768
2021/04/29 06:52:21 DEBUG : /1.mp4: Read: ofst=819920896, fh=0x2
2021/04/29 06:52:21 DEBUG : 1.mp4: ReadFileHandle.seek from 32768 to 819920896 (fs.RangeSeeker)
2021/04/29 06:52:21 DEBUG : 1.mp4: ChunkedReader.RangeSeek from 126976 to 819920896 length -1
2021/04/29 06:52:21 DEBUG : 1.mp4: ChunkedReader.Read at -1 length 4096 chunkOffset 819920896 chunkSize 134217728
2021/04/29 06:52:21 DEBUG : 1.mp4: ChunkedReader.openRange at 819920896 length 134217728
2021/04/29 06:52:21 DEBUG : 1.mp4: ChunkedReader.Read at 819924992 length 8192 chunkOffset 819920896 chunkSize 134217728
2021/04/29 06:52:21 DEBUG : 1.mp4: ChunkedReader.Read at 819933184 length 16384 chunkOffset 819920896 chunkSize 134217728
2021/04/29 06:52:21 DEBUG : 1.mp4: ChunkedReader.Read at 819949568 length 32768 chunkOffset 819920896 chunkSize 134217728
2021/04/29 06:52:21 DEBUG : 1.mp4: ChunkedReader.Read at 819982336 length 65536 chunkOffset 819920896 chunkSize 134217728
2021/04/29 06:52:21 DEBUG : /1.mp4: >Read: n=32768
2021/04/29 06:52:21 DEBUG : /1.mp4: Read: ofst=819953664, fh=0x2
2021/04/29 06:52:21 DEBUG : 1.mp4: ChunkedReader.Read at 820047872 length 131072 chunkOffset 819920896 chunkSize 134217728
2021/04/29 06:52:21 DEBUG : /1.mp4: >Read: n=32768
2021/04/29 06:52:21 DEBUG : /1.mp4: Read: ofst=819986432, fh=0x2
2021/04/29 06:52:21 DEBUG : 1.mp4: ChunkedReader.Read at 820178944 length 262144 chunkOffset 819920896 chunkSize 134217728
2021/04/29 06:52:21 DEBUG : /1.mp4: >Read: n=65536
2021/04/29 06:52:21 DEBUG : /1.mp4: Read: ofst=820051968, fh=0x2
2021/04/29 06:52:22 DEBUG : 1.mp4: ChunkedReader.Read at 820441088 length 524288 chunkOffset 819920896 chunkSize 134217728
2021/04/29 06:52:22 DEBUG : /1.mp4: >Read: n=131072
2021/04/29 06:52:22 DEBUG : /1.mp4: Read: ofst=820183040, fh=0x2
2021/04/29 06:52:22 DEBUG : 1.mp4: ChunkedReader.Read at 820965376 length 1048576 chunkOffset 819920896 chunkSize 134217728
2021/04/29 06:52:22 DEBUG : /1.mp4: >Read: n=262144
2021/04/29 06:52:22 DEBUG : /1.mp4: Read: ofst=820445184, fh=0x2
2021/04/29 06:52:22 DEBUG : 1.mp4: ChunkedReader.Read at 822013952 length 1048576 chunkOffset 819920896 chunkSize 134217728
2021/04/29 06:52:22 DEBUG : /1.mp4: >Read: n=524288
2021/04/29 06:52:22 DEBUG : /1.mp4: Read: ofst=820969472, fh=0x2
2021/04/29 06:52:22 DEBUG : 1.mp4: ChunkedReader.Read at 823062528 length 1048576 chunkOffset 819920896 chunkSize 134217728
2021/04/29 06:52:22 DEBUG : /1.mp4: >Read: n=1048576
2021/04/29 06:52:22 DEBUG : /1.mp4: Read: ofst=822018048, fh=0x2
2021/04/29 06:52:22 DEBUG : /1.mp4: >Read: n=65536
2021/04/29 06:52:22 DEBUG : /1.mp4: Read: ofst=822083584, fh=0x2
2021/04/29 06:52:22 DEBUG : /1.mp4: >Read: n=1048576
2021/04/29 06:52:22 DEBUG : /1.mp4: Read: ofst=823132160, fh=0x2
2021/04/29 06:52:22 DEBUG : /1.mp4: >Read: n=102126

So the ultimate question would be: is it possible to completely disable the pre-reading of file when I right click the file?

i shared a weblink, with that you should be able to find the menu entry is reading the media file.
or use process explorer, from another great set of windows utilities from sysinternals, to figure out which executable is accessing the media file.

Hi jojo,

My apologies. Your earlier reply was too fast and ahead of mine :slight_smile: My context menus are all Windows default without 3rd party applications. Process Monitor confirms that it is Windows Explorer that's reading the file. So I guess I cannot stop it :roll_eyes: unless there is a hidden Windows setting somewhere...

sure, the odds are it would be windows explorer.
most content menu items are .dll, some are .exe

for the context menu, if you can figure out which entry is the cause, you might want to disable it.
try that nirosft utility in the weblink i shared.

  1. disable all entries.
  2. if the speeds up the menu, enable each entry one by one, and find out which entries cause the slowdown.

Thank you for the suggestion. ShellExView listed 240 menu entries (all from Windows default) and warned me when I tried to disable them, citing that disabling default shell extensions may lead to boot problems. I guess I will leave them as is for now, until I set up a virtual machine to try out.

hey @VBB, long time....

Make sure the folders you're accessing, or better yet the entire drive, is set to 'Documents'.

image

This helps quite a bit with Windows Explorer. And, like the human monkey :wink: suggested, change the command to 'mount'. Here is what I've been using for a long time now:

rclone mount --attr-timeout 1000h --dir-cache-time 1000h --poll-interval 0 --rc --read-only -v

HEY JOJO!!!! I lurk every day :stuck_out_tongue:

Once mounted, I use this command to prime the files and folders:

rclone rc vfs/refresh recursive=true --timeout 30m

This speeds up access enormously without taking additional space, like cache mode would.

1 Like

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