Hardware Transcoding Issue After Update

Hello,

Since today, I’ve been facing major issues with Plex hardware transcoding.

It almost doesn’t work anymore… almost because it works about 1 in 10 attempts, and the other 9 times it only plays 10–15 seconds of a movie/series before stopping entirely.

Here are my details:

  • OS: Debian 12 (Kernel 6.8.12-5)
  • Plex version: 1.41.3.9314 (latest)
  • NVIDIA driver: 560.35.03 (latest)

A few months ago, everything was working fine (though I haven’t used it much recently). Manual transcoding works flawlessly (tested with FFMPEG, NVENC, and NVDECODE—I’m able to convert 4K HEVC videos without issues using my GTX 1050).

My hardware:

  • Intel i5-8300H
  • GTX 1050
  • 64 GB RAM
  • Plex running bare-metal

I strongly suspect this is a Plex bug since the issue started right after my updates today. I’ve tried rolling back the kernel (6.1, 6.5, and 6.8) and the NVIDIA drivers (535, 550, and 560), but nothing changed.

In the logs, I consistently see the following error (with no additional details, even with verbose logging enabled):

Jobs: '/usr/lib/plexmediaserver/Plex Transcoder' exit code for process 125755 is -9 (signal: Killed)

Does anyone have an idea of what could be going on? This is really frustrating. :confused:

Thanks in advance!
Plex Media Server.log (1.7 MB)

What does nvidia-smi show?

I’m using nvidia-firmware-550-550.120 and fully operational without issue.

There are times when the latest nvidia drivers are a bit ‘bleeding edge’.
Also, has DKMS run to update initramfs ?

Hi,
Nvidia-smi show the process for like… 5 second … and all disapear just after.

as i said, i have already tested other version (535 and 550), not better …
yes i have run initramfs for the DKMS

In the transcoder device selector, are you set to auto or have you selected the Nvidia ?

PMS sees both GPUs

Jan 05, 2025 19:49:40.311 [139740242631312] DEBUG - Opening 2 database sessions to library (com.plexapp.plugins.library.blobs), SQLite 3.39.4, threadsafe=1
Jan 05, 2025 19:49:40.314 [139740242631312] INFO - Running migrations. (EPG 0)
Jan 05, 2025 19:49:40.314 [139740242631312] DEBUG - Captured session 0.
Jan 05, 2025 19:49:40.314 [139740242631312] DEBUG - Captured session 1.
Jan 05, 2025 19:49:40.316 [139740173052728] DEBUG - [GPU] Got device: Intel CoffeeLake-H GT2 [UHD Graphics 630], intel@builtin, default true, best true, ID 8086:3e9b:1028:086f@0000:00:02.0, DevID [8086:3e9b:1028:086f], flags 0x38e7
Jan 05, 2025 19:49:40.316 [139740173052728] DEBUG - [GPU] Got device: NVIDIA GP107M [GeForce GTX 1050 Mobile], nvidia@unknown, default false, best false, ID 10de:1c8d:1028:086f@0000:01:00.0, DevID [10de:1c8d:1028:086f], flags 0xe8
Jan 05, 2025 19:49:40.316 [139740173052728] INFO - Preemptively preparing driver imd for GPU Intel CoffeeLake-H GT2 [UHD Graphics 630]
Jan 05, 2025 19:49:40.316 [139740173052728] DEBUG - [DriverDL/imd] Skipping download; already exists
Jan 05, 2025 19:49:40.316 [139740173052728] INFO - Preemptively preparing driver icr for GPU Intel CoffeeLake-H GT2 [UHD Graphics 630]
Jan 05, 2025 19:49:40.316 [139740173052728] DEBUG - [DriverDL/icr] Skipping download; already exists

UHD Graphics 630 is the integrated GPU of my CPU
the GTX 1050 is selected in my transcoder device (not in auto)

Your logs show me that the card is seen on the PCI but when you scroll down further, the transcoder isn’t seeing it for probing.

