Files not accessible on union remote

What is the problem you are having with rclone?

New files added to a union remote are no longer accessible by the Plex Media Scanner. This only affects files from the last three or four days and only one of a bunch of union remotes which use identical settings but differen upstreams and moint points, of course. The union remote consists of a GD and a local upstream. It doesn't matter where the files reside. They cannot be accessed neither from the remote nor local upstream

The mount commands run as windows services. It doesn't make a difference if they are started by the windows system account or the user running PMS. I also mounted the remote from a command prompt logged in as the user running PMS what didn't make any difference regarding the behaviour.

When the local upstream is presented to Plex as a seperate media folder (not through rclone but as a standard windows directory), everything works fine and as expected.

So in general, it looks pretty much like a permission problem, but i have no idea how to fix that other than adding the --allow-other flag to the mount, which didn't solve the problem.

Run the command 'rclone version' and share the full output of the command.

rclone v1.58.0-beta.5948.c504d9701

  • os/version: Microsoft Windows 10 Enterprise 2009 (64 bit)
  • os/kernel: 10.0.19042.1466 (x86_64)
  • os/type: windows
  • os/arch: amd64
  • go/version: go1.17.6
  • go/linking: dynamic
  • go/tags: cmount

Tested with versions from 1.51.0 up to latest beta.

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

Google Drive

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

rclone mount movies-u: c:\mnt\union\movies-u --stats=0 --checkers=16 --vfs-read-chunk-size 128M --vfs-read-chunk-size-limit 2G --drive-use-trash --vfs-cache-mode full --allow-other

The rclone config contents with secrets removed.

[gdrive_crypt]
type = crypt
remote = gdrive:Video/
filename_encryption = standard
password = ***
password2 = ***

[movies-u]
type = union
upstreams = gdrive_crypt:/Movies:nc c:\mnt\local\movies-local

A log from the command with the -vv flag

Mount Init and portion when Plex is scanning the directories where access fails:

