Preparing to reinstall Ubuntu - tips?

Server Version#:
Player Version#:
<If providing server logs please do NOT turn on verbose logging

I’m getting ready to scrape my hard drive and reinstall Ubuntu to repair whatever it is I did to my video drivers. Is there a guide or any tips on how to prepare for that to minimize problems setting Plex up again? All of my media is on a separate hard drive. As far as I know everything else is on the boot drive.

Thanks,
Mike

Mike,

  1. Stop Plex
  2. as root:
    cd /var/lib/plexmediaserver ; tar cf /path/to/some/place/safe/PlexBackup.tar ./library
  3. save that until after reload

After reload

  1. Install PMS (downloaded from Plex - not the Ubuntu store SNAP)
  2. Stop PMS
  3. cd /var/lib/plexmediaserver
  4. sudo tar xf /path/to/saved/PlexBackup.tar
  5. sudo chown -R plex:plex .
  6. Start PMS

Thanks!

Worked perfectly. Thanks. Can you tell me why I needed to download and install instead of the SNAP?

SNAP is an isolated container; more isolated than any docker.
It is bound to different directories (per SNAP package rules) and can only see your home directory.

As of Ubuntu 20.04, the only packages you can download from the Ubuntu store are SNAP packages.

The best resource now is to enable the Plex repository or download/update manually. It’s always a good idea to keep at least one DEB package available

Any reason to not use the repository?

Anything needed to switch to the repository if I already installed manually, or should I just redo it?

Thanks

There’s no reason not to use the repository.
I always recommend to keep at least 1 known-good copy on hand.
It serves as the quick “get back up and running” installation after anything major with the host. The repo it setup automatically by performing that installation (less the final step to enable)

@Saberwolf

Thanks for that. Am I missing something in the installer ‘postinst’ code?

no your not missing anything that i can tell i am still kinda new to linux still learning. i have just removed the info from the deb package as part of my automation scripts. plex website does not help on setting up linux repo install just pushes out the deb file.

install gnupg for apt key install

apt install gnupg2 or gnupg1

install apt key

wget -q https://downloads.plex.tv/plex-keys/PlexSign.key -O - | apt-key add -

add line to plexmediaserver.list file

echo “deb https://downloads.plex.tv/repo/deb/ public main” > /etc/apt/sources.list.d/plexmediaserver.list

apt update and install plexmediaserver

apt update && apt install plexmediaserver

Thanks Saberwolf. Will do once I’ve got things working again.

Unfortunately, clearly I’ve done something wrong.

I don’t understand what I do wrong, but when I start messing with permissions, it seems I have to do it several times with multiple reboots to make anything happen.

Couldn’t record. Couldn’t access tuners after I tried to fix the recording. Still couldn’t record. Couldn’t transcode to other devices.

Now, everything seems to be working, but I’ll hold off for a few days before I celebrate.

Note to self for next time - in the fstab file, “ro” means read only. You don’t want that. Also don’t forget to change the permissions to allow plex to do things on the media drive.

Mike

sorry yes the deb package does not install repo after manually installed deb package due to lake of dependency required for apt-key add command it requires gnupg it does how every leave the required info in the plexmediaserver.list file for user to correct at a later date.

@Saberwolf

  1. You don’t need to add any other packages to install the Plex signing key.
  2. My installation script does write the Repo definition file.
  3. I do not enable it by default , nor do I add the key because I felt making that modification was presumptuous.

In light of the point however, I will discuss with the team about adding the signing key during package installation. This will reduce the number of steps required to use the repo to one (remove the comment). I believe the user should be in control of turning that on/off

@Mike-Denver

I maintain a set of Linux tips which will probably be of use.
In them I also show examples of setting up permissions for media files ( How to mount other hard drives tip )

https://forums.plex.tv/tag/server-linux-tips

What can I do you help you with completing the reinstallation?

Nothing. It’s all good now. Thanks for your help.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.