Confirm please /dev/dri is enumerating both devices

Also please confirm the plex runtime user is a member of the group which owns /dev/dri ?

This is going to be something simple. It’s looking like a udev permissions problem.

supplemental:

libnvidia-decode and libnvidia-encode are also at same revision?

I don’t have the specific version of libnvidia-encode and libnvidia-decode, but they come from my installation of the proprietary nvidia driver (560), so I think it’s the same version.

I have both entered in /dev/dri, and plex is a member of the video and render groups.

I rebooted again, no better, but what I find strange, as I said earlier, is that transcoding runs for 5 seconds and preloads me for like 20 seconds, and works fine with FFMPEG in manual mode :/.

dpkg -l | grep libnvidia

No, libnvidia-decode and libnvidia-encode do not come with the driver.
You must install them manually

I have the RTX 2000 Ada Generation. Installation of the decode and encode libraries was required for PMS to use it.

Using the vetted drivers is better than using the .run package

ok, I’ve tried my distribution’s drivers, and it’s worse.
I get a segfault when I try to transcode, which kills PMS, and same for other software (like FFMPEG), so I’m going to look for another version to see what’s going on :/.

I’ll test other driver combinations, and if it persists I’ll try roll-back my version of Plex to see …

apart from version 525 (obviously buggy on my system …) I have the same behavior with drivers 550 and 560.

I’ve also tested kernel roll-back (6.5.13 being the oldest I have, and functional during my initial installation).

I’m able to transcode well outside PLEX (with FFMPEG for exemple), I’ve also tested with the “plex” user to check permission, I can transcode with CUDA, NVENC and NVDEC.

I’ve also roll-back my PMS… version to 1.32.8 (old version).

so I have the .run driver that worked before, the kernel version that went with it, and the know good PMS version, these 3 versions are exactly what I tested and validated some time ago … and it doesn’t work …

what’s frustrating is that it often manages to transcode for several seconds (even more than a minute like now), so PMS actually manages to use the card for a while … but I don’t understand why it suddenly stops afterwards …

i can also SEE it in my monitoring …

I’m a bit out of ideas, and I really don’t want to reinstall the OS (it’s a LAB hypervisor, and I’ve got 8 TB of VMs and containers on it … not critical because it’s a lab and it’s Sunday, but it’s not possible to reinstall…)

PS : I’ve tried running plex as root, to see if it’s a permission problem, same problem … I’ve really run out of ideas :confused:

just got home.

  1. Stop Plex
  2. Remove the contents of the ‘Drivers’ directory
  3. Remove the contents of the ‘Codecs’ directory except for the .device_id file (your license)
  4. Install this
[chuck@lizum Downloads.2007]$ nvidia-smi
Sun Jan  5 19:18:28 2025       
+-----------------------------------------------------------------------------------------+
| NVIDIA-SMI 550.120                Driver Version: 550.120        CUDA Version: 12.4     |
|-----------------------------------------+------------------------+----------------------+
| 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  NVIDIA RTX 2000 Ada Gene...    On  |   00000000:01:00.0  On |                  Off |
| 30%   48C    P2             44W /   70W |    2355MiB /  16380MiB |     37%      Default |
|                                         |                        |                  N/A |
+-----------------------------------------+------------------------+----------------------+
                                                                                         
+-----------------------------------------------------------------------------------------+
| Processes:                                                                              |
|  GPU   GI   CI        PID   Type   Process name                              GPU Memory |
|        ID   ID                                                               Usage      |
|=========================================================================================|
|    0   N/A  N/A      5942      G   /usr/lib/xorg/Xorg                            274MiB |
|    0   N/A  N/A      6130      G   /usr/bin/gnome-shell                          167MiB |
|    0   N/A  N/A      6726      G   ...seed-version=20241225-174432.450000        520MiB |
|    0   N/A  N/A     24950    C+G   /usr/bin/celluloid                              0MiB |
|    0   N/A  N/A     54979      C   ...lib/plexmediaserver/Plex Transcoder        612MiB |
|    0   N/A  N/A     55211      C   ...lib/plexmediaserver/Plex Transcoder        612MiB |
+-----------------------------------------------------------------------------------------+
[chuck@lizum Downloads.2008]$ 

