Handling of long paths on Windows (>260 characters)

there are two different issues in this post and it can be very confusing.
i will try to explain.

  1. the current version of rclone does not use UNC when --cache-dir is given a value of c: without the trailing slash, in effect a relative path.
    the beta fixed that.

  2. where i think your confusion is.
    on windows, and all the way back to MS-DOS, there is a difference between
    c:
    c:\

try this, open a command prompt and run these, all will list the files in the current working folder,
dir c:
dir .
dir .\

and if you feed those values to --cache-dir, rclone will behave the same, to create the cache in the current working folder, which in these cases, is the folder that the .cmd batch script is run from C:\data\rclone\scripts\rr\other\mount

--cache-dir=c:
fs cache: switching user supplied name "c:vfs\\wasabi01" for canonical name "//?/c:/data/rclone/scripts/rr/other/mount/vfs/wasabi01"
--cache-dir=.
fs cache: switching user supplied name "vfs\\wasabi01" for canonical name   "//?/c:/data/rclone/scripts/rr/other/mount/vfs/wasabi01"
--cache-dir=.\
fs cache: switching user supplied name "vfs\\wasabi01" for canonical name   "//?/c:/data/rclone/scripts/rr/other/mount/vfs/wasabi01"

whereas this will create the cache in the root of c:

--cache-dir=c:\
fs cache: switching user supplied name "\\\\?\\c:\\vfs\\wasabi01" for canonical name "//?/c:/vfs/wasabi01"
1 Like

Thank you both for testing (and for your explanations @asdffdsa)

I've merged this to master now which means it will be in the latest beta in 15-30 mins and released in v1.54

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