HW Transcoding on QNAP issues

Please share your secrets!

I’m am so sick and tired of every QNAP s/w (and/or nvidia kernel/driver) update causing nothing but utter grief with hardware transcoding (yes, the card is in QTS mode, nvidia-smi sees it just fine, Plex lets me choose it as the h/w transcoding device, and then it just simply doesn’t use it, spiking my cpu to 100% and the fans spinning like it’s a rocket ship).

I’d love to be able to once again have functioning h/w transcoding and Plex and QNAP just keep pointing the fingers at each other.

If using Container Station, did you also add the GPU under the Runtime settings?

I also ended up having to modify the Preferences.xml file for my docker Plex server. The “HardwareDevicePath” entry. In my case to HardwareDevicePath=“/dev/dri/renderD129”.

SSH in to your QNAP server, run ls -l /dev/dri. That will show your GPU variables.

Finally got to the container station route and still not having luck with h/w transcoding. :frowning:

I’m able to run nvidia-smi from inside the container and it sees the GPU.

I selected the Nvidia card via the settings in Plex – transcoding still went to the CPU.

Stopped the container, updated HardwareDevicePath to /dev/dri/renderD128 in Preferences.xml, started the container, and same result – still not transcoding on the GPU.

Every permutation (GPU granted via container station, enabling DRI via container station, running with privileged mode or not) results in the same error when the plex container starts:

Apr 06, 2026 22:10:03.122 [139669170121360] ERROR - [GPU] Cuda function failed with error initialization error

Updated to add the logs once I enabled debug and verbose (though still not helpful):

Apr 06, 2026 22:41:38.761 [140553932983096] VERBOSE - [Req#79d/Transcode] [FFMPEG] - Rescanning for external libs: '/config/Library/Application\ Support/Plex\ Media\ Server/Codecs/74455c4-a119aa85fdef32b7dbfbf8a2-linux-x86_64/'
Apr 06, 2026 22:41:38.761 [140554000845624] VERBOSE - It took 0.0 sec to serialize a list with 1 elements.
Apr 06, 2026 22:41:38.762 [140553932983096] DEBUG - [Req#79d/Transcode] Codecs: hardware transcoding: testing API nvdec for device 'pci:0000:01:00.0' (NVIDIA TU117 [GeForce GTX 1650])
Apr 06, 2026 22:41:38.762 [140553932983096] DEBUG - [Req#79d/Transcode] [FFMPEG] - Loaded lib: libcuda.so.1
Apr 06, 2026 22:41:38.762 [140553932983096] DEBUG - [Req#79d/Transcode] [FFMPEG] - Loaded sym: cuInit
Apr 06, 2026 22:41:38.762 [140553932983096] DEBUG - [Req#79d/Transcode] [FFMPEG] - Loaded sym: cuDriverGetVersion
...
Apr 06, 2026 22:41:38.762 [140553932983096] DEBUG - [Req#79d/Transcode] [FFMPEG] - Loaded sym: cuGraphicsResourceGetMappedPointer_v2
Apr 06, 2026 22:41:38.762 [140554125028152] DEBUG - Completed: [192.168.1.10:62533] 200 GET /library/metadata/568?includeMarkers=1 (15 live) #7ab GZIP 28ms 3161 bytes (pipelined: 2)
Apr 06, 2026 22:41:38.762 [140553932983096] DEBUG - [Req#79d/Transcode] [FFMPEG] - Loaded sym: cuDeviceGetUuid
Apr 06, 2026 22:41:38.762 [140553932983096] DEBUG - [Req#79d/Transcode] [FFMPEG] - Loaded sym: cuDeviceGetUuid_v2
...
Apr 06, 2026 22:41:38.821 [140553932983096] ERROR - [Req#79d/Transcode] [FFMPEG] - cu->cuInit(0) failed
Apr 06, 2026 22:41:38.821 [140553932983096] ERROR - [Req#79d/Transcode] [FFMPEG] -  -> CUDA_ERROR_NOT_INITIALIZED: initialization error
Apr 06, 2026 22:41:38.821 [140553932983096] ERROR - [Req#79d/Transcode] [FFMPEG] -
Apr 06, 2026 22:41:38.821 [140553932983096] DEBUG - [Req#79d/Transcode] Codecs: hardware transcoding: opening hw device failed - probably not supported by this system, error: Generic error in an external library
Apr 06, 2026 22:41:38.821 [140553932983096] DEBUG - [Req#79d/Transcode] Could not create hardware context for h264

If there were a problem with the container station runtime then it would be expected that nvidia-smi inside the container would not run, so this really, really seems like a Plex-specific issue.

This is so frustrating!