Help moving library metadata

Server Version#: 1.13.10.352

I’ve just made the switch to Ubuntu 18 from Windows and am trying to follow guides for moving the Plex Library metadata to an SSD. The issue I’m running in o is that all the guides say the data is located at /var/lib/plexmediaserver but I find that directory at /var/snap/plexmediaserver. Can I just supplement the path and have the guide be accurate still?

I’m also unable to stop plexmediaserver to perform the move. I’ve tried the following commands to stop plex but receive errors saying:

killall ‘Plex Media Server’ “killall ‘Plex Media Server’”
sudo service plexmediaserver stop “Failed to stop plexmediaserver.service: Unit plexmediaserver.service not loaded.”

I’m able to access the server via the webui but cannot figure out how to stop it once running.

Can anyone help a linux newbie out?

Thanks in advance!

You are using the snap-package, so you use the commands “sudo snap stop plexmediaserver” and “sudo snap start plexmediaserver” to start and stop PMS.

Thanks gaygirlie_hotmail.com! That’s one issue solved very simply.

Making progress now :slight_smile:

Ok I’ve run into a couple other issues.

First… I’m trying to move this directory to a dedicated SSD but the guide says not to use /media directory because Gnome uses it(although I don’t know about Unity), but this is where the drive mounts to. Is this still an issue in Ubuntu 18? How do I go about moving this SSD that’s mounted in /media/USER/Plex Library to /home/plex? This feels like a very Linux noob question to ask.

The guide also says to delete the original plexmediaserver directory but I tried using rm -rf /path/to/old/plex but it gave me a list of errors that rm could not remove files. Maybe a permission issue?

I’m stumped on how to proceed. Any help would be greatly appreciated.

Help me understand a few things please?

  1. where is the data you brought over from Windows?
  2. Am I correct that you want to use a dedicated SSD for Plex? (your main Ubuntu is on HD?)
  3. Are there any other customizations you would like?
  1. I did not bring the server data over from Windows, just the media and it’s currently on my Drobo until I get Plex sorted out. Then the media will be transferred to ext4 drives in the new server.
  2. I am using an SSD for Ubuntu and want to use a second SSD for Plex.
  3. I would love for all of my drives to mount on boot along with Plex starting on boot. These are next on my list to figure out.

I’ve tried to follow your guide below and have referenced others allowing the way, but yours seems to be the best and most concise.

I’ve also configured a RAMDISK to use for my transcoding location and pointed plex to that location. I believe that is set to auto-mount via an edit to fstab. That still needs to be tested but I want to get this figured out first.

You’re only missing the other part. The one you also need is to make the 2nd SSD mount stable and away from /media where it does user plex no good.

In here, I show the mount point as /disks, you can just as easily use /ssd

This would make the path to your Plex Library become /ssd/plex/Library/Application Support (or similar)

Make sense?

I’m reading through the guide now but I think it’s going to take me a few to wrap my head around it. I’ll respond with an update or questions as soon as possible. Thanks for your help ChuckPA.

You’re very welcome. Take your time absorbing it. I condense a lot of info into it.
If you have any questions, post them here and it will ping me.

I’m confused out the 3 disk part of this process. Which drives am I actually identifying here?

  1. SSD for Plex. Understood.
  2. External NTFS drive. The Drobo?
  3. External ext4 drive? What is this? I only have 1 external in the picture here and it’s the Drobo.

Ah.

  1. SSD #1 (the OS) for Ubuntu and PMS (software)
  2. SSD #2 (data only) for your Plex metadata library
  3. Drobo would be this part… It is where your movies/tv episodes/music are stored

We add SSD #2, make it part of the OS. Now we can move your Metadata there.

Ok that makes sense.

[root@lizum chuck]# mkdir /disks /disks/c /disks/media3 /disks/chuck2t

What is the /disks/c? I left that part unedited when creating the directory and think that was a mistake.

Later when editing fstab there is this:

# Mount /dev/sda1 directly  READ-ONLY,  and use the device name because it will never change
/dev/sda1                                 /disks/c       ntfs  defaults,auto,ro,nofail 0 1

Why does the name not change? This is your OS drive, correct?

Do I need to make another directory in /ssd for the OS drive since I left the command as /ssd/c originally?

