Plex Consistently Shuts Down Every Day on my Synology

Server Version#: 1.19.1.2645-ccb6eb67e
Synology Device: DS716+II
Synology Version: DSM 6.2.2-24922 Update 4
Player Version#: 1.6.5.1097-3bb9dc68 (on my Macbook Pro)

Without fail, the Plex package stops every day and needs to be re-opened through the Synology interface. I have made sure to download every recent update and keep my Synology up to date, and this problem has continued.

Logs are attached.

Plex Media Server Logs_2020-04-12_11-06-31.zip (5.3 MB)

Turn off the DLNA server. It leaks memory
Your system is swapping then fails due to Out of Memory.

Apr 12, 2020 08:56:18.973 [0x7f5165fc5700] DEBUG - Item 12172 (Café Del Mar, Vol. 6) Scanning metadata graphic elements in XML file ""/Info.xml
Apr 12, 2020 08:56:23.946 [0x7f51662b3700] WARN - SLOW QUERY: It took 6340.000000 ms to retrieve 1 items.
Apr 12, 2020 08:56:24.252 [0x7f51662b3700] DEBUG - Path matched, we're reusing media item 31847
Apr 12, 2020 08:56:28.832 [0x7f5165fc5700] WARN - SLOW QUERY: It took 1520.000000 ms to retrieve 0 items.
Apr 12, 2020 08:56:28.832 [0x7f51662b3700] DEBUG - Looking for path match for [/volume1/JT Media Library/Music/Unknown Artist/Unknown Album/Our Hero.wav]
Apr 12, 2020 08:56:31.345 [0x7f516688f700] ERROR - Error issuing curl_easy_perform(handle): 28
Apr 12, 2020 08:56:31.642 [0x7f516688f700] DEBUG - HTTP simulating 408 after curl timeout
Apr 12, 2020 08:56:31.852 [0x7f516688f700] WARN - MyPlex: Updating device connections failed, retrying in 160 seconds.
Apr 12, 2020 08:56:33.559 [0x7f5165fc5700] WARN - SLOW QUERY: It took 3500.000000 ms to retrieve 2 items.
Apr 12, 2020 08:56:35.693 [0x7f5165fc5700] WARN - SLOW QUERY: It took 1010.000000 ms to retrieve 0 items.
Apr 12, 2020 08:56:38.145 [0x7f516511f700] DEBUG - Sync: uploadStatus
Apr 12, 2020 08:56:38.915 [0x7f5165fc5700] WARN - SLOW QUERY: It took 1240.000000 ms to retrieve 0 items.
Apr 12, 2020 08:56:39.027 [0x7f51662b3700] WARN - SLOW QUERY: It took 8480.000000 ms to retrieve 1 items.
Apr 12, 2020 08:56:39.105 [0x7f51662b3700] DEBUG - Path matched, we're reusing media item 31848
Apr 12, 2020 08:56:42.331 [0x7f51662b3700] DEBUG - Looking for path match for [/volume1/JT Media Library/Music/Unknown Artist/Unknown Album/Our Song....wav]
Apr 12, 2020 08:56:54.699 [0x7f51662b3700] WARN - SLOW QUERY: It took 10610.000000 ms to retrieve 1 items.
Apr 12, 2020 08:56:54.816 [0x7f51662b3700] DEBUG - Path matched, we're reusing media item 31849
Apr 12, 2020 08:56:59.218 [0x7f51662b3700] DEBUG - Looking for path match for [/volume1/JT Media Library/Music/Unknown Artist/Unknown Album/Ouverture!!!.mp3]
Apr 12, 2020 08:57:09.084 [0x7f51662b3700] WARN - SLOW QUERY: It took 8180.000000 ms to retrieve 1 items.
Apr 12, 2020 08:57:09.228 [0x7f51662b3700] DEBUG - Path matched, we're reusing media item 31850
Apr 12, 2020 08:57:14.547 [0x7f51662b3700] DEBUG - Looking for path match for [/volume1/JT Media Library/Music/Unknown Artist/Unknown Album/PHONE_CALL_EDIT_20140731.wav]
Apr 12, 2020 08:57:25.464 [0x7f51662b3700] WARN - SLOW QUERY: It took 8380.000000 ms to retrieve 1 items.
Apr 12, 2020 08:57:25.465 [0x7f51662b3700] DEBUG - Path matched, we're reusing media item 31851
Apr 12, 2020 08:57:32.423 [0x7f51662b3700] DEBUG - Looking for path match for [/volume1/JT Media Library/Music/Unknown Artist/Unknown Album/PJ2_MusicDemo_JT_20121119.mp3]
Apr 12, 2020 08:57:47.355 [0x7f51662b3700] WARN - SLOW QUERY: It took 13790.000000 ms to retrieve 1 items.
Apr 12, 2020 08:57:48.401 [0x7f51662b3700] DEBUG - Path matched, we're reusing media item 31852
Apr 12, 2020 08:57:55.795 [0x7f51662b3700] DEBUG - Looking for path match for [/volume1/JT Media Library/Music/Unknown Artist/Unknown Album/Pagani v1.4.wav]
Apr 12, 2020 08:58:22.179 [0x7f51662b3700] WARN - SLOW QUERY: It took 21160.000000 ms to retrieve 1 items.
Apr 12, 2020 08:58:22.183 [0x7f51662b3700] DEBUG - Path matched, we're reusing media item 31853
Apr 12, 2020 08:58:31.751 [0x7f51662b3700] DEBUG - Looking for path match for [/volume1/JT Media Library/Music/Unknown Artist/Unknown Album/Paige_EDIT (mp3).mp3]
Apr 12, 2020 08:58:54.394 [0x7f51662b3700] WARN - SLOW QUERY: It took 11660.000000 ms to retrieve 1 items.
Apr 12, 2020 08:58:54.437 [0x7f51662b3700] DEBUG - Path matched, we're reusing media item 31854
Apr 12, 2020 08:58:59.728 [0x7f5165fc5700] WARN - SLOW QUERY: It took 137320.000000 ms to retrieve 15 items.

