I’ve been using this solution for a long while now, but a recent upgrade to the Media Server on my Ubuntu box has stopped this from working - I had to add /lib to the end of this solution - so:
May help someone, or just something weird has happened on my machine!
To be clear - this is when I’m running the Plex Media Scanner from the terminal - it all works fine without me having to do this through the web interface.
PMS 1.15.0 brought a change to the location where we store the runtime libraries.
We now store them under the Plex installation directory (/usr/lib/plexmediaserver) in the lib subdirectory.
All packages are shipped with LD_LIBRARY_PATH updated to reflect this.
Ubuntu 16+ uses systemd. As such:
/lib/systemd/system/plexmediaserver.serivce is the master file
Your customizationed configuration parameters only go in /etc/systemd/system/plexmediaserver.service.d/override.conf
If you have any other files in /etc/systemd/system than this, we need to bring you back into sync with how systemd should be used.