Intel NUC 7i7BNH running Windows 10 Pro 21H2 19044.1415:
Processor Intel(R) Core™ i7-7567U CPU @ 3.50GHz 3.50 GHz
Installed RAM 32.0 GB (31.9 GB usable)
System type 64-bit operating system, x64-based processor
Plex server Version 1.25.3.5385
Clients are all sorts. Roku, AppleTV, ChromeCast, Samsung, etc…
I’ve been running my Plex server on a NUC for a few years but the last few months I’ve been seeing Plex crashes due to memory usage.
I started to take more notice of it because when memory usage got high, some of the thumbnails for media items on the Plex Home page would start showing up blank and no matter what I did they wouldn’t update. Then after it eventually crashed and I started it again, things were fine and all the thumbnails showed up again.
I started looking in the logs and noticed messages like:
Jan 05, 2022 18:40:32.209 [7244] ERROR - Format [JPEG] - Insufficient memory (case 4)
Jan 05, 2022 18:40:32.209 [7244] ERROR - Error resizing an image, we don’t trust what we cached [C:\Users\tooon\AppData\Local\Plex Media Server\Cache\PhotoTranscoder\b3\b3b4d07f229a7470821e0a74d6789a75a4c40770.jpg]
So I’ve come to a point where it’ll stay up for a day or two, but will eventually die because it’s running into that 2G memory limit. Some nights I check memory usage before bed and exit Plex and start a new one so that it doesn’t die unexpectedly overnight or the next day.
Sadly since the crashes are memory related, the few crash dirs that it’s been able to create are all empty.
I’ve got a number of log zips from some of those occurrences of when it crashes, and from when the memory seems to balloon quickly and I stop/start it before bed.
I have Debug logging enabled, and also enabled LogMemoryUse and upped LogNumFiles to 50 to try and hold onto more logs for better troubleshooting, but I wish I could see more of what’s going on to correlate between logs. I’ve had vmmap running to be able to visualize the memory growth on an ongoing basis. I haven’t given procmon a shot yet though.
I also have some “Plex Transcoder.exe.####.dmp” files from …\AppData\Local\CrashDumps, not sure if those would be relevant or not.
Based on a recommendation from another thread, I looked in …\AppData\Local\Temp and found a bunch of files named logs.zip from the timeframe that these crashes have been happening, and when I rename them to have .zip ending, they turn out to be plex log zips. I’m guessing these may be from instances where it’s crashed and it’s trying to build the crashreport zip, but due to the memory condition it’s unable to complete it.
Interestingly it crashed again just as I was writing this up:
Jan 08, 2022 21:38:40.393 [7000] ERROR - Thread: Couldn’t add a new thread to the pool of size 11: boost::thread_resource_error: Resource temporarily unavailable
Jan 08, 2022 21:38:40.393 [16292] ERROR - Thread: Uncaught exception running async task which was spawned by thread 7452: bad allocation

