Let me add: the former is intended working and thus not an issue, the latter is a plex bug.
TeknoJunky via Plex Forum plex@discoursemail.com ezt írta (időpont: 2019. aug. 6., Ke 16:03):
Let me add: the former is intended working and thus not an issue, the latter is a plex bug.
TeknoJunky via Plex Forum plex@discoursemail.com ezt írta (időpont: 2019. aug. 6., Ke 16:03):
The work around I used is to reset the nvidia GPU with this command:
lsof /dev/nvidia* | awk ‘{print $2}’ | xargs -I {} kill {} | nvidia-smi -pm 1
This will reset the nvidia gpu (and kills all the process that uses the nvidia GPU!) and enables the persistence mode of the GPU. I put this command in an @hourly crontab on my ubuntu server so it resets the GPU every hour.
Install lsof if needed.
Yes but it also cuts the transcoding when you actually watch a movie.
This is my script to detect and kill bad Plex process 
#!/bin/bash
TOKILL=""
CPT_TRANSCODE=-1
CPT_SERVER=-1
for ELEMENT in $(lsof /dev/nvidia0 | awk '{print $1 "@" $2}')
do
IFS='@' read -r -a array <<< "$ELEMENT"
if [ "${array[0]}" != "Xorg" ] && [ "${array[0]}" != "ffmpeg" ]
then
if [ "${array[0]}" = "Plex\x20T" ]
then
((CPT_TRANSCODE++))
fi
if [ "${array[0]}" = "Plex\x20M" ]
then
((CPT_SERVER++))
TOKILL="${array[1]}"
fi
fi
done
if [ $CPT_SERVER -gt 0 ] && [ $CPT_TRANSCODE -lt 1 ] && [ "$1" != "test" ]
then
kill -9 "$TOKILL"
fi
if [ "$1" == "test" ]
then
echo "$TOKILL"
fi
̶E̶U̶R̶E̶K̶A̶ ̶!̶
̶T̶h̶e̶ ̶b̶u̶g̶ ̶s̶e̶e̶m̶s̶ ̶t̶o̶ ̶b̶e̶ ̶r̶e̶s̶o̶l̶v̶e̶d̶ ̶s̶i̶n̶c̶e̶ ̶1̶.̶1̶6̶.̶5̶.̶1̶4̶8̶8̶ ̶u̶p̶d̶a̶t̶e̶.̶
̶̶T̶r̶y̶ ̶a̶n̶d̶ ̶t̶e̶s̶t̶ ̶t̶o̶ ̶v̶a̶l̶i̶d̶a̶t̶e̶,̶ ̶b̶u̶t̶ ̶i̶t̶ ̶s̶e̶e̶m̶s̶ ̶t̶o̶ ̶b̶e̶ ̶o̶k̶ ̶f̶o̶r̶ ̶m̶e̶ ̶;̶)̶
PS : In fact … no … bug still here, sorry for the bad news 
What is a bit more worrisome for me is that even the 1.16.7.1573 alpha has no fix for this issue.
Even though there is stated that they updated to the current upstream ffmpeg.
So no fix on the horizon for the next couple of weeks… (even months?)
@ChuckPa have you got some news about transcoder (ffmpeg) upgrade ?
This is still something I plan to continue looking into after we resolve some Windows issues with the new Transcoder Preview build.
There is an ETA for new transcoder ? (not exact day, but few weeks ? few months ?)
Thanks !
I Hope this problème (s-state) will be fix… it’s a very critical issue.
Why doesnt create Docker images of the New transcoder ?
Can you please try these steps to install the preview in your existing PMS-docker container Docker Install Steps
Update with your methode, server is 1.16.7.1597-a6e223f7f
Bug still here 
Do you want some logs ?
No need for logs. I will be shifting my focus back to this issue tomorrow 
So after digging into this issue, we found that it’s not new behaviour, and has existed since we first added nvdec support on Linux.
Currently, when a transcode is requested, the Plex Media Server process probes which hardware transcoding APIs are supported on the system by attempting to open a decoder or encoder for the requested codec. Once we know that it is supported we then spawn the Plex Transcoder with the appropriate arguments.
We’ve found that in some cases, after opening and closing the NVENC test session, the device remains in its higher-power state until the process has exited, rather than returning to its low-power state after the session is closed.
We are still investigating a solution, but I wanted to provide a bit of a technical update.
Thanks for answers @chrisallen 
It’s a bit disturbing to see that we are not progressing (since 2014) but ok 
For exemple, in others streaming solution (it works very well, this issue is not present), ffmpeg command is :
/usr/local/bin/ffmpeg -ss 00:16:18.000 -c:v hevc_cuvid -resize 1920x800 -i file:"/mountedVolumes/Films/toto.mkv" -map_metadata -1 -map_chapters -1 -threads 0 -map 0:1 -map 0:0 -map -0:s -codec:v:0 h264_nvenc -pix_fmt yuv420p -preset default -b:v 10346752 -maxrate 10346752 -bufsize 20693504 -profile:v high -force_key_frames:0 "expr:gte(t,978+n_forced*3)" -copyts -vsync -1 -codec:a:0 aac -strict experimental -ac 2 -ab 384000 -af "volume=2" -f segment -max_delay 5000000 -avoid_negative_ts disabled -start_at_zero -segment_time 3 -individual_header_trailer 0 -segment_format mpegts -segment_list_type m3u8 -segment_start_number 326 -segment_list "/transcode/transcodes/dee49b699e103f4a3b9c35187022d24a.m3u8" -y "/transcode/transcodes/dee49b699e103f4a3b9c35187022d24a%d.ts"
With ffmpeg version 4.2.1 Copyright (c) 2000-2019 the FFmpeg developers
Thought I’d add an observation when killing the Plex\x20M processes.
If I have a stream going that is transcoding, remove the ‘transcode throttle buffer’, and let the teanscode finish while the player continues to stream. Now the 20T process is gone and the 20M process remains. However if I kill the 20M process, plex stops serving the now transcoded media to the player.
Still no idea to fix the bug ? 
We have reached out to Nvidia regarding this issue since Plex Media Server is using the API as per the spec, but only sometimes does the card return to P8 state after the probing attempting to open a decoder or encoder for the requested codec.
The bug is present just sometimes on your side? In my case it is present in 100% of cases
Same here. I see this bug 100% of the time.