Plex Plugin Permissions 12.2-RELEASE-p10 - Unable to see Media in Plex

danielf

Cadet
Joined
Jul 10, 2021
Messages
4
I have re-installed my Plex Plugin (Jail was installed with the Plugin) as I couldn't get it to Upgrade after moving from Freenas 11.2 to TrueNAS-12.0-U5.1 I have followed a couple of youtube videos to try and get the permissions correct with no success. I have set the permissions on storage to media setting to plex as well as setting the mount point to plex\media. When I manage plex (not plex pass)I can navigate to the the media folder and see the Movies, Series, 3D and Music folders by no files are picked up when I scan for media. I have been at this now for over a week and am not making any headway. I suspect something to do with permissions.

1632502334338.png


Permissions on my folders

root@freenas[~]# ls -larh
total 23
drwxr-xr-x 2 root wheel 3B Jun 19 13:45 syslog
drwxr-xr-x 3 root wheel 3B Jun 19 13:46 samba
-rw-r--r-- 1 root wheel 667B Sep 18 13:56 .zshrc
-rw------- 1 root wheel 2.1K Sep 24 16:53 .zsh-histfile
-rw-r--r-- 1 root wheel 90B Sep 18 13:56 .zlogin
-rw-r--r-- 1 root wheel 119B Sep 18 13:56 .warning
drwxr-xr-x 2 root wheel 2B Dec 22 2018 .ssh
-rw-r--r-- 1 root wheel 1.1K Sep 18 13:56 .shrc
-rw-r--r-- 2 root wheel 405B Sep 18 13:56 .profile
-rw-r--r-- 1 root wheel 328B Sep 18 13:56 .login
-rw-r--r-- 1 root wheel 80B Sep 18 13:56 .k5login
-rw-r--r-- 1 root wheel 179B Sep 18 13:56 .gdbinit
-rw-r--r-- 2 root wheel 1.0K Sep 18 13:56 .cshrc
-rw-r--r-- 1 root wheel 1.1K Sep 18 13:56 .bashrc
-rw------- 1 root wheel 121B Dec 24 2018 .bash_history
drwxr-xr-x 20 root wheel 27B Sep 24 12:52 ..
drwxr-xr-x 5 root wheel 17B Sep 24 16:59 .
root@freenas[~]# cd /mnt
root@freenas[/mnt]# ls -larh
total 6
drwxrwxr-x+ 5 freenas freenas 6B Jul 3 12:41 NAS
-rw-r--r-- 1 root wheel 5B Sep 18 13:56 md_size
drwxr-xr-x 20 root wheel 27B Sep 24 12:52 ..
drwxr-xr-x 3 root wheel 128B Sep 24 12:52 .
root@freenas[/mnt]# cd NAS
root@freenas[/mnt/NAS]# ls -larh
total 42
drwxrwxr-x+ 7 plex plex 8B Sep 19 12:04 Media
drwxrwxr-x 9 root wheel 12B Sep 18 17:23 iocage
drwxrwxrwx+ 13 freenas 1001 13B Jul 18 22:57 BU
-rwxrwxr-x+ 1 freenas freenas 0B Dec 23 2018 .windows
drwxr-xr-x 3 root wheel 128B Sep 24 12:52 ..
drwxrwxr-x+ 5 freenas freenas 6B Jul 3 12:41 .
root@freenas[/mnt/NAS]# cd Media
root@freenas[/mnt/NAS/Media]# ls -larh
total 286
drwxrwxr-x+ 2 plex plex 9B Sep 19 12:04 truenas
drwxrwxr-x+ 60 plex plex 61B Sep 23 19:24 Series
drwxrwxr-x+ 241 plex plex 242B Jun 30 18:48 music
drwxrwxr-x+ 375 plex plex 376B Sep 4 18:54 Movies
drwxrwxr-x+ 5 plex plex 6B May 30 2020 3D
-rwxrwxr-x+ 1 plex plex 0B Dec 24 2018 .windows
drwxrwxr-x+ 5 freenas freenas 6B Jul 3 12:41 ..
drwxrwxr-x+ 7 plex plex 8B Sep 19 12:04 .
root@freenas[/mnt/NAS/Media/3D]# ls -larh
total 93
drwxrwxr-x+ 2 plex plex 3B Jan 20 2019 Venom (2018) 3D [HSBS]
drwxrwxr-x+ 2 plex plex 3B May 30 2020 Star Wars Episode IX The Rise of Skywalker (2019) [HSBS]
drwxrwxr-x+ 2 plex plex 3B Oct 27 2019 Avengers Endgame (2019) 3D [HSBS]
drwxrwxr-x+ 3 plex plex 128B Sep 24 12:52 ..
drwxrwxr-x+ 5 plex plex 6B Jul 3 12:41 .

Any guidance would be appreciated
 
Joined
Jan 7, 2015
Messages
1,155
While according to the host it looks correct, but the + sign at the end means that the files are ACL managed. And unfortunately I dont have a ton of experience with ACL perms. Enter the plex jail and see if root still owns /media and who exactly is owning the media inside the mounted /media/*.

Ultimately I suspect that your plex user on the TN host does not have the UID of 972 which will be the case inside the jail as this user/group is automagically created, but you must create them on the host and will likely have the ID of 1000-something, unless you changed it. This is true for both the UID and GID should be properly set to 972. Anyways just a hunch on that, but def look into it.
 

danielf

Cadet
Joined
Jul 10, 2021
Messages
4
Thanks for the response John, I created a user and group with plex and linked both to UID 972. I agree something not good with the permissions. If I go to the root@plex (Jail shell) I get to /mnt and then /plex and there is only . and .. maybe I should have stuck with 11.2 as that was working for a good couple of years
 
Joined
Jan 7, 2015
Messages
1,155
Thats a bad idea. Your media is being mounted inside the jail to /media not /mnt or /plex and normally root owns /media by default.
 
Joined
Jan 7, 2015
Messages
1,155
Also, Go to Jails-->Plex-->Mount Points-->Edit-->...-->Edit ACL and have a look around in there set a rule to allow plex full access if not to outright own. Be care ful here as if you go setting something for plex permissions recursively, your iocage dataset is also in /mnt/NAS/, think breakage.

Very possible this is all already the case too, its just what I would also have a good look at, make sure its all correct.
 

danielf

Cadet
Joined
Jul 10, 2021
Messages
4
ok finally the aha moment...
Setup my Pool as below
nas - pool
iocage - dataset
media - dataset
movies - dataset
series - dataset

Mount point set to media as source and media within the jail as destination. Library was set in plex to the movies and series dataset.

Remove the movies & series dataset and created a share to the media dataset and then created a movies and series folder in the media share so when I set up my library I was now able to see my movies and series in plex.

Still think the previous setup could have worked if I had the permissions correct because that's how I had it setup and working in freenas.

Anyway at least I know a bit more about Truenas now. Thanks John for your guidance
 
Top