2024-03-21, 06:16 AM
(This post was last modified: 2024-03-21, 06:18 AM by Zinic. Edited 1 time in total.)
After the third day of troubleshooting, I kneel before any who can help me!
Hardware Acceleration transcoding does not work for QSV and VAAPI. I've tried every solution online for the specific error I'm getting and nothing works. The solution for other people boiled down to a permissions issue. Specifically, this is my error:
Info on my setup:
Intel Core i5-12400 (Alder Lake)
64 GB RAM
Running on TrueNAS-SCALE-23.10.2
Community App 10.8.13.1 (up to date) (uses docker)
What I have tried:
In app settings, I added host path to /dev/dri because I could not see it in jellyfin's shell. The mount path was set to /dev/dri
In app settings, I added environmental "device" with value "/dev/dridev/dri"
I've tried VAApi too and get the "No VA display found for device /dev/dri/renderD128." ffmpeg error
Why am I still having an issue with this FFmpeg error if I've given it permissions and a path to renderD128?
Hardware Acceleration transcoding does not work for QSV and VAAPI. I've tried every solution online for the specific error I'm getting and nothing works. The solution for other people boiled down to a permissions issue. Specifically, this is my error:
Code:
/usr/lib/jellyfin-ffmpeg/ffmpeg -analyzeduration 200M -init_hw_device vaapi=va:,kernel_driver=i915,driver=iHD -init_hw_device qsv=qs@va -filter_hw_device qs -hwaccel vaapi -hwaccel_output_format vaapi -autorotate 0 -i file:"/Movies/4k UHD/Ralph Breaks The Internet (2018) {imbd-tt5848272} [UHD].mkv" -autoscale 0 -map_metadata -1 -map_chapters -1 -threads 0 -map 0:0 -map 0:1 -map -0:s -codec:v:0 h264_qsv -preset 7 -look_ahead 0 -b:v 59616000 -maxrate 59616000 -bufsize 119232000 -g:v:0 72 -keyint_min:v:0 72 -vf "setparams=color_primaries=bt709:color_trc=bt709:colorspace=bt709,scale_vaapi=format=nv12:extra_hw_frames=24,hwmap=derive_device=qsv,format=qsv" -codec:a:0 libfdk_aac -ac 2 -ab 384000 -af "volume=2" -copyts -avoid_negative_ts disabled -max_muxing_queue_size 2048 -f hls -max_delay 5000000 -hls_time 3 -hls_segment_type mpegts -start_number 0 -hls_segment_filename "/config/transcodes/ae334f858828729cdeb54348e71e7345%d.ts" -hls_playlist_type vod -hls_list_size 0 -y "/config/transcodes/ae334f858828729cdeb54348e71e7345.m3u8"
ffmpeg version 5.1.4-Jellyfin Copyright (c) 2000-2023 the FFmpeg developers
built with gcc 10 (Debian 10.2.1-6)
configuration: --prefix=/usr/lib/jellyfin-ffmpeg --target-os=linux --extra-libs=-lfftw3f --extra-version=Jellyfin --disable-doc --disable-ffplay --disable-ptx-compression --disable-static --disable-libxcb --disable-sdl2 --disable-xlib --enable-lto --enable-gpl --enable-version3 --enable-shared --enable-gmp --enable-gnutls --enable-chromaprint --enable-libdrm --enable-libass --enable-libfreetype --enable-libfribidi --enable-libfontconfig --enable-libbluray --enable-libmp3lame --enable-libopus --enable-libtheora --enable-libvorbis --enable-libopenmpt --enable-libdav1d --enable-libwebp --enable-libvpx --enable-libx264 --enable-libx265 --enable-libzvbi --enable-libzimg --enable-libfdk-aac --arch=amd64 --enable-libsvtav1 --enable-libshaderc --enable-libplacebo --enable-vulkan --enable-opencl --enable-vaapi --enable-amf --enable-libmfx --enable-ffnvcodec --enable-cuda --enable-cuda-llvm --enable-cuvid --enable-nvdec --enable-nvenc
libavutil 57. 28.100 / 57. 28.100
libavcodec 59. 37.100 / 59. 37.100
libavformat 59. 27.100 / 59. 27.100
libavdevice 59. 7.100 / 59. 7.100
libavfilter 8. 44.100 / 8. 44.100
libswscale 6. 7.100 / 6. 7.100
libswresample 4. 7.100 / 4. 7.100
libpostproc 56. 6.100 / 56. 6.100
[AVHWDeviceContext @ 0x55dd6429ad00] No VA display found for any default device.
Device creation failed: -22.
Failed to set value 'vaapi=va:,kernel_driver=i915,driver=iHD' for option 'init_hw_device': Invalid argument
Error parsing global options: Invalid argument
Info on my setup:
Intel Core i5-12400 (Alder Lake)
64 GB RAM
Running on TrueNAS-SCALE-23.10.2
Community App 10.8.13.1 (up to date) (uses docker)
Code:
admin@truenas[~]$ lspci -nn | grep -Ei "3d|display|vga"
00:02.0 VGA compatible controller [0300]: Intel Corporation Alder Lake-S GT1 [UHD Graphics 730] [8086:4692] (rev 0c)
admin@truenas[~]$ ls -lh /dev/dri
total 0
drwxr-xr-x 2 root root 80 Mar 20 21:57 by-path
crw-rw-rw- 1 root video 226, 0 Mar 20 21:57 card0
crw-rw-rw- 1 root render 226, 128 Mar 20 21:57 renderD128 <---- Note other group has rw permissions
admin@truenas[~]$ getent group render
render:x:107:apps
What I have tried:
Code:
sudo usermod -aG render jellyfin <---- Based on suggestions but jellyfin user is not found
sudo usermod -aG render apps <---- I try apps since jellyfin is part of the apps user/group.
sudo usermod -aG video apps
sudo chmod 666 /dev/dri/card0
sudo chmod 666 /dev/dri/renderD128
In app settings, I added environmental "device" with value "/dev/dridev/dri"
I've tried VAApi too and get the "No VA display found for device /dev/dri/renderD128." ffmpeg error
Why am I still having an issue with this FFmpeg error if I've given it permissions and a path to renderD128?