"Optimize Database" will Crash the whole Server 1.23.5 / 1.23.6

QTS 4.5.4.1723 (Newest)
Plex Media Server 1.23.3.4707 > Runs without any issues
Plex Media Server 1.23.4.4805 > Not possible to Download
Plex Media Server 1.23.5.4841 > Crash
Plex Media Server 1.23.6.4810 > Crash

Maybe because of added support for QTS 5.0, QTS 4.5 is now brocken?

Even if you do a clean install without restore anything, it won’t open the Webinterface until you reboot the QNAP which i actually just use for PLEX.


Spent the wohle day trying to get a newer Version running but at least when i press “Optimize Database”, the wohle Server will crash immediately and i have to use a Backup.

Even if i installed an older version, i could not get access anymore, usually not even to the web interface. Just when i was lucky after a reboot, but then was my server still missing.

Tried everything, also logout / login (server and plex.tv), enough space, set all rigts new again, nothing will let it run.

Only completly new install, reboot and restored Backup will work until you press again “Optimize Database” if you are on 1.23.5 / 1.23.6.
Same identically way with 1.23.3 and lower will work whitout any issues.


Even if i repair the DB (Check says OK) it won’t work.

"/share/CACHEDEV1_DATA/.qpkg/PlexMediaServer/Plex SQLite" com.plexapp.plugins.library.db ".output dump.sql" ".dump"
rm com.plexapp.plugins.library.db
"/share/CACHEDEV1_DATA/.qpkg/PlexMediaServer/Plex SQLite" com.plexapp.plugins.library.db ".read dump.sql"

What i found at the Repair site "QNAP – admin:admin", this is wrong, QTS 4.5 uses as default Group “administrators”

Plex Media Server.log (172.7 KB)
This LOG is generated after a clean install, can’t even open PLEX (before reboot).

@Soluna

QTS 5.0 is best-effort only because QTS 5.0 is beta.

QNAP requested we remove the version restriction to allow further testing.

As Synology stabilizes, I will have more time to work with QTS 5.0

Recommendation is to revert to QTS 4.5

I Use QTS 4.5 - Never installed QTS 5.0.
But since your Packages support QTS 5.0, they won’t run @ QTS 4.5 anymore (in my case).

What was also strange, after the Update was my Mounted “Plex Media Folder” under the File Station no longer accessable from my user (admin deactivated but for all these her i used admin account).

@Soluna

I did not change any of the scripts (QPKG mechanisms).

Please observe below, from the source tree itself.

Thank you for the log file. It shows a process is hung. We need to take care of this first.

Jul 22, 2021 21:33:53.930 [0x7fb756f5dd30] DEBUG - Completed forward migration 20210628131300.
Jul 22, 2021 21:33:53.939 [0x7fb756f5dd30] DEBUG - HttpServer: Listening on IPv6 as well as IPv4.
Jul 22, 2021 21:33:53.939 [0x7fb756f5dd30] ERROR - HttpServer: Error binding acceptor: Address in use
Jul 22, 2021 21:33:53.939 [0x7fb756f5dd30] ERROR - HttpServer: Error opening acceptor on IPv6, falling back to IPv4: Address in use
Jul 22, 2021 21:33:53.939 [0x7fb756f5dd30] ERROR - HttpServer: Error binding acceptor: Address in use
Jul 22, 2021 21:33:53.939 [0x7fb756f5dd30] ERROR - Error: Unable to set up server: listen: Address in use (N5boost10wrapexceptINS_6system12system_errorEEE)

If you’re comfortable on the command line, clearing the pid without restarting the NAS

  1. Plex stopped
  2. kill -i $(ps -ef | grep -i plex | cut -d ' ' -f 1)
  3. You will have 1 “No such process.”. This is expected.
  4. Now Plex can be restarted if the DB repair is complete.

Please advise if there’s more to do before it can be restarts.

PS: I filed a change request to fix the documentation which I authored :man_facepalming:

Thx 4 reply, probably i can not try before sunday because i am two days not at home, actually it runs again with 1.23.3, as i always just have to install this version and restore backup, without any issues.

  • Working 1.23

  • Stopped

  • Updated 1.23.5.4862

  • Opened / Worked

  • Scan for Movies / Series

  • Delete all LOGs

  • Activate Debug

  • Optimise DB / Worked for the first time

  • Uninstall PLEX

  • Install 1.23.5.4862

  • Opened / Worked

  • Scan for Movies / Series

  • Optimise DB for the first time / Worked

  • Was away less than 1h

  • Optimise DB for the secound time / Broken

