I just installed plexmediaserver 0.9.16.6.1993-5089475 onto a fresh Fedora 24 Server. It fails to start using systemd with:
Jun 20 21:44:50 meerkat sh[29051]: /usr/lib/plexmediaserver/Plex Media Server: error while loading shared libraries: libboost_system.so.1.59.0: cannot open shared object file: No such file or directory
Jun 20 21:44:50 meerkat systemd[1]: plexmediaserver.service: Main process exited, code=exited, status=127/n/a
I edited plexmediaserver.service
to print the env before attempting to execute Plex Media Server
. For some reason, LD_LIBRARY_PATH
isn't getting exported through the Environment=
statement within the Unit. As you can see here:
Jun 20 21:44:50 meerkat sh[29051]: SHELL=/sbin/nologin
Jun 20 21:44:50 meerkat sh[29051]: PLEX_MEDIA_SERVER_MAX_PLUGIN_PROCS=6
Jun 20 21:44:50 meerkat sh[29051]: LC_ALL=en_US.UTF-8
Jun 20 21:44:50 meerkat sh[29051]: USER=plex
Jun 20 21:44:50 meerkat sh[29051]: PLEX_MEDIA_SERVER_TMPDIR=/tmp
Jun 20 21:44:50 meerkat sh[29051]: PLEX_MEDIA_SERVER_HOME=/usr/lib/plexmediaserver
Jun 20 21:44:50 meerkat sh[29051]: PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin
Jun 20 21:44:50 meerkat sh[29051]: PWD=/
Jun 20 21:44:50 meerkat sh[29051]: LANG=en_US.UTF-8
Jun 20 21:44:50 meerkat sh[29051]: SHLVL=1
Jun 20 21:44:50 meerkat sh[29051]: HOME=/var/lib/plexmediaserver
Jun 20 21:44:50 meerkat sh[29051]: LOGNAME=plex
Jun 20 21:44:50 meerkat sh[29051]: PLEX_MEDIA_SERVER_APPLICATION_SUPPORT_DIR=/var/lib/plexmediaserver/Library/Application Support
Jun 20 21:44:50 meerkat sh[29051]: _=/usr/bin/env
Jun 20 21:44:50 meerkat sh[29051]: /usr/lib/plexmediaserver/Plex Media Server: error while loading shared libraries: libboost_system.so.1.59.0: cannot open shared object file: No such file or directory
Jun 20 21:44:50 meerkat systemd[1]: plexmediaserver.service: Main process exited, code=exited, status=127/n/a
I verified this by changing the ExecStart=
statement to /bin/sh -c 'LD_LIBRARY_PATH=/usr/lib/plexmediaserver /usr/lib/plexmediaserver/Plex\ Media\ Server'
. Then the service starts successfully.
I'm not sure if this is a change in systemd that ships with Fedora or not.
systemd-229-8