Rafa-RHCP 0 Posted February 26, 2020 Posted February 26, 2020 Hello guys, i´m new at this community and was reading this topic. I got the same issue. I installed Emby on a VPS and use RClone connected to Google Drive but when I try to pick the media to the library only part of the path (or even none of the paths) show up in order it´s impossible to go ahead with this process. I tried to unmount Rclone drive several times, changed folder location both to / and /home and nothing changes. It´s important to say that it happens both in Ubuntu 18.04 LTS and CentOs 8. I have also changed local folder "GDrive" permissions to 777 and user to "emby" but once i mount it, Rclone automatically rolls back permissions to root again. Does anybody know what else can I do to solve this? Thanks in advance.
Luke 42077 Posted March 1, 2020 Posted March 1, 2020 Hello guys, i´m new at this community and was reading this topic. I got the same issue. I installed Emby on a VPS and use RClone connected to Google Drive but when I try to pick the media to the library only part of the path (or even none of the paths) show up in order it´s impossible to go ahead with this process. I tried to unmount Rclone drive several times, changed folder location both to / and /home and nothing changes. It´s important to say that it happens both in Ubuntu 18.04 LTS and CentOs 8. I have also changed local folder "GDrive" permissions to 777 and user to "emby" but once i mount it, Rclone automatically rolls back permissions to root again. Does anybody know what else can I do to solve this? Thanks in advance. @@kikinjo, @@horstepipe, @igeorge, @@tdiguy, @@Kyouma, @@fbrassin, @@cybergrimes, @@JaScoMa, @@shocker do you have any tips on using rclone this way?
fbrassin 47 Posted March 1, 2020 Posted March 1, 2020 Hello guys, i´m new at this community and was reading this topic. I got the same issue. I installed Emby on a VPS and use RClone connected to Google Drive but when I try to pick the media to the library only part of the path (or even none of the paths) show up in order it´s impossible to go ahead with this process. I tried to unmount Rclone drive several times, changed folder location both to / and /home and nothing changes. It´s important to say that it happens both in Ubuntu 18.04 LTS and CentOs 8. I have also changed local folder "GDrive" permissions to 777 and user to "emby" but once i mount it, Rclone automatically rolls back permissions to root again. Does anybody know what else can I do to solve this? Thanks in advance. I think this problem is related to rclone config and not about emby. I think you could be helped posting your problem and rclone config in rclone forum.
kikinjo 281 Posted March 1, 2020 Posted March 1, 2020 This sounds like folder permissions, not related to emby. How are u running rclone with sudo or without ? Where is your config located, paste the path here. Also as fbrassin sais, post the rclone config and mount command.
shocker 135 Posted March 1, 2020 Posted March 1, 2020 Indeed sound like a permission issue. A basic mount command can be: rclone mount thedrive_from_config: /path/to/your/mount --config=/path/to/your/config/rclone.conf --allow-other --dir-cache-time 48h --vfs-cache-max-age 48h --vfs-read-chunk-size 10M --vfs-read-chunk-size-limit 512M --buffer-size 512M --syslog --umask 002 --allow-non-empty --fast-list --use-mmap --vfs-cache-mode=minimal --vfs-cache-max-size=4G --dir-cache-time=96h --timeout 1h --attr-timeout=1s --log-level INFO You create a folder with emby permission, but once mounted it will get the mount permission as you have inside. You can change after the mount the permissions with: chown -R emby:emby /path/to/your/mount
Rafa-RHCP 0 Posted March 1, 2020 Posted March 1, 2020 Indeed sound like a permission issue. A basic mount command can be: rclone mount thedrive_from_config: /path/to/your/mount --config=/path/to/your/config/rclone.conf --allow-other --dir-cache-time 48h --vfs-cache-max-age 48h --vfs-read-chunk-size 10M --vfs-read-chunk-size-limit 512M --buffer-size 512M --syslog --umask 002 --allow-non-empty --fast-list --use-mmap --vfs-cache-mode=minimal --vfs-cache-max-size=4G --dir-cache-time=96h --timeout 1h --attr-timeout=1s --log-level INFO You create a folder with emby permission, but once mounted it will get the mount permission as you have inside. You can change after the mount the permissions with: chown -R emby:emby /path/to/your/mount I did as you suggested but nothing different happened. These are the steps i´ve done (commented) root@emby:/home# adduser rclone (created a new user for rclone) Adding user `rclone' ... Adding new group `rclone' (1000) ... Adding new user `rclone' (1000) with group `rclone' ... Creating home directory `/home/rclone' ... Copying files from `/etc/skel' ... Enter new UNIX password: Retype new UNIX password: passwd: password updated successfully Changing the user information for rclone Enter the new value, or press ENTER for the default Full Name []: Room Number []: Work Phone []: Home Phone []: Other []: Is the information correct? [Y/n] y root@emby:/home# ls -l total 4 drwxr-xr-x 2 rclone rclone 4096 Mar 1 22:03 rclone root@emby:/home# # adduser rclone sudo (adding rclone user to sudo group) root@emby:/home# su rclone rclone@emby:/home$ cd /home/ rclone@emby:/home$ ls -l total 4 drwxr-xr-x 2 rclone rclone 4096 Mar 1 22:03 rclone (the folder for user rclone has a default permission) rclone@emby$ su root Password: root@emby:/# chown rclone:root rclone (changing rclone group to root) root@emby:/# chown -R 777 rclone (changing all permissions) root@emby:/# cd /home/ root@emby:/home# ls -l total 4 drwxrwxrwx 2 rclone root 4096 Mar 1 22:03 rclone (Note that it kept the permissions i just set) root@emby:/home# su rclone (running as user rclone) rclone@emby:/home$ cd /home/rclone rclone@emby:~$ mkdir GDrive (creating a mounting folder) rclone@emby:~$ chmod -R 777 GDrive (giving it full access) rclone@emby:~$ ls -l total 4 root@emby:/home/rclone# nohup rclone mount GDrive: /home/rclone/Gdrive --allow-non-empty --config=/root/.config/rclone/rclone.conf --allow-other --dir-cache-time 48h --vfs-cache-max-age 48h --vfs-read-chunk-size 10M --vfs-read-chunk-size-limit 512M --buffer-size 512M --syslog --umask 002 --allow-non-empty --fast-list --use-mmap --vfs-cache-mode=minimal --vfs-cache-max-size=4G --dir-cache-time=96h --timeout 1h --attr-timeout=1s --log-level INFO (run the command @@shocker suggested but just added --allow-non-empty) root@emby:/home/rclone# cd /home/rclone/GDrive/ root@emby:/home/rclone/GDrive# ls -l total 0 (It didn´t work) root@emby:/home/rclone/GDrive# nohup rclone mount GDrive: /home/rclone/GDrive --allow-non-empty & [1] 1270 root@emby:/home/rclone/GDrive# nohup: ignoring input and appending output to 'nohup.out' (Worked now) root@emby:/home/rclone/GDrive# cd /home/rclone/GDrive/ root@emby:/home/rclone/GDrive# ls -l total 64226 -rw-r--r-- 1 root root 241396 Jan 17 00:16 'MOVIES' (Mount permission is only for root now) root@emby:/home/rclone/GDrive# su rclone (logged as user rclone now) rclone@emby:~/GDrive$ cd /home/rclone/ rclone@emby:~$ ls -l (checking permissions) ls: cannot access 'GDrive': Permission denied (WTF!!!) total 4 d????????? ? ? ? ? ? GDrive
Rafa-RHCP 0 Posted March 1, 2020 Posted March 1, 2020 These are the steps i performed: >I create a new droplet with Ubuntu 18.04.3 LTS on a VPS by DigitalOcean. This droplet is simple and didn´t use any special features but the defaults. >All repositories were updated using apt-get update && apt-get upgrade && apt-get autoremove -y -y >Then i downloaded Emby Server and ran dpkg -i emby-server-deb_4.3.1.0_amd64.deb >Emby user was "emby" >Rclone was installed with curl https://rclone.org/install.sh | sudo bash > Run rclone config and created a New remote for Google Drive called "GDrive" > Created a new user named rclone and gave it full permissions > Inside /home/rclone i created GDrive folder with full permissions >Logged as root I ran nohup rclone mount GDrive: /home/rclone/GDrive --allow-non-empty & >Emby stills not showing the beyond /home/rclone when looking out folders PS: Rclone and Emby were installed as root but i´m unable to run them and mount Rclone using another user. I also believe the issue is not on Emby but on RClone mounting permissions but I really believe someone here had this problem before and this information can be useful
Rafa-RHCP 0 Posted March 2, 2020 Posted March 2, 2020 (edited) UPDATE: I could run Rclone mounting as common user rclone (non-root) and it loaded Google Drive files but i´m still unable to see the directories under /home/rclone through Emby. In GDrive folder its permissions are drwxrwxr-x 1 rclone rclone 0 Aug 9 2019 I also used the same strategy @@Polonha did by changing "emby" service account to rclone group but stills not working That´s the latest log I got from Emby System.UnauthorizedAccessException: System.UnauthorizedAccessException: Access to the path '/home/rclone/GDrive' is denied. ---> System.IO.IOException: Permission denied --- End of inner exception stack trace --- at System.IO.Enumeration.FileSystemEnumerator`1.CreateDirectoryHandle(String path, Boolean ignoreNotFound) at System.IO.Enumeration.FileSystemEnumerator`1..ctor(String directory, EnumerationOptions options) at System.IO.Enumeration.FileSystemEnumerable`1..ctor(String directory, FindTransform transform, EnumerationOptions options) at System.IO.Enumeration.FileSystemEnumerableFactory.FileSystemInfos(String directory, String expression, EnumerationOptions options) at System.IO.DirectoryInfo.InternalEnumerateInfos(String path, String searchPattern, SearchTarget searchTarget, EnumerationOptions options) at System.IO.DirectoryInfo.EnumerateFileSystemInfos(String searchPattern, SearchOption searchOption) at Emby.Server.Implementations.IO.ManagedFileSystem.GetFileSystemEntries(String path, Boolean recursive) at MediaBrowser.Api.EnvironmentService.GetFileSystemEntries(GetDirectoryContents request) at MediaBrowser.Api.EnvironmentService.Get(GetDirectoryContents request) at Emby.Server.Implementations.Services.ServiceController.Execute(HttpListenerHost appHost, Object requestDto, IRequest req) at Emby.Server.Implementations.Services.ServiceHandler.ProcessRequestAsync(HttpListenerHost appHost, IRequest httpReq, IResponse httpRes, RestPath restPath, String responseContentType, CancellationToken cancellationToken) at Emby.Server.Implementations.HttpServer.HttpListenerHost.RequestHandler(IRequest httpReq, ReadOnlyMemory`1 urlString, ReadOnlyMemory`1 localPath, CancellationToken cancellationToken) Source: System.IO.FileSystem TargetSite: IntPtr CreateDirectoryHandle(System.String, Boolean) InnerException: System.IO.IOException: Permission denied Source: TargetSite: Does anyone have further suggestions? Edited March 2, 2020 by Rafa-RHCP
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now