As the server my Jellyfin LXC is running on now has an iGPU, I wanted to see if I could use it to enable hardware acceleration for transcoding.
Map the video and render groups
- Proxmox root node
- Find the group ids for video and render
- cat /etc/group
- For me it was 44 and 104
- Allow the mapping of those 2 gids
- vi /etc/subgid
- Add
- root:44:1
- root:104:1
- Determine the name of the card and render device
- ls -al /dev/dri
- For example mine are
- /dev/dri/card1
- /dev/dri/renderD128
- Jellyfin container
- Note what its ID is. For my example I will use XXX
- Find the group ids for video and render
- cat /etc/group
- For me it was 44 and 104 as well
- Make sure jellyfin user is part of the video and render groups
- groups jellyfin
- Proxmox root node
- Map the group ids
- vi /etc/pve/lxc/XXX.conf
- Add the following:
lxc.idmap: u 0 100000 65536lxc.idmap: g 0 100000 44lxc.idmap: g 44 44 1lxc.idmap: g 45 100045 58lxc.idmap: g 104 104 1lxc.idmap: g 105 100105 65431
Device Passthrough
- Map the device
- Proxmox -> jellyfin -> Resources
- Add -> Device Passthrough
- Device: /dev/dri/card1
- Advanced: check
- gid: 44
- Click "Add"
- Add -> Device Passthrough
- Device: /dev/dri/renderD128
- Advanced: check
- gid: 104
- Click: "Add"
Finalize changes
- Restart the Jellyfin container
- Turn on hardware acceleration in the Jellyfin UI
- Dashboard -> Playback -> Transcoding
- Hardware Acceleration: "Intel Quicksync (QSV)"
Results
Unfortunately, my Haswell processor (Xeon E3-1275 v3) doesn't support Intel Quicksync (QSV) in Jellyfin. It does support Video Acceleration API (VAAPI), but the quality was horrible and doesn't completely remove the load from the processor. With this in mind, I just kept hardware acceleration to None and video transcoding disabled on the users.
Appendix
Sources
- https://www.reddit.com/r/Proxmox/comments/1bx2dbk/help_mounting_igpu_to_unprivileged_lxc/
- https://bookstack.swigg.net/books/linux/page/lxc-gpu-access
- https://mattedwards.org/2023/11/jellyfin-in-an-unprivileged-lxc-with-intel-quicksync/
- https://jellyfin.org/docs/general/post-install/transcoding/hardware-acceleration/intel#linux-setups
- https://www.reddit.com/r/Proxmox/comments/1j7g2hs/a_quick_guide_on_how_to_setup_igpu_passthrough/