Unraid + Nvidia GPU HW transcoding issue

Been having a transcoding issue for several weeks now too. Plex stopped using my nvidia card and only uses my CPU. I found this thread that seems to suggest the recent versions are the culprit somehow. I’m running Version 1.32.4.7195 (logs attached) on unRaid. I also use Folding at Home and it utilizes my GPU just fine, so I have to assume it is the Plex app that isn’t recognizing my GPU anymore.

ChuckPa, you mentioned a fix in an upcoming release, any idea which release that will be?

Plex Media Server Logs_2023-07-03_10-31-40.zip (6.3 MB)

@lonewolf147

The ‘fixes’ I’ve been mentioning around the forum are for the GeminiLake CPUs.
ApolloLake is now fixed.

I’m trying to figure out what’s happening with Unraid kernel version 6.x
(it breaks something… it might be as simple as the driver blacklist from kernel 5.x is out of date in kernel 6.x)

On your machine, you have an i7-9700. There’s nothing ‘special’ about this machine. It’s a CoffeeLake and requires nothing more than not being ‘grabbed’ by Unraid itself (which it loves to do)

The QSV capability which you can use should be listed in the transcoder HW selector. On our test machine, I see QSV, AMD, and Nvidia. (the selector presents everything found)

Nvidia drivers which I’m using are:
NVIDIA-SMI 525.125.06 Driver Version: 525.125.06 CUDA Version: 12.0

When you open the unraid terminal window and invoke nvidia-smi, do you see what I see here? :point_up_2:

Gotcha, I wasn’t really sure what you were all talking about with the *lake names.
Here is my nvidia-smi (you can see the Folding At Home process is running)

I’m sorry, where is this selector located? I don’t see any kind of dropdown selector in Plex.

  1. The selector is in Settings - Server - Transcoder - Show Advanced.

  2. Regarding your Nvidia drivers version, I am always VERY skeptical of increases.
    You’re running CUDA 12.2 while I have 12.0 (which is known to work – Ubuntu vetted)

[chuck@glockner movies.2005]$ nvidia-smi
Tue Jul  4 01:19:35 2023       
+-----------------------------------------------------------------------------+
| NVIDIA-SMI 525.125.06   Driver Version: 525.125.06   CUDA Version: 12.0     |
|-------------------------------+----------------------+----------------------+
| GPU  Name        Persistence-M| Bus-Id        Disp.A | Volatile Uncorr. ECC |
| Fan  Temp  Perf  Pwr:Usage/Cap|         Memory-Usage | GPU-Util  Compute M. |
|                               |                      |               MIG M. |
|===============================+======================+======================|
|   0  Quadro P2200        On   | 00000000:07:00.0 Off |                  N/A |
| 48%   43C    P0    49W /  75W |    626MiB /  5120MiB |     28%      Default |
|                               |                      |                  N/A |
+-------------------------------+----------------------+----------------------+
                                                                               
+-----------------------------------------------------------------------------+
| Processes:                                                                  |
|  GPU   GI   CI        PID   Type   Process name                  GPU Memory |
|        ID   ID                                                   Usage      |
|=============================================================================|
|    0   N/A  N/A   2176871      C   ...diaserver/Plex Transcoder      622MiB |
+-----------------------------------------------------------------------------+
[chuck@glockner movies.2005]$

I’ve moved this out of the Synology thread to its own.

PMS on Synology does not use an Nvidia GPU.

@lonewolf147

We’re over here now.

1 Like

Ok, I’ll give downgrading my drivers a shot and see what happens.
In Plex, I don’t have that dropdown option under transcoder settings

One other question, before I change drivers, the version you are running isn’t listed as an option for me to download. Do you know where I can find a list of the versions and their CUDA version so I can be sure to get a 12.0?

I would use 525.105.17 That’s also known to work (I’ve previously used it)

@lonewolf147