(Note: I’ve not updated the server name but am running the version above)

[chuck@lizum Downloads.2008]$ dpkg -l | grep plexm
ii  plexmediaserver                                 1.41.3.9232-434341a9d                    amd64        Plex organizes all of your personal media so you can easily access and enjoy it.
[chuck@lizum Downloads.2009]$ 

Hello, I’m having this same issue, and after looking at the /Dev/DRI and DRM nodes, I’ve found what looks like left over unused nodes? maybe from the driver and libraries being updated? I used sudo ubuntu-drivers --gpgpu install to install the drivers and libraries, currently on 570 for everything. Would running that deb file still fix things for me?

got another update. Tried following the steps… found the Driver folder was already empty, and running the Deb file gives an error:

./plexmediaserver_1.41.3.9232-434341a9d_amd64.deb: line 1: syntax error near unexpected token `newline'
./plexmediaserver_1.41.3.9232-434341a9d_amd64.deb: line 1: `!<arch>'

I’m running Ubuntu 22 kernel 5.15.0
plex version is 1.41.4.9399
Nvidia Driver 570

I can get things to play with direct stream, but only plays for about 5 seconds after changing to any transcoding quality, with any kind of video, combinations of H265/H264 and MKV/MP4, using an RTX A2000, same as you I believe ChuckPa. Running videos separately works fine

You don’t run the .deb as a script

sudo dpkg -i  filename.deb

