Pausing a movie which is transcoded (hardware) is killing the hw-transcoder

Server Version#: 1.21.3.4021
Player Version#: 4.52.1 Plex Web

I’m using a Synology DS 716+ with hardware-transcoder. Everything works just fine: until I pause a movie which is using hardware-transcode (shown in the dashboard wich transcoding (hw) ).

If I pause and try to resume, the hw-transcoder is dead and can’t be used until I reboot the whole system.

In the logs I can find things like this, but as I said: it is working fine until the movie is paused and resumed.

Feb 15, 2021 21:14:12.151 [0x7f8bbeb7d700] ERROR - [Transcode] [FFMPEG] - libva: /volume1/@appstore/Plex Media Server/lib/dri/iHD_drv_video.so init failed
Feb 15, 2021 21:14:12.153 [0x7f8bbeb7d700] ERROR - [Transcode] [FFMPEG] - libva: /volume1/@appstore/Plex Media Server/lib/dri/iHD_drv_video.so init failed
Feb 15, 2021 21:14:12.331 [0x7f8c29bc1700] ERROR - [Transcode] Error creating directory "/transcode": Permission denied
Feb 15, 2021 21:14:12.332 [0x7f8c29bc1700] ERROR - [Transcode] [FFMPEG] - libva: /volume1/@appstore/Plex Media Server/lib/dri/iHD_drv_video.so init failed
Feb 15, 2021 21:14:12.334 [0x7f8c29bc1700] ERROR - [Transcode] Error creating directory "/transcode": Permission denied
Feb 15, 2021 21:14:12.360 [0x7f8bbe2b3700] ERROR - [Transcoder] [AVHWDeviceContext @ 0x23afc00] libva: /volume1/@appstore/Plex Media Server/lib/dri/iHD_drv_video.so init failed
Feb 15, 2021 21:14:12.524 [0x7f8bbe88f700] ERROR - [Transcoder] [mpegts @ 0x2671900] H.264 bitstream malformed, no startcode found, use the video bitstream filter 'h264_mp4toannexb' to fix it ('-bsf:v h264_mp4toannexb' option with ffmpeg)
Feb 15, 2021 21:14:12.524 [0x7f8c0940d700] ERROR - [Transcoder] av_interleaved_write_frame(): Invalid data found when processing input
Feb 15, 2021 21:14:12.571 [0x7f8bbdcd7700] ERROR - [FFMPEG] - libva: /volume1/@appstore/Plex Media Server/lib/dri/iHD_drv_video.so init failed
Feb 15, 2021 21:14:12.572 [0x7f8bbdcd7700] ERROR - Error creating directory "/transcode": Permission denied
Feb 15, 2021 21:14:12.612 [0x7f8c286f0700] ERROR - [Transcoder] [AVHWDeviceContext @ 0x129b980] libva: /volume1/@appstore/Plex Media Server/lib/dri/iHD_drv_video.so init failed

Any suggestions: I really don’t want to reboot everytime I pause a movie…

Logs please?

Adding the VaapiDriver Attribute in the preferences.xml is stated as workaround for v<1.21 and the Permission are set plex:users rw:r:r for /volume1/Plex/Library and all Subdirs/Files.
The File is not damaged: it works fine until I pause it and the transcoder crashes. It’s reproducable with other files as well.

Hi, this is the log from start of server. But this time there was no crash: only the errors in the logs. I was tinkering quite a while yesterday:

  1. create this /transcode folder: then this error was gone, transcoding artifacts were created in there, but the transcoding itself was degraded to SD
  2. Moving the /transcode folder to the share where plex is located /volume1/Plex/transcode: still degraded to SD
  3. Removed this folder again: transcoding works, but again crashing after pausing
  4. after that I assumed that the transcording artifacts are in memory if the path is not found: so I created a ramdisk to avoid the degragation and used this for the transcoding-tmp

Since then I was not able to reproduce the error: can you confirm my assumption? And what are those errors in the logs: it seems hw-transcoding is still working?

