Failed to start Plex Media Server

server-linux

#1

Hi there,
from one day to another, plex doesnt run anymore. I cant remember that I tinkered around that could have something changed, but I think I (or something) messed around with the user/rights-management (this still confuses me a bit).
The logs:

nuc@nuc:~$ systemctl status plexmediaserver.service
● plexmediaserver.service - Plex Media Server for Linux
   Loaded: loaded (/etc/systemd/system/plexmediaserver.service; enabled; vendor preset: enabled)
   Active: inactive (dead) (Result: exit-code) since Tue 2017-08-08 13:42:35 CEST; 7min ago
  Process: 8268 ExecStart=/bin/sh -c /usr/lib/plexmediaserver/Plex\ Media\ Server (code=exited, status=134)
  Process: 8265 ExecStartPre=/bin/sh -c /usr/bin/test -d "${PLEX_MEDIA_SERVER_APPLICATION_SUPPORT_DIR}" || /bin/mkdir -p "${PLEX_MEDIA_SERVER_APPLICATION_SUPPORT_DIR}" (code=exited, status=0/SUCCES
 Main PID: 8268 (code=exited, status=134)

Aug 08 13:42:30 nuc systemd[1]: plexmediaserver.service: Unit entered failed state.
Aug 08 13:42:30 nuc systemd[1]: plexmediaserver.service: Failed with result 'exit-code'.
Aug 08 13:42:35 nuc systemd[1]: plexmediaserver.service: Service hold-off time over, scheduling restart.
Aug 08 13:42:35 nuc systemd[1]: Stopped Plex Media Server for Linux.
Aug 08 13:42:35 nuc systemd[1]: plexmediaserver.service: Start request repeated too quickly.
Aug 08 13:42:35 nuc systemd[1]: Failed to start Plex Media Server for Linux.
Aug 08 13:53:10 nuc systemd[1]: Starting Plex Media Server for Linux...
-- Subject: Unit plexmediaserver.service has begun start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit plexmediaserver.service has begun starting up.
Aug 08 13:53:10 nuc systemd[1]: Started Plex Media Server for Linux.
-- Subject: Unit plexmediaserver.service has finished start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit plexmediaserver.service has finished starting up.
--
-- The start-up result is done.
Aug 08 13:53:10 nuc sudo[8591]: pam_unix(sudo:session): session closed for user root
Aug 08 13:53:10 nuc sh[8628]: terminate called after throwing an instance of 'std::runtime_error'
Aug 08 13:53:10 nuc sh[8628]:   what():  locale::facet::_S_create_c_locale name not valid
Aug 08 13:53:11 nuc sh[8628]: Aborted (core dumped)
Aug 08 13:53:11 nuc systemd[1]: plexmediaserver.service: Main process exited, code=exited, status=134/n/a
Aug 08 13:53:11 nuc systemd[1]: plexmediaserver.service: Unit entered failed state.
Aug 08 13:53:11 nuc systemd[1]: plexmediaserver.service: Failed with result 'exit-code'.
Aug 08 13:53:14 nuc sudo[8634]:      nuc : TTY=pts/9 ; PWD=/home/nuc ; USER=root ; COMMAND=/bin/journalctl -xe
Aug 08 13:53:14 nuc sudo[8634]: pam_unix(sudo:session): session opened for user root by nuc(uid=0)

Do you see something here that could be the cause?
Thanks
quan


#2

You need to (re)create your system's locale . This can happen during a system update. PMS defaults to en_US.utf-8 if nothing is defined.

sudo locale-gen en_us.utf-8 (or your appropriate locale)

and then verify you have the environment variable LANG set to match

The default plexmediaserver.service file defines:

Environment=LC_ALL=en_US.UTF-8
Environment=LANG=en_US.UTF-8


#3

THANK YOU <3
Everything runs fine (again) now. I appreciate your help.
quan