not sure if this happened in context with the latest update to 6.3.2 or a prior power outage, but my Plex doesn’t start any more.
journalctl logs the failing reason:
Starting Plex Media Server...
[b]DietPi Plex Media Server[679]: [b]/bin/mkdir: cannot create directory ‘/var/lib/plexmediaserver/Library’: File exists[/b][/b]
DietPi systemd[1]: plexmediaserver.service: Control process exited, code=exited status=1
DietPi systemd[1]: Failed to start Plex Media Server.
ls /mnt/plexlib/Library
ls: cannot access '/mnt/plexlib/Library': No such file or directory
systemctl status plexmediaserver
● plexmediaserver.service - Plex Media Server
Loaded: loaded (/lib/systemd/system/plexmediaserver.service; enabled; vendor preset: enabled)
Drop-In: /etc/systemd/system/plexmediaserver.service.d
└─dietpi-group.conf, dietpi-services_edit.conf
Active: failed (Result: exit-code) since Sun 2020-09-06 11:40:16 CEST; 2min 49s ago
Process: 1680 ExecStartPre=/bin/sh -c /usr/bin/test -d "${PLEX_MEDIA_SERVER_APPLICATION_SUPPORT_DIR}" || /bin/mkdir -p "${PLEX_MEDIA_SERVER_APPLICATION_SUPPOR
T_DIR}" (code=exited, status=1/FAILURE)
/var/lib/plexmediaserver has been originally owned by root:root, I experimented with plex:plex, plex:dietpi, root:dietpi etc., no success.
Is there anybody experiencing the same or has an idea to fix it?
Will a simple dietpi uninstall/reinstall fix this at a last resort? (Fearing the loss of all the metadata)
Thank you for taking a look at this and hinting me to broken hardware.
Plexlib had been moved and symlinked to an external disk, as it grew too large for the SD-Card.
This disk died (in fact a 16GB USB-Stick just for this purpose).
If you ever lose an external plexlibrary :
Create a new mounting point on a fresh disk.
Create a folder called “Library” on it.
Make this folder owned by plex (chown -R plex:plex )
Create a symlink to “Library” inside /var/lib/plexmediaserver
Set the correct user:group for the original library folder:
chown -R plex:plex /var/lib/plexmediaserver
Restart Plex.
Just did it and Plex ran up successfully.
Now it’s like a fresh install, building a new library.
Thank you for the push to the right direction, Joulinar!