PMS Packaging 07-2022 - Forum Preview & Testing.
The purpose of this preview is to confirm the changes presented below work under all known conditions.
After initial testing with AMD64 CPUs, all DEB packages will be built and tested.
-
Confirm CPU detection logic:
a. Continues correct operation for all Intel CPUs, Sandy Bridge through TigerLake
b. Properly detects newer variable-length CPU naming starting with the AlderLake processor family.
c No improper selection of Beignet/OpenCL on CometLake and above Processors.
-
Confirm package signing key automatically upgrades to GPG signing and
works successfully after upgrading on Ubuntu 20.04+ and Debian 10.0+
Changed in this update:
-
CPU detection logic updated:
a. Intel CPU identification parsing update to correctly identify newer CPUs which use variable length identification string.
b. Intel N and G series CPUs (series 5-8) now identified correctly.
-
Plex signing key updated to support gpg keyrings for Ubuntu 20+ / Debian 10+
a. Packaging will automatically upgrade existing repository definition
b. Packaging will ensure Plex signing key always current (self updating)
-
Internal changes to significantly reduce use of subprocesses. (80%)
-
Apt βpurgeβ support enabled. Purging will remove default package correctly.
Metadata stored in alternate locations will not be touched.
Build 2 (10-Jul-2022)
Fixes:
- CPU identification logic failed with some (12th Gen) CPUs - Fixed.
- Intel N and G CPU identification logic - rewritten to use new mechanism.
- Minor adjustments to shell variable processing (clean up)
βBuild redactedβ
Final build - Submitted to QA:
2 Likes
I installed the deb, followed the instructions to manually install all the Intel packages and then ran the installer again and it looks like it confirms everything correctly. Turned on HDR tone mapping and HW looks like itβs still working. Is it not feasible for the install script to handle downloading and installing those intel packages for the user, though?
But with tone mapping enabled, the transcode speed reported by Tautulli is like fully halved. Is that normal?
@BinaryJay
No, itβs not possible.
If you watch when you run updates, apt will assert a lock file.
( have you seen the messages about waiting for pid xxxxx ?)
It is for this reason I cannot install another package while PMS itself is being installed by apt.
I cannot speak to Tautulli.
My focus here is solely the packaging. PMS issues / 3rd party issues are outside my focus.
May I ask your HW, OS, configuration? Iβm curious what the host environment is so I can keep track of what remains to be confirmed.
@ChuckPa
22.04 (KVM in Proxmox, iGPU passed through), i5-7500
My question wasnβt so much about Tautulli but of the expected performance impact of enabling HDR tone mapping on QuickSync. I did not expect transcoding performance to be impacted so much. Plex is reporting HW for both decode and encode.
Jay,
When hardware tone mapping is enabled, there is an added load on the CPUβs internal databus.
There are PCI links between the QSV ASIC and the GPU (which does the tone mapping).
The HW transcode + tone mapping process involves:
- Read frame from file
- QSV HW decode the input frame to raw video
- send the raw frame to the GPU
- Allow OpenCL-Beignet / Intel Compute Runtime/Intel OpenCL to process the frame
- Send the completed frame back to the QSV ASIC for output encoding.
- Multiplex audio & video β Send to device
Compare this with regular HW transcoding
- Read frame from file
- Point QSV ASIC at the input buffer and invoke transcode. (decode + encode in one operation)
- Multiplex output audio (still in the same location) with audio β Send to device.
If you look at the logs, youβll see a lot of βZero Copyβ operations.
These are where the data is operated on in the same buffer (no copying to a new buffer)
When tone mapping, the simple load of pushing the data to the GPU and back is what we see as βdecreased performanceβ.
As example,
- Intel i7-7700 can HW transcode about 600 Mbps
- Same Intel i7-7700 can HW transcode + tonemap about 400 Mbps
(Reference: My QNAP TVS-1282 i7-7700)
If this is what youβre seeing in Tautulli then itβs perfectly understandable.
Tonemapping does exact a price.
As long as youβre transcoding better than 1:1, youβre good.
Typically, I see 4:1 performance (I can run 4 streams with ease)
To the point of this thread,
How well did this package install for you?
Being in a container is detected and skips 99% of the logic.
Package installed fine with no problems and nothing unexpected. Detected everything I didnβt have during first run, and then detected everything was installed and correct afterwards on the second run. Itβs not running in a container, itβs in a virtual machine (so it shouldnβt matter as far as youβre concerned).
Do you have the file /tmp/plexinstaller.log please?
Thank you. That looks great.
Can you confirm the package signing key installed correctly ?
Yes, apt no longer emits the warning about the plex repo.
Excellent. Thank you for confirming.
try to install
sudo dpkg -i pms-packaging-preview-build-1-amd64.deb
Selecting previously unselected package plexmediaserver.
(Reading database β¦ 178316 files and directories currently installed.)
Preparing to unpack pms-packaging-preview-build-1-amd64.deb β¦
PlexMediaServer install: Pre-installation Validation.
dpkg: error processing archive pms-packaging-preview-build-1-amd64.deb (βinstall):
new plexmediaserver package pre-installation script subprocess returned error exit status 1
Errors were encountered while processing:
pms-packaging-preview-build-1-amd64.deb
Ubuntu Desktop 22.04
Intel i5-12500
@OneNightEntertainment
Would you mind breaking open the package and running just the preinstall script to see where itβs failing for you?
- create a subdirectory and cd into it
- copy / move the DEB file into the subdir
ar x name-of-file.deb
tar xf control.tar.gz
Now youβll see the preinstall script
run that with sudo .
It will print errors / give console output .
check the status return echo $? when it finishes.
~/Downloads$ sudo ./preinst
PlexMediaServer install: Pre-installation Validation.
/Downloads$ echo $?
1
I got this
Would you please now edit the preinstall and add -x to bash?
#!/bin/bash -x
Look down a few lines and see if you have set -e.
If so, remove that line.
Now save and exit the editor.
Give it a spin and see where it stops
Would you please run this script for me and show me the output ?
[chuck@lizum ~.2004]$ cat cpusku
#!/bin/bash
# find Intel CPUSKU anywhere in model name
Processor="$(cat /proc/cpuinfo | grep 'model name' | uniq)"
Index=1
CPUSKU=""
# Find the xx-yyyyy CPUSKU
while [ $Index -lt 8 ] && [ "$CPUSKU" = "" ];
do
CPUCode="$(echo $Processor | awk \{print\$$Index\} | grep \\-)"
[ "$CPUCode" != "" ] && CPUSKU="$CPUCode"
Index=$((Index + 1))
done
# Trim off all pre-dash and alpha characters
CPUSKU="${CPUSKU//[^-]*-/}"
CPUSKU="${CPUSKU//[A-Z]/}"
[ "$CPUSKU" = "" ] && CPUSKU=0
echo CPUSKU=\"$CPUSKU\"
I found the problem. This sample script should work correctly.