Library empty on fresh install

I have a fresh install of Plex (latest version). Install was fine aside from the lack of obvious naming and permission requirements.

I now have tried adding the Library as type Movies and as type Other media.

Same result: There are no items in this library

The plex user is part of my user group. My user group is the owner of this directory. I have even added the plex user to the root group to make sure it wasn’t still about permissions.

me@xps:/media/me/MyHD/Media/Movies$ groups plex
plex : plex root video me

All files are inside the me directory within the /media/me/MyHD/Media/Movies/files located here

me@xps:~$ ll /media/
total 12
drwxr-xr-x   3 root root 4096 Jun 30 22:22 ./
drwxr-xr-x  24 root root 4096 Jun 29 06:08 ../
drwxr-xr-x+  4 me me  4096 Jul  1 02:10 me/

Server Status:

me@xps:~/Downloads$ sudo systemctl status plexmediaserver.service
● plexmediaserver.service - Plex Media Server
   Loaded: loaded (/lib/systemd/system/plexmediaserver.service; enabled; vendor 
   Active: active (running) since Mon 2019-07-01 02:57:21 PDT; 15h ago
 Main PID: 11654 (sh)
   CGroup: /system.slice/plexmediaserver.service
           ├─11654 /bin/sh -c  PLEX_MEDIA_SERVER_INFO_VENDOR="$(grep ^NAME= /etc
           ├─11674 /usr/lib/plexmediaserver/Plex Media Server
           ├─11694 Plex Plug-in [com.plexapp.system] /usr/lib/plexmediaserver/Re
           ├─11747 /usr/lib/plexmediaserver/Plex Tuner Service /usr/lib/plexmedi
           └─11748 /usr/lib/plexmediaserver/Plex DLNA Server

Jul 01 02:57:21 xps systemd[1]: Starting Plex Media Server...
Jul 01 02:57:21 xps systemd[1]: Started Plex Media Server.
Jul 01 18:45:15 xps systemd[1]: Started Plex Media Server.

This is the directory structure visible in plex.

![Screenshot_2019-07-01_18-57-01|690x496](upload://n0a5q3DxoI2H8LZ9lD2J0rhiBwl.png) 

So the plex interface is only showing me a short list of available directories to add during the Library creation.  The parent directory MyHD is a typical usb HD.  Mounted to `/media/me/MyHD`

My files are located in directory:
me@xps:/media/me/MyHD/Media/Movies$ pwd
/media/me/MyHD/Media/Movies

From what I understand the naming convention needs to be Parent directory (MyHD) ->Media -> Movies.
All of my movies are in that directory. Some of the movies are in directories and some are only single files. There are thousands of files in there yet it cannot “see” any of them…

me@xps:/media/me/MyHD/Media/Movies$ sudo journalctl -xe | grep -i plex
[sudo] password for me: 
Jul 01 18:44:59 xps sudo[11289]:      me : TTY=pts/2 ; PWD=/home/me/Downloads ; USER=root ; COMMAND=/bin/systemctl enable plexmediaserver.service
Jul 01 18:45:15 xps sudo[11377]:      me : TTY=pts/2 ; PWD=/home/me/Downloads ; USER=root ; COMMAND=/bin/systemctl start plexmediaserver.service
Jul 01 18:45:15 xps systemd[1]: Started Plex Media Server.
-- Subject: Unit plexmediaserver.service has finished start-up
-- Unit plexmediaserver.service has finished starting up.
Jul 01 18:45:20 xps sudo[11381]:      me : TTY=pts/2 ; PWD=/home/me/Downloads ; USER=root ; COMMAND=/bin/systemctl enable plexmediaserver.service
Jul 01 18:46:07 xps sudo[13259]:      me : TTY=pts/2 ; PWD=/home/me/Downloads ; USER=root ; COMMAND=/bin/systemctl status plexmediaserver.service
Jul 01 18:50:51 xps sudo[13459]:      me : TTY=pts/2 ; PWD=/home/me/Downloads ; USER=root ; COMMAND=/bin/systemctl restart plexmediaserver.service
Jul 01 18:50:51 xps systemd[1]: Stopping Plex Media Server...
-- Subject: Unit plexmediaserver.service has begun shutting down
-- Unit plexmediaserver.service has begun shutting down.
Jul 01 18:50:51 xps systemd[1]: Stopped Plex Media Server.
-- Subject: Unit plexmediaserver.service has finished shutting down
-- Unit plexmediaserver.service has finished shutting down.
Jul 01 18:50:51 xps systemd[1]: Starting Plex Media Server...
-- Subject: Unit plexmediaserver.service has begun start-up
-- Unit plexmediaserver.service has begun starting up.

Here is some of the disk information:
It looks like the FS type is exFAT. Is that correct?

Block ID:::

me@xps:/media$ blkid | grep -i sda1
/dev/sda1: LABEL="MyHD" UUID="52F0-FEC1" TYPE="exfat" PARTUUID="1be014c0-01"

FDISK:::

me@xps:/media$ sudo fdisk -l /dev/sda1
Disk /dev/sda1: 1.8 TiB, 2000397884928 bytes, 3907027119 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0x00000000

Device      Boot      Start        End    Sectors  Size Id Type
/dev/sda1p1      4294967295 8589934589 4294967295    2T ff BBT
/dev/sda1p2      4294967295 8589934589 4294967295    2T ff BBT
/dev/sda1p3      4294967295 8589934589 4294967295    2T ff BBT
/dev/sda1p4      4294967295 6854241533 2559274239  1.2T ff BBT

LSBLK:::

me@xps:/media$ lsblk -l /dev/sda1
NAME MAJ:MIN RM  SIZE RO TYPE MOUNTPOINT
sda1   8:1    0  1.8T  0 part /media/me/MyHD

MOUNT:::

me@xps:/media$ mount | grep "^/dev/sda1"
/dev/sda1 on /media/me/MyHD type fuseblk (rw,nosuid,nodev,relatime,user_id=0,group_id=0,default_permissions,allow_other,blksize=4096,uhelper=udisks2)

So, I’m stuck. Can anyone confirm if the naming convention is correct?
Is it still a possible permissions issue?

Thank you for any help.

The root problem you face is faced by all Gnome desktop manager users.

/media/me/MyHD

is only visible by you. Plex is locked out.

By being in the /media/username/diskname configuration, this also tells me you don’t have entries in /etc/fstab for them to put them in a proper, shareable, location.

I used example names here to demonstrate how-to. Pick whichever names you wish provided the top-most doesn’t conflict with anything existing.

Does that apply if the plex user is part of my group?

Correct about no fstab configuration…I am just using the default Gnome /media directory.

If I understand this correctly. All I need to do is:
create a new directory for example mkdir /plex?
add an entry to fstab to mount /dev/sda1 to /plex?
That would mean I am no longer using the /media parent directory. I’ll be using /plex instead. Right?
I do have a question regarding the fstab file. It looks like my /dev/sda1 is type: exfat. So would I use exfat as the type in fstab? or should I use ntfs? Thanks for your help and the quick reply btw.

You understand the use of /plex correctly. You own it but with permissions of 755 for all directories, user plex can read it. (linux is very strict on User permissions).

Having it in the group works for most things but not /media. /media is a UID-exclusive mount lock.

If the drive is EXT4 format, put ext4 in the /etc/fstab entry
if it’s NTFS format, put ntfs (or ntfs-3g) in the /etc/fstab entry.

The How-To will show you everything you need to know.

I understand. Thanks for the assistance. The filesystem type is exfat so my fstab looked like:
UUID=52F0-FEC1 /plex exfat defaults,auto,ro,nofail 0 1
It looks like it mounted correctly. I am going to try and add a new library now.

Looks like it is adding the Library! :slight_smile:

Such a relief. No matter what I searched for I couldn’t find any info about the /media folder and plex.

It might be good to add that bit to the install instructions for Gnome users. In any case, I am going to try and play a movie tonight. I don’t see why it wouldn’t work. Thanks!

The Linux Tips section is there and contains all that plus a lot of other information.

Ok. Thank you for your help. Now I need to figure out why some of my files aren’t playing audio on the firestick. Always something.

I can’t help with players, sorry. Keeping my arms around Linux and its variants on desktops and NAS boxes is about all I can handle given the current support load.

I would look in the players tags … There are many threads about them.
Use the search … Surely something will come up

Not a problem. I’ll figure something out.

Quick question. I am able to watch movies and stuff but if I try and delete anything i get the operation not permitted again. Even though in my fstab I have it set to rw. Any idea whats going on?

chown: changing ownership of './myfile.mp4': Operation not permitted
and
root@xps:/plex# mount | grep -i sda1
/dev/sda1 on /plex type fuseblk (rw,nosuid,nodev,relatime,user_id=0,group_id=0,default_permissions,allow_other,blksize=4096)

I wanted to post this for anyone else having the same issue.

hardware: Seagate 2TB backup plus
OS: Ubuntu

If you are going to use a disk formatted as exfat you need to mount it properly.
UUID=43F0-FCC1 /plex exfat-fuse default_permissions,uid=1000,gid=1000,nosuid,nodev,relatime,blksize=4096 0 0

Is that for those OS’s which have exfat as a FUSE driver?

Yup. I was trying exfat, fuse3g, ntfs, fat and understandably they didn’t mount the disk properly.

If you mount with exfat-fuse default_permissions it works like a charm. It was strange though. While researching the issue I didn’t see any references to exfat-fuse at all. After digging into fuse a bit more their is a filesystem TYPE called “exfat-fuse” that is available. That was the part that was killin me.

That is a good one and definitely keeper information.

What does blkid show when you query it? Does it show exfat or exfat-fuse ?

I will make special note of it in the How-To if it’s identifiable.

1 Like

Awesome. I think that will definitely help some people. When I run blkid it only shows exfat :frowning_face:

TYPE="exfat"

Which distro are you using? It must be distro specific

me@xps:/plex$ lsb_release -a
No LSB modules are available.
Distributor ID:	Ubuntu
Description:	Ubuntu 16.04.6 LTS
Release:	16.04
Codename:	xenial

I updated my other question as well.

Interesting. I wouldn’t have expected that. Others have been using exfat (not exfat-fuse) without issue.

Thanks for the info, I will update

It was a surprise to me as well. I am obviously not a long time Plex user, but I do work as a sysadmin, and I have NEVER experienced this before. Hopefully it helps someone out there.