Direct play streams that are actively being played get cut off by the "terminate paused sessions" setting

Server Version#:1.18.8.2527
Player Version#:7.29.2.16071

Recently I’ve encountered an issue where the android TV plex app will abruptly terminate a stream that is direct playing on android TV with the help of rcombs (big thanks) I was able to determine that it was related to the value configured under the “terminate sessions paused for longer than” setting.

In my case the value was set to 10 minutes and my stream sessions were consistently be cut out at 11 or so minutes, this behavior only happens on Android TV, and one when the video is being direct played, if the video has subtitles or is being played at a lower quality the server will not forcefully close the session.

03-23 15:51:28.110  i: Fetching [method:GET] https://192.168.0.3:32400/:/timeline?audioStreamID=173910&bufferedTime=31733&duration=1299590&guid=com.plexapp.agents.thetvdb%3A%2F%2F269586%2F2%2F12%3Flang%3Den&key=%2Flibrary%2Fmetadata%2F15669&playbackTime=610205&playQueueItemID=170694&ratingKey=15669&state=playing&time=607239&token=...5HR2&X-Plex-Client-Identifier=fd432632bb45f484-com-plexapp-android&X-Plex-Token=...5HR2
03-23 15:51:28.465  i: [ExoPlayer][EventLogger] loading [617.35, 607.62, window=0, true]
03-23 15:51:28.577  i: [ExoPlayer][EventLogger] loading [617.47, 607.73, window=0, false]
03-23 15:51:28.736  i: [ExoPlayer][EventLogger] loading [617.62, 607.89, window=0, true]
03-23 15:51:28.746  i: [ExoPlayer][EventLogger] loading [617.64, 607.90, window=0, false]
03-23 15:51:31.840  i: [ExoPlayer][EventLogger] loading [620.73, 611.00, window=0, true]
03-23 15:51:31.952  i: [ExoPlayer][EventLogger] loading [620.84, 611.11, window=0, false]
03-23 15:51:35.256  i: [ExoPlayer][EventLogger] loading [624.15, 614.41, window=0, true]
03-23 15:51:35.277  i: [ExoPlayer][EventLogger] loading [624.16, 614.43, window=0, false]
03-23 15:51:36.854  i: [ExoPlayer][EventLogger] loading [625.74, 616.01, window=0, true]
03-23 15:51:37.020  i: [ExoPlayer][EventLogger] loading [625.91, 616.17, window=0, false]
03-23 15:51:38.111  i: [PlaybackTimeBehaviour] Time: 620208 IsStarted: true
03-23 15:51:38.115  i: Fetching [method:GET] https://192.168.0.3:32400/:/timeline?audioStreamID=173910&bufferedTime=33615&duration=1299590&guid=com.plexapp.agents.thetvdb%3A%2F%2F269586%2F2%2F12%3Flang%3Den&key=%2Flibrary%2Fmetadata%2F15669&playbackTime=620209&playQueueItemID=170694&ratingKey=15669&state=playing&time=617073&token=...5HR2&X-Plex-Client-Identifier=fd432632bb45f484-com-plexapp-android&X-Plex-Token=...5HR2
03-23 15:51:41.850  i: [ExoPlayer][EventLogger] loading [630.74, 621.01, window=0, true]
03-23 15:51:41.927  i: [FFmpeg] [ERROR] [tls @ 0xcb384d20] Error in the pull function.

03-23 15:51:41.928  i: [FFmpeg] [WARN] [https @ 0xbaf7f740] Will reconnect at 1121981903 in 0 second(s), error=I/O error.

03-23 15:51:41.973  i: [ExoPlayer][EventLogger] loading [630.86, 621.13, window=0, false]
03-23 15:51:42.168  i: [FFmpeg] [WARN] [https @ 0xbaf7f740] HTTP error 503 Service Unavailable

03-23 15:51:42.183  i: [FFmpeg] [ERROR] [tls @ 0xcb384d20] The specified session has been invalidated for some reason.

03-23 15:51:42.186  i: [FFmpeg] [WARN] [https @ 0xbaf7f740] Will reconnect at 1121981903 in 1 second(s), error=I/O error.

03-23 15:51:43.394  i: [FFmpeg] [WARN] [https @ 0xbaf7f740] HTTP error 503 Service Unavailable

03-23 15:51:43.410  i: [FFmpeg] [ERROR] [tls @ 0xcb384d20] The specified session has been invalidated for some reason.

03-23 15:51:43.411  i: [FFmpeg] [WARN] [https @ 0xbaf7f740] Will reconnect at 1121981903 in 3 second(s), error=I/O error.

03-23 15:51:46.607  i: [FFmpeg] [WARN] [https @ 0xbaf7f740] HTTP error 503 Service Unavailable

03-23 15:51:46.625  i: [FFmpeg] [WARN] [https @ 0xbaf7f740] Will reconnect at 1121981903 in 7 second(s), error=I/O error.

03-23 15:51:46.628  i: [FFmpeg] [ERROR] [tls @ 0xcb384d20] The specified session has been invalidated for some reason.

The time stamp for the error on the client matches the timestamp for the server error:

Mar 23, 2020 15:51:42.268 [16352] WARN - Denying access to direct play of part 20713 due to terminated session

As per the above logs the time for the server to close the session matches up the the time errors were recorded for the session becoming invalid. Upon clearing the “Terminate sessions paused for longer than” setting I was able to direct play media from start to finish on my android TV device as expected which certainly points to that being the issue.

Would love to see a fix for this.

1 Like

Any updates on this issue? This has been happening for the last few weeks. The only solution is disabling the “Terminate Sessions Paused for Longer Than” setting.’

PMS Version 1.18.8.2527
NVidia Shield Client - Direct Play (subtitles usually on) - Tried with/without experimental player on

BigWheel [Plex Employee]
Freezing issue appears to be fixed in an upcoming 7.30 update (I don’t know an exact release date)

1 Like

It’s TRUE, coming soon. Disable the pause termination feature for now on the server.

7.30 is now publicly available. That version should resolve this issue :slight_smile:

1 Like

I thought I was losing my mind over this and was alone.

But it’s good to see that other people have noticed it, and that Plex have already fixed it. Will try the refresh tomorrow, and let you know if it persists or not.

1 Like

I am experiencing the same on the 1.18.9.2571. The release note for 1.18.9.2578 does not seem to address this issue.

It was a client side issue, not a server side problem. :slight_smile:

I experienced this on these three platforms Amazon FireTV 4k stick, NVIDA 2017 Shield, and NVIDIA 2019 Shield Pro. Issue went away yesterday when I disabled termination of paused atreams after 30 minutes. It only occured when watching inside my house where the stream was direct play. My logs also indicate they were appearing paused and getting terminated.

That issue is fixed in v7.30 of the Android app (which covers the Amazon and Nvidia devices you mentioned). Please check which version of the Android app you’re using :slight_smile:

1 Like

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