Hardware Transcoding stopped Working (GENTOO LINUX) - SOLVED

Sorry, my bad - I understood DEBUG should only be enabled in case requested specifically.

DEBUG should be left on all the time :slight_smile:
We can respond immediately when log files are presented in most cases.

VERBOSE logs are almost never needed anymore. They display each data packet.
It’s used for new device development only now.

Thanks for the fresh logs.

  1. libcuda.so.1 – loads
Jun 10, 2021 20:24:49.368 [0x7f90462a9640] DEBUG - [Transcode] Codecs: hardware transcoding: testing API nvdec
Jun 10, 2021 20:24:49.368 [0x7f90462a9640] DEBUG - [Transcode] [FFMPEG] - Loaded lib: libcuda.so.1
Jun 10, 2021 20:24:49.368 [0x7f90462a9640] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuInit
Jun 10, 2021 20:24:49.368 [0x7f90462a9640] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuDeviceGetCount
Jun 10, 2021 20:24:49.368 [0x7f90462a9640] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuDeviceGet
Jun 10, 2021 20:24:49.368 [0x7f90462a9640] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuDeviceGetAttribute
Jun 10, 2021 20:24:49.368 [0x7f90462a9640] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuDeviceGetName
Jun 10, 2021 20:24:49.368 [0x7f90462a9640] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuDeviceComputeCapability
Jun 10, 2021 20:24:49.368 [0x7f90462a9640] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuCtxCreate_v2
Jun 10, 2021 20:24:49.368 [0x7f90462a9640] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuCtxSetLimit
Jun 10, 2021 20:24:49.368 [0x7f90462a9640] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuCtxPushCurrent_v2
Jun 10, 2021 20:24:49.368 [0x7f90462a9640] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuCtxPopCurrent_v2
Jun 10, 2021 20:24:49.368 [0x7f90462a9640] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuCtxDestroy_v2
Jun 10, 2021 20:24:49.368 [0x7f90462a9640] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuMemAlloc_v2
Jun 10, 2021 20:24:49.368 [0x7f90462a9640] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuMemAllocPitch_v2
Jun 10, 2021 20:24:49.368 [0x7f90462a9640] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuMemsetD8Async
Jun 10, 2021 20:24:49.368 [0x7f90462a9640] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuMemFree_v2
Jun 10, 2021 20:24:49.368 [0x7f90462a9640] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuMemcpy2D_v2
Jun 10, 2021 20:24:49.368 [0x7f90462a9640] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuMemcpy2DAsync_v2
  1. Nvidia hardware recognized and engaged.