Plex Media Server 1.23.5.4862 (No Debug Log).log (32.1 KB)
Debug was not activated, not sure if it will help.

  • Stop PLEX

  • kill -i $(ps -ef | grep -i plex | cut -d ' ' -f 1) will just get out -sh: kill: i: invalid signal specification and with sudo kill: bad signal name 'i'

  • There is no pid for plex, pidof plexwill get nothing out

  • /bin/ps | grep -i plex gives out 18916 admin 70296 S ./Plex Media Server and 20390 admin 964 S grep -i plex with always different numbers

  • run with Plex SQLite will output Error: unknown option: -i

Run Plex but still not possible to access Web
Plex Media Server 1.23.5.4862 (No Debug Log #1).log (815 Bytes) (New Log File)
Plex Media Server 1.23.5.4862 (No Debug Log #2).log (40.4 KB) (Old with new entries)

Because after a reboot it will always work until “Optimize DB” will break it again.

Now i could press it several times, then i rescannec both libraries and did it again like i also usually clean the packages.
Plex Media Server 1.23.5.4862 (No Debug Log #3).log (30.3 KB)

Now i installed QTS 5.0 Final and Updated PLEX to 1.24.4.5081

It’s still the same Error, when i wanna Optimize my DB PLEX will crash and not be able to access again.
After Updates, first “Optimize DB” was done, then i refreshed Movies, tried to Optimize DB again and it broke again.

Please help to find and fix this issue because i can’t use it anymore and its also not a real way to stand with QTS 4.5 and PLEX 1.23.3.4707 for next years.
Now i used it for 3 Months without any issue and i also can use older Version, but not one newer than 1.23.3.4707

Plex Media Server.log (18.4 KB)

Please enable Debug Logging when providing logs for diagnostics.

Settings → Server → General → Enable Plex Media Server debug logging

Always i start Plex Service after a DB restore, it will change the Time of “com.plexapp.plugins.library.db” File and create “wal” and “shm”.
Don’t know for what is “com.plexapp.plugins.library.blobs.db” but they was about years just some KB and since i could just use 1.23.3.4707 it is getting bigger and bigger, now 919 MB.

Among other things i did these steps now

If i Stop PLEX the “wal” and “shm” won’t appear and when i Start PLEX again i can’t even access the Web.
If i restore just the DB, i still can’t access the Web anymore, even not in PLEX Clients.
If i restore the whole “Plex Media Server” Folder, nothing changes.
If i reinstall PLEX APP without delete it before, nothing changes.

After i reboot the wohle NAS, i can Access PLEX again. (Like i remember, that not always helped).
Of course i deleted an restored the unclosed DB before.

As there i had shared already normal LOGs i wanna activate both because there it will need usually a lot of time to get access again.



Opened PLEX Web under normal user login (also admin rights because usually admin is deactivated, made never a difference)

  • 12:13 - Optimize DB
  • 12:14 - Scan for Metadata and close / reopen PLEX
  • 12:15 - Optimaie DB / Clean Packages
  • 12:16 - Scan for Metadata
  • 12:17 - Optimize DB
  • 12:19 - Optimize DB / Clean Packages (without wait until Optimize DB was ended) >> PLEX Crashed

Now i don’t know if “Clean Packages” will affected it because i am sure that i was waiting in QTS 4.5 until “Optimize DB” was done and it also broke.
Until i close the Web Page i can click around but no sites will load.
Don’t know why i could refresh DB three Times until it happened but here are the LOGs.

Plex Media Server 2021-10-22 _ 1225.log (2.7 MB) (right after)
Plex Media Server 2021-10-22 _ 1232.log (2.7 MB) (after stop plex and reboot NAS)



Opened Web over “admin” (Still activated because this PLEX issue, every Backup and Restore i always do under Admin)

  • Deactivated, Restored DB, Reboot NAS
  • 12:51 - Activate PLEX and Open
  • 12:52 - Optimize DB
  • 12:53 - Optimize DB again
  • 12:54 - Clean Packages
  • 12:55 - Optimize DB / Clean Packages (after ending)
  • 12:56 - Optimize DB / Clean Packages (without wait until Optimize DB was ended) >> PLEX Crashed

Maybe now its just if you wanna press “Clean Packages” when "Optimize DB was not done.
Hope so because this would be easier to fix.
But still i am sure that it before in QTS 4.5 also crashed without “Clean Packages”, even this doesn’t matter anymore if it really just would be this now.

Plex Media Server 2021-10-22 _ 1304.log (871.4 KB)

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.