HW Transcoding Not Working with Nvidia GPU

Server Version#: 1.22.1.4200-c073686f2
Player Version#: 4.53.0

I’m running PMS on an Ubuntu 20.04 server with AMD 5950x CPU and Nvidia RTX 3070 GPU. I have the nvidia drivers installed and nvidia-smi works correctly.

image

The Plex installation shows that it finds the GPU:

Retrieving list of available distributions
Downloading release "plexmediaserver_1.22.1.4200-c073686f2_amd64.deb"
File downloaded
(Reading database ... 88845 files and directories currently installed.)
Preparing to unpack .../plexmediaserver_1.22.1.4200-c073686f2_amd64.deb ...
PlexMediaServer install: Pre-installation Validation.
PlexMediaServer install: Pre-installation Validation complete.
Unpacking plexmediaserver (1.22.1.4200-c073686f2) over (1.22.0.4163-d8c4875dd) ...
Setting up plexmediaserver (1.22.1.4200-c073686f2) ...
PlexMediaServer install: PlexMediaServer-1.22.1.4200-c073686f2 - Installation starting.
PlexMediaServer install:
PlexMediaServer install: Now installing based on:
PlexMediaServer install:   Installation Type:   Update
PlexMediaServer install:   Process Control:     systemd
PlexMediaServer install:   Plex User:           plex
PlexMediaServer install:   Plex Group:          plex
PlexMediaServer install:   Video Group:         render
PlexMediaServer install:   Metadata Dir:        /var/lib/plexmediaserver/Library/Application Support
PlexMediaServer install:   Temp Directory:      /tmp
PlexMediaServer install:   Lang Encoding:       en_US.UTF-8
PlexMediaServer install:   Intel QSV Hardware:  Not found
PlexMediaServer install:   Nvidia GPU card:     Found
PlexMediaServer install: 
PlexMediaServer install:   OpenCL library:      Installed
PlexMediaServer install:   Beignet package:     Installed
PlexMediaServer install: 
PlexMediaServer install: Completing final configuration.
PlexMediaServer install: Starting Plex Media Server.
PlexMediaServer install: PlexMediaServer-1.22.1.4200-c073686f2 - Installation successful.  Errors: 0, Warnings: 0
Processing triggers for libc-bin (2.31-0ubuntu9.2) ...
Processing triggers for mime-support (3.64ubuntu1) ...

I have the options enabled:

But it still doesn’t use hardware encoding:

image

What am I missing?

Missing the DEBUG (not VERBOSE) log files ZIP which capture the start of the playback for me to review :slight_smile:

Now you forgot what really matters.

Turn DEBUG logging, not VERBOSE, back on please and try again?

Whoops, for some reason, I thought debug was on by default.

Here are the logs after enabling debug logging (not verbose) and streaming a transcoded video:

attachment deleted

Looks like this is the relevant section:

Mar 17, 2021 11:57:10.476 [0x7f888dffb700] ERROR - [Transcode] [FFMPEG] - libva: vaGetDriverNameByIndex() failed with unknown libva error, driver_name = (null)
Mar 17, 2021 11:57:10.476 [0x7f888dffb700] ERROR - [Transcode] [FFMPEG] - Failed to initialise VAAPI connection: -1 (unknown libva error).
Mar 17, 2021 11:57:11.362 [0x7f888dffb700] ERROR - [Transcode] [FFMPEG] - Cannot load libnvidia-encode.so.1
Mar 17, 2021 11:57:11.362 [0x7f888dffb700] ERROR - [Transcode] [FFMPEG] - The minimum required Nvidia driver for nvenc is 418.30 or newer
Mar 17, 2021 11:57:11.382 [0x7f888dffb700] WARN - [Transcode] Codecs: avcodec_open2 returned -1 for encoder 'h264_nvenc'

Yup. That was it.

I had to install libnvidia-encode-460-server

Now it works:

image

  • Have you tried more than 3 transcodes to check Plex is doing HW transcode?

I have similar issue after update to Plex Server 1.22.1.4200. I’m using Windows 10 Pro 20H2: 19042.868. I installed Nvidia GEFORCE GAME READY Driver 461.92 with Nvidia patch. But Plex can do only 3 HW transcodes. Forth transcode is HW decode or software. The I downgraded (Fresh install) Nvidia drivers to 461.72. But still no luck. I don’t know Plex or windows or Nvidia patch making this issue.

you can find my both threads in here.

https://github.com/keylase/nvidia-patch/issues/388

https://forums.plex.tv/t/plex-hardware-transcoding-failed-with-nvidia-geforce-1660-with-geforce-game-ready-driver-461-72-patched-drivers/701218

Please help me.

Can anybody please help me? :frowning_face:

Your problem and solution would be different from mine, as I’m running on Linux, and you’re on Windows.

Thank you very much for the reply. Can you please test and let me know how many HW transcodes (I mean decode and encode) Plex can do? :slightly_smiling_face:

I don’t know the answer to this, nor can I test it. My test wouldn’t indicate the potential performance for your case since Linux and Windows have very different implementations.

This site has some relevant info and tips. Your GPU is the TU116, and it has a hard session limit of 3.

Yes I know Plex server has different implementation for Linux and windows platforms but core features are the same in each build number. I just need to know PMS 1.22.1.4200 did any changes to HW transcoding or not.

Thank you for your help. :slightly_smiling_face:

There have been some library additions:

Here’s where I’m working in another thread.

https://global.discourse-cdn.com/plex/optimized/3X/3/9/39cd5855fe40009abb5f329348d81a9f27912f8b_2_690x377.png

This is more related to regular Plex than HW transcoding per se

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.