Jun 10, 2021 20:24:49.571 [0x7f9046598640] DEBUG - [Transcode] Starting a transcode session zw44sqbe0pd7b65j1a1effhe at offset -1.0 (state=3)
Jun 10, 2021 20:24:49.571 [0x7f9046598640] DEBUG - [Transcode] TPU: hardware transcoding: using hardware decode accelerator nvdec
Jun 10, 2021 20:24:49.571 [0x7f9046598640] DEBUG - [Transcode] TPU: hardware transcoding: zero-copy support present
Jun 10, 2021 20:24:49.571 [0x7f9046598640] DEBUG - [Transcode] TPU: hardware transcoding: using zero-copy transcoding
Jun 10, 2021 20:24:49.571 [0x7f9046598640] DEBUG - [Transcode] [Universal] Using local file path instead of URL: /raid/data/movies/Movies/Live Comedy/David Cross - Making America Great Again (2016).mkv
Jun 10, 2021 20:24:49.571 [0x7f9046598640] DEBUG - [Transcode] TPU: hardware transcoding: final decoder: nvdec, final encoder: nvenc
Jun 10, 2021 20:24:49.571 [0x7f9046598640] DEBUG - [Transcode/JobRunner] Job running: FFMPEG_EXTERNAL_LIBS='/raid/data/users/plexmediaserver//Library/Application\ Support/Plex\ Media\ Server/Codecs/73e06c8-3759-linux-x86_64/' X_PLEX_TOKEN=xxxxxxxxxxxxxxxxxxxx8' '/usr/lib/plexmediaserver/Plex Transcoder' '-codec:0' 'h264' '-hwaccel:0' 'nvdec' '-hwaccel_fallback_threshold:0' '10' '-hwaccel_output_format:0' 'cuda' '-hwaccel_device:0' 'cuda' '-codec:1' 'ac3' '-analyzeduration' '20000000' '-probesize' '20000000' '-i' '/raid/data/movies/Movies/Live Comedy/David Cross - Making America Great Again (2016).mkv' '-filter_complex' '[0:0]hwupload[0];[0]scale_cuda=w=720:h=392:format=nv12[1]' '-map' '[1]' '-metadata:s:0' 'language=eng' '-codec:0' 'h264_nvenc' '-b:0' '1224k' '-maxrate:0' '1632k' '-bufsize:0' '3264k' '-forced-idr:0' '1' '-r:0' '23.975999999999999' '-force_key_frames:0' 'expr:gte(t,n_forced*3)' '-filter_complex' '[0:1] aresample=async=1:ocl='\''stereo'\'':rematrix_maxval=0.000000dB:osr=48000[2]' '-map' '[2]' '-metadata:s:1' 'language=eng' '-codec:1' 'aac' '-b:1' '167k' '-f' 'dash' '-seg_duration' '3' '-init_seg_name' 'init-stream$RepresentationID$.m4s' '-media_seg_name' 'chunk-stream$RepresentationID$-$Number%05d$.m4s' '-window_size' '5' '-delete_removed' 'false' '-skip_to_segment' '1' '-time_delta' '0.0625' '-manifest_name' 'http://127.0.0.1:32400/video/:/transcode/session/zw44sqbe0pd7b65j1a1effhe/5adfee63-bb58-484c-93b8-bf7d55455a70/manifest?X-Plex-Http-Pipeline=infinite' '-avoid_negative_ts' 'disabled' '-map_metadata' '-1' '-map_chapters' '-1' 'dash' '-start_at_zero' '-copyts' '-vsync' 'cfr' '-init_hw_device' 'cuda=cuda:/dev/dri/renderD128' '-filter_hw_device' 'cuda' '-y' '-nostats' '-loglevel' 'quiet' '-loglevel_plex' 'error' '-progressurl' 'http://127.0.0.1:32400/video/:/transcode/session/zw44sqbe0pd7b65j1a1effhe/5adfee63-bb58-484c-93b8-bf7d55455a70/progress'
Jun 10, 2021 20:24:49.571 [0x7f9046598640] DEBUG - [Transcode/JobRunner] Jobs: Starting child process with pid 11221
Jun 10, 2021 20:24:49.573 [0x7f9045fba640] DEBUG - Request: [127.0.0.1:50674 (Loopback)] PUT /video/:/transcode/session/zw44sqbe0pd7b65j1a1effhe/5adfee63-bb58-484c-93b8-bf7d55455a70/progress?status=startup (12 live) Signed-in Token (jazzer23) (range: bytes=0-) 

Whatever you did resolved it.

Whatever you did resolved it.

Yes, I did downgrade to 1.22, that’s it. I did not touch any setting, library, nvidia drivers, anything. I went from one version of Plex to another.
It is reproducible. PMS 1.23 doesn’t use my GPU, PMS 1.22 does.

Can I share my complete 1.23 logs for which transcoding via NVIDA is broken? Would you mind having a look? I can’t accept that I need to use a legacy version on modern hardware.

Thanks!

Alright, I’ve upgrading to the newest version (PlexPass) again (1.23.2.4656). I have not touched anything else and - as expected - HW transcoding broke (again). Please see my logs enclosed.
I’d be so happy if we could resolve this issue.

@SleepwalkerX

Thank you for recreating that log. It is the ā€œhard evidenceā€ I need.

One last piece of information please?

where is libcuda.so.1 ?

It’s at

/usr/lib64/libcuda.so.1

Thank you. I don’t have a Nvidia card to verify with

Thanks for checking. Could it be that Plex 1.23 is looking at an alternate path for the library? I’ve seen that most distros have CUDA libs at /usr/lib/x86_64- linux -gnu/

Do you suggest to symlink?

I had to do some research.

  1. cd /usr/lib/plexmediaserver/etc
  2. edit the file ld-musl-x86_64.path
  3. add /usr/lib/lib64 to the file. (EDIT: /usr/lib64)
  4. restart PMS (1.23.x)

After you’ve confirmed it’s working, :smiley:

I’ll remind you that Gentoo isn’t a supported distribution and something in your build put the libraries in a non-standard location. :rofl:

EDIT

It also helps when I can read :slight_smile:

2 Likes

