Trying to mount an encrypted remote on Windows 2016

As the title says, I am trying to mount an encrypted remote on a fresh install of Windows Server 2016. I am using the lastest version of rclone: 1.49.5 and WinSfp: 2019.1.

Here is the command I am using to mount the remote:

.\rclone mount --allow-other --allow-non-empty Media: X:

Here is my config file:

[Net]
type = drive
client_id = ***REMOVED***
client_secret = ***REMOVED***
scope = drive
token = ***REMOVED***

[driveCache]
type = cache
remote = Net:Enc
plex_url = http://127.0.0.1:32400
plex_username = ***REMOVED***
plex_password = ***REMOVED***
chunk_size = 5M
info_age = 1d
chunk_total_size = 10G

[Media]
type = crypt
remote = driveCache:
filename_encryption = standard
directory_name_encryption = true
password = ***REMOVED***
password2 = ***REMOVED***

Here is the output from the command with -vv:

PS C:\Tools\rclone-v1.49.5> .\rclone mount --allow-other --allow-non-empty Media: X: -vv
2019/10/14 16:44:51 DEBUG : rclone: Version "v1.49.5" starting with parameters ["C:\\Tools\\rclone-v1.49.5\\rclone.exe"
"mount" "--allow-other" "--allow-non-empty" "Media:" "X:" "-vv"]
2019/10/14 16:44:51 DEBUG : Using config file from "C:\\Users\\***REMOVED***\\.config\\rclone\\rclone.conf"
2019/10/14 16:44:52 DEBUG : driveCache: wrapped Net:Enc at root
2019/10/14 16:44:52 INFO  : driveCache: Cache DB path: C:\Users\***REMOVED***\AppData\Local\rclone\cache-backend\driveCache.db
2019/10/14 16:44:52 INFO  : driveCache: Cache chunk path: C:\Users\***REMOVED***\AppData\Local\rclone\cache-backend\driveCache
2019/10/14 16:44:52 INFO  : driveCache: Chunk Memory: true
2019/10/14 16:44:52 INFO  : driveCache: Chunk Size: 5M
2019/10/14 16:44:52 INFO  : driveCache: Chunk Total Size: 10G
2019/10/14 16:44:52 INFO  : driveCache: Chunk Clean Interval: 1m0s
2019/10/14 16:44:52 INFO  : driveCache: Workers: 4
2019/10/14 16:44:52 INFO  : driveCache: File Age: 1d
2019/10/14 16:44:52 DEBUG : Adding path "cache/expire" to remote control registry
2019/10/14 16:44:52 DEBUG : Adding path "cache/stats" to remote control registry
2019/10/14 16:44:52 DEBUG : Adding path "cache/fetch" to remote control registry
2019/10/14 16:44:52 DEBUG : driveCache: wrapped Net:Enc at root
2019/10/14 16:44:52 INFO  : driveCache: Cache DB path: C:\Users\***REMOVED***\AppData\Local\rclone\cache-backend\driveCache.db
2019/10/14 16:44:52 INFO  : driveCache: Cache chunk path: C:\Users\***REMOVED***\AppData\Local\rclone\cache-backend\driveCache
2019/10/14 16:44:52 INFO  : driveCache: Chunk Memory: true
2019/10/14 16:44:52 INFO  : driveCache: Chunk Size: 5M
2019/10/14 16:44:52 INFO  : driveCache: Chunk Total Size: 10G
2019/10/14 16:44:52 INFO  : driveCache: Chunk Clean Interval: 1m0s
2019/10/14 16:44:52 INFO  : driveCache: Workers: 4
2019/10/14 16:44:52 INFO  : driveCache: File Age: 1d
2019/10/14 16:44:52 DEBUG : Adding path "cache/expire" to remote control registry
2019/10/14 16:44:52 DEBUG : Adding path "cache/stats" to remote control registry
2019/10/14 16:44:52 DEBUG : Adding path "cache/fetch" to remote control registry
2019/10/14 16:44:52 DEBUG : Encrypted drive 'Media:': Mounting on "X:"
2019/10/14 16:44:52 DEBUG : Cache remote driveCache:: subscribing to ChangeNotify
2019/10/14 16:44:52 DEBUG : Adding path "vfs/forget" to remote control registry
2019/10/14 16:44:52 DEBUG : Adding path "vfs/refresh" to remote control registry
2019/10/14 16:44:52 DEBUG : Adding path "vfs/poll-interval" to remote control registry
2019/10/14 16:44:52 DEBUG : Encrypted drive 'Media:': Mounting with options: ["-o" "fsname=Media:" "-o" "subtype=rclone"
 "-o" "max_readahead=131072" "-o" "attr_timeout=1" "-o" "atomic_o_trunc" "-o" "uid=-1" "-o" "gid=-1" "--FileSystemName=r
clone" "-o" "volname=Media" "-o" "nonempty" "-o" "allow_other"]
2019/10/14 16:44:52 DEBUG : Encrypted drive 'Media:': Init:
2019/10/14 16:44:52 DEBUG : Encrypted drive 'Media:': >Init:
2019/10/14 16:44:52 DEBUG : /: Statfs:
2019/10/14 16:44:52 DEBUG : /: >Statfs: stat={Bsize:4096 Frsize:4096 Blocks:274877906944 Bfree:273864058271 Bavail:27487
7906944 Files:1000000000 Ffree:1000000000 Favail:0 Fsid:0 Flag:0 Namemax:255}, errc=0
2019/10/14 16:44:52 DEBUG : /: Getattr: fh=0xFFFFFFFFFFFFFFFF
2019/10/14 16:44:52 DEBUG : /: >Getattr: errc=0
2019/10/14 16:44:52 DEBUG : /: Readlink:
2019/10/14 16:44:52 DEBUG : /: >Readlink: linkPath="", errc=-40
The service rclone has been started.
2019/10/14 16:44:52 DEBUG : /: Statfs:
2019/10/14 16:44:52 DEBUG : /: >Statfs: stat={Bsize:4096 Frsize:4096 Blocks:274877906944 Bfree:273864058271 Bavail:27487
7906944 Files:1000000000 Ffree:1000000000 Favail:0 Fsid:0 Flag:0 Namemax:255}, errc=0
2019/10/14 16:44:52 DEBUG : /: Getattr: fh=0xFFFFFFFFFFFFFFFF
2019/10/14 16:44:52 DEBUG : /: >Getattr: errc=0
2019/10/14 16:44:52 DEBUG : /: Getattr: fh=0xFFFFFFFFFFFFFFFF
2019/10/14 16:44:52 DEBUG : /: >Getattr: errc=0
2019/10/14 16:44:52 DEBUG : /: Opendir:
2019/10/14 16:44:52 DEBUG : /: OpenFile: flags=O_RDONLY, perm=-rwxrwxrwx
2019/10/14 16:44:52 DEBUG : /: >OpenFile: fd=/ (r), err=<nil>
2019/10/14 16:44:52 DEBUG : /: >Opendir: errc=0, fh=0x0
2019/10/14 16:44:52 DEBUG : /: Releasedir: fh=0x0
2019/10/14 16:44:52 DEBUG : /: >Releasedir: errc=0
2019/10/14 16:44:52 DEBUG : /: Getattr: fh=0xFFFFFFFFFFFFFFFF
2019/10/14 16:44:52 DEBUG : /: >Getattr: errc=0
2019/10/14 16:44:52 DEBUG : /: Getattr: fh=0xFFFFFFFFFFFFFFFF
2019/10/14 16:44:52 DEBUG : /: >Getattr: errc=0
2019/10/14 16:44:52 DEBUG : /: Opendir:
2019/10/14 16:44:52 DEBUG : /: OpenFile: flags=O_RDONLY, perm=-rwxrwxrwx
2019/10/14 16:44:52 DEBUG : /: >OpenFile: fd=/ (r), err=<nil>
2019/10/14 16:44:52 DEBUG : /: >Opendir: errc=0, fh=0x0
2019/10/14 16:44:52 DEBUG : /: Releasedir: fh=0x0
2019/10/14 16:44:52 DEBUG : /: >Releasedir: errc=0
2019/10/14 16:44:52 DEBUG : /: Getattr: fh=0xFFFFFFFFFFFFFFFF
2019/10/14 16:44:52 DEBUG : /: >Getattr: errc=0
2019/10/14 16:44:52 DEBUG : /: Getattr: fh=0xFFFFFFFFFFFFFFFF
2019/10/14 16:44:52 DEBUG : /: >Getattr: errc=0
2019/10/14 16:44:52 DEBUG : /: Opendir:
2019/10/14 16:44:52 DEBUG : /: OpenFile: flags=O_RDONLY, perm=-rwxrwxrwx
2019/10/14 16:44:52 DEBUG : /: >OpenFile: fd=/ (r), err=<nil>
2019/10/14 16:44:52 DEBUG : /: >Opendir: errc=0, fh=0x0
2019/10/14 16:44:52 DEBUG : /: Releasedir: fh=0x0
2019/10/14 16:44:52 DEBUG : /: >Releasedir: errc=0
2019/10/14 16:45:52 DEBUG : Cache remote driveCache:: starting cleanup
2019/10/14 16:45:52 DEBUG : Google drive root 'Enc': Checking for changes on remote
2019/10/14 16:45:52 DEBUG : Cache remote driveCache:: starting cleanup
2019/10/14 16:45:52 DEBUG : Google drive root 'Enc': Checking for changes on remote
2019/10/14 16:46:52 DEBUG : Google drive root 'Enc': Checking for changes on remote
2019/10/14 16:46:52 DEBUG : Google drive root 'Enc': Checking for changes on remote
2019/10/14 16:47:02 DEBUG : Cache remote driveCache:: starting cleanup
2019/10/14 16:47:02 DEBUG : Cache remote driveCache:: starting cleanup
2019/10/14 16:47:52 DEBUG : Google drive root 'Enc': Checking for changes on remote
2019/10/14 16:47:52 DEBUG : Google drive root 'Enc': Checking for changes on remote
2019/10/14 16:48:02 DEBUG : Cache remote driveCache:: starting cleanup
2019/10/14 16:48:02 DEBUG : Cache remote driveCache:: starting cleanup
2019/10/14 16:48:52 DEBUG : Google drive root 'Enc': Checking for changes on remote
2019/10/14 16:48:52 DEBUG : Google drive root 'Enc': Checking for changes on remote
2019/10/14 16:49:02 DEBUG : Cache remote driveCache:: starting cleanup
2019/10/14 16:49:02 DEBUG : Cache remote driveCache:: starting cleanup
2019/10/14 16:49:52 DEBUG : Google drive root 'Enc': Checking for changes on remote
2019/10/14 16:49:52 DEBUG : Google drive root 'Enc': Checking for changes on remote
2019/10/14 16:50:02 DEBUG : Cache remote driveCache:: starting cleanup
2019/10/14 16:50:02 DEBUG : Cache remote driveCache:: starting cleanup
2019/10/14 16:50:52 DEBUG : Google drive root 'Enc': Checking for changes on remote
2019/10/14 16:50:52 DEBUG : Google drive root 'Enc': Checking for changes on remote
2019/10/14 16:51:02 DEBUG : Cache remote driveCache:: starting cleanup
2019/10/14 16:51:02 DEBUG : Cache remote driveCache:: starting cleanup
2019/10/14 16:51:52 DEBUG : Google drive root 'Enc': Checking for changes on remote
2019/10/14 16:51:52 DEBUG : Google drive root 'Enc': Checking for changes on remote
2019/10/14 16:52:02 DEBUG : Cache remote driveCache:: starting cleanup
2019/10/14 16:52:02 DEBUG : Cache remote driveCache:: starting cleanup
2019/10/14 16:52:52 DEBUG : Google drive root 'Enc': Checking for changes on remote
2019/10/14 16:52:52 DEBUG : Google drive root 'Enc': Checking for changes on remote
2019/10/14 16:53:02 DEBUG : Cache remote driveCache:: starting cleanup
2019/10/14 16:53:02 DEBUG : Cache remote driveCache:: starting cleanup
2019/10/14 16:53:52 DEBUG : Google drive root 'Enc': Checking for changes on remote
2019/10/14 16:53:52 DEBUG : Google drive root 'Enc': Checking for changes on remote
2019/10/14 16:54:02 DEBUG : Cache remote driveCache:: starting cleanup
2019/10/14 16:54:02 DEBUG : Cache remote driveCache:: starting cleanup

Everything seems to be OK, but the "X:" drive never shows up. I have tried on Windows 10 and now on this fresh 2016 install and have gotten the same results. Any help would be appreciated.

Thank you!

I expect you are running it under the SYSTEM account (because it's set up as a service or in task-manager under SYSTEM), but you have not set the --allow-other flag.
That might cause it to be inaccessible to you (another user presumably). Any other services that need to access it must be also run under an account that has access to the drive - just in general. In terms of permissions and such.

BTW - be careful using --allow-non-empty . I don't see why you need it, and it can cause some significant problems if you don't use it correctly. Recommend removing that unless you are sure you know what you are doing and that you absolutely need it.

hello and welcome to the rclone forum,

  1. you might be using an old version of winfsp. tho i do not think that is the cause of your current problem.
  2. there seem to be a bunch of bugs and problems with rclone 1.49.5, perhaps try a old version. tho i do not thing that is the cause of your current problem.

i agree the @thestigma,
so try this

  1. open a .cmd prompt as administrator.
  2. run your rclone command
  3. open another .cmd prompt as administrator and try dir x:

if that does not work, create a task in task scheduler, make sure it runs under your username and then open a command prompt not as administrator and try dir x:

Are you sure SYSTEM account access will translate to Administrator account though? I don't think I have tested this, but they are separate accounts, so I wouldn't take that for granted unless you know for sure.

BTW did the OP just edit in the --allow-other flag now, or did I completely miss that it was already there? If so, sorry OP :slight_smile: In any case --allow-other should remove this limitation and it should generally be visible and available to everyone by default. If it's still not showing up I think we have a different problem somewhere.

Good idea to do a check on X from cmd in any case - just to eliminate any problem with explorer simply not showing the drive (certain registry setting can hide drives ect.)

Do note it is perfectly normal to need to wait 3-4 seconds for a drive to start showing and you may even need to F5 refresh.

also, take a look at this.
not sure how anybody gets anything done without it.

https://support.microsoft.com/en-us/help/3035277/mapped-drives-are-not-available-from-an-elevated-prompt-when-uac-is-co

and you had access without --allow-other ? I'm not trying to contradict you here, just picking up useful knowledge for myself :slight_smile: I don't think I have tried this exact thing.

sorry, i got confused as to what post i was replying to, that last post was for another topic and so i just withdrew it.

in post --cache-dir doesn't work for network location, i demonstrated that running rclone mount as system user and accessing the mount using command prompt.
and i do not user windows explorer at all, i use double commander

my original script had --allow-other and that worked fine.
but since you asked what would happen without --allow-other, i just changed the script to:

whoami > logfile.txt
net use z: \\servername\sharefolder /user:username password
set flags=--dir-cache-time=72h --drive-chunk-size=64M --vfs-read-chunk-size=32M --vfs-read-chunk-size-limit=off --vfs-cache-mode=writes --cache-dir=z: --log-level=DEBUG
set mountsource=wasabiwest01:thetestfolder
set mountdrive=x:
set logfile=--log-file=logfile.txt
rclone.exe mount %mountsource% %mountdrive% %flags% %logfile%

i was able to access the mount x: using elevated and non-elevated command prompts and i can also see it in double commander.

ok, useful to know. Some permissions must be transferring between system and admin then.

WOW!!!! I was running PowerShell as an admin and not my normal account. I ran it as my account and low and behold, the drive showed up. Apparently the --allow-other wasn't working.

This is on rclone 1.49.5 by the way. You guys are the absolute best. I couldn't be more thankful.

good news,

as i understand it, the issue is not --allow-others flag.

the admin vs normal account issue you experienced is done by microsoft intentionally and for good reason for the typical end-user.

for a power user, it is a pain in the glass so i suggest that you make this one registry change.

https://support.microsoft.com/en-us/help/3035277/mapped-drives-are-not-available-from-an-elevated-prompt-when-uac-is-co

Perhaps some documentation clean up as "allow-other" is related to Linux fuse as an option as that fuse parameter does not exist on WinFSP.

good point, i could do more testing on windows.

So in other words it does nothing on Windows? If so then yes, very relevant.

I had a grep through the WinFSP source code and I don't think that it understands allow-other. I couldn't find a doc which options WinFSP/FUSE does support though.

This?


(linked by Animosity in the other thread)

That is the source code file I was looking at. Bill Z has probably written a nice doc though, we just haven't found it yet!

please see my post

it seems that the allow-other does NOTHING on windows,

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