bsab5
March 30, 2019, 8:31pm
1
Server Version#: Ubuntu 18.04
Player Version#: 3.93.1
Upgraded from a 1.14.x version to 1.15.3.835 today and now Plex won’t start. I looked through forums and found some references to permissions, etc, but can not fix the issue. Please help.
When running “service plexmediaserver start” I get the following error.
Job for plexmediaserver.service failed because the control process exited with error code.
See “systemctl status plexmediaserver.service” and “journalctl -xe” for details.
Reviewing the 2 logs it states to check doesn’t provide much. Any help would be appreciated.
Did you customize your Plex install by editing /lib/systemd/system/plexmediaserver.service ?
Customizing your Plex configuration on systemd based systems
This information is intended for those systems where cat /proc/1/comm returns systemd.
On systems which use Systemd (Ubuntu 16+, Fedora, Centos 7, Debian 8,) you create this customization file which SystemD reads prior to launching PMS. This file is independent of the default configuration and service control mechanisms in /lib/systemd/system/plexmediaserver.service. Your customization override is preserved across updates, uninstal…
bsab5
March 31, 2019, 3:40pm
3
Not that I’m aware of. I have a pretty basic install. When I built my latest server I did migrate my library (/var/lib/plexmediaserver/Library/Application Support) from a prior Ubuntu install that was migrated initially from a Ubuntu 14 build. Other than that I mostly let everything just run as is.
Here is my server’s /lib/systemd/system/plexmediaserver.service:
[Unit]
Description=Plex Media Server
After=network.target network-online.target
[Service]
Environment=“PLEX_MEDIA_SERVER_APPLICATION_SUPPORT_DIR=/var/lib/plexmediaserver/Library/Application Support”
Environment=PLEX_MEDIA_SERVER_HOME=/usr/lib/plexmediaserver
Environment=PLEX_MEDIA_SERVER_MAX_PLUGIN_PROCS=6
Environment=PLEX_MEDIA_SERVER_TMPDIR=/tmp
ExecStartPre=/bin/sh -c ‘/usr/bin/test -d “{PLEX_MEDIA_SERVER_APPLICATION_SUPPORT_DIR}" || /bin/mkdir -p " {PLEX_MEDIA_SERVER_APPLICATION_SUPPORT_DIR}”’
ExecStart=/bin/sh -c ’
PLEX_MEDIA_SERVER_INFO_VENDOR="(grep ^NAME= /etc/os-release | awk -F= "{print \\$2}" | tr -d \\" )" \
PLEX_MEDIA_SERVER_INFO_DEVICE="PC" \
PLEX_MEDIA_SERVER_INFO_MODEL=" (uname -m)"
PLEX_MEDIA_SERVER_INFO_PLATFORM_VERSION="$(grep ^VERSION= /etc/os-release | awk -F= “{print \$2}” | tr -d \" )"
LD_LIBRARY_PATH=/usr/lib/plexmediaserver/lib
“/usr/lib/plexmediaserver/Plex Media Server”’
Type=simple
User=plex
Group=plex
Restart=on-failure
RestartSec=5
StartLimitInterval=60s
StartLimitBurst=3
[Install]
WantedBy=multi-user.target
Does this look standard and if not what should I change?
I also have an issue with package updates. Everything I read said this would be resolved with the Plex 1.15 install.
Apt update:
W: Conflicting distribution: https://downloads.plex.tv/repo/deb public InRelease (expected public but got )
Because of this I manually installed 1.15.3.835 because the web app kept telling me there was a new version of Plex, but it wasn’t being picked up for whatever reason. But other than the manual install and a few things I did post install to try to troubleshoot the service not starting, my Plex build is unchanged from when it was running on 1.14.
Regarding the failure to start, please report the following:
grep plex /etc/passwd
ls -la /var/lib/plexmediaserver
bsab5
March 31, 2019, 5:38pm
6
ChuckPa:
grep plex /etc/passwd
grep plex /etc/passwd:
plex:x:111:118::/var/lib/plexmediaserver:/bin/bash
plexpy:x:112:65534::/home/plexpy:/bin/false
ls -la /var/lib/plexmediaserver:
total 12
drwxr-xr-x 3 plex plex 4096 Mar 30 14:04 .
drwxr-xr-x 46 root root 4096 Aug 15 2018 …
drwxr-xr-x 3 plex plex 4096 Mar 30 16:15 Library
bsab5
March 31, 2019, 5:39pm
7
Yes, I saw those warning to ignore but from what I recall those were from Feb and most said it was going to be fixed shortly. Do we have an ETA on when that will be fixed or do I need to modify the repository to look elsewhere?
I don’t have an ETA (unfortunately).
The repository work became single-threaded and is in the hands of the one team member who can finish it.
Modify to look elsewhere? Where else would you look? There is only one Plex repository and only one plex.tv/downloads site
bsab5
April 1, 2019, 5:54pm
9
I never saw a response to my other inquiry, where you asked me to give the results of those 2 commands.
grep plex /etc/passwd:
plex:x:111:118::/var/lib/plexmediaserver:/bin/bash
plexpy:x:112:65534::/home/plexpy:/bin/false
ls -la /var/lib/plexmediaserver:
total 12
drwxr-xr-x 3 plex plex 4096 Mar 30 14:04 .
drwxr-xr-x 46 root root 4096 Aug 15 2018 …
drwxr-xr-x 3 plex plex 4096 Mar 30 16:15 Library
Let’s start this by hand and see what comes up
Assign a temporary password to user plex
Assign /bin/sh as the shell for plex (default is /sbin/nologin )
Execute this manual start (su plex first to run as user plex )
#!/bin/sh
export PLEX_MEDIA_SERVER_MAX_PLUGIN_PROCS=6
export PLEX_MEDIA_SERVER_HOME=/usr/lib/plexmediaserver
export PLEX_MEDIA_SERVER_MAX_STACK_SIZE=3000
export PLEX_MEDIA_SERVER_TMPDIR=/tmp
export PLEX_MEDIA_SERVER_APPLICATION_SUPPORT_DIR="/var/lib/plexmediaserver/Library/Application Support"
export LD_LIBRARY_PATH="/usr/lib/plexmediaserver/lib"
export TMPDIR="${PLEX_MEDIA_SERVER_TMPDIR}"
echo $PLEX_MEDIA_SERVER_MAX_PLUGIN_PROCS $PLEX_MEDIA_SERVER_MAX_STACK_SIZE $PLEX_MEDIA_SERVER_APPLICATION_SUPPORT_DIR
(cd /usr/lib/plexmediaserver; ./Plex\ Media\ Server)
1 Like
bsab5
April 9, 2019, 8:00pm
12
ChuckPA, here are the results. I think I did this correctly. FYI, my Plex user was already assigned to /bin/sh.
Results:
su plex
$ #!/bin/sh
$ export PLEX_MEDIA_SERVER_MAX_PLUGIN_PROCS=6
$ export PLEX_MEDIA_SERVER_HOME=/usr/lib/plexmediaserver
$ export PLEX_MEDIA_SERVER_MAX_STACK_SIZE=3000
$ export PLEX_MEDIA_SERVER_TMPDIR=/tmp
$ export PLEX_MEDIA_SERVER_APPLICATION_SUPPORT_DIR="/var/lib/plexmediaserver/Library/Application Support"
$ export LD_LIBRARY_PATH="/usr/lib/plexmediaserver/lib"
$ export TMPDIR="${PLEX_MEDIA_SERVER_TMPDIR}"
$ echo $PLEX_MEDIA_SERVER_MAX_PLUGIN_PROCS $PLEX_MEDIA_SERVER_MAX_STACK_SIZE $PLEX_MEDIA_SERVER_APPLICATION_SUPPORT_DIR
6 3000 /var/lib/plexmediaserver/Library/Application Support
$ (cd /usr/lib/plexmediaserver; ./Plex\ Media\ Server)
sh: 11: ./Plex Media Server: not found
bsab5
April 9, 2019, 8:00pm
13
Thanks! My repo works now. So if only I can get Plex working…
It would only show “not found” if there is NOEXEC preventing execution.
What extra info is missing?
I looked right at it too and missed it
Change:
cd /usr/lib/plexmediaserver
./Plex\ Media\ Server
Invoking a sub-shell ( )
, returns you to your $HOME directory. “Plex Media Server” isn’t there.
bsab5
April 9, 2019, 10:33pm
16
Here is exactly what I put in and the results. After the last command what should happen? I’m not familiar with these steps so I’m literally copying and pasting into an SSH session. Am I missing something?
su plex
Password:
$ #!/bin/sh
$ export PLEX_MEDIA_SERVER_MAX_PLUGIN_PROCS=6
$ export PLEX_MEDIA_SERVER_HOME=/usr/lib/plexmediaserver
$ export PLEX_MEDIA_SERVER_MAX_STACK_SIZE=3000
$ export PLEX_MEDIA_SERVER_TMPDIR=/tmp
$ export PLEX_MEDIA_SERVER_APPLICATION_SUPPORT_DIR="/var/lib/plexmediaserver/Library/Application Support"
$ export LD_LIBRARY_PATH="/usr/lib/plexmediaserver/lib"
$ export TMPDIR="${PLEX_MEDIA_SERVER_TMPDIR}"
$ echo $PLEX_MEDIA_SERVER_MAX_PLUGIN_PROCS $PLEX_MEDIA_SERVER_MAX_STACK_SIZE $PLEX_MEDIA_SERVER_APPLICATION_SUPPORT_DIR
6 3000 /var/lib/plexmediaserver/Library/Application Support
$ cd /usr/lib/plexmediaserver ./Plex\ Media\ Server
I checked Plex after these commands and it was still not running. I also tried to start Plex manually and it prompted me for my main user password, which I put in but still it did not start.
Moderator Edit: Triple backtick for legibility
Your last line should be broken into two lines.
cd /usr/lib/plexmediaserver
./Plex\ Media\ Server
bsab5
April 10, 2019, 12:11pm
18
Ok. Here are the results.
su plex
Password:
$ #!/bin/sh
$ export PLEX_MEDIA_SERVER_MAX_PLUGIN_PROCS=6
$ export PLEX_MEDIA_SERVER_HOME=/usr/lib/plexmediaserver
$ export PLEX_MEDIA_SERVER_MAX_STACK_SIZE=3000
$ export PLEX_MEDIA_SERVER_TMPDIR=/tmp
$ export PLEX_MEDIA_SERVER_APPLICATION_SUPPORT_DIR="/var/lib/plexmediaserver/Library/Application Support"
$ export LD_LIBRARY_PATH="/usr/lib/plexmediaserver/lib"
$ export TMPDIR="${PLEX_MEDIA_SERVER_TMPDIR}"
$ echo $PLEX_MEDIA_SERVER_MAX_PLUGIN_PROCS $PLEX_MEDIA_SERVER_MAX_STACK_SIZE $PLEX_MEDIA_SERVER_APPLICATION_SUPPORT_DIR
6 3000 /var/lib/plexmediaserver/Library/Application Support
$ cd /usr/lib/plexmediaserver
$ ./Plex\ Media\ Server
sh: 11: ./Plex Media Server: not found
Moderator edit for legibility
bsab5
April 12, 2019, 11:05pm
19
Chuck, any other suggestions?
I just wanted to pop in here to mention I’m having similar problems. Upgrade from a working 1.14 to a 1.15 and the server doesn’t start.
Running 18.04 but on a 386.
I’ve downgraded back to 1.14.