Hardware transcode does not work with tone mapping

Server Version#: 1.25.5.5492
Player Version#: Webplayer 4.69.1

I just setup a new plex server on an Intel Core i3-8300 and hardware transcoding works fine as long as I disable HDR tone mapping in the transcode config, but if I enable it hardware transcoding is not used for HDR10 files. As far as I know the Core i3-8300 should be able to transcode HDR10 in hardware. Is there any way for me to debug this issue?

Can you please provide the DEBUG log files which capture this happening?

Also, if you still have /tmp/plexinstaller.log, may I see it as well ?

The plexinstaller.log is already gone, I unfortunately rebooted the server.

Is this the correct log?
Plex Media Server.log.zip (448.5 KB)
The server is currently detecting intros so it may be a little bit cluttered, but I think 21:38:46.860 is the correct timestamp

I found the playback attempt (it took some time)

Feb 12, 2022 21:01:37.123 [0x7f5db32adb38] DEBUG - [Transcode/7176AA82-09F9-4F91-AB6B-1E197C10D385] [FFMPEG] - Format 0x30313050 -> p010le.
Feb 12, 2022 21:01:37.123 [0x7f5db32adb38] DEBUG - [Transcode/7176AA82-09F9-4F91-AB6B-1E197C10D385] [FFMPEG] - Created surface 0.
Feb 12, 2022 21:01:37.123 [0x7f5db32adb38] DEBUG - [Transcode/7176AA82-09F9-4F91-AB6B-1E197C10D385] [FFMPEG] - Direct mapping possible.
Feb 12, 2022 21:01:37.123 [0x7f5db32adb38] DEBUG - [Transcode/7176AA82-09F9-4F91-AB6B-1E197C10D385] TPU: hardware transcoding: final decoder: vaapi, final encoder: vaapi
Feb 12, 2022 21:01:37.123 [0x7f5db3762b38] DEBUG - Statistics: (44F75FE6-D824-4881-82C9-68AE45AB6238) Reporting active playback in state 2 of type 1 (scrobble: 0) for account 1
Feb 12, 2022 21:01:37.124 [0x7f5db32adb38] DEBUG - [Transcode/7176AA82-09F9-4F91-AB6B-1E197C10D385/JobRunner] Job running: EnableExtendedVaFormats='1' FFMPEG_EXTERNAL_LIBS='/var/lib/plexmediaserver/Library/Application\ Support/Plex\ Media\ Server/Codecs/62cc2bc-4226-linux-x86_64/' LIBVA_DRIVERS_PATH='/usr/lib/plexmediaserver/lib/dri' NEOReadDebugKeys='1' X_PLEX_TOKEN='xxxxxxxxxxxxxxxxxxxx' '/usr/lib/plexmediaserver/Plex Transcoder' '-codec:0' 'hevc' '-hwaccel:0' 'vaapi' '-hwaccel_fallback_threshold:0' '10' '-hwaccel_output_format:0' 'vaapi' '-hwaccel_device:0' 'vaapi' '-ss' '551' '-analyzeduration' '20000000' '-probesize' '20000000' '-i' '/media/plexdrive.encrypted/movies/Dune (2021)/Dune.2021.2160p.HMAX.WEB-DL.DDP5.1.Atmos.HDR.H.265-FLUX.mkv' '-filter_complex' '[0:0]hwupload[0];[0]scale_vaapi=w=3840:h=2160:format=p010[1];[1]hwmap=derive_device=opencl[2];[2]tonemap_opencl=tonemap=mobius:format=nv12:m=bt709:p=bt709:r=tv[3];[3]hwmap=derive_device=vaapi:reverse=1[4];[4]hwupload[5]' '-map' '[5]' '-codec:0' 'h264_vaapi' '-b:0' '63180k' '-maxrate:0' '84240k' '-bufsize:0' '168480k' '-r:0' '23.975999999999999' '-force_key_frames:0' 'expr:gte(t,n_forced*1)' '-map' '0:1' '-metadata:s:1' 'language=eng' '-codec:1' 'copy' '-copypriorss:1' '0' '-segment_format' 'mpegts' '-f' 'ssegment' '-individual_header_trailer' '0' '-segment_time' '1' '-segment_start_number' '551' '-segment_copyts' '1' '-segment_time_delta' '0.0625' '-segment_list' 'http://127.0.0.1:32400/video/:/transcode/session/7176AA82-09F9-4F91-AB6B-1E197C10D385/d9e1519f-d321-4423-ae4d-813666a2ca53/manifest?X-Plex-Http-Pipeline=infinite' '-segment_list_type' 'csv' '-segment_list_size' '5' '-segment_list_separate_stream_times' '1' '-segment_list_unfinished' '1' '-max_delay' '5000000' '-avoid_negative_ts' 'disabled' '-map_metadata' '-1' '-map_chapters' '-1' 'media-%05d.ts' '-start_at_zero' '-copyts' '-init_hw_device' 'vaapi=vaapi:' '-filter_hw_device' 'vaapi' '-y' '-nostats' '-loglevel' 'quiet' '-loglevel_plex' 'error' '-progressurl' 'http://127.0.0.1:32400/video/:/transcode/session/7176AA82-09F9-4F91-AB6B-1E197C10D385/d9e1519f-d321-4423-ae4d-813666a2ca53/progress'
Feb 12, 2022 21:01:37.124 [0x7f5db32adb38] DEBUG - [Transcode/7176AA82-09F9-4F91-AB6B-1E197C10D385/JobRunner] Jobs: Starting child process with pid 30757
Feb 12, 2022 21:01:37.126 [0x7f5db748fb38] DEBUG - Completed: [192.168.188.55:64089] 200 GET /:/timeline