I figured it out (I must be getting old and forgot)

  1. Default LXC mapping is “file system”
  2. It says ‘devices’ but they are bind volume mounts.

My PMS runs native on the host without issue

I installed PMS in the LXC (NO DRIVERS – they are already on the host)

Selected Nvidia GPU

Jul 04, 2023 17:44:15.197 [140051752450872] DEBUG - [GPU] Got device: GP106GL [Quadro P2200], nvidia@unknown, default true, best true, ID 10de:1c31:10de:131b@0000:07:00.0, DevID [10de:1c31:10de:131b], flags 0xe8

NO HW transcoding

Screenshot from 2023-07-04 14-09-54

In the Ubuntu VM – perfect device pass through.
(device versus file system – that’s the key)

Sorry for forgetting the distinction here.

I rolled back the nvidia driver to that version, rebooted and tried again. Still no luck, the GPU isn’t being used by Plex. Transcoding is being done with the CPU.

Sorry, but this confused me. I don’t know what LXC mapping is or bind volumes.
My PMS is not running on a VM. I have it installed on its own set of pool drives though, so as to have plenty of room and not compete with other dockers in the appdata directory.

But I’ve had PMS installed like this for over a year and it’s only been in the past month or two that this problem started.

Here are my latest log files.
Plex Media Server Logs_2023-07-05_05-09-49.zip (6.5 MB)

Hello, just to add to this discussion. I am also dealing with the same issue as lonewolf147. To be clear, I believe we are both have PMS installed as a container on Unraid.
I did revert the NVIDIA driver back to v470.182.03 and the hardware transcoding is now working. The only issue now is that I don’t have the ability to change the quality of the video during transcoding, it automatically goes to SD quality.
Any help would be appreciated.

And now it doesn’t work anymore again after restarting the container. I am able to choose the video conversion quality but the video doesn’t start and the GPU is not used. See attached the logs download.
Plex Media Server Logs_2023-07-07_11-09-40.zip (3.9 MB)

Hey everyone, came here to say that I am having seemingly exact same issue. I use the binhex-plex docker on unraid 6.12.3 and PLEX seemingly refuses to use my GPU now.

image

my PMS logs say this:

