HW Transcode, Docker/Linux/Nvidia P2000 - Negitave Colors

Server Version#:1.18.3.2129
Player Version#: 4.16.4
Transcode Log File: https://pastebin.com/ZvRpQ2fb
Sample of Transcode Image: https://imgur.com/a/hp1bqeW

Looking for anyone who can help. Running into an issue that I’m a bit stumped on, some video files (haven’t nailed down which ones specifically) direct play fine, however if they are transcoded they get a green tint to them. Guessing this is some known issue specific to support of a codec or HW transcode on linux…hoping there’s a workaround.

Most transcodes are fine, seems to be higher quality videos are the issues…guessing due to the colors supported in the file.

System is a new build running ubuntu 19.10 with a Nvidia Quadro P2000.

NVIDIA-SMI 440.36 Driver Version: 440.36 CUDA Version: 10.2

Those are player logs, not server logs.
The transcoder log doesn’t help

Verify DEBUG logging is on, VERBOSE is off
Recreate the problem
Capture the ZIP log set
Attach it.

There is a known issue with the iHD driver and ApolloLake CPUs.
Your logs will allow confirmation and correct workaround (while they fix it) to get you running again.

bump…anyone have any ideas?

Been super busy. sorry

It is not liking the nvidia drivers at all.

Dec 10, 2019 22:47:39.536 [0x7f33f4ff9700] VERBOSE - [FFMPEG] - Nvenc initialized successfully
Dec 10, 2019 22:47:39.548 [0x7f33f4ff9700] VERBOSE - [FFMPEG] - Nvenc unloaded
Dec 10, 2019 22:47:39.571 [0x7f33f4ff9700] DEBUG - Codecs: testing h264 (decoder) with hwdevice vaapi
Dec 10, 2019 22:47:39.571 [0x7f33f4ff9700] VERBOSE - [FFMPEG] - Rescanning for external libs: '/config/Library/Application\ Support/Plex\ Media\ Server/Codecs/8bf330d-2772-linux-x86_64/'
Dec 10, 2019 22:47:39.571 [0x7f33f4ff9700] DEBUG - Codecs: hardware transcoding: testing API vaapi
Dec 10, 2019 22:47:39.571 [0x7f33f4ff9700] VERBOSE - [FFMPEG] - Ignoring device 0 with non-matching kernel driver (nvidia-drm).
Dec 10, 2019 22:47:39.571 [0x7f33f4ff9700] VERBOSE - [FFMPEG] - Cannot open DRM render node for device 1.
Dec 10, 2019 22:47:39.571 [0x7f33f4ff9700] VERBOSE - [FFMPEG] - Cannot open a VA display from DRM device (null).
Dec 10, 2019 22:47:39.571 [0x7f33f4ff9700] VERBOSE - [FFMPEG] - Ignoring device 0 with non-matching kernel driver (nvidia-drm).
Dec 10, 2019 22:47:39.571 [0x7f33f4ff9700] VERBOSE - [FFMPEG] - Cannot open DRM render node for device 1.
Dec 10, 2019 22:47:39.571 [0x7f33f4ff9700] VERBOSE - [FFMPEG] - Cannot open a VA display from DRM device (null).
Dec 10, 2019 22:47:39.571 [0x7f33f4ff9700] VERBOSE - [FFMPEG] - Ignoring device 0 with non-matching kernel driver (nvidia-drm).
Dec 10, 2019 22:47:39.571 [0x7f33f4ff9700] VERBOSE - [FFMPEG] - Cannot open DRM render node for device 1.
Dec 10, 2019 22:47:39.571 [0x7f33f4ff9700] VERBOSE - [FFMPEG] - Cannot open a VA display from DRM device (null).
Dec 10, 2019 22:47:39.571 [0x7f33f4ff9700] DEBUG - Codecs: hardware transcoding: opening hw device failed - probably not supported by this system, error: Generic error in an external library
Dec 10, 2019 22:47:39.571 [0x7f33f4ff9700] DEBUG - Codecs: testing h264 (decoder) with hwdevice nvdec
Dec 10, 2019 22:47:39.571 [0x7f33f4ff9700] VERBOSE - [FFMPEG] - Rescanning for external libs: '/config/Library/Application\ Support/Plex\ Media\ Server/Codecs/8bf330d-2772-linux-x86_64/'
Dec 10, 2019 22:47:39.571 [0x7f33f4ff9700] DEBUG - Codecs: hardware transcoding: testing API nvdec
Dec 10, 2019 22:47:39.571 [0x7f33f4ff9700] DEBUG - [FFMPEG] - Loaded lib: libcuda.so.1
Dec 10, 2019 22:47:39.571 [0x7f33f4ff9700] DEBUG - [FFMPEG] - Loaded sym: cuInit