Feb 16, 2021 08:29:40.346 [0x7ff6b8579700] INFO - AutoUpdate: no updates available
Feb 16, 2021 08:29:41.263 [0x7ff6b911f700] WARN - QueryParser: Invalid field 'contentDirectoryID' found, ignoring.
Feb 16, 2021 08:29:41.526 [0x7ff6b911f700] WARN - QueryParser: Invalid field 'contentDirectoryID' found, ignoring.
Feb 16, 2021 08:29:41.752 [0x7ff6b911f700] WARN - QueryParser: Invalid field 'contentDirectoryID' found, ignoring.
Feb 16, 2021 08:29:42.016 [0x7ff6b911f700] WARN - QueryParser: Invalid field 'contentDirectoryID' found, ignoring.
Feb 16, 2021 08:29:42.809 [0x7ff6b911f700] WARN - SLOW QUERY: It took 350.000000 ms to retrieve 35 items.
Feb 16, 2021 08:29:43.079 [0x7ff6ba5a1700] WARN - Held transaction for too long (../Statistics/StatisticsManager.cpp:245): 0.130000 seconds
Feb 16, 2021 08:29:44.280 [0x7ff6bb159700] WARN - QueryParser: Invalid field 'contentDirectoryID' found, ignoring.
Feb 16, 2021 08:29:44.290 [0x7ff6bb159700] WARN - QueryParser: Invalid field 'contentDirectoryID' found, ignoring.
Feb 16, 2021 08:29:44.306 [0x7ff6bb159700] WARN - QueryParser: Invalid field 'contentDirectoryID' found, ignoring.
Feb 16, 2021 08:29:44.336 [0x7ff6bb159700] WARN - QueryParser: Invalid field 'contentDirectoryID' found, ignoring.
Feb 16, 2021 08:29:44.489 [0x7ff66bfff700] WARN - QueryParser: Invalid field 'contentDirectoryID' found, ignoring.
Feb 16, 2021 08:29:44.503 [0x7ff66bfff700] WARN - QueryParser: Invalid field 'contentDirectoryID' found, ignoring.
Feb 16, 2021 08:29:44.531 [0x7ff66bfff700] WARN - QueryParser: Invalid field 'contentDirectoryID' found, ignoring.
Feb 16, 2021 08:29:44.566 [0x7ff66bfff700] WARN - QueryParser: Invalid field 'contentDirectoryID' found, ignoring.
Feb 16, 2021 08:29:45.162 [0x7ff66bd11700] WARN - QueryParser: Invalid field 'contentDirectoryID' found, ignoring.
Feb 16, 2021 08:29:45.172 [0x7ff66bd11700] WARN - QueryParser: Invalid field 'contentDirectoryID' found, ignoring.
Feb 16, 2021 08:29:45.189 [0x7ff66bd11700] WARN - QueryParser: Invalid field 'contentDirectoryID' found, ignoring.
Feb 16, 2021 08:29:45.215 [0x7ff66bd11700] WARN - QueryParser: Invalid field 'contentDirectoryID' found, ignoring.
Feb 16, 2021 08:30:01.073 [0x7ff6e2c39700] INFO - AutoUpdate: no updates available
Feb 16, 2021 08:30:05.515 [0x7ff66bfff700] INFO - AutoUpdate: no updates available
Feb 16, 2021 08:30:05.590 [0x7ff6e2c39700] WARN - QueryParser: Invalid field 'contentDirectoryID' found, ignoring.
Feb 16, 2021 08:30:05.616 [0x7ff6e2c39700] WARN - QueryParser: Invalid field 'contentDirectoryID' found, ignoring.
Feb 16, 2021 08:30:05.657 [0x7ff6e2c39700] WARN - QueryParser: Invalid field 'contentDirectoryID' found, ignoring.
Feb 16, 2021 08:30:05.693 [0x7ff6e2c39700] WARN - QueryParser: Invalid field 'contentDirectoryID' found, ignoring.
Feb 16, 2021 08:30:06.491 [0x7ff6b8579700] WARN - QueryParser: Invalid field 'contentDirectoryID' found, ignoring.
Feb 16, 2021 08:30:06.516 [0x7ff6b8579700] WARN - QueryParser: Invalid field 'contentDirectoryID' found, ignoring.
Feb 16, 2021 08:30:06.555 [0x7ff6b8579700] WARN - QueryParser: Invalid field 'contentDirectoryID' found, ignoring.
Feb 16, 2021 08:30:06.611 [0x7ff6b8579700] WARN - QueryParser: Invalid field 'contentDirectoryID' found, ignoring.
Feb 16, 2021 08:30:16.000 [0x7ff6b911f700] ERROR - [Transcode] [FFMPEG] - libva: /volume1/@appstore/Plex Media Server/lib/dri/iHD_drv_video.so init failed
Feb 16, 2021 08:30:16.132 [0x7ff6b911f700] ERROR - [Transcode] [FFMPEG] - libva: /volume1/@appstore/Plex Media Server/lib/dri/iHD_drv_video.so init failed
Feb 16, 2021 08:30:17.803 [0x7ff6b8579700] ERROR - [Transcode] [FFMPEG] - libva: /volume1/@appstore/Plex Media Server/lib/dri/iHD_drv_video.so init failed
Feb 16, 2021 08:30:17.967 [0x7ff66bd11700] ERROR - [Transcoder] [AVHWDeviceContext @ 0x16a5c00] libva: /volume1/@appstore/Plex Media Server/lib/dri/iHD_drv_video.so init failed
Feb 16, 2021 08:30:24.820 [0x7ff66bd11700] WARN - SLOW QUERY: It took 370.000000 ms to retrieve 1 items.
Feb 16, 2021 08:30:24.852 [0x7ff6e1898700] WARN - SLOW QUERY: It took 430.000000 ms to retrieve 6 items.
Feb 16, 2021 08:30:25.035 [0x7ff66bfff700] WARN - SLOW QUERY: It took 640.000000 ms to retrieve 6 items.
Feb 16, 2021 08:41:08.067 [0x7ff6e1898700] ERROR - [Transcode/b6crm5xzokd2udmd9a54nd2w] [FFMPEG] - libva: /volume1/@appstore/Plex Media Server/lib/dri/iHD_drv_video.so init failed
Feb 16, 2021 08:41:08.490 [0x7ff6e0e9e700] ERROR - [Transcoder] [AVHWDeviceContext @ 0x1b51bc0] libva: /volume1/@appstore/Plex Media Server/lib/dri/iHD_drv_video.so init failed
  1. Those are WARNings. You’re seeing new work Engineering is slowly fielding into the product. You may ignore “QueryParser” messages.

  2. I can’t tell what is happening here without seeing the MDE output (DEBUG logging level would be required) but if you have HW transcoding for H.264 which is working then I would suspect you are attempting to HW transcode a HEVC video in hardware on a CPU which can’t handle it (e.g. J1800 / J1900 / J3355 level CPUs ).

  3. This error is the transcoder verifying the CPU’s capability. It tries, sees it cannot and adapts. It’s not really an error even though it’s reported as one. If you want to consider it an error – then the error is you’re curating media which your hardware cannot play :slight_smile:

