Plex write access/permissions

Status
Not open for further replies.

Visseroth

Guru
Joined
Nov 4, 2011
Messages
546
OK, so I'm have my media folder setup as 775, group is public as I don't want unauthenticated users writing or damaging anything in my media folder.
My question is how do I give plex read/write access to the media folder. How do I add plex to the public group or make plex the owner?
I don't see a plex user nor do I know or see what group the plex plugin is a part of.

Any help figuring this out is appreciated.
 

Visseroth

Guru
Joined
Nov 4, 2011
Messages
546
I'd like plex to be able to write so I can optimize videos, delete, ect.
 

Visseroth

Guru
Joined
Nov 4, 2011
Messages
546
I have not thoroughly followed the instructions. I know enough to put a jail in place and make it work as it should minus some obvious permission issues per the instructions...
Before selecting the “Source”, it is important to first ensure that the permissions of the selected directory or dataset grant permission to the user/group account inside of the jail.

My issue is, Plex does NOT have permissions to write to the destination because I do not know what group/user is associated with the plex plugin. If I browse to the jail ls -l says owner is root, group is wheel. Well the owner of my media is root but the group is public. Group and public have full access but "everyone" only has read only.

I'd like Plex to have rwx so I can do things like delete videos, optimize, ect

So, does anyone know what user needs to be added to the public group in order to make rwx work?
 

Joshua Parker Ruehlig

Hall of Famer
Joined
Dec 5, 2011
Messages
5,949

marshalleq

Explorer
Joined
Mar 12, 2016
Messages
88
Hi, there are quite a few scenarios here which come into play depending on where you're copying your data from, what protocol you're using and whether the server is on the same machine as the data or not. The basic issues are that depending on the above scenarios, permissions are written quite differently and can cause plex to not see the media, not be able to write changes or even see some files and not others. I wrote a guide for this just yesterday over on Tech-KnowHow. I think it explains what you're trying to do. If not let me know as it's still quite fresh in my head and I may be able to help you nut it out. Hope it works!

Direct link: https://www.tech-knowhow.com/2016/03/how-to-plex-permissions-linux/

Thanks.
 

dcholth

Dabbler
Joined
Feb 14, 2017
Messages
12
Did you ever find a solution to this? I'd like to do the same thing, but before I go through these steps, I'm curious if they actually worked.
 

Visseroth

Guru
Joined
Nov 4, 2011
Messages
546
Yep, got it working.
Ended up creating a "Media" group with a ID of 1029 in my case to match the group ID of Plex. Since the group ID matches that of Plex it is able to read and write since the Media group has read and write privileges to the folder and all it's subs.
 

dcholth

Dabbler
Joined
Feb 14, 2017
Messages
12
Thats great! Can you expand on it a bit though? How did you find the ID of Plex? I'm not seeing an ID anywhere in jails/plugins/etc, and Plex doesnt show up as a user or a user-group.
 

Visseroth

Guru
Joined
Nov 4, 2011
Messages
546
Sorry, dropped the ball on this. Completely forgot about this post until I started digging around for some stuff.
Anyhow, if you ssh into your server and log in as the su (SuperUser) then you can jls which will tell you the number of your plex jail.
jexec # tcsh into your jail. This is how I do it. Or you can go to your webgui of FreeNAS, click on jails, select Plex and click on the command icon at the bottom.
Once in do a "less /etc/passwd" to see all the user IDs
Do a "less /etc/group" to see all your group IDs

On my server I created a media group (ID 1029) and made the folders in plex that had access to the media on FreeNAS read/writeable by both owner and group (chmod 771). Use ls -l to see owner, group and folder permissions. To allow Plex to have r/w privlidges I matched the group ID of the folder (in my case /media/) in Plex to that of the group I created in FreeNAS.
Make sense? or do I need to do a how to? I probably should. I'm no pro, but took me a while to figure this out, with some help of coarse.
 
Status
Not open for further replies.
Top