Server Version#: 1.29.2.6364-6d72b0cf6 (QNAP NAS)
Player Version#: 9.12.2.36964 (Sony/Android TV)
NAS Model: QNAP TS-873A
NAS Firmware: QuTS hero h5.0.1.2192
Plex server hangs while scanning new movies.
“Activity” icon on server shows continuous activity but the file being scanned never advances.
On the client side, cannot mark media as “Played”, watching shows in a TV series will not automatically advance to the next show in the series (shows black screen until I press the “Back” button on the remote), new moves and TV shows are not added to the client UI.
Problem has only shown up within the last week but occurs several times per day, requiring that the Plex server by stopped/restarted.
When stopping/starting Plex though the QNAP GUI, service fails to restart correctly (all libraries are inaccessible to the client and client GUI shows yellow triangles with an exclamation point). Restarting manually through the CLI shows that the Plex server isn’t actually stopped by the plex.sh script:
[nasadmin@stockroom PlexMediaServer]$ sudo /share/ZFS1_DATA/.qpkg/PlexMediaServer/plex.sh stop
Password:
Stopping Plex Media Server…
[nasadmin@stockroom PlexMediaServer]$ sudo ps -ef | grep -i plex
6143 nasadmin 1032 S grep -i plex
31850 admin 70784 S ./Plex Media Server
Need to manually kill the server before restarting Plex:
From what I see, there are several things happening here:
Your shared folder definitions are going through the NFS client layer. This isn’t necessary and will slow it down. To remedy,
The database access is pretty slow.
I’d like to recommend –
For each of your library sections.
– EDIT the library section,
– Advanced
– Folders
– ADD the paths but exclude NFS_v=4 part . e.g. /share/media/movies-hd
– After all are added, OK / SAVE and let PMS scan it.
– When you see the scanning has stopped,
– EDIT the same library section again.
– DELETE only the path references through NFSv=4.
– OK/SAVE again and let it scan one last time.
What this does is stop using NFS client layer to access the local media.
After that’s done, Empty Trash, Clean Bundles, and Optimize Database
When you have a condition where PMS isn’t stopping, it’s usually because it’s getting hung up by the database.
Are you good at the shell?
If so, I have a shell script for you to use which will do a deeper check and optimization of the database than can be done while PMS is running.
Thanks, things are running better now. Likely that removing the NFSv4 was the major source of the problem. (Didn’t see any issues with failing to track progress on watched media which was my leading indicator of a problem.).
Running the DBRepair.sh script didn’t reveal any issues but I also added an SSD cache to the NAS after all changes which likely contributes to the new, snappier behavior.
I’d note that adding a new path then removing the original path was a slow operation for both the TV and Music libraries which are much larger than the Movie library, so anyone who comes across this note might want to be patient, only change one library at a time, and disable automatic/periodic library scans to speed up the process.