Also,

you have more directories being monitored than Linux can natively handle.
the table size needs increasing.

Thank you so much - will do! I’ll ping you here in a few days to let you know how it goes. Much appreciated.

@ChuckPa just a quick note - I executed the Linux task as described, but was getting an error because (I think) one of the apostrophes in the example code (the closing one) is incorrect. I changed it to a ‘normal’ apostrophe and the task was able to complete.

I am a bit of a n00b here with Linux coding, so please do let me know if I’m mistaken.

Will check in once again in several days with how this all worked out. Thank you!

It is a copy/paste as-written

using this notation (back ticks on preceding and succeeding lines)
```
paste here
```

Show me

# This is an example only.   Use your actual result below
echo 's2s_watches_max=262144' >> /etc/synoinfo.conf

Thank you so much for your quick and helpful replies @ChuckPa! Much appreciated.

This is the code that I used -

echo 's2s_watches_max=98304' >> /etc/synoinfo.conf

I have 40948 folders in my media library.

I think I must have made a copy and paste error before with the code, which is why it didn’t work. The second apostrophe was showing up as a back tick…! So probably user error.

Thank you again.

Did you round up to 65536 ? (next integral multiple of 32768)

40947 / 32768 =   (int)  1
1 + 1 = 2
2 * 32768 = 65536

s2s_watches_max=65536

D’oh! Thank you as always @ChuckPa, much appreciated. I’ll run again with the correct math.

@jetjoe

I updated the script. Please use the updated one.

What I did now keeps the old values from accumulating in /etc/synoinfo.conf (which would be bad over time).

Done. I ran the script below. Thank you!

sed -i 's/^s2s_watches_max=.*$//' /etc/synoinfo.conf

echo 's2s_watches_max=65536' >> /etc/synoinfo.conf

don’t forget to restart :slight_smile:

Rebooted - thank you!

Update here @ChuckPa. Unfortunately, Plex is still having issues.

This morning, Plex did not shut down, but it’s hung up and the interface could not be loaded. The package had to be stopped and restarted manually.

I’m noticing this weird CPU/RAM usage. The CPU was at 2% / RAM was at 39% when Plex was launched a couple of days ago. During this morning’s hang up, the CPU was all the way up to 49% and RAM usage is up to 85%.

Any thoughts? I’m also uploading a new batch of logging from after this AM’s relaunch.

Screen Shot 2020-04-16 at 9.42.13 AM Screen Shot 2020-04-14 at 10.05.24 PM

Plex Media Server Logs_2020-04-16_09-52-01.zip (5.0 MB)

Plex crashed again this morning.

Seems like the ‘leaky RAM’ issue everybody is writing about.

Until this is fixed, I need to scrap Plex and will just use Synology’s built-in Video and Audio Stations.

This is so disappointing.

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