this post was submitted on 15 Oct 2023
35 points (100.0% liked)

Piracy: ꜱᴀɪʟ ᴛʜᴇ ʜɪɢʜ ꜱᴇᴀꜱ

54577 readers
697 users here now

⚓ Dedicated to the discussion of digital piracy, including ethical problems and legal advancements.

Rules • Full Version

1. Posts must be related to the discussion of digital piracy

2. Don't request invites, trade, sell, or self-promote

3. Don't request or link to specific pirated titles, including DMs

4. Don't submit low-quality posts, be entitled, or harass others



Loot, Pillage, & Plunder

📜 c/Piracy Wiki (Community Edition):


💰 Please help cover server costs.

Ko-Fi Liberapay
Ko-fi Liberapay

founded 1 year ago
MODERATORS
 

Edit: For those who stumble across this with the same issue, I eventually got it working by adding “default-runtime”: “nvidia”, to /etc/docker/daemon.json then restarting the docker service and Jellyfin container.

I am in the process of setting up a new media server on an old PC using Ubuntu Server and CasaOS and have run into my first major roadblock.

To give some background, I formerly had my media server running on my main gaming PC on Windows using Plex and the *arr suite. I’m now trying to do things the right way and set everything back up from scratch on some spare hardware with Jellyfin and all the rest in dockerized containers. I chose CasaOS because I’m not overly familiar with Linux and thought that would be a good way to ease into things.

Everything was going well until I tried to get hardware acceleration enabled in Jellyfin. For the life of me I cannot seem to get the Nvidia drivers properly installed, much less give Jellyfin access to the device. I’m using a GTX 960.

I’m not sure exactly what additional info I need to give here, but here’s something I hope helps:

*****@home-server:/$ nvidia-smi
NVIDIA-SMI has failed because it couldn't communicate with the NVIDIA driver. Make sure that the latest NVIDIA driver is installed and running.
*****@home-server:/$ nvcc --version
nvcc: NVIDIA (R) Cuda compiler driver
Copyright (c) 2005-2021 NVIDIA Corporation
Built on Thu_Nov_18_09:45:30_PST_2021
Cuda compilation tools, release 11.5, V11.5.119
Build cuda_11.5.r11.5/compiler.30672275_0
*****@home-server:/$ ls /usr/src | grep nvidia
nvidia-srv-535.104.12
*****@home-server:/$ sudo dkms install -m nvidia -v srv-535.104.12
Error! Could not locate dkms.conf file.
File: /usr/src/nvidia-srv-535.104.12/dkms.conf does not exist.

If there’s anything important I’m leaving out - and I probably am - let me know. Also if there’s anywhere else you recommend I post this let me know that as well.

top 6 comments
sorted by: hot top controversial new old
[–] [email protected] 5 points 1 year ago (1 children)

You don't need to run dkms commands on your own.

If you're just running a simple media server, you don't need the bleeding edge Nvidia driver. Just install the packages that come with Ubuntu. If you're not used to Linux in general, here are the easiest steps to do so: https://phoenixnap.com/kb/install-nvidia-drivers-ubuntu

[–] [email protected] 2 points 1 year ago (1 children)

Thank you! After doing it this way I was finally able to get an output from nvidia-smi. Now would you happen to know how to give my Jellyfin Docker container access to the device for hardware acceleration?

[–] [email protected] 6 points 1 year ago (1 children)
[–] [email protected] 1 points 1 year ago* (last edited 1 year ago) (1 children)

Well I decided to use CasaOS because I thought it would make things easier, but here it seems to complicate things. As far as I can tell CasaOS provides no way to manually change the docker-compose file (it is all done through the web UI) so I'm unsure how to do step 3 in the docs above.

Seems these are the relevant options: --runtime=nvidia \ --gpus all \

Anyone have an idea of how I can enable these options for my Jellyfin Docker container in CasaOS? I do see an option to add "container commands" but not sure what I would need to enter there if that is the correct place.

[–] [email protected] 1 points 1 year ago

I'd start googling or looking through their forums. Somebody else has surely solved this for you.

[–] [email protected] 1 points 1 year ago

Be careful with your solution. Ever other container you launch will attempt to access the Nvidia runtime, which gives access to the GPU. This may have unintended consequences, versus just running individual containers with Nvidia runtime set, and gpus=all set.