I used to be able to do this, on a previous version of Plex Media Server, but now that I re-installed PMS the “right” way (i.e. so service plexmediaserver start works) this has STOPPED working.
The attached image shows a user who can browse to root to find their media folder. Mine, in the FreeBSD jail, lives at /media which is exactly where I want it.
However, when I want to add a folder to a library, I see this:
No option to browse to /media
Now, /media IS there; I can tell when I’m ssh’d to the server. And it IS accessible to the Plex user. In fact, if I hard type /media in the textbox at the top of the “add folder” dialog it finds my movies and adds them no problem.
But (for various reasons) I need that button to browse me to / back.
There appears to be an option with jail creation that interferes with the operation of the getfsstat syscall. Can you try running this in the jail to see which mounts it displays:
#include <sys/param.h>
#include <sys/ucred.h>
#include <sys/mount.h>
#include <stdio.h>
#include <stdlib.h>
int main(int argc, char *argv[])
{
struct statfs *mntbuf = 0;
int fssize = getfsstat(NULL, 0, 0);
if (fssize)
{
mntbuf = (struct statfs* )malloc(fssize * sizeof(struct statfs));
fssize = getfsstat(mntbuf, fssize * sizeof(struct statfs), MNT_WAIT);
}
if (fssize)
{
for (int i = 0; i < fssize; i ++)
printf("Found %s\n", mntbuf[i].f_mntonname);
}
free(mntbuf);
return 0;
}
Put that in a file, such as test.c, run cc test.c and then ./a.out. Your jail may not have a compiler installed by default so you may want to either install one beforehand with pkg or do this in a separate jail (created similarly to the one giving you issues). It should print out all the mount points it finds.
For reference, my jails do not exhibit any issues so I cannot reproduce this.
@gbooker02
I created a test folder in my Plex jail, added the test.c file with the code you gave, ran cc test.c and the ./a.out. My output was nothing, my terminal prompt just went to the next line (just as if you’d pressed enter with no command).
What’s weird is that the jail has the proper mounts, and the jail is accessing them currently. All of my media is mounted outside the jail, as is my actual plex dataset, and I am listening to music via plex while typing this, and recently added new media to the server which shows correctly via the database.
The issue really only seems to effect adding new folders or libraries… For some reason Plex can’t seem to see outside of it’s database…
No output is what I was expecting given your previous descriptions. What is happening is Plex is populating the left-hand side of the add folder dialog with the list of the mounts. However, the above code indicates that within the jail, it is told about 0 mounts. This appears to be a jail option according to https://www.freebsd.org/cgi/man.cgi?query=jail&sektion=&n=1 (see enforce_statfs). This does not affect visibility of media or anything on the filesystem; only which mountpoints the jail is told about.
One would normally expect / to be a mounted disk somewhere, but it is not in the list. For reference in my jail it outputted:
@gbooker02 - side question, you’d mentioned that you’d dumped jails. Did you switch over to iohyve?
Yep. I got frustrated with maintaining jails, pkg being painful and out of date, and other issues. So I’m running docker on top of Ubuntu 16.04 inside iohyve. I wrote up my initial work as well as when I changed to running the config dirs inside the VM under ZFS with zfs send/recv backups. I have several containers running there, but the UniFi container made all that work worth it on its own. It is such a pain to get UniFi working in a jail as well as updating it that when it had a critical update, it prompted me to investigate doing this rather than try to coax the new version to run in a jail again.
@gbooker02 thanks for the links, saved for future reference
Hopefully we’ll have some resolution to this smaller bug on the FreeNAS side of things (as I understand it, it’s a jails issue, not a Plex issue). I mean, typing paths for new media libraries isn’t all that hard, but I’d still love to be able to click around!!
Thanks everyone for your help on this.
I was starting to despair that anyone would agree that this is a problem. Hopefully Freenas will fix this in a future update.
i have the same problem i have installed freenas and my jail from scratch but i cant seem to get this fixed.
i am thinking of revering to a previous version of freenas and using my backup to repopulate my upgraded zfs1 array
all the fixes talked in this thread is above my capabilities. i have been working on this for 3 days
i created some new problems along the way so i am frustrated to the bone
I just added another ticket on FreeNAS regarding this issue.
I installed a new FreeNAS system using version 11 on an Asus A68HM F2+ mobo with 8GB and 4 x 6TB drives.
I am booting up on dual 16GB Kingston sticks.
I have been seeing this on version 11 and was only able to get the ENTIRE data blob on one media type if I selected / for the media source.
Any attempts to drop down to /video, /movies /television/, /music etc will not work and the system just spins for a second and indicates no libraries are found.
I am not able to manually go up and down the directory tree as I was able to using FreeNAS 9.
It looks like FreeNAS 9 has disappeared from the download area.
Is it possible to go back easily from 11 to 9? (IF I find an ISO)?
Solved - I had the exact same issue - Solved the problem by reverting from FreeNAS-11.0-U1 back to FreeNAS-9.10.2-U5.
Fortunately found a FreeNAS-9.10.2-U2.iso lying around in my download directory
Thanks
I just installed 11.0 on a new server (upgraded Mobo, CPU, memory, etc)
ran into this issue.
I found a workaround, where it shows your relative path (photo from above /usr/something/something) change that by manually typing in your path.
for me /media/TV for my TV shows, etc worked just fine.
I’ve setup using the plugin and the generic jail, updated plex packages on both setups, but still have a problem even accessing my media.
Plex cannot see my root directory, nor can I type in /media to point plex in the right direction.
My steps.
Created zpool RaidZ2 titled ‘MediaFiles’
Change permissions to allow read,write,execute for owner,group,other
Created a dataset in MediaFiles titled ‘Movies’
Change permissions to allow read,write,execute for owner,group,other
Created a Jail titled PlexPass
Created a storage, source: mnt/Mediafiles/movies , destination: /media/movies
Shell, followed ahughes03’s guide to generic jail pkg install
Setup Plex, signed in, attempted to add library
At Add Folder , I see only the following
Top Box
/usr/local/plexdata-plexpass/Plex Media Server
Im not able to continue this message for some reason on my ipad, so I’ve moved to my laptop. Sorry for the confusion.
Left side pane is Home root
right side pane
cache
codecs
logs
plugin support
plugins
preferences (greyed out)
I cannot point plex to my media/movies directory even by typing it into the top field box. I can however confirm, my storage destination directory media/movies has a copy of my test media file which i transferred into the source directory.
let me suggest stopping the jail, resetting your permissions recursively (even though your post indicates everything should be accessible), then restarting your jail and seeing if you can manually enter /media/movies into the top field box.
Alternatively, you could try mapping /mnt/MediaFiles/movies into /usr/local/plexdata-plexpass/Plex Media Server and see if it appears in the right side drop down.