Jul 16, 2023 17:43:39.708 [23019775531832] ERROR - [Req#bc/Transcode] [FFMPEG] - Cannot load libcuda.so.1
Jul 16, 2023 17:43:39.708 [23019775531832] ERROR - [Req#bc/Transcode] [FFMPEG] - Could not dynamically load CUDA
Jul 16, 2023 17:43:39.712 [23019775531832] ERROR - [Req#bc/Transcode] [FFMPEG] - Cannot load libcuda.so.1
Jul 16, 2023 17:43:39.712 [23019775531832] ERROR - [Req#bc/Transcode] [FFMPEG] - Could not dynamically load CUDA
Jul 16, 2023 17:43:39.713 [23019775531832] ERROR - [Req#bc/Transcode] [FFMPEG] - Cannot load libcuda.so.1
Jul 16, 2023 17:43:39.713 [23019775531832] ERROR - [Req#bc/Transcode] [FFMPEG] - Could not dynamically load CUDA
Jul 16, 2023 17:43:39.717 [23019775531832] ERROR - [Req#bc/Transcode] [FFMPEG] - Cannot load libcuda.so.1
Jul 16, 2023 17:43:39.717 [23019775531832] ERROR - [Req#bc/Transcode] [FFMPEG] - Could not dynamically load CUDA
Jul 16, 2023 17:43:39.718 [23019775531832] ERROR - [Req#bc/Transcode] [FFMPEG] - Cannot load libcuda.so.1
Jul 16, 2023 17:43:39.718 [23019775531832] ERROR - [Req#bc/Transcode] [FFMPEG] - Could not dynamically load CUDA
Jul 16, 2023 17:43:39.721 [23019775531832] ERROR - [Req#bc/Transcode] [FFMPEG] - Cannot load libcuda.so.1
Jul 16, 2023 17:43:39.721 [23019775531832] ERROR - [Req#bc/Transcode] [FFMPEG] - Could not dynamically load CUDA
Jul 16, 2023 17:43:39.723 [23019775531832] ERROR - [Req#bc/Transcode] [FFMPEG] - Cannot load libcuda.so.1
Jul 16, 2023 17:43:39.723 [23019775531832] ERROR - [Req#bc/Transcode] [FFMPEG] - Could not dynamically load CUDA
Jul 16, 2023 17:43:39.726 [23019775531832] ERROR - [Req#bc/Transcode] [FFMPEG] - Cannot load libcuda.so.1
Jul 16, 2023 17:43:39.726 [23019775531832] ERROR - [Req#bc/Transcode] [FFMPEG] - Could not dynamically load CUDA
Jul 16, 2023 17:43:40.008 [23019786246968] INFO - [Req#7a/Transcode] CodecManager: starting EAE at “/config/transcode/pms-1cf0c95b-7da9-4839-a70e-aa83e6c2cdc5/EasyAudioEncoder”

Ich777 helped me up in the unraid forum. I have no idea what happened, but I had to set this all up again:

@ChuckPa - do you have anymore insight on our issues here?

Ubuntu 22.04.2 and updates installed 535.54.03 over 525 recently. Issues occurring as well.

Curious if there’s a fix inbound on Plex or if this is totally tossed to hope nVidia does something or not?

EDIT - reverted to 525 (installed 525.125.06) and issue still occurs for me where resume functionality doesn’t work. I see that the transcoder is now running on the GPU though so I guess one bug fixed but the inability for resume to work exists still.

Well, isn’t this fun?

:see_no_evil: :gun:

LOL

I upgraded to 535.54.03 without issue.

  • Installed the 535 server driver (not desktop driver)
  • removed ALL “525” driver packages (important)
  • Rebuild initramfs
  • Reboot was required to reload all modules properly
[chuck@lizum ~.1999]$ gog nvidia-smi
Thu Jul 20 12:42:27 2023       
+---------------------------------------------------------------------------------------+
| NVIDIA-SMI 535.54.03              Driver Version: 535.54.03    CUDA Version: 12.2     |
|-----------------------------------------+----------------------+----------------------+
| GPU  Name                 Persistence-M | Bus-Id        Disp.A | Volatile Uncorr. ECC |
| Fan  Temp   Perf          Pwr:Usage/Cap |         Memory-Usage | GPU-Util  Compute M. |
|                                         |                      |               MIG M. |
|=========================================+======================+======================|
|   0  Quadro P2200                   On  | 00000000:07:00.0 Off |                  N/A |
| 49%   41C    P0              21W /  75W |    242MiB /  5120MiB |      2%      Default |
|                                         |                      |                  N/A |
+-----------------------------------------+----------------------+----------------------+
                                                                                         
+---------------------------------------------------------------------------------------+
| Processes:                                                                            |
|  GPU   GI   CI        PID   Type   Process name                            GPU Memory |
|        ID   ID                                                             Usage      |
|=======================================================================================|
|    0   N/A  N/A    392198      C   ...lib/plexmediaserver/Plex Transcoder      238MiB |
+---------------------------------------------------------------------------------------+
[chuck@lizum ~.1999]$

From reading reports, some of the ‘535 variants’ were indeed problematic.

I am still using a nice “old” 5.4, 5.15, and 5.19 kernel.

In the context of “Video playback on Linux”

Unraid 6.9.0beta35

BETA bothers me very much.

Trying to run a production environment on an unproven OS foundation?
Are you mad?
Are you trying to emulate me?

:rofl:

Where do you find the Server driver instead of the Desktop driver? I don’t see anything in the settings to indicate a difference between them.

You might not have any choice. Unraid is in control.

On Ubuntu server, the packages are distinct

[chuck@glockner ~.2001]$ dpkg -l | grep nvidia
ii  gpustat                               0.6.0-1                                 all          pretty nvidia device monitor
ii  libnvidia-cfg1-535-server:amd64       535.54.03-0ubuntu0.22.04.1              amd64        NVIDIA binary OpenGL/GLX configuration library
ii  libnvidia-common-535-server           535.54.03-0ubuntu0.22.04.1              all          Shared files used by the NVIDIA libraries
ii  libnvidia-compute-535-server:amd64    535.54.03-0ubuntu0.22.04.1              amd64        NVIDIA libcompute package
ii  libnvidia-decode-535-server:amd64     535.54.03-0ubuntu0.22.04.1              amd64        NVIDIA Video Decoding runtime libraries
ii  libnvidia-egl-wayland1:amd64          1:1.1.9-1.1                             amd64        Wayland EGL External Platform library -- shared library
ii  libnvidia-encode-535-server:amd64     535.54.03-0ubuntu0.22.04.1              amd64        NVENC Video Encoding runtime library
ii  libnvidia-extra-535-server:amd64      535.54.03-0ubuntu0.22.04.1              amd64        Extra libraries for the NVIDIA Server Driver
ii  libnvidia-fbc1-535-server:amd64       535.54.03-0ubuntu0.22.04.1              amd64        NVIDIA OpenGL-based Framebuffer Capture runtime library
ii  libnvidia-gl-535-server:amd64         535.54.03-0ubuntu0.22.04.1              amd64        NVIDIA OpenGL/GLX/EGL/GLES GLVND libraries and Vulkan ICD
ii  libnvidia-ml-dev:amd64                11.5.50~11.5.1-1ubuntu1                 amd64        NVIDIA Management Library (NVML) development files
ii  nvidia-compute-utils-535-server       535.54.03-0ubuntu0.22.04.1              amd64        NVIDIA compute utilities
ii  nvidia-cuda-dev:amd64                 11.5.1-1ubuntu1                         amd64        NVIDIA CUDA development files
ii  nvidia-cuda-gdb                       11.5.114~11.5.1-1ubuntu1                amd64        NVIDIA CUDA Debugger (GDB)
ii  nvidia-cuda-toolkit                   11.5.1-1ubuntu1                         amd64        NVIDIA CUDA development toolkit
ii  nvidia-cuda-toolkit-doc               11.5.1-1ubuntu1                         all          NVIDIA CUDA and OpenCL documentation
ii  nvidia-dkms-535-server                535.54.03-0ubuntu0.22.04.1              amd64        NVIDIA DKMS package
ii  nvidia-driver-535-server              535.54.03-0ubuntu0.22.04.1              amd64        NVIDIA Server Driver metapackage
ii  nvidia-firmware-535-server-535.54.03  535.54.03-0ubuntu0.22.04.1              amd64        Firmware files used by the kernel module
ii  nvidia-kernel-common-535-server       535.54.03-0ubuntu0.22.04.1              amd64        Shared files used with the kernel module
ii  nvidia-kernel-source-535-server       535.54.03-0ubuntu0.22.04.1              amd64        NVIDIA kernel source package
ii  nvidia-opencl-dev:amd64               11.5.1-1ubuntu1                         amd64        NVIDIA OpenCL development files
ii  nvidia-prime                          0.8.17.1                                all          Tools to enable NVIDIA's Prime
ii  nvidia-profiler                       11.5.114~11.5.1-1ubuntu1                amd64        NVIDIA Profiler for CUDA and OpenCL
ii  nvidia-utils-535-server               535.54.03-0ubuntu0.22.04.1              amd64        NVIDIA Server Driver support binaries
ii  nvidia-visual-profiler                11.5.114~11.5.1-1ubuntu1                amd64        NVIDIA Visual Profiler for CUDA and OpenCL
ii  xserver-xorg-video-nvidia-535-server  535.54.03-0ubuntu0.22.04.1              amd64        NVIDIA binary Xorg driver