Player Version#: Plex web 4.87.2 (but doesn’t really matter, since it’s the same issue on all clients)
CPU: Intel i3-12100T
No extra GPU installed
Unraid Version 6.11.5 (thus I’m running the 5.19.17 kernel)
Docker Image: plexinc/pms-docker:latest
/dev/dri is mounted into the container
transcode temp directory is a mounted directory from the host
Option: Enable HDR tone mapping
Option: Disable video stream transcoding
Option: Use hardware acceleration when available
Option: Use hardware-accelerated video encoding
simultaneous transcodes is set to unlimited
In general, I can confirm, that 1080p H246 and HEVC content is being transcoded properly. The same applies to 2160p HEVC non-HDR content. They all utilize my iGPU when transcoding content. Thus, CPU usage is low while iGPU usage goes up.
When I try the same with 4k HEVC HDR, things start to fall apart and it’s 100% utilizing my CPU without using the iGPU at all. Beside my own content, I was also testing the LG New York demo linked here without success. Hardware transcoding not working in docker - #33 by ChuckPa
This is a small snippet I have identified to look suspicious
Jan 19, 2023 09:51:46.527 [0x15530b287b38] Error — [Req#187446/Transcode/kus7i1qd4rcm6ixfa7zpwuqf/812bf490-2ad8-4730-bb88-68a52ab99ccf] [AVHWDeviceContext @ 0x150ede1c0840] Failed to get number of OpenCL platforms: -1001.
Jan 19, 2023 09:51:46.527 [0x15530b48ab38] Error — [Req#18746b/Transcode/kus7i1qd4rcm6ixfa7zpwuqf/812bf490-2ad8-4730-bb88-68a52ab99ccf] [AVHWDeviceContext @ 0x150ede1c0840] Failed to get number of OpenCL platforms: -1001.
Jan 19, 2023 09:51:46.527 [0x15530b287b38] Error — [Req#18746f/Transcode/kus7i1qd4rcm6ixfa7zpwuqf/812bf490-2ad8-4730-bb88-68a52ab99ccf] [Parsed_hwmap_2 @ 0x150ee40db980] Failed to created derived device context: -19.
Jan 19, 2023 09:51:46.527 [0x15530b48ab38] Error — [Req#187472/Transcode/kus7i1qd4rcm6ixfa7zpwuqf/812bf490-2ad8-4730-bb88-68a52ab99ccf] [Parsed_hwmap_2 @ 0x150ee40db980] Failed to configure output pad on Parsed_hwmap_2
Jan 19, 2023 09:51:46.528 [0x15530b287b38] Error — [Req#187475/Transcode/kus7i1qd4rcm6ixfa7zpwuqf/812bf490-2ad8-4730-bb88-68a52ab99ccf] Error reinitializing filters!
Jan 19, 2023 09:51:46.528 [0x15530b48ab38] Error — [Req#187478/Transcode/kus7i1qd4rcm6ixfa7zpwuqf/812bf490-2ad8-4730-bb88-68a52ab99ccf] Failed to inject frame into filter network: No such device
Jan 19, 2023 09:51:46.528 [0x15530b287b38] Error — [Req#18747b/Transcode/kus7i1qd4rcm6ixfa7zpwuqf/812bf490-2ad8-4730-bb88-68a52ab99ccf] Error while processing the decoded data for stream #0:0
Jan 19, 2023 09:51:46.539 [0x15531e9f9b38] Debug — Jobs: '/usr/lib/plexmediaserver/Plex Transcoder' exit code for process 7941 is 1 (failure)
Jan 19, 2023 09:51:46.539 [0x15530748cb38] Debug — Streaming Resource: Changing client to use software decoding
Further I was digging a bit deeper and found possible solutions here in the PLEX forums and in the Unraid forums stating to enable GuC / HuC firmware loading. I haven’t dont any changes to it yet, but I dug into my syslog and found them at least to be enabled. I’m unsure if GuC submission must be enabled in order to get everything to work.
Dec 24 23:09:26 tower kernel: i915 0000:00:02.0: [drm] Finished loading DMC firmware i915/adls_dmc_ver2_01.bin (v2.1)
Dec 24 23:09:26 tower kernel: i915 0000:00:02.0: [drm] GuC firmware i915/tgl_guc_70.1.1.bin version 70.1
Dec 24 23:09:26 tower kernel: i915 0000:00:02.0: [drm] HuC firmware i915/tgl_huc_7.9.3.bin version 7.9
Dec 24 23:09:26 tower kernel: i915 0000:00:02.0: [drm] HuC authenticated
Dec 24 23:09:26 tower kernel: i915 0000:00:02.0: [drm] GuC submission disabled
Dec 24 23:09:26 tower kernel: i915 0000:00:02.0: [drm] GuC SLPC disabled
So, what else can I look into to get it working? I’m happy to share any kind of logs. Just let me know and I’ll send them via DM.
The service restarted, performed a DB migration for around one minute and now shows up as 1.29.2.6273. Restarting the container always resulted in an auto-upgrade even after using a specific image tag. Not sure if this is intended.
After performing another test, I am able to HW transcode 2160p HDR content to 1080p SDR (selected by me). CPU utilization is around the normal 15-20% (which is normal) while iGPU utilization went up. For confirmation, Tautulli also shows up to use HW transcoding while using Plex Web.
The New York Demo on the other hand doesn’t give me any option to change the video quality. It automatically transcodes to 1080p SDR. If I’m not mistaken, I was able to change the quality on 1.30.x. Anyway it looks like this version is indeed able to HW transcode properly.
Appreciate all your work on this! The most stable workaround I have found is using PMS 1.29 and 515.86.01 NVIDIA driver (for those on the NVIDIA side). It prevents a lot of the general transcoding bugs and the EAC3 audio issues.
As mentioned, I am able to change the quality for basically all my .mkv H264/HEVC content, but not for that LG New York demo you linked which comes in a .ts container. This is the UI I see, when playing it
Not a big deal for me, since all my other files that I just tested are working just fine since. But maybe worth to look into if this version is supposed to be distributed to others who have their content in different containers.
This is the file you linked in another thread which I downloaded. I remuxed them into an mkv container which worked perfectly fine. I was able to change the quality of the demo in its new container. So I assume the file is just not perfectly suitable with Plex or at least this Plex version. I don’t think we have to look into it any further.
Back to the actual topic: so, what’s different to to the 1.29.2. Plex version you provided? It looks like it has not been published as container image. Is this an internal version with specific settings or did someone simply break HDR transcoding in 1.30.x and the verison you provided is the last working version?
This thread once linked to the 1.29.2.6273 thread which seems to be the verison you linked here as well. Unfortunately, since October the same thread has been updated to 1.30.0.6359 which didn’t work for me in terms of HDR → SDR transcoding.
Last night, I tracked down a 1080p HW transcoding bug in 1.30.1 . It manifests as:
[h264 @ 0x7faee87bd100] No decoder surfaces left
Error while decoding stream #0:0: Invalid data found when processing input
[h264 @ 0x7faee87bd100] No decoder surfaces left
Error while decoding stream #0:0: Invalid data found when processing input
[h264 @ 0x7faee87bd100] reference picture missing during reorder
[h264 @ 0x7faee87bd100] Missing reference picture, default is 65598
[h264 @ 0x7faee87bd100] No decoder surfaces left
Error while decoding stream #0:0: Invalid data found when processing input
[h264 @ 0x7faee87bd100] reference picture missing during reorder
[h264 @ 0x7faee87bd100] Missing reference picture, default is 65598
[h264 @ 0x7faee87bd100] No decoder surfaces left
Error while decoding stream #0:0: Invalid data found when processing input
[h264 @ 0x7faee87bd100] No decoder surfaces left
Error while decoding stream #0:0: Invalid data found when processing input
[h264 @ 0x7faee87bd100] reference picture missing during reorder
[h264 @ 0x7faee87bd100] Missing reference picture, default is 65600
[h264 @ 0x7faee87bd100] reference picture missing during reorder
[h264 @ 0x7faee87bd100] Missing reference picture, default is 65600
[h264 @ 0x7faee87bd100] reference picture missing during reorder
[h264 @ 0x7faee87bd100] Missing reference picture, default is 65600
[h264 @ 0x7faee87bd100] reference picture missing during reorder
[h264 @ 0x7faee87bd100] Missing reference picture, default is 65600
Impossible to convert between the formats supported by the filter 'Parsed_scale_cuda_1' and the filter 'auto_scale_0'
Error reinitializing filters!
Failed to inject frame into filter network: Function not implemented
Error while processing the decoded data for stream #0:0
I thought I tested this verison back then without success. Had another look into it and it does seem to HW transcode HDR content as well. Makes it a little easier to use since the other version was overwritten everytime I had to restart the container.
Question is, if there’s any kind of ETA for >1.30.x releases to fix the HDR transcoding issue.
I isolated it Thurday (JAN 19) night. It’s not possible to expect an ETA this quickly
I do not know the problem you’re having. I will go revisit the whole process but AFAIK, it is still all working because the drivers which are downloaded into “Plex Media Server/Drivers” aren’t being reported as failing for everyone
@ChuckPa With a “fix ETA” I was talking about HEVC 2160p HDR content that requires HDR → SDR tonemapping since everything else seems to work fine for me.
Tonemapping was working until 1.28.0.5999-97678ded3, broke with 1.28.1.6041-xxx, started to work again with 1.29.0.6244-819d3678c (for some including me), announced to be fixed with 1.29.1.6241-xxx (beta) and stopped to work with 1.30.x.
Now the interesting part: I went back to the linuxserver.io container since it is easier to switch between versions. After testing out your linked .deb package and the official 1.29.2.6364-6d72b0cf6 container, I went back to my initially broken 1.30.1.6562 version and it now HW transcodes HDR content just fine…
I’m not really sure what to look for, but I can now see 2 newly created/recently modified directories in my Drivers directory within my mounted Plex config directory: icr-9-linux-x86_64 (created 19th Jan; probably from your .deb package version) and a icr-15-linux-x86_64 (created on 22nd Jan; probably from the 1.29.x container).
So, something must’ve been broken inbetween and I have no idea what and why. I know it was working with 1.29.0 eventhough others reported It wasn’t working for them and something must’ve happened inbetwen that it broke with 1.30.x for me as well and for whatever reason it fixed itself just by going back and forth between 1.29 and 1.30.