It knows it needs to tonemap and is setting up to do so when the transcoder launches.

‘-filter_complex’ ‘[0:0]hwupload[0];[0]scale_vaapi=w=3840:h=2160:format=p010[1];[1]hwmap=derive_device=opencl[2];[2]tonemap_opencl=tonemap=mobius:format=nv12:m=bt709:p=bt709:r=tv[3];[3]hwmap=derive_device=vaapi:reverse=1[4];[4]hwupload[5]’

To run the preinstall (inventory) phase again,

[chuck@lizum ~.2008]$ sudo /var/lib/dpkg/info/plexmediaserver.preinst 
PlexMediaServer install: Pre-installation Validation.
PlexMediaServer install: Pre-installation Validation complete.
[chuck@lizum ~.2009]$  ls -la /tmp/plexinstaller.log 
-rw-r--r-- 1 root root 1020 Feb 13 18:41 /tmp/plexinstaller.log
[chuck@lizum ~.2010]$

Now please get and attach the installer log file.
It will tell us if the OpenCL and Beignet package requirements have been satisfied.

ᨂ cat -p plexinstaller.log
# Plex Media Server installation configuration info:  Mon Feb 14 08:18:27 UTC 2022
Init=0
Systemd=1
Custom=0
LinuxContainer=0
NewInstall=0
HaveOverride=0
OverrideFile=""
PlexUser="plex"
PlexGroup="plex"
VideoGroup="render"
AppSuppDir="/var/lib/plexmediaserver/Library/Application Support"
PlexTempDir="/tmp"
LangEncoding="en_US.UTF-8"
ExistingVersion=12505
HaveHardware=1
HaveTranscoderPref=0
NeedUser=0
NeedGroup=0
NeedVideo=0
Verbose=1
Running=1
Errors=0
Warnings=0
HaveIntel=1
HaveIntelCore=1
HaveIntelXeon=0
Havei915=1
HaveNvidia=0
Processor=Intel(R) Core(TM) i3-8300 CPU @ 3.70GHz
CPUSKU=8300
NeedOpenCL=1
NeedBeignet=1
NeedIntelCompute=0
HaveIntelGmmlib=0
HaveIntelIGCCore=0
HaveIntelIGCOpenCL=0
HaveIntelOpenCL=0
HaveIntelCompute=0
HaveBeignet=1
HaveOpenCL=1
Platform="HP ProDesk 600 G4 SFF"
Processor="Intel(R) Core(TM) i3-8300 CPU @ 3.70GHz"
Distro="Ubuntu 21.10"
Kernel="Linux blackbox 5.13.0-28-generic #31-Ubuntu SMP Thu Jan 13 17:41:06 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux"
Memory="7733 911 6020"

Any further idea @ChuckPa ?

I have one but you’re really not going to like it.

I have seen countless problems with Ubuntu 21.x and hardware transcoding.
The moment folks back down to 20.04.3 things start to work.

In 2 months time, all support for Ubuntu 21.anything will be gone.
Ubuntu 22.04 will be ‘wet behind the ears’ and not yet stable.

My recommendation is to go back to Ubuntu 20.04.3 LTS and then wait for things to settle with Ubuntu 22.04 (at least until after 22.04.1 LTS is released). This provides the most stable platform for you to run on (LTS supported until 2025). You’ll have a proven and stable OS with the solid 8300 CPU

I run an i7-8809 and it’s on 20.04.3 LTS.

I have a little shell script to help you recreate what you now have on 21 if you’d like.

Going out on a limb, hoping I am not being too forward, my primary recommendation is:

  • As you reinstall Ubuntu 20.04.3 LTS, since you likely are going to lose the home directory (?), is to create /home as a freestanding partition.

This is my partition structure. I use XFS for the file system. You’re free to use EXT4 if you wish.

Model: Samsung SSD 970 PRO 1TB (nvme)
Disk /dev/nvme0n1: 1024GB
Sector size (logical/physical): 512B/512B
Partition Table: gpt
Disk Flags: 

Number  Start   End     Size    File system     Name                  Flags
 1      1049kB  524MB   523MB   fat16           EFI System Partition  boot, esp
 2      524MB   132GB   131GB   xfs             root
 3      132GB   196GB   64.0GB  linux-swap(v1)  swap                  swap
 4      196GB   1024GB  829GB   xfs             home

The biggest gain here is:

  • /home can be kept across every reinstall of the OS even when changing to another distro.
  • You copy / save your important data in /home and have it immediately available as you install the new OS. Done right, you copy the files from /home back to where they need to be in /etc.
  • If you use the little tool I have, you let it help you automatically reinstall all your existing packages (except that first Plex install). I can switch distros in about 30 minutes

Is this of any help?

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