Adant 2 Posted December 22, 2021 Share Posted December 22, 2021 (edited) Hi Team - Long time emby user. I recently upgraded my media PC to a mini-pc with a Intel N5095 CPU and have had quite the journey getting HW transcoding to work. A little context: I've paid for and enabled emby premier The N5095 CPU does support Intel Quick sync and uses iHD drivers. This is a Jasper Lake Gen 11 CPU. I'm running openmediavault which lies on debian I'm running emby within docker however I have the same symptoms when running emby from Debian directly After finally figuring out how to get my video drivers working in linux (vainfo looks good, /dev/dri/ is populated), I see the hardware available within emby server's transcoding page. Everything is checked green. However when transcoding a video, it is still using software to do the transcoding. See the attached images. Anyone have any ideas what might be going on here? I'm losing my mind not being able to test HW transcoding - want to make sure this CPU can handle it (it should). What the dashboard displays: Emby server transcoding settings: Edit - when looking at the logs (attached) - I'm noticing this: 19:55:17.340 [h264_qsv @ 0x2245500] Current profile is unsupported 19:55:17.340 [h264_qsv @ 0x2245500] Selected ratecontrol mode is unsupported 19:55:17.340 [h264_qsv @ 0x2245500] Low power mode is unsupported 19:55:17.340 [h264_qsv @ 0x2245500] Current frame rate is unsupported 19:55:17.340 [h264_qsv @ 0x2245500] Current picture structure is unsupported 19:55:17.340 [h264_qsv @ 0x2245500] Current resolution is unsupported 19:55:17.340 [h264_qsv @ 0x2245500] Current pixel format is unsupported 19:55:17.340 [h264_qsv @ 0x2245500] some encoding parameters are not supported by the QSV runtime. Please double check the input parameters. Thanks! ffmpeg-transcode-73dfd4fb-e76b-4c9d-954b-4aeb2bbee015_1.txt Edited December 22, 2021 by Adant added log info Link to comment Share on other sites More sharing options...
Adant 2 Posted December 22, 2021 Author Share Posted December 22, 2021 Additional note... when I disable the encoder, it appears that decoding using quick sync does work. Something fishy going on. Link to comment Share on other sites More sharing options...
Adant 2 Posted December 23, 2021 Author Share Posted December 23, 2021 Few other items to add: running Debian 11 and OMV6 if it matters I've added enable_guc=2 via echo "options i915 enable_guc=2" > /etc/modprobe.d/i915.conf vainfo below: root@omv:~# 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 VAProfileVC1Simple : VAEntrypointVLD VAProfileVC1Main : VAEntrypointVLD VAProfileVC1Advanced : VAEntrypointVLD VAProfileJPEGBaseline : VAEntrypointVLD VAProfileJPEGBaseline : VAEntrypointEncPicture VAProfileH264ConstrainedBaseline: VAEntrypointVLD VAProfileH264ConstrainedBaseline: VAEntrypointEncSliceLP VAProfileVP8Version0_3 : VAEntrypointVLD VAProfileHEVCMain : VAEntrypointVLD VAProfileHEVCMain : VAEntrypointEncSliceLP VAProfileHEVCMain10 : VAEntrypointVLD VAProfileHEVCMain10 : VAEntrypointEncSliceLP VAProfileVP9Profile0 : VAEntrypointVLD VAProfileVP9Profile0 : VAEntrypointEncSliceLP VAProfileVP9Profile1 : VAEntrypointVLD VAProfileVP9Profile1 : VAEntrypointEncSliceLP VAProfileVP9Profile2 : VAEntrypointVLD VAProfileVP9Profile2 : VAEntrypointEncSliceLP VAProfileVP9Profile3 : VAEntrypointVLD VAProfileVP9Profile3 : VAEntrypointEncSliceLP VAProfileHEVCMain422_10 : VAEntrypointVLD VAProfileHEVCMain444 : VAEntrypointVLD VAProfileHEVCMain444 : VAEntrypointEncSliceLP VAProfileHEVCMain444_10 : VAEntrypointVLD VAProfileHEVCMain444_10 : VAEntrypointEncSliceLP Link to comment Share on other sites More sharing options...
Luke 36884 Posted December 23, 2021 Share Posted December 23, 2021 @softworkz will take a look at this. Thanks. Link to comment Share on other sites More sharing options...
Solution Adant 2 Posted December 23, 2021 Author Solution Share Posted December 23, 2021 @Luke @softworkz I think I just figured it out. It doesn't look like the ffmepg version in the current 4.6.7.0 doesn't have the latest updates to work with this. I just tried beta v4.7.0.19 and transcoding appears to work! However I welcome any other feedback on the above to confirm my findings and that my setup is right. Link to comment Share on other sites More sharing options...
Luke 36884 Posted December 23, 2021 Share Posted December 23, 2021 Thanks for the feedback. Link to comment Share on other sites More sharing options...
softworkz 3301 Posted December 23, 2021 Share Posted December 23, 2021 @Adant - QuickSync-out-of-the-box is only working in the beta branch. If you're running the release version, you have the following two choices: Use VAAPI codecs instead of QuickSync (recommended) Install QuickSync manually (might not be straight-forward, please see our KB) sw Link to comment Share on other sites More sharing options...
Q-Droid 609 Posted December 23, 2021 Share Posted December 23, 2021 9 hours ago, softworkz said: @Adant - QuickSync-out-of-the-box is only working in the beta branch. If you're running the release version, you have the following two choices: Use VAAPI codecs instead of QuickSync (recommended) Install QuickSync manually (might not be straight-forward, please see our KB) sw Wait, has something changed or is this for that specific new generation of iGPU and out-of-the-box will come eventually? I've been under the impression that Emby rolls in the current Intel graphics drivers, at least as current as the dev cycle allows. Link to comment Share on other sites More sharing options...
softworkz 3301 Posted December 24, 2021 Share Posted December 24, 2021 10 hours ago, Q-Droid said: Wait, has something changed or is this for that specific new generation of iGPU and out-of-the-box will come eventually? I've been under the impression that Emby rolls in the current Intel graphics drivers, at least as current as the dev cycle allows. That's just what I said: the betas are including Intel Graphics driver plus the MSDK (quicksync) Link to comment Share on other sites More sharing options...
softworkz 3301 Posted December 24, 2021 Share Posted December 24, 2021 (edited) 21 hours ago, Adant said: Few other items to add: running Debian 11 and OMV6 if it matters I've added enable_guc=2 via echo "options i915 enable_guc=2" > /etc/modprobe.d/i915.conf vainfo below: I forgot to mention: this is a bit tricky because Emby includes its own versions of the graphics driver and libva. When you want to make such tests, you need to run it in a way like Emby sees it. To get an idea how to do that, just take a look a the stubs in the bin folder of an Emby installation (e.g. ffmpeg-emby or emby-ffmpeg whichever exists) Edited December 24, 2021 by softworkz Link to comment Share on other sites More sharing options...
Adant 2 Posted January 3, 2022 Author Share Posted January 3, 2022 Thanks softworkz for the explanation. Apologies for the delay in response - busy and sick holidays. I thought I did configure quicksync manually correctly to work on the stable release of emby. In fact, quicksync did work properly on stable release for decoding, but failed when trying to encode. I did only install the drivers via the package manager instead of compiling it myself - not sure if that makes a difference. In looking through other forums/docs (plex and jellyfin), it sounds like these JasperLake chips are very picky on ffmpeg version and certain options set for the GPU. Regardless, the fact that it will be working in an upcoming release marks this as solved more or less. I've been running beta and it has been quite stable. A few other notes for folks in a similar boat as me. Getting these Jasper Lake CPUs set up properly in linux is a pain because they are new-ish. The linux kernel isn't as out-of-the-box ready for them. I listed the steps I needed to take below to get this working. I would say that the N5095 chip is a champ with transcoding. Albeit a celeron, it can handle transcoding very well including HDR tone mapping. Update repo sources to include non-free Install intel-media-va-non-free, vainfo See if dev/dri is there. If not: edit "/etc/default/grub" and adding: GRUB_CMDLINE_LINUX="... quiet i915.force_probe=4e55" The 4e55 I found by running: lspci Then update grub: update-grub Add 'options i915 force_probe=1 enable_guc=2' in /etc/modprobe.d/i915.conf 1 Link to comment Share on other sites More sharing options...
softworkz 3301 Posted January 3, 2022 Share Posted January 3, 2022 49 minutes ago, Adant said: Regardless, the fact that it will be working in an upcoming release marks this as solved more or less. I've been running beta and it has been quite stable. Thanks for the feedback. The beta ships most of the things that are required - but maybe not all? Which steps do you think would still be required for getting it to work with the beta? Link to comment Share on other sites More sharing options...
Adant 2 Posted January 3, 2022 Author Share Posted January 3, 2022 No problem! Assuming that the beta does include all the necessary drivers, just the below would be needed I think. Apparently the below is a workaround though for this CPU - it should be fixed in updated linux kernels at some point? I'm far from an expert in linux, but I could not get the drivers to show up unless I did the below. See if dev/dri is there. If not: edit "/etc/default/grub" and adding: GRUB_CMDLINE_LINUX="... quiet i915.force_probe=4e55" The 4e55 I found by running: lspci Then update grub: update-grub The enable_guc=2 - I'm not sure if this is needed. Similar to the above, this is getting fixed/updated in later linux OS's. It appears to just be specific to these newer CPUs. I found this from here: https://jellyfin.org/docs/general/administration/hardware-acceleration.html#tips-for-intel-gen9-and-gen11-when-using-vaapi-or-qsv-on-linux and also mentioned here: https://forums.plex.tv/t/can-jasper-lake-n6005-use-hardware-transcoding/758158/12 Hope this helps! 1 Link to comment Share on other sites More sharing options...
softworkz 3301 Posted January 3, 2022 Share Posted January 3, 2022 Great, thanks for sharing this information, I'm sure it will be helpful for other Emby users! Link to comment Share on other sites More sharing options...
softworkz 3301 Posted May 17, 2022 Share Posted May 17, 2022 @Adant and for all others who might arrive here: Jasper Lake should work under the following conditions: You have Linux Kernel 5.4 or later You have set the kernel parameter: i915.enable_guc=2 please see here: https://01.org/linuxgraphics/downloads/firmware Your distribution has the "right" firmware included (to date, Intel couldn't tell us what that means and how to determine) You are using Emby Server Beta or Emby Server 4.7.0 or later Tone Mapping Support Intel has confirmed that native tone mapping is not supported on Jasper and Elkhart Lake. We created an issue with them regarding the incorrect detection output (indicating that TM would be supported). What does work though is OpenCL based tone mapping, it just needs to be configured manually in Emby until it is fixed by Intel. Link to comment Share on other sites More sharing options...
wedgekc 12 Posted May 17, 2022 Share Posted May 17, 2022 I just setup a mini Jasper Lake box (N5095) with Ubuntu 22.04 for some traveling I'll be doing over the next month. For some reason, I needed to upgrade the kernel to 5.17.8 (The default kernel for Ubuntu 22.04 despite being newer than 5.4 didn't work) and added "options i915 enable_guc=2" to /etc/modprobe.d/i915.conf, update-initramfs -u and everything started to work on the latest emby beta docker. Link to comment Share on other sites More sharing options...
softworkz 3301 Posted May 17, 2022 Share Posted May 17, 2022 1 hour ago, wedgekc said: I just setup a mini Jasper Lake box (N5095) with Ubuntu 22.04 for some traveling I'll be doing over the next month. For some reason, I needed to upgrade the kernel to 5.17.8 (The default kernel for Ubuntu 22.04 despite being newer than 5.4 didn't work) and added "options i915 enable_guc=2" to /etc/modprobe.d/i915.conf, update-initramfs -u and everything started to work on the latest emby beta docker. I'm glad to hear that it's working for you. Thanks a lot for the feedback. Which kernel versions and which firmware versions will work and which won't - even Intel couldn't tell us (we have some channels). Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now