This sounded too good to be true, I was convinced that this will work. Though, in reality it doesn’t :(.

My ld-musl-x86_64.path looks like this:

/usr/local/lib
/usr/lib/x86_64-linux-gnu
/usr/local/lib/x86_64-linux-gnu
/lib/x86_64-linux-gnu
/usr/lib/lib64

I’ve restarted Plex but still the issue prevails:

Jun 11, 2021 19:54:26.882 [0x7ff00e08eb38] ERROR - [Transcode] [FFMPEG] - Cannot load libcuda.so.1
Jun 11, 2021 19:54:26.882 [0x7ff00e08eb38] ERROR - [Transcode] [FFMPEG] - Could not dynamically load CUDA

Thank you for your efforts so far. I think we are close.

CUDA works on my system (for instance when invocating ffmpeg directly); though Plex doesn’t find the libraries for some reason…

Hang on - this worked!!! The correct path was

/usr/lib64

This might be gentoo-specific. I’ve been using this distro for 10+ years and I don’t plan on switching.

THANK YOU so much, @ChuckPa. You are amazing; I even had fun in the process!

Sorry for the typo on target directory name – :man_facepalming:

Glad it’s running

1 Like

I am late to the party but I recently came to realize that the hardware transcoding stopped working on my server back in May when I upgraded to 1.23.0 with the unable to load libcuda.so.1 error since then.

I am running the Linuxserver Plex Docker image on a QNAP server with a NVDIA card. The NVIDIA libraries used inside that container are mounted in a non-standard directory /usr/local/nvidia/lib from the parent host. Adding that path to /usr/lib/plexmediaserver/etc/ld-musl-x86_64.path resolved my issue.

I wanted to point that, up until 1.23.0, I was adding that path to /etc/ld.so.conf.d/cuda.conf and running ldconfig after that. So it seems that after 1.23.x, the PMS no longer considers the loaded shared libraries. I assume this is due to the compiler change introduced in 1.23.x?

Yes,

As of 1.23.0, musl is now the new toolchain & loader.

We program all the standard locations but it doesn’t dive into ldconfig’s conf file.

As you found, adding it resolves the problem.

1 Like

Just for reference, the the LD_LIBRARY_PATH environment variable can be used to specify the non-standard library directory path as well.

It is much easier to do so, when running a Docker image, than to update the path config file each time the container is created.

Folks, I am getting the same error here, with this file:
image


GeForce 1050 Ti, Drivers up to date and working.
ERROR - [Transcode] [FFMPEG] - libva: vaGetDriverNameByIndex() failed with unknown libva error, driver_name = (null)
This is extremely frustrating, I followed step by step all the instructions.
Plex is not even transcoding the file, where can I see the related errors?
This is proof that my config is working: (I am watching another movie in this case
image

@theluke79

Is Plex a member of the group which owns the card? (/dev/dri/renderDxxx )

If you installed the card after Plex, it’s probably easier to add plex to that group.

The installer will do it for you. You’re choice.

1 Like

Hi.

I have the same problem trying using Plex Media Player on Linux Mint 20.04.
I’ve checked about ā€œplexā€-user added to the groups ā€œvideoā€ and ā€œrenderā€.

On the Server i’ve installed the newest NVidia-Drivers for NVidia GTX 770 (cuda compatible).

nvidia-smi:
NVIDIA-SMI 470.74 Driver Version: 470.74 CUDA Version: 11.4

In Processes ā€œplexmediaserverā€ is listed with about 90MB but the Media Player won’t stream any video. Each stream breaks with (from plex debug log):
[Transcode] [FFMPEG] - libva: vaGetDriverNameByIndex() failed with unknown libva error, driver_name = (null)

I try to get transcoding on nvidia running for weaks now but nothing works.

Still get the same Message about libva each time the server trys to transcode.

I have the same issure, but don’t have a /usr/lib/plexmediaserver/etc file to even check for the .path files. Should I make one? I’m not sure how to fix it at this point.

Apologies for the late reply, I was not getting notified.

It is fixed now, thank you!

This is my ld-musl-x86_64.path:


/usr/local/lib
/usr/lib/x86_64-linux-gnu
/usr/local/lib/x86_64-linux-gnu
/lib/x86_64-linux-gnu
/usr/lib64

This is the error in the logs:

Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] ERROR - [Transcode] [FFMPEG] - libva: vaGetDriverNameByIndex() failed with unknown libva error, driver_name = (null)
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] ERROR - [Transcode] [FFMPEG] - Failed to initialise VAAPI connection: -1 (unknown libva error).
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] Codecs: hardware transcoding: opening hw device failed - probably not supported by this system, error: I/O error
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] Codecs: testing h264 (decoder) with hwdevice nvdec
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] Codecs: hardware transcoding: testing API nvdec
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded lib: libcuda.so.1
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuInit
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuDeviceGetCount
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuDeviceGet
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuDeviceGetAttribute
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuDeviceGetName
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuDeviceComputeCapability
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuCtxCreate_v2
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuCtxSetLimit
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuCtxPushCurrent_v2
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuCtxPopCurrent_v2
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuCtxDestroy_v2
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuMemAlloc_v2
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuMemAllocPitch_v2
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuMemsetD8Async
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuMemFree_v2
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuMemcpy2D_v2
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuMemcpy2DAsync_v2
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuGetErrorName
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuGetErrorString
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuCtxGetDevice
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuStreamCreate
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuStreamQuery
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuStreamSynchronize
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuStreamDestroy_v2
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuStreamAddCallback
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuEventCreate
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuEventDestroy_v2
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuEventSynchronize
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuEventQuery
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuEventRecord
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuLaunchKernel
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuLinkCreate
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuLinkAddData
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuLinkComplete
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuLinkDestroy
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuModuleLoadData
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuModuleUnload
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuModuleGetFunction
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuTexObjectCreate
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuTexObjectDestroy
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuGLGetDevices_v2
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuGraphicsGLRegisterImage
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuGraphicsUnregisterResource
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuGraphicsMapResources
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuGraphicsUnmapResources
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuGraphicsSubResourceGetMappedArray
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuDeviceGetUuid
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuImportExternalMemory
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuDestroyExternalMemory
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuExternalMemoryGetMappedBuffer
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuExternalMemoryGetMappedMipmappedArray
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuMipmappedArrayGetLevel
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuMipmappedArrayDestroy
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuImportExternalSemaphore
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuDestroyExternalSemaphore
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuSignalExternalSemaphoresAsync
Nov 04, 2021 12:51:00.678 [0x7f8fdf6d7b38] DEBUG - [Transcode] [FFMPEG] - Loaded sym: cuWaitExternalSemaphoresAsync
Nov 04, 2021 12:51:00.729 [0x7f8fdf6d7b38] DEBUG - [Transcode] Codecs: Testing with profile 'High'
Nov 04, 2021 12:51:00.746 [0x7f8fdf6d7b38] DEBUG - [Transcode] Scaled up video bitrate to 16794Kbps based on 1.500000x fudge factor.
Nov 04, 2021 12:51:00.746 [0x7f8fdf6d7b38] DEBUG - [Transcode] MDE: Selected protocol http; container: mkv
Nov 04, 2021 12:51:00.746 [0x7f8fdf6d7b38] DEBUG - [Transcode] MDE: analyzing media item 27432
Nov 04, 2021 12:51:00.746 [0x7f8fdf6d7b38] DEBUG - [Transcode] MDE: Lethal Weapon 3 (1992): Direct Play is disabled
Nov 04, 2021 12:51:00.746 [0x7f8fdf6d7b38] DEBUG - [Transcode] MDE: Lethal Weapon 3 (1992): no direct play video profile exists for http/mkv/h264
Nov 04, 2021 12:51:00.746 [0x7f8fdf6d7b38] DEBUG - [Transcode] MDE: Lethal Weapon 3 (1992): no direct play video profile exists for http/mkv/h264/dca
Nov 04, 2021 12:51:00.746 [0x7f8fdf6d7b38] DEBUG - [Transcode] MDE: Lethal Weapon 3 (1992): no direct play video profile exists for http/mkv/h264/aac
Nov 04, 2021 12:51:00.746 [0x7f8fdf6d7b38] DEBUG - [Transcode] MDE: Lethal Weapon 3 (1992): Direct Streaming is disabled, so video stream will be transcoded
Nov 04, 2021 12:51:00.746 [0x7f8fdf6d7b38] DEBUG - [Transcode] MDE: Lethal Weapon 3 (1992): no remuxable profile found, so video stream will be transcoded
Nov 04, 2021 12:51:00.746 [0x7f8fdf6d7b38] DEBUG - [Transcode] Codecs: testing h264_nvenc (encoder)
Nov 04, 2021 12:51:00.746 [0x7f8fdf6d7b38] DEBUG - [Transcode] Codecs: hardware transcoding: testing API nvenc

I have added plex:plex as owner of the card

sudo chown -R plex:plex /dev/dri

And restarted Plex: it does work now, THANK YOU!