Apologies. and thank you for the assistance. I ran the downgrade successfully, and now I’m getting an error for [Req#12be/Transcode] Denying access due to session lacking permission to transcode key /library/metadata/2196 and, after looking into your previous posts and solutions on the subject, I looked into permissions for the folder, and files. When checking, I found the whole Metadata folder missing… somehow… at least I expect its under /var/lib/plexmediaserver/Library/metadata? well anyway, I ran the scan files, metadata refresh, and analyze, then tried it again and it just got stuck loading, for like 5 minutes, before giving a new FFMPEG error: [Req#6a281/Transcode] [FFMPEG] - cu->cuInit(0) failed [Req#6a281/Transcode] [FFMPEG] - -> CUDA_ERROR_UNKNOWN: unknown error looked into that… found there was two cuda folders under usr/local, but before I changed anything… it just started working? this has been a weird one. Thank you for all the help though, hopefully it keeps working. I bet this was caused by me hitting too close to maxing out the storage space, I might rebuild to a new system if it happens again.

@joshua286

May I please get your Server Logs ZIP file?

Seeing singular statements in isolation isn’t possible to diagnose

It does sound like you have a permissions problem in /var/lib/plexmediaserver

it’s usually easy to fix what’s missing without resorting to a :hammer_and_pick: approach :slight_smile:

If you use the default server installation (where ‘plex’ is the runtime user)
then you can remedy any permission problems in three (3) steps
( with plex stopped )

  • sudo chown -R plex:plex /var/lib/plexmediaserver
  • sudo find /var/lib/plexmediaserver -type d -exec chmod 755 {} \'
  • sudo find /var/lib/plexmediaserver -type f -exec chmod 644 {} \;

I suggest running these 3 commands, starting plex, then Refresh Metadata for all sections in your library.

This will fetch fresh metadata and write the missing structures.

After that’s done, We can take steps to clean up what happened before.

Thank you for the additional info, however, I apologize but I don’t think they will be any use anymore, after checking, the logs are only going back to about 10 hours ago, a few hours after I fixed things.

I suggest you not use the 570 drivers.

Production release is still 550.127.08
New Feature branch is 565.77 (supporting my RTX 2000)

Specifically (This is the New-Features branch)

[chuck@lizum ~.2002]$ dpkg -l | grep nvidia-driver
ii  nvidia-driver-565-open                     565.77-0ubuntu0~gpu22.04.1               amd64        NVIDIA driver (open kernel) metapackage
[chuck@lizum ~.2003]$ 

This is production for my P2200 (on the NAS)

[chuck@glockner tv5.2017]$ dpkg -l | grep nvidia-driver
ii  nvidia-driver-550-server               550.127.08-0ubuntu0.24.04.1             amd64        NVIDIA Server Driver metapackage
[chuck@glockner tv5.2018]$ 

I recommend you consider looking at apt list | grep nvidia-driver and come back into the vetted drivers.

You can install the specific driver metapackage of choice

example: sudo apt install nvidia-driver-xxx

Please consider getting your nvidia package versions in sync if/when you can.

Even I have a stray older “535” package in there but otherwise all are 565.

[chuck@lizum ~.2007]$ dpkg -l | grep nvidia
ii  libnvidia-cfg1-565:amd64                   565.77-0ubuntu0~gpu22.04.1               amd64        NVIDIA binary OpenGL/GLX configuration library
ii  libnvidia-common-565                       565.77-0ubuntu0~gpu22.04.1               all          Shared files used by the NVIDIA libraries
rc  libnvidia-compute-535:amd64                535.183.01-0ubuntu0.22.04.1              amd64        NVIDIA libcompute package
ii  libnvidia-compute-565:amd64                565.77-0ubuntu0~gpu22.04.1               amd64        NVIDIA libcompute package
ii  libnvidia-decode-565:amd64                 565.77-0ubuntu0~gpu22.04.1               amd64        NVIDIA Video Decoding runtime libraries
ii  libnvidia-egl-wayland1:amd64               1:1.1.15-0ubuntu0~gpu22.04.1             amd64        Wayland EGL External Platform library -- shared library
ii  libnvidia-encode-565:amd64                 565.77-0ubuntu0~gpu22.04.1               amd64        NVENC Video Encoding runtime library
ii  libnvidia-extra-565:amd64                  565.77-0ubuntu0~gpu22.04.1               amd64        Extra libraries for the NVIDIA driver
ii  libnvidia-fbc1-565:amd64                   565.77-0ubuntu0~gpu22.04.1               amd64        NVIDIA OpenGL-based Framebuffer Capture runtime library
ii  libnvidia-gl-565:amd64                     565.77-0ubuntu0~gpu22.04.1               amd64        NVIDIA OpenGL/GLX/EGL/GLES GLVND libraries and Vulkan ICD
ii  nvidia-compute-utils-565                   565.77-0ubuntu0~gpu22.04.1               amd64        NVIDIA compute utilities
ii  nvidia-dkms-565-open                       565.77-0ubuntu0~gpu22.04.1               amd64        NVIDIA DKMS package (open kernel module)
ii  nvidia-driver-565-open                     565.77-0ubuntu0~gpu22.04.1               amd64        NVIDIA driver (open kernel) metapackage
ii  nvidia-firmware-565-565.77                 565.77-0ubuntu0~gpu22.04.1               amd64        Firmware files used by the kernel module
ii  nvidia-kernel-common-565                   565.77-0ubuntu0~gpu22.04.1               amd64        Shared files used with the kernel module
ii  nvidia-kernel-source-565-open              565.77-0ubuntu0~gpu22.04.1               amd64        NVIDIA kernel source package
ii  nvidia-prime                               0.8.17.1                                 all          Tools to enable NVIDIA's Prime
ii  nvidia-settings                            510.47.03-0ubuntu1                       amd64        Tool for configuring the NVIDIA graphics driver
ii  nvidia-utils-565                           565.77-0ubuntu0~gpu22.04.1               amd64        NVIDIA driver support binaries
ii  screen-resolution-extra                    0.18.2                                   all          Extension for the nvidia-settings control panel
ii  xserver-xorg-video-nvidia-565              565.77-0ubuntu0~gpu22.04.1               amd64        NVIDIA binary Xorg driver
[chuck@lizum ~.2008]$