pvoveris 0 Posted August 13, 2019 Share Posted August 13, 2019 Is there a way to configure Emby to create it's files to be owned by someone other than root? I recently installed Emby on my NAS and every time it adds files they are owned by root, which cause some problems when trying to open them. Emby Server version 4.2.1.0 QNAP firmware 4.3.6.0993 Kind Regards, Peter Link to comment Share on other sites More sharing options...
Luke 37071 Posted August 13, 2019 Share Posted August 13, 2019 Hi, can you please give an example? What files are you referring to? Thanks. Link to comment Share on other sites More sharing options...
pvoveris 0 Posted August 13, 2019 Author Share Posted August 13, 2019 Sure, those files would be items such as Info, Subtitles, Posters. Basically any metadata that Emby discovers about my media and creates and stores a file. Peter Link to comment Share on other sites More sharing options...
Luke 37071 Posted August 13, 2019 Share Posted August 13, 2019 You mean files inside your media directory? Link to comment Share on other sites More sharing options...
pvoveris 0 Posted August 13, 2019 Author Share Posted August 13, 2019 That is correct. Link to comment Share on other sites More sharing options...
alucryd 216 Posted August 14, 2019 Share Posted August 14, 2019 The server is started as root, so any file created by emby will belong to root. Even if they're owned by root, they should be mod 644 and be at least world-readable, could you check what mod those files are? There is no easy way to change the user on the qnap side. One thing you can already do though if the mod is something like 640 is set the sticky bit on your media folders, that way any file that emby creates will belong to the group of your user instead of root. Link to comment Share on other sites More sharing options...
pvoveris 0 Posted August 15, 2019 Author Share Posted August 15, 2019 Thanks, I will give that a try and see how it works out. Link to comment Share on other sites More sharing options...
pvoveris 0 Posted August 15, 2019 Author Share Posted August 15, 2019 Didn't seem to accomplish anything, this is the permissions of the files Emby creates in the media folders on the NAS. drwxrwxrwx 3 pvoveris pvoveris 4096 Aug 15 09:23 ./ drwxrwxrwx 3 pvoveris pvoveris 4096 Aug 15 09:23 ../ -rw-rw---- 1 root root 14535 Aug 15 09:23 'Pennyworth (2019) - S01E01 - Pilot-thumb.jpg' -rw-rw---- 1 root root 70812 Aug 15 09:23 'Pennyworth (2019) - S01E02 - The Landlord`s Daughter-thumb.jpg' -rw-rw---- 1 root root 106211 Aug 15 09:23 'Pennyworth (2019) - S01E03 - Martha Kane-thumb.jpg' -rw-rw---- 1 root root 1919 Aug 15 05:08 'Pennyworth - S01E04 - Lady Penelope.nfo' -rw-rw---- 1 root root 76275 Aug 15 09:23 'Pennyworth - S01E04 - Lady Penelope-thumb.jpg' -rw-rwx--- 1 pvoveris pvoveris 427 Aug 9 15:53 season.nfo* drwxrwxrwx 3 pvoveris pvoveris 4096 Jul 30 18:53 '.@__thumb'/ Link to comment Share on other sites More sharing options...
alucryd 216 Posted August 16, 2019 Share Posted August 16, 2019 Sorry I did it again, I mean setgid, not sticky bit. You can do that recursively with: find . -type d -exec chmod g+s {} + Your directories should be rws on the second triplet after that. Link to comment Share on other sites More sharing options...
Luke 37071 Posted August 27, 2019 Share Posted August 27, 2019 @@pvoveris how did this go? Link to comment Share on other sites More sharing options...
pvoveris 0 Posted August 28, 2019 Author Share Posted August 28, 2019 It works, but sometimes gets out of sync, unsure why but eventually I will encounter items that do not have the correct permissions. I just wrote a script that I run that recursively trolls the media directories and chown's the files to my ID and group. Thanks for the help. Peter Link to comment Share on other sites More sharing options...
Luke 37071 Posted August 28, 2019 Share Posted August 28, 2019 Thanks for the feedback. Link to comment Share on other sites More sharing options...
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