Jellyfin: Difference between revisions
jellyfin-media-player was renamed to jellyfin-desktop and updated so it's no longer marked as insecure |
→NVENC: Add blurb on the Nvidia support matrix. |
||
| (5 intermediate revisions by 2 users not shown) | |||
| Line 24: | Line 24: | ||
If you would like to install the desktop application, use the following: | If you would like to install the desktop application, use the following: | ||
{{Warning|1=Currently in NixOS 25.11, jellyfin-desktop 2.0 on nixpkgs is unsupported (and no longer available on their [https://github.com/jellyfin/jellyfin-desktop/releases release page]) as it relies on an out-of-date QT engine. This can cause '''rapid, bright flashes''' when playing video on Wayland, which is a '''serious seizure risk''' (see [https://github.com/jellyfin/jellyfin-desktop/issues/127 this issue]). | |||
The easiest fixes are: | |||
* Use the web player. | |||
* Run from the CLI with: `QT_QPA_PLATFORM=xcb jellyfin-desktop > /dev/null 2>&1 & disown` | |||
* Create a launch script your app launcher can find [https://docs.vicinae.com/install/script as explained for vicinae here].}} | |||
{{code|lang=nix|line=no|1={ | {{code|lang=nix|line=no|1={ | ||
| Line 42: | Line 51: | ||
{{code|lang=nix|line=no|1={ | {{code|lang=nix|line=no|1={ | ||
services.jellyfin.enable = true; | services.jellyfin.enable = true; | ||
} | } | ||
}} | }} | ||
| Line 136: | Line 140: | ||
<!--T:18--> | <!--T:18--> | ||
Modern hardware often includes video acceleration capabilities that can significantly reduce CPU usage during transcoding. For detailed information, see the [https://jellyfin.org/docs/general/post-install/transcoding/hardware-acceleration/ official Jellyfin documentation].<ref name="jellyfin-hw">Jellyfin Documentation Team, "Hardware acceleration", Jellyfin Documentation, Accessed October 2025. https://jellyfin.org/docs/general/post-install/transcoding/hardware-acceleration/</ref> | Modern hardware often includes video acceleration capabilities that can significantly reduce CPU usage during transcoding. For detailed information, see the [https://jellyfin.org/docs/general/post-install/transcoding/hardware-acceleration/ official Jellyfin documentation].<ref name="jellyfin-hw">Jellyfin Documentation Team, "Hardware acceleration", Jellyfin Documentation, Accessed October 2025. https://jellyfin.org/docs/general/post-install/transcoding/hardware-acceleration/</ref> | ||
==== GPU Identification ==== | |||
If a computer with multiple GPUs is being configured, such as a laptop with a discrete GPU, selecting the correct GPU by path may be difficult. The paths in question are at <code>/dev/dri</code>. There will be several entries within this directory: | |||
* <code>/dev/dri/card*</code> | |||
: 2D graphics accelerators, these are not relevant to Jellyfin. | |||
* <code>/dev/dri/renderD*</code> | |||
: 3D graphics accelerators. These are what Jellyfin uses. Often <code>/dev/dri/renderD128</code> and sequentially increasing from there. | |||
* <code>/dev/dri/by-path</code> | |||
: A directory that contains symlinks to the above devices, but with their PCI bus IDs. This will be used for identification. | |||
To identify, run <code>lspci</code>. This will most likely need to be downloaded, and is included in the package [https://search.nixos.org/packages?channel=unstable&query=lspci#show=pciutils pciutils]. This will show all devices on the PCI bus. For example: | |||
{{code|lang=text|line=no| | |||
00:00.0 Host bridge: Intel Corporation Xeon E3-1200 v6/7th Gen Core Processor Host Bridge/DRAM Registers (rev 05) | |||
00:01.0 PCI bridge: Intel Corporation 6th-10th Gen Core Processor PCIe Controller (x16) (rev 05) | |||
00:02.0 VGA compatible controller: Intel Corporation Kaby Lake-H GT2 [HD Graphics 630] (rev 04) | |||
00:14.0 USB controller: Intel Corporation 100 Series/C230 Series Chipset Family USB 3.0 xHCI Controller (rev 31) | |||
00:14.2 Signal processing controller: Intel Corporation 100 Series/C230 Series Chipset Family Thermal Subsystem (rev 31) | |||
00:15.0 Signal processing controller: Intel Corporation 100 Series/C230 Series Chipset Family Serial IO I2C Controller #0 (rev 31) | |||
00:15.1 Signal processing controller: Intel Corporation 100 Series/C230 Series Chipset Family Serial IO I2C Controller #1 (rev 31) | |||
00:16.0 Communication controller: Intel Corporation 100 Series/C230 Series Chipset Family MEI Controller #1 (rev 31) | |||
00:17.0 SATA controller: Intel Corporation HM170/QM170 Chipset SATA Controller [AHCI Mode] (rev 31) | |||
00:1c.0 PCI bridge: Intel Corporation 100 Series/C230 Series Chipset Family PCI Express Root Port #3 (rev f1) | |||
00:1c.3 PCI bridge: Intel Corporation 100 Series/C230 Series Chipset Family PCI Express Root Port #4 (rev f1) | |||
00:1f.0 ISA bridge: Intel Corporation HM175 Chipset LPC/eSPI Controller (rev 31) | |||
00:1f.2 Memory controller: Intel Corporation 100 Series/C230 Series Chipset Family Power Management Controller (rev 31) | |||
00:1f.3 Audio device: Intel Corporation HM175/QM175/CM238 HD Audio Controller (rev 31) | |||
00:1f.4 SMBus: Intel Corporation 100 Series/C230 Series Chipset Family SMBus (rev 31) | |||
01:00.0 VGA compatible controller: NVIDIA Corporation GP106M [GeForce GTX 1060 Mobile] (rev a1) | |||
01:00.1 Audio device: NVIDIA Corporation GP106 High Definition Audio Controller (rev a1) | |||
02:00.0 Network controller: Qualcomm Atheros QCA6174 802.11ac Wireless Network Adapter (rev 32) | |||
03:00.0 Unassigned class [ff00]: Realtek Semiconductor Co., Ltd. RTL8411B PCI Express Card Reader (rev 01) | |||
03:00.1 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8111/8168/8211/8411 PCI Express Gigabit Ethernet Controller (rev 12) | |||
}} | |||
The beginning of each line denotes the device's PCI bus ID. Note this for the GPU desired, and add this device to your Jellyfin configuration via the <code>/dev/dri/by-path</code> directory. In this example, the Nvidia 1060M is added to the config. It can also be added to the config by inspecting the <code>by-path</code> symlink with <code>realpath</code> and using the canonical path. | |||
{{code|1={ | |||
services.jellyfin = { | |||
enable = true; | |||
hardwareAcceleration = { | |||
enable = true; | |||
type = "nvenc"; | |||
device = "/dev/dri/by-path/pci-0000:01:00.0-render"; | |||
}; | |||
}|lang=nix}} | |||
==== NVENC ==== | |||
Nvidia GPU's use NVENC for hardware encoding. To use this, CUDA must be enabled: | |||
{{Code|1={ | |||
nix.settings = { | |||
substituters = [ | |||
"https://cache.flox.dev" | |||
]; | |||
trusted-public-keys = [ | |||
"flox-cache-public-1:7F4OyH7ZCnFhcze3fJdfyXYLQw/aV7GEed86nQ7IsOs=" | |||
]; | |||
}; | |||
nixpkgs.config.cudaSupport = true; | |||
services.jellyfin = { | |||
enable = true; | |||
hardwareAcceleration = { | |||
enable = true; | |||
type = "nvenc"; | |||
device = "/dev/dri/renderD128"; | |||
}; | |||
}; | |||
}|lang=nix}}For configuring the <code>services.jellyfin.transcoding.hardwareDecodingCodec</code> and <code>services.jellyfin.transcoding.hardwareDecodingCodec</code> options for Nvidia GPUs, [https://developer.nvidia.com/video-encode-decode-support-matrix consult the support matrix provided by Nvidia] | |||
==== VAAPI and Intel QSV ==== <!--T:19--> | ==== VAAPI and Intel QSV ==== <!--T:19--> | ||