PMS shuts down (crashes) about the same time every week... Logs included

Server Version#: 4.152.0
Player Version#: N/A

My server seem to crash at about the same time every week. Can you help me identify a solution based on the logs?

These are the logs from the 10 minutes prior to the server shutdown this morning. It seem to happen at 0641. Tautulli reported the server to be down at 0643

Nov 17, 2025 06:31:22.086 [139834537716536] WARN - SLOW QUERY: It took 260.000000 ms to retrieve 0 items.
Nov 17, 2025 06:31:29.497 [139834557922104] ERROR - MetadataAgent: unable to save posters asset from ‘https://lastfm.freetls.fastly.net/i/u/300x300/f86dffe247f35937a5d9c9153acb53e5.gif’ to ‘“/var/packages/PlexMediaServer/shares/PlexMediaServer/AppData/Plex Media Server/Metadata/Albums/a/4e3fd96d0118bf1c5e3405213bba1f296d5f62b.bundle/Contents/_combined/posters”’
Nov 17, 2025 06:31:38.867 [139834557922104] WARN - SLOW QUERY: It took 220.000000 ms to retrieve 1 items.
Nov 17, 2025 06:31:54.282 [139834557922104] WARN - [Lyrics] SLOW QUERY: It took 260.000000 ms to retrieve 24 items.
Nov 17, 2025 06:31:56.136 [139834557922104] WARN - [Lyrics] SLOW QUERY: It took 290.000000 ms to retrieve 50 items.
Nov 17, 2025 06:32:00.801 [139834557922104] WARN - [Lyrics] SLOW QUERY: It took 350.000000 ms to retrieve 67 items.
Nov 17, 2025 06:32:10.293 [139834557922104] WARN - [Lyrics] SLOW QUERY: It took 450.000000 ms to retrieve 40 items.
Nov 17, 2025 06:32:19.901 [139834557922104] WARN - [Lyrics] SLOW QUERY: It took 1780.000000 ms to retrieve 40 items.
Nov 17, 2025 06:32:23.979 [139834557922104] WARN - [Lyrics] SLOW QUERY: It took 1520.000000 ms to retrieve 36 items.
Nov 17, 2025 06:33:28.638 [139834557922104] WARN - SLOW QUERY: It took 220.000000 ms to retrieve 1 items.
Nov 17, 2025 06:33:39.152 [139834557922104] WARN - [Lyrics] SLOW QUERY: It took 290.000000 ms to retrieve 29 items.
Nov 17, 2025 06:33:45.992 [139834557922104] WARN - [Lyrics] SLOW QUERY: It took 250.000000 ms to retrieve 31 items.
Nov 17, 2025 06:33:54.200 [139834557922104] WARN - [Lyrics] SLOW QUERY: It took 310.000000 ms to retrieve 54 items.
Nov 17, 2025 06:34:01.891 [139834557922104] WARN - [Lyrics] SLOW QUERY: It took 320.000000 ms to retrieve 58 items.
Nov 17, 2025 06:35:23.151 [139834555812664] ERROR - [UltraBlurProcessor] Failed to get color palette: Empty pixels when quantize
Nov 17, 2025 06:35:23.156 [139834555812664] ERROR - [UltraBlurProcessor] Failed to get color palette: Empty pixels when quantize
Nov 17, 2025 06:35:23.159 [139834555812664] ERROR - [UltraBlurProcessor] Failed to select colors
Nov 17, 2025 06:35:23.398 [139834557922104] WARN - [Lyrics] SLOW QUERY: It took 210.000000 ms to retrieve 4 items.
Nov 17, 2025 06:35:31.723 [139834557922104] WARN - [Lyrics] SLOW QUERY: It took 230.000000 ms to retrieve 24 items.
Nov 17, 2025 06:35:33.235 [139834557922104] WARN - [Lyrics] SLOW QUERY: It took 240.000000 ms to retrieve 20 items.
Nov 17, 2025 06:36:23.953 [139834557922104] WARN - [Lyrics] SLOW QUERY: It took 210.000000 ms to retrieve 13 items.
Nov 17, 2025 06:37:14.692 [139834557922104] WARN - SLOW QUERY: It took 700.000000 ms to retrieve 1 items.
Nov 17, 2025 06:37:32.261 [139834557922104] WARN - [Lyrics] SLOW QUERY: It took 250.000000 ms to retrieve 55 items.
Nov 17, 2025 06:37:48.626 [139834557922104] WARN - [Lyrics] SLOW QUERY: It took 340.000000 ms to retrieve 23 items.
Nov 17, 2025 06:37:53.832 [139834557922104] ERROR - [MetadataAgent/GuidExchange/tv.plex.agents.music] Failing exchange for lack of track matches.
Nov 17, 2025 06:37:53.835 [139834557922104] WARN - MetadataAgentPostProcessor: error refreshing metadata for mbid://2a19c9a7-64d3-4063-b6c5-1e629dab1585
Nov 17, 2025 06:38:03.719 [139834599627576] WARN - [Req#7e649] Ignoring client [4bc3b261-2a3a-45ca-87e2-55f25e886eab] reporting timeline state playing: metadata item 89798 no longer exists
Nov 17, 2025 06:38:42.428 [139834557922104] WARN - [Lyrics] SLOW QUERY: It took 230.000000 ms to retrieve 20 items.
Nov 17, 2025 06:38:54.854 [139834557922104] ERROR - [MetadataAgent/GuidExchange/tv.plex.agents.music] Matching item mbid://76b4958d-b935-4ec9-b4e5-aabeaa7b45b8 returned incomplete results
Nov 17, 2025 06:38:54.857 [139834557922104] WARN - MetadataAgentPostProcessor: error refreshing metadata for mbid://76b4958d-b935-4ec9-b4e5-aabeaa7b45b8
Nov 17, 2025 06:38:54.959 [139834557922104] ERROR - [MetadataAgent/GuidExchange/tv.plex.agents.music] Matching item mbid://380b5314-9077-443c-9521-842587f176a4 returned incomplete results
Nov 17, 2025 06:38:54.962 [139834557922104] WARN - MetadataAgentPostProcessor: error refreshing metadata for mbid://380b5314-9077-443c-9521-842587f176a4
Nov 17, 2025 06:39:02.962 [139834557922104] WARN - SLOW QUERY: It took 230.000000 ms to retrieve 0 items.
Nov 17, 2025 06:40:04.004 [139834557922104] WARN - [Lyrics] SLOW QUERY: It took 250.000000 ms to retrieve 24 items.
Nov 17, 2025 06:40:10.673 [139834557922104] WARN - [Lyrics] SLOW QUERY: It took 280.000000 ms to retrieve 23 items.
Nov 17, 2025 06:41:00.744 [139834557922104] WARN - SLOW QUERY: It took 230.000000 ms to retrieve 1 items.
Nov 17, 2025 06:41:30.585 [139834523503416] ERROR - [MetadataAgent/GuidExchange/tv.plex.agents.music/tv.plex.metadata.agents/Response::fetch] failed to complete query (404)
Nov 17, 2025 06:41:30.585 [139834557922104] ERROR - [MetadataAgent/GuidExchange/tv.plex.agents.music/tv.plex.metadata.agents] Request for item plex://album/5d07c6a9403c640290b2de17 has failed
Nov 17, 2025 06:41:31.546 [139834557922104] WARN - [MetadataAgent/GuidExchange/tv.plex.agents.music] Crash: Crash reporting disabled

@Hoggorm

It’s very clear your database is severely fragmented.

It needs a level of optimization which “Optimize database” cannot provide.

The crash might be because of other, minor, database problem(s) but it’s not possible to determine from this excerpt.

My advise is to first run DBRepair and have it perform the basic checks of the DB and then optimize it as it should be (to restore performance)

There is documentation in the README.md

I recommend reading completely and asking if you have ANY questions.

Oh boy… That looks very advanced for me…

First question before I even start reading the Readme file: The Plex server is located on a Synology using Synology Hybrid Raid with one disk fail protection. This means that the data is distributed over four disk in the NAS. Would not that make the data, by default, fragmented? And really not solvable?

The crash seem to be when using the tv.plex.agents.music. Since this does not appear to be regarding fragmented disk, is this a place to start problem solving? I’m not sure I will be able to fully understand DBRepair… It seems to be above my knowledge level in computers…

Synology SHR is one way they create RAID volumes.
It’s very fast and the data is written to the drives such that it enhances the performance significantly.

I have an old DS1815+ with SHR RAID and it provide 900 MB/sec sustained.

We don’t need to care about where the data is physically stored. The drives are more than fast enough for that.

The “SLOW QUERY” shows us the database’s internal indexes need reorganizing and rebuilding.

Do you have any experience using the Windows or MacOS command line?

Possibly also related, are you using Plexamp for music?

I understand.

Yes, I am using Plexamp for music.

I’ve never used the MacOS command line, and Windows experience is basically limited to “ipconfig” if you know what I mean…

Now, I have actually SSHed into the NAS and been able to use command lines there a couple of times. I started reading the Readme and I it seems to me that I need to unzip, install and elevate the DBRepair.sh file. I should be able to do this.

Reading further on the document however I am lost at “Typical usage”

I can’t really say that I understand what commands to use after installation and elevation of the .sh file… Do I just type 2 for automatic or what… :woozy_face:

First, There is an issue with Plexamp and PMS. From what I know, Engineering has already identified the cause and is working on it. I don’t know how quickly it will be released but expect soon.

Regarding your databases, If I gave you a step-by-step, would that help you enough ?

1 Like

I see. I’ve really not seen any specific issues with Plexamp so far. I use it basically every day.

I think I should be able to do it then yes. If you would help me with that it would be highly appreciated!

The only case I am worried about is if the expected result do not happen. Or nothing happens at all after typing a command. Then I fear I might break something when exiting SSH… I read about the 99 command than I understand will revert everything? It could be useful to know what to type should it be necessary…

Not to nag or anything, but I’d love a step-by-step guide on how to use DBRepair on my Synology NAS Plex Server.