Hardware Transcoding Problems: Jasper Lake (N5105) + Docker + OMV 6 (Debian 11)

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

I’ve read through everything I could find on the topic, but can’t seem to make hw transcoding work. Please advise what it is that I’m doing wrong. As far as I understand, here’s what I should’ve done.

Passing /dev/dri to the container - :white_check_mark:
Adding options i915 enable_guc=2 to i915.conf - :white_check_mark:
Praying - :white_check_mark:

Attaching logs:
Plex Media Server Logs_2022-10-30_15-57-21.zip (616.6 KB)

vainfo:

error: XDG_RUNTIME_DIR not set in the environment.
error: can't connect to X server!
libva info: VA-API version 1.10.0
libva info: Trying to open /usr/lib/x86_64-linux-gnu/dri/iHD_drv_video.so
libva info: Found init function __vaDriverInit_1_10
libva info: va_openDriver() returns 0
vainfo: VA-API version: 1.10 (libva 2.10.0)
vainfo: Driver version: Intel iHD driver for Intel(R) Gen Graphics - 21.1.1 ()
vainfo: Supported profile and entrypoints
      VAProfileNone                   :	VAEntrypointVideoProc
      VAProfileNone                   :	VAEntrypointStats
      VAProfileMPEG2Simple            :	VAEntrypointVLD
      VAProfileMPEG2Main              :	VAEntrypointVLD
      VAProfileH264Main               :	VAEntrypointVLD
      VAProfileH264Main               :	VAEntrypointEncSliceLP
      VAProfileH264High               :	VAEntrypointVLD
      VAProfileH264High               :	VAEntrypointEncSliceLP
      VAProfileJPEGBaseline           :	VAEntrypointVLD
      VAProfileJPEGBaseline           :	VAEntrypointEncPicture
      VAProfileH264ConstrainedBaseline:	VAEntrypointVLD
      VAProfileH264ConstrainedBaseline:	VAEntrypointEncSliceLP
      VAProfileVP8Version0_3          :	VAEntrypointVLD
      VAProfileHEVCMain               :	VAEntrypointVLD
      VAProfileHEVCMain               :	VAEntrypointEncSliceLP
      VAProfileHEVCMain10             :	VAEntrypointVLD
      VAProfileHEVCMain10             :	VAEntrypointEncSliceLP
      VAProfileVP9Profile0            :	VAEntrypointVLD
      VAProfileVP9Profile1            :	VAEntrypointVLD
      VAProfileVP9Profile2            :	VAEntrypointVLD
      VAProfileVP9Profile3            :	VAEntrypointVLD
      VAProfileHEVCMain422_10         :	VAEntrypointVLD
      VAProfileHEVCMain444            :	VAEntrypointVLD
      VAProfileHEVCMain444            :	VAEntrypointEncSliceLP
      VAProfileHEVCMain444_10         :	VAEntrypointVLD
      VAProfileHEVCMain444_10         :	VAEntrypointEncSliceLP

Controller info:

VGA compatible controller: Intel Corporation Device 4e61 (rev 01) (prog-if 00 [VGA controller])
	DeviceName: Intel(R) UHD Graphics Device
	Subsystem: Intel Corporation Device 3027
	Flags: bus master, fast devsel, latency 0, IRQ 139, IOMMU group 1
	Memory at 6000000000 (64-bit, non-prefetchable) [size=16M]
	Memory at 4000000000 (64-bit, prefetchable) [size=256M]
	I/O ports at 4000 [size=64]
	Expansion ROM at 000c0000 [virtual] [disabled] [size=128K]
	Capabilities: [40] Vendor Specific Information: Len=0c <?>
	Capabilities: [70] Express Root Complex Integrated Endpoint, MSI 00
	Capabilities: [ac] MSI: Enable+ Count=1/1 Maskable+ 64bit-
	Capabilities: [d0] Power Management version 2
	Capabilities: [100] Process Address Space ID (PASID)
	Capabilities: [200] Address Translation Service (ATS)
	Capabilities: [300] Page Request Interface (PRI)
	Kernel driver in use: i915
	Kernel modules: i915

