Tinker, Tailor, Soldier, Sponge

View Original

How to Update Plex Jails on FreeNAS 11

In which I post a reference, mostly for myself, on how to update my chosen media server...

I'm not going to cover how to install Plex on FreeNAS as it is very easy using the plugins system explained in the docs.[1]

Upgrading, however, is a different issue. While the plugin does get updates that will preserve your data they are often quite behind the release schedule of the Plex team. Also I have had issues with some of my Plex plugins (like Trakt.tv) after using this upgrade method. In the past I have tried a hodgepodge of different methods to acheive it but now the most reliable method is using the PMS Updater script.[2]

Tools

  • A FreeNAS 11 server with the Plex plugin installed
  • PMS Updater

How-To

Turning the plugin off before upgrading.

  1. Turn the plugin off.
  2. ssh into your server and create a zfs snasphot using the warden: warden zfsmksnap <name of jail>.* [3]
  3. Find the jail number using jls then sudo jexec <jail number> into the jail.
  4. Download PMS Updater from Github: wget https://raw.githubusercontent.com/mstinaff/PMS_Updater/master/PMS_Updater.sh –no-check-certificate
  5. Enable the script: chmod +x PMS_Updater.sh
  6. Then run it: ./PMS_Updater.sh -v -a -u <Plex user> -p <Plex password>
  7. This script will do the bulk of the work including a backup but it won't properly restart until you turn the plugin back on in the GUI.

The plugin back to working order post upgrade. N.B.: The version number in the GUI will be incorrect after using this method.

*Probably plexmediasever_1 unless you have multiple.

Tom Out!

References

[1] Plugins, FreeNAS.org: https://doc.freenas.org/9.3/freenas_plugins.html

[2] PMS Updater, mstinaff on Github: https://github.com/mstinaff/PMS_Updater/blob/master/README.md

[3] Jails. How should I do things?, FreeBSD forums: https://forums.freebsd.org/threads/jails-how-should-i-do-things.41975/