Also, in the future, please do not turn on VERBOSE unless requested. DEBUG is the default for a reason. I was barely able to find this in your logs . It was about to fall off the end of the disk buffer. (fixed size)

Can you tell me where I can find the info you posted above. I sifted through the logs and didn’t find it. It’s hard for me to believe the driver isn’t working because it is hardware transcoding and working fine on most files. Atm there are just 2 that produce this result. They direct play fine but hw transcoding the color shifts to this green overlay. Other files transcode and direct play file.

If I can find the log file your talking about I’ll see if I can reproduce it with different media.

Atm…kind stuck. I can run nvidia-smi fine in the container, when transcoding I see it show up under the hosts nvidia-smi so I know it’s using the card…

Also, are the errors above related to vaapi specific to Intel? As I have AMD with a Nvidia p2000 i’d assume it’s be vdpau or Nouveau…it seems like the errors are related to testing for the hw decoder and it fails on vaapi as I don’t have Intel and once it hits nvdec it seems to take off…

Halp?

May I have a fresh ZIP of the entire logs here attached to your next reply?

@ChuckPa wanted you to just disable Verbose logging on your server. You can do that directly in the server settings (Settings -> General -> Enable Plex Media Server verbose logging). Uncheck that box, save your changes then try and reproduce the problem.

Plex Media Server Logs_2019-12-16_21-04-48.zip (3.9 MB)

Replicated the issue on a couple movies. From what I can tell, the video files that cause the issues are higher quality. played 3 movies that produce the issue and then transcoded a few that are fine. all state they are being hw transcoded which I do see the stream through nvidia-smi on the host…so I know the nvidia card (p2000) is working.

here are 2 image captures showing the output of the nvidia-smi command in the docker container and host system while transcoding:

Thanks for the logs. I see more video errors than DEBUG errors. This does make it pretty obvious.