Here’s my unsaved edit to /etc/fstab. Please let me know if they make sense and if the /ssd/c directory is correct. Yes… I need to stop putting spaces in things now.
My OS SSD is formatted to ext4 and a LABEL is not present in the blkid output for it.

# Addtions for external and internal drives
# Mount Big Drobo (ext4)  at /ssd/"Big Drobo" for Plex
UUID=06C8EE5EC8EE4C0D /ssd/"Big Drobo"  ntfs  defaults,auto,rw,nofail 0 1

# Mount Plex SSD (NTFS) at /ssd/"Plex Library" for Plex
UUID=29cf6d21-ed8f-456c-aac1-a8c9790b9b77 /ssd/"Plex Library" ext4  defaults,auto,rw,nofail 0 1

# Mount /dev/sda1 directly  READ-ONLY,  and use the device name because it will never change
/dev/sdf1  /ssd/c  ext4  defaults,auto,ro,nofail 0 1

There should be #'s in from of the bold parts.

Moderator edited: Used code formatting to improve readability

Your use of quotes is incorrect. Let’s first address that?

In /etc/fstab, quotes are messy and always a problem. We go to great expense to avoid them.

Please clarify for me which is which?

  1. “/ssd/Big Drobe” is your Drobo NAS shared directory?
  2. “/ssd/Plex Library” is where you would like your Plex metadata (Library) to be?
  3. “/ssd/c” , while a bit misleading, is named “c” only because it provides reference to the Window C: drive. It gives you a “what is what” mapping.
  1. “/ssd/Big Drobo” is a USB attached RAID enclosure. It’s not an NAS.
  2. “/ssd/Plex Library” is where you would like your Plex metadata (Library) to be? - Yes.
  3. “/ssd/c” , while a bit misleading, is named “c” only because it provides reference to the Window C: drive. It gives you a “what is what” mapping. - That means I can use any name as the reference, right?

To keep your /etc/fstab easier for now, can we not use spaces?

  1. Thanks for clarifying “drobo”
  2. We can use directory slashes and get rid of the name (quotes aren’t needed anymore)
  3. Yes, “c” is an arbitary name. I used it in my example only to help those transitioning from Windows to Linux as a well known reference point. (hence: /disks/c)

Now that I understand your structure better, I would like to make the following suggesting

For this first part, can we simplify the names?

I would like to suggest:

  1. /drobo for your drobo mount point
  2. /plex for where SSD #2 mounts and then becomes /plex/Library
  3. Shorten /ssd/c to just /c or /C (Linux is case sensitive so these are two different names.

How does this sound?

I’m glad you’re pushing for this change now. This is fine with me and something I knew would need to be done eventually.

I’m going to have to work on that tomorrow though because changing the mount point will break the plex libraries I have setup and interrupt others, right?

Can you provide instructions on how to change the mount points?

Assuming:

  1. the UUID for the drobo and the SSD are correct,
  2. your Windows drive is indeed /dev/sda1 (it should be)
  3. We use linux standard naming convention of lower case unless we have a very specific reason.

I recommend:

#
# Lines to add for Plex use
#
# Addtions for external and internal drives
#
# Big Drobo
UUID=06C8EE5EC8EE4C0D      /drobo                  ntfs  defaults,auto,rw,nofail 0 1

# Mount Plex SSD
UUID=29cf6d21-ed8f-456c-aac1-a8c9790b9b77 /plex    ext4  defaults,auto,rw,nofail 0 1

# Mount /dev/sda1 directly  READ-ONLY,  and use the device name because it will never change
/dev/sda1                  /c                      ntfs  defaults,auto,ro,nofail 0 1

These lines get added to the bottom of your fstab file.

Please let me know how this fits with your needs?

If so, you’ll need to make the directories and set their permissions (this basic info is in the how-to… just copy the “chmod 755” instructions in that section.

We will address putting your Plex metadata into proper position tomorrow.

Before I retire for the evening,

  1. When we change how the media is mounted (move content to a new location), we follow a simple procedure and , for short time, you see both your media unavailable and then having duplicates.

  2. I have personal business tomorrow morning. I will return after 1pm EST.

I appreciate all your help.

The weird thing is that /dev/sda1 is a 5TB internal storage drive.
I’m going to double check the UUIDs a little later. I also have some errands to run tomorrow so hopefully we will find some time to work on this.