2022/01/22 11:29:03 DEBUG : rclone: Version "v1.58.0-beta.5948.c504d9701" starting with parameters ["C:\\tools\\rclone\\rclone.exe" "mount" "movies-u:" "c:\\mnt\\union\\movies-u" "--log-file" "c:\\logs\\rc-movies-u.log" "--rc" "--rc-addr" "localhost:9506" "--stats=0" "--checkers=16" "--drive-chunk-size" "32M" "-vv" "--vfs-read-chunk-size" "128M" "--vfs-read-chunk-size-limit" "2G" "--drive-use-trash" "--config" "c:\\config\\rclone\\rclone.conf" "--vfs-cache-mode" "full" "--allow-other"]
2022/01/22 11:29:03 NOTICE: Serving remote control on http://localhost:9506/
2022/01/22 11:29:03 DEBUG : Creating backend with remote "movies-u:"
2022/01/22 11:29:03 DEBUG : Using config file from "c:\\config\\rclone\\rclone.conf"
2022/01/22 11:29:03 DEBUG : Creating backend with remote "c:/mnt/local/movies-local"
2022/01/22 11:29:03 DEBUG : Creating backend with remote "gdrive_crypt:/Filme"
2022/01/22 11:29:03 DEBUG : fs cache: renaming cache item "c:/mnt/local/movies-local" to be canonical "//?/c:/mnt/local/movies-local"
2022/01/22 11:29:03 DEBUG : fs cache: switching user supplied name "c:/mnt/local/movies-local" for canonical name "//?/c:/mnt/local/movies-local"
2022/01/22 11:29:03 DEBUG : Creating backend with remote "gdrive:Video/psgidn4mpgrn4q77b2kre1dpn0"
2022/01/22 11:29:03 DEBUG : gdrive: detected overridden config - adding "{oFuT8}" suffix to name
2022/01/22 11:29:04 DEBUG : fs cache: renaming cache item "gdrive:Video/psgidn4mpgrn4q77b2kre1dpn0" to be canonical "gdrive{oFuT8}:Video/psgidn4mpgrn4q77b2kre1dpn0"
2022/01/22 11:29:04 DEBUG : fs cache: switching user supplied name "gdrive:Video/psgidn4mpgrn4q77b2kre1dpn0" for canonical name "gdrive{oFuT8}:Video/psgidn4mpgrn4q77b2kre1dpn0"
2022/01/22 11:29:04 DEBUG : union root '': actionPolicy = *policy.EpAll, createPolicy = *policy.EpMfs, searchPolicy = *policy.FF
2022/01/22 11:29:04 NOTICE: --allow-other flag does nothing on Windows
2022/01/22 11:29:04 INFO  : union root '': poll-interval is not supported by this remote
2022/01/22 11:29:04 DEBUG : vfs cache: root is "C:\\Windows\\system32\\config\\systemprofile\\AppData\\Local\\rclone"
2022/01/22 11:29:04 DEBUG : vfs cache: data root is "\\\\?\\C:\\Windows\\system32\\config\\systemprofile\\AppData\\Local\\rclone\\vfs\\movies-u"
2022/01/22 11:29:04 DEBUG : vfs cache: metadata root is "\\\\?\\C:\\Windows\\system32\\config\\systemprofile\\AppData\\Local\\rclone\\vfsMeta\\movies-u"
2022/01/22 11:29:04 DEBUG : Creating backend with remote "C:/Windows/system32/config/systemprofile/AppData/Local/rclone/vfs/movies-u/"
2022/01/22 11:29:04 DEBUG : fs cache: renaming cache item "C:/Windows/system32/config/systemprofile/AppData/Local/rclone/vfs/movies-u/" to be canonical "//?/C:/Windows/system32/config/systemprofile/AppData/Local/rclone/vfs/movies-u/"
2022/01/22 11:29:04 DEBUG : Creating backend with remote "C:/Windows/system32/config/systemprofile/AppData/Local/rclone/vfsMeta/movies-u/"
2022/01/22 11:29:04 DEBUG : fs cache: renaming cache item "C:/Windows/system32/config/systemprofile/AppData/Local/rclone/vfsMeta/movies-u/" to be canonical "//?/C:/Windows/system32/config/systemprofile/AppData/Local/rclone/vfsMeta/movies-u/"
2022/01/22 11:29:04 DEBUG : vfs cache RemoveNotInUse (maxAge=3600000000000, emptyOnly=false): item Angel Has Fallen (2019)/Angel Has Fallen (2019) - [BLURAY-1080P][DTS 5.1][X264]-ENCOUNTERS.mkv not removed, freed 0 bytes
2022/01/22 11:29:04 INFO  : vfs cache: cleaned: objects 1 (was 1) in use 0, to upload 0, uploading 0, total size 45.106Mi (was 45.106Mi)
2022/01/22 11:29:04 DEBUG : Network mode mounting is disabled
2022/01/22 11:29:04 DEBUG : Mounting on "c:\\mnt\\union\\movies-u" ("movies-u")
2022/01/22 11:29:04 DEBUG : union root '': Mounting with options: ["-o" "attr_timeout=1" "-o" "uid=-1" "-o" "gid=-1" "--FileSystemName=rclone" "-o" "volname=movies-u"]
2022/01/22 11:29:04 DEBUG : union root '': Init: 
2022/01/22 11:29:04 DEBUG : union root '': >Init: 
2022/01/22 11:29:04 DEBUG : /: Statfs: 
2022/01/22 11:29:04 DEBUG : /: >Statfs: stat={Bsize:4096 Frsize:4096 Blocks:298870916816 Bfree:274877906944 Bavail:274877906944 Files:1000000000 Ffree:1000000000 Favail:0 Fsid:0 Flag:0 Namemax:255}, errc=0
[...]
2022/01/22 11:12:57 DEBUG : /: Releasedir: fh=0x2
2022/01/22 11:12:57 DEBUG : /: >Releasedir: errc=0
2022/01/22 11:13:07 DEBUG : /: Releasedir: fh=0x0
2022/01/22 11:13:07 DEBUG : /: >Releasedir: errc=0
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): Getattr: fh=0xFFFFFFFFFFFFFFFF
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): >Getattr: errc=0
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): Getattr: fh=0xFFFFFFFFFFFFFFFF
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): >Getattr: errc=0
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): Opendir: 
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): OpenFile: flags=O_RDONLY, perm=-rwxrwxrwx
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): >OpenFile: fd=Angel Has Fallen (2019)/ (r), err=<nil>
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): >Opendir: errc=0, fh=0x0
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): Readdir: ofst=0, fh=0x0
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): >Readdir: items=2, errc=0
2022/01/22 11:13:07 DEBUG : /: Getattr: fh=0xFFFFFFFFFFFFFFFF
2022/01/22 11:13:07 DEBUG : /: >Getattr: errc=0
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): Getattr: fh=0xFFFFFFFFFFFFFFFF
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): >Getattr: errc=0
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): Getattr: fh=0xFFFFFFFFFFFFFFFF
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): >Getattr: errc=0
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): Getattr: fh=0xFFFFFFFFFFFFFFFF
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): >Getattr: errc=0
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): Opendir: 
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): OpenFile: flags=O_RDONLY, perm=-rwxrwxrwx
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): >OpenFile: fd=Angel Has Fallen (2019)/ (r), err=<nil>
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): >Opendir: errc=0, fh=0x2
2022/01/22 11:13:07 DEBUG : /: Releasedir: fh=0x1
2022/01/22 11:13:07 DEBUG : /: >Releasedir: errc=0
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): Releasedir: fh=0x0
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): >Releasedir: errc=0
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): Getattr: fh=0xFFFFFFFFFFFFFFFF
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): >Getattr: errc=0
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): Getattr: fh=0xFFFFFFFFFFFFFFFF
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): >Getattr: errc=0
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): Opendir: 
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): OpenFile: flags=O_RDONLY, perm=-rwxrwxrwx
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): >OpenFile: fd=Angel Has Fallen (2019)/ (r), err=<nil>
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): >Opendir: errc=0, fh=0x0
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): Getattr: fh=0xFFFFFFFFFFFFFFFF
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): >Getattr: errc=0
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): Getattr: fh=0xFFFFFFFFFFFFFFFF
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): >Getattr: errc=0
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): Opendir: 
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): OpenFile: flags=O_RDONLY, perm=-rwxrwxrwx
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): >OpenFile: fd=Angel Has Fallen (2019)/ (r), err=<nil>
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): >Opendir: errc=0, fh=0x1
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): Releasedir: fh=0x1
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): >Releasedir: errc=0
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): Getattr: fh=0xFFFFFFFFFFFFFFFF
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): >Getattr: errc=0
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): Getattr: fh=0xFFFFFFFFFFFFFFFF
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): >Getattr: errc=0
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): Opendir: 
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): OpenFile: flags=O_RDONLY, perm=-rwxrwxrwx
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): >OpenFile: fd=Angel Has Fallen (2019)/ (r), err=<nil>
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): >Opendir: errc=0, fh=0x1
2022/01/22 11:13:07 DEBUG : /: Statfs: 
2022/01/22 11:13:07 DEBUG : /: >Statfs: stat={Bsize:4096 Frsize:4096 Blocks:298870896329 Bfree:274877906944 Bavail:274877906944 Files:1000000000 Ffree:1000000000 Favail:0 Fsid:0 Flag:0 Namemax:255}, errc=0
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): Releasedir: fh=0x1
2022/01/22 11:13:07 DEBUG : /Angel Has Fallen (2019): >Releasedir: errc=0
2022/01/22 11:13:09 DEBUG : /Angel Has Fallen (2019): Releasedir: fh=0x0
2022/01/22 11:13:09 DEBUG : /Angel Has Fallen (2019): >Releasedir: errc=0
2022/01/22 11:13:09 DEBUG : /: Getattr: fh=0xFFFFFFFFFFFFFFFF
2022/01/22 11:13:09 DEBUG : /: >Getattr: errc=0
2022/01/22 11:13:09 DEBUG : /: Getattr: fh=0xFFFFFFFFFFFFFFFF
2022/01/22 11:13:09 DEBUG : /: >Getattr: errc=0
2022/01/22 11:13:09 DEBUG : /: Opendir: 
2022/01/22 11:13:09 DEBUG : /: OpenFile: flags=O_RDONLY, perm=-rwxrwxrwx
2022/01/22 11:13:09 DEBUG : /: >OpenFile: fd=/ (r), err=<nil>
2022/01/22 11:13:09 DEBUG : /: >Opendir: errc=0, fh=0x0
2022/01/22 11:13:09 DEBUG : /: Readdir: ofst=0, fh=0x0
2022/01/22 11:13:09 DEBUG : /: >Readdir: items=2867, errc=0
2022/01/22 11:13:09 DEBUG : /: Getattr: fh=0xFFFFFFFFFFFFFFFF
2022/01/22 11:13:09 DEBUG : /: >Getattr: errc=0
2022/01/22 11:13:09 DEBUG : /: Getattr: fh=0xFFFFFFFFFFFFFFFF
2022/01/22 11:13:09 DEBUG : /: >Getattr: errc=0
2022/01/22 11:13:09 DEBUG : /: Opendir: 
2022/01/22 11:13:09 DEBUG : /: OpenFile: flags=O_RDONLY, perm=-rwxrwxrwx
2022/01/22 11:13:09 DEBUG : /: >OpenFile: fd=/ (r), err=<nil>
2022/01/22 11:13:09 DEBUG : /: >Opendir: errc=0, fh=0x1
2022/01/22 11:13:09 DEBUG : /Angel Has Fallen (2019): Releasedir: fh=0x2
2022/01/22 11:13:09 DEBUG : /Angel Has Fallen (2019): >Releasedir: errc=0
2022/01/22 11:13:09 DEBUG : /: Releasedir: fh=0x0
2022/01/22 11:13:09 DEBUG : /: >Releasedir: errc=0
2022/01/22 11:13:09 DEBUG : /: Getattr: fh=0xFFFFFFFFFFFFFFFF
2022/01/22 11:13:09 DEBUG : /: >Getattr: errc=0
2022/01/22 11:13:09 DEBUG : /: Getattr: fh=0xFFFFFFFFFFFFFFFF
2022/01/22 11:13:09 DEBUG : /: >Getattr: errc=0
2022/01/22 11:13:09 DEBUG : /: Opendir: 
2022/01/22 11:13:09 DEBUG : /: OpenFile: flags=O_RDONLY, perm=-rwxrwxrwx
2022/01/22 11:13:09 DEBUG : /: >OpenFile: fd=/ (r), err=<nil>
2022/01/22 11:13:09 DEBUG : /: >Opendir: errc=0, fh=0x0
2022/01/22 11:13:09 DEBUG : /: Getattr: fh=0xFFFFFFFFFFFFFFFF
2022/01/22 11:13:09 DEBUG : /: >Getattr: errc=0
2022/01/22 11:13:09 DEBUG : /: Getattr: fh=0xFFFFFFFFFFFFFFFF
2022/01/22 11:13:09 DEBUG : /: >Getattr: errc=0
2022/01/22 11:13:09 DEBUG : /: Opendir: 
2022/01/22 11:13:09 DEBUG : /: OpenFile: flags=O_RDONLY, perm=-rwxrwxrwx
2022/01/22 11:13:09 DEBUG : /: >OpenFile: fd=/ (r), err=<nil>
2022/01/22 11:13:09 DEBUG : /: >Opendir: errc=0, fh=0x2
2022/01/22 11:13:09 DEBUG : /: Statfs: 
2022/01/22 11:13:09 DEBUG : /: >Statfs: stat={Bsize:4096 Frsize:4096 Blocks:298870896329 Bfree:274877906944 Bavail:274877906944 Files:1000000000 Ffree:1000000000 Favail:0 Fsid:0 Flag:0 Namemax:255}, errc=0