Dec 16, 2019 21:03:46.653 [0x7f154202a700] DEBUG - Completed: [172.16.50.92:55243] 200 GET /video/:/transcode/universal/dash/kc1ifrdtgw765mx1z1mtbl5z/0/15.m4s (11 live) TLS GZIP 3ms 2429760 bytes (pipelined: 45)
Dec 16, 2019 21:03:46.654 [0x7f1514ff9700] ERROR - [Transcoder] [Parsed_scale_cuda_1 @ 0x26cecc0] cu->cuTexObjectCreate(&tex, &res_desc, &tex_desc, ((void*)0)) failed -> CUDA_ERROR_INVALID_VALUE: invalid argument
Dec 16, 2019 21:03:46.655 [0x7f14e17fa700] ERROR - [Transcoder] [Parsed_scale_cuda_1 @ 0x26cecc0] cu->cuTexObjectCreate(&tex, &res_desc, &tex_desc, ((void*)0)) failed -> CUDA_ERROR_INVALID_VALUE: invalid argument
Dec 16, 2019 21:03:46.655 [0x7f14e1ffb700] ERROR - [Transcoder] [Parsed_scale_cuda_1 @ 0x26cecc0] cu->cuTexObjectCreate(&tex, &res_desc, &tex_desc, ((void*)0)) failed -> CUDA_ERROR_INVALID_VALUE: invalid argument
Dec 16, 2019 21:03:46.656 [0x7f14657fa700] ERROR - [Transcoder] [Parsed_scale_cuda_1 @ 0x26cecc0] cu->cuTexObjectCreate(&tex, &res_desc, &tex_desc, ((void*)0)) failed -> CUDA_ERROR_INVALID_VALUE: invalid argument
Dec 16, 2019 21:03:46.657 [0x7f15321c8700] ERROR - [Transcoder] [Parsed_scale_cuda_1 @ 0x26cecc0] cu->cuTexObjectCreate(&tex, &res_desc, &tex_desc, ((void*)0)) failed -> CUDA_ERROR_INVALID_VALUE: invalid argument
Dec 16, 2019 21:03:46.657 [0x7f1541829700] ERROR - [Transcoder] [Parsed_scale_cuda_1 @ 0x26cecc0] cu->cuTexObjectCreate(&tex, &res_desc, &tex_desc, ((void*)0)) failed -> CUDA_ERROR_INVALID_VALUE: invalid argument
Dec 16, 2019 21:03:46.661 [0x7f14e27fc700] ERROR - [Transcoder] [Parsed_scale_cuda_1 @ 0x26cecc0] cu->cuTexObjectCreate(&tex, &res_desc, &tex_desc, ((void*)0)) failed -> CUDA_ERROR_INVALID_VALUE: invalid argument
Dec 16, 2019 21:03:46.662 [0x7f1514ff9700] ERROR - [Transcoder] [Parsed_scale_cuda_1 @ 0x26cecc0] cu->cuTexObjectCreate(&tex, &res_desc, &tex_desc, ((void*)0)) failed -> CUDA_ERROR_INVALID_VALUE: invalid argument
Dec 16, 2019 21:03:46.662 [0x7f14e17fa700] ERROR - [Transcoder] [Parsed_scale_cuda_1 @ 0x26cecc0] cu->cuTexObjectCreate(&tex, &res_desc, &tex_desc, ((void*)0)) failed -> CUDA_ERROR_INVALID_VALUE: invalid argument

what is the XML of the video played?

The logs show it plays along fine for a bit then goes into error state. Is there video file damage?

This one works perfect : https://pastebin.com/7AhGAveb
This one has the green tint: https://pastebin.com/gWr2WSNu

Some of the jumping around may be because I was playing different files that cause an issue and then playing files that work fine. As far as I can tell the files are perfectly fine as if I direct play them they work great…when I transcode them is when I get the odd green tint…however other than the green tint…they seem great…transcoded that is. Again, direct played they are fine.

Is it possible to get a sample of the file?
When I see solid green overcast on an image, the usual root cause is codec or video failure. A sample will allow me to replicate and then use to submit a trouble report
A dd slice, about 20-30 MB should do fine.

I have a QNAP NAS with an nVidia 1060 which I can attempt to replicate it on.

one more that produces a green tint for good measure: https://pastebin.com/WiXewVqG

I’ll slice up the file tomorrow, make sure the sample produces the issue on my end then will send it your way.

Thanks. When you and I both have the same results then I can guarantee Engineering will see it as well (they will use the same QNAP for testing)

try this file : https://drive.google.com/file/d/1TJSZV03oNlZ43eWM3DqLfKBv1oGunP9f/view?usp=sharing

I cut with head -c $(( 8192*8192 )) input.mkv > sample.mkv then used mkvmerge to fix the cut. Issue is there on my end still.

I’m not using a QNAP, here is my hardware : https://pastebin.com/uW9sgkJc

Thanks for the file.

The machine is in use right now/today.
I will verify / recreate as soon as it’s available.

I uploaded the wrong file…the one I linked worked…here is a busted one…same file, however the first one I ran through ffmpeg and it fixed it…this on is untouched other than trimmed.

Not pushing, just curious how / if you were able to replicate the issue.

Thanks!

I’ve not had access. With proximity to the holiday, it’s unlikely I will have time next week.