This from your logs is very similar to something I was seeing in my own when it wasn’t working:

Oct 30, 2022 15:56:59.526 [0x7f4c618e0b38] DEBUG - [Req#245/Transcode] [FFMPEG] - Direct mapping possible.
Oct 30, 2022 15:56:59.526 [0x7f4c618e0b38] DEBUG - [Req#245/Transcode] [FFMPEG] - Driver supports RC modes CQP.
Oct 30, 2022 15:56:59.526 [0x7f4c618e0b38] DEBUG - [Req#245/Transcode] [FFMPEG] - Driver does not support ICQ RC mode.
...
Oct 30, 2022 15:56:59.963 [0x7f4c59e93b38] ERROR - [Req#2b8/Transcode/BACF6755-7FC9-45DE-BB2E-1A6C8AE353CB/cd2277d9-5131-4c24-b9f1-3560b0d12c61] Error initializing output stream 0:0 -- Error while opening encoder for output stream #0:0 - maybe incorrect parameters such as bit_rate, rate, width or height

That last bit is the Plex Transcoder process failing after being unable to initialize the encoder.

Can you run the following on your system and provide the output?

sudo dmesg | grep i915

1 Like

If I may add?

1.29.1 had that problem with certain N5xxx CPUs.

It was corrected for Forum Preview 1.29.2

1 Like
[    4.304048] i915 0000:00:02.0: [drm] VT-d active for gfx access
[    4.304058] fb0: switching to i915 from EFI VGA
[    4.313480] i915 0000:00:02.0: vgaarb: deactivate vga console
[    4.313797] i915 0000:00:02.0: [drm] Transparent Hugepage mode 'huge=within_size'
[    4.329378] i915 0000:00:02.0: vgaarb: changed VGA decodes: olddecodes=io+mem,decodes=io+mem:owns=io+mem
[    4.330157] i915 0000:00:02.0: firmware: direct-loading firmware i915/icl_dmc_ver1_09.bin
[    4.330610] i915 0000:00:02.0: [drm] Finished loading DMC firmware i915/icl_dmc_ver1_09.bin (v1.9)
[    4.332504] i915 0000:00:02.0: firmware: failed to load i915/ehl_guc_62.0.0.bin (-2)
[    4.332511] i915 0000:00:02.0: Direct firmware load for i915/ehl_guc_62.0.0.bin failed with error -2
[    4.332513] i915 0000:00:02.0: [drm] GuC firmware i915/ehl_guc_62.0.0.bin: fetch failed with error -2
[    4.332515] i915 0000:00:02.0: [drm] GuC firmware(s) can be downloaded from https://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git/tree/i915
[    4.480851] i915 0000:00:02.0: [drm] GuC is uninitialized
[    4.483414] [drm] Initialized i915 1.6.0 20201103 for 0000:00:02.0 on minor 0
[    4.527053] fbcon: i915drmfb (fb0) is primary device
[    4.577353] i915 0000:00:02.0: [drm] fb0: i915drmfb frame buffer device
[    4.752510] snd_hda_intel 0000:00:1f.3: bound 0000:00:02.0 (ops i915_audio_component_bind_ops [i915])
[    4.969084] mei_hdcp 0000:00:16.0-b638ab7e-94e2-4ea2-a552-d1c54b627f04: bound 0000:00:02.0 (ops i915_hdcp_component_ops [i915])

You’re getting the i915 but not the QSV ASIC.

This is from ESXi, passing through the UHD 630 (QSV ASIC).

You want something equivalent to this in OMV (?) then again into the container’s namespace.

This is an issue I was experiencing as well. Enabling the GuC does nothing if it cannot load the firmware. Head to the site it references and download ehl_guc_62.0.0.bin. Place it in /lib/firmware/i915/ and reboot. If hardware accelerated transcoding still fails, report the same output from dmesg and server logs again so we can see if the firmware was found.

(Here’s a direct link to the file, if you want to use that.)

1 Like

OMG finally! It works!

Thanks a lot!

No problem, glad you got it working!

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