This is the corresponding log section from Plex. Apparently, the error message is reported by the OS and not by PMS as it is written in German and means the system cannot find the dedicated file or directory

Jan 22, 2022 11:14:12.636 [5116] DEBUG - Scanner: Processing directory C:\mnt\union\movies-u\Angel Has Fallen (2019) (parent: yes)
Jan 22, 2022 11:14:12.644 [5116] DEBUG - Directory had 1 files, database had 0 files, can't skip.
Jan 22, 2022 11:14:12.649 [5116] WARN - Error scanning directory, we'll skip and continue: boost::filesystem::relative: Das System kann die angegebene Datei nicht finden: "C:\mnt\union\movies-u\Angel Has Fallen (2019)\Angel Has Fallen (2019) - [BLURAY-1080P][DTS 5.1][X264]-ENCOUNTERS.mkv", "C:\mnt\union\movies-u"

If you remove Plex from the equation, what happens if you browse to that location? Can you see the file? Can you access it? Not sure what mediainfo alternative is on Windows, but something to check the file out?

That does nothing on Windows and can be removed.

That does nothing on a mount and can be removed.

That's the default so you can remove it.

Any reason to set that to 2G?

I can browse the location and can play the file through the union mount with a player running on the machine locally like VLC with no issues.

I would not blame rclone for the issues if it would not make a difference if Plex sees the files through the union mount point or as a windows directory just provided as an additional media folder.

Thanks for the annotations regarding the mount command. I will shorten it.

If I repeat that back:

  • You can browse and see the files
  • You can play it via VLC via the rclone mount
  • Plex cannot do the same thing

Is that right? Would seem like a permissions issue or something with Plex.

This is correct.

The service creating the mount point as well as Plex are run by the same user account. And this is also the same account which can play the media by using VLC. So permissions should be find from my understanding.

The files / directories affected had been created by Radarr, which also runs under the same user account as all the other services involved. I also tried to create a new directory manually and copied the files over but with no success.

The union which serves my tv show library to Plex relies on the exact same structure and has not shown any issues even with newly added content. Therefore it is really hard to tell who's the guilty one here.

I'm not a Windows guy so not sure what Plex does on Windows.

You've shared that every app works but Plex so seems like that's the focal point as I'm not sure what does unique on Windows or why one folder would throw a permissions error.

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