Feb 16, 2021 08:41:08.067 [0x7ff6e1898700] ERROR - [Transcode/b6crm5xzokd2udmd9a54nd2w] [FFMPEG] - libva: /volume1/@appstore/Plex Media Server/lib/dri/iHD_drv_video.so init failed
Feb 16, 2021 08:41:08.490 [0x7ff6e0e9e700] ERROR - [Transcoder] [AVHWDeviceContext @ 0x1b51bc0] libva: /volume1/@appstore/Plex Media Server/lib/dri/iHD_drv_video.so init failed

Ok, I only was considering the ERROR Statements in the log, the rest is for completeness. And yes: the videos are HEVC.

Screenshot 2021-02-16 215604

Still this does not explain why I can play them, CPU around 10% thus assuming HW transcoding works. Then I pause the video, wait a few minutes and it stops working and will not work again until I reboot the machine. CPU is btw an Intel Celeron N3150 quad-core.

If I just deactivate the HW-Transcoding, it also works, but very slow with CPU at 100%: which seems to be quite logical…

As I already mentioned, moving the transcoder-tmp to a ramdrive seems to mitigate the issue. The ERRORS in the logs are still shown, but it seems plex finds a workaround. I just want to understand whats going on there and why it seems to work with the ramdrive as transcoding-tmp.

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