Jump to content

Nginx http/2 with Kodi


banderson1311

Recommended Posts

banderson1311

I am seeing this same issue using Emby for Kodi on the Firestick.  I am using direct paths playback and seeing it freeze every 30-60 seconds on multiple firesticks.  I confirmed that playback was fine using the Emby app on my phone.  This started within the last few days (I believe it worked with no issues on Friday).  I am attaching both the Kodi and Emby logs in case that helps.  Let me know if there's anything else I should try.

embyserver.txt kodi.log

Link to comment
Share on other sites

quickmic

First, issue:

failed to load addon settings from special://profile/addon_data/plugin.video.emby/settings.xml

 

Seems emby for kodi settings are corrupted -> special://profile/addon_data/plugin.video.emby/settings.xml

This can happen on power cuts. Do you have a backup of kodi/userdata/addon_data/plugin.video.emby/settings.xml ? Can you restore it?

If not, I'm afraid you have to reset your emby for kodi settings.

Edited by quickmic
Link to comment
Share on other sites

banderson1311

Thanks.  I'll take a look at the settings.  I'll also check the logs on the other devices that were giving me similar behavior to see if the same error is present there.

  • Like 1
Link to comment
Share on other sites

banderson1311

I restored a backup of the configuration file and resolved that issue.  Interestingly I was unable to reproduce the random stopping today on each of the different devices where this was occurring yesterday.  I'm not sure what changed.  I'll continue monitoring and if I notice anything will get an updated log.  Thanks for your help.

Link to comment
Share on other sites

Samuel77

Hello, sorry for my delayed response. I have attached the embycon debug log below. Please note I'm still having the random stopping when watching something on "HTTPS" Port 443. It's happening both on embycon and also on emby android app ONLY when I use "HTTPS". No issues whatsoever if I use "HTTP". The following issue only started happening since the new emby server update (4.5-4.5.2 ). On old emby server (4.3.1) I had no issues direct streaming/direct playing with the HTTPS protocol. Hope you can figure out what's causing this issue. Thank you.

kodi.log

Link to comment
Share on other sites

quickmic

@Luke

Propably it has something todo with HTTP/2 SSL error log msg here:

2020-11-11 01:56:54.759 T:12178  NOTICE: EmbyCon.resources.lib.downloadutils|DEBUG|Closing HTTP connection: <httplib.HTTPSConnection instance at 0xb0d026e0>
2020-11-11 01:56:56.087 T:12285   ERROR: CCurlFile::FillBuffer - Failed: Stream error in the HTTP/2 framing layer(92)

 

Edited by quickmic
Link to comment
Share on other sites

quickmic

@TeamB

 

Please check these log records:

2020-11-11 01:56:46.170 T:12178  NOTICE: EmbyCon.resources.lib.play_utils|DEBUG|Sending POST progress started: {'ItemId': u'1368023', 'PlaySessionId': u'a74dcd5b1a1942d88c7a5897a581dd32', 'QueueableMediaTypes': 'Video', 'PlaylistLength': 1, 'MediaSourceId': u'fef2872848c4243295f9586ea6fb7ea2', 'IsMuted': False, 'PositionTicks': 25933420410L, 'IsPaused': False, 'CanSeek': True, 'VolumeLevel': 100, 'PlayMethod': 'DirectStream', 'PlaylistIndex': 0, 'RunTimeTicks': 31150002441L}
2020-11-11 01:56:46.171 T:12178  NOTICE: EmbyCon.resources.lib.downloadutils|DEBUG|downloadUrl
2020-11-11 01:56:46.181 T:12178  NOTICE: EmbyCon.resources.lib.downloadutils|DEBUG|Before: {server}/emby/Sessions/Playing/Progress
2020-11-11 01:56:46.194 T:12178  NOTICE: EmbyCon.resources.lib.downloadutils|DEBUG|After: https://emby.popcorney.xyz:443/emby/Sessions/Playing/Progress

 

Focus here: "'RunTimeTicks': 31150002441L"

and here:

"'PositionTicks': 25933420410L"

That doesn't seem right -> L

 

Edited by quickmic
Link to comment
Share on other sites

banderson1311
6 hours ago, quickmic said:

Please try disable UPNP in kodi.

It was already disabled in Kodi.  I did turn off port forwarding in Emby server which cleared a lot of errors from the Emby log.  Not sure if that would have any correlation to the Kodi issues.  I also tweaked a few settings in Kodi.  I'll keep an eye on this and see if the issue reoccurs.

  • Like 1
Link to comment
Share on other sites

TeamB
9 hours ago, quickmic said:

@TeamB

 

Please check these log records:


2020-11-11 01:56:46.170 T:12178  NOTICE: EmbyCon.resources.lib.play_utils|DEBUG|Sending POST progress started: {'ItemId': u'1368023', 'PlaySessionId': u'a74dcd5b1a1942d88c7a5897a581dd32', 'QueueableMediaTypes': 'Video', 'PlaylistLength': 1, 'MediaSourceId': u'fef2872848c4243295f9586ea6fb7ea2', 'IsMuted': False, 'PositionTicks': 25933420410L, 'IsPaused': False, 'CanSeek': True, 'VolumeLevel': 100, 'PlayMethod': 'DirectStream', 'PlaylistIndex': 0, 'RunTimeTicks': 31150002441L}
2020-11-11 01:56:46.171 T:12178  NOTICE: EmbyCon.resources.lib.downloadutils|DEBUG|downloadUrl
2020-11-11 01:56:46.181 T:12178  NOTICE: EmbyCon.resources.lib.downloadutils|DEBUG|Before: {server}/emby/Sessions/Playing/Progress
2020-11-11 01:56:46.194 T:12178  NOTICE: EmbyCon.resources.lib.downloadutils|DEBUG|After: https://emby.popcorney.xyz:443/emby/Sessions/Playing/Progress

 

Focus here: "'RunTimeTicks': 31150002441L"

and here:

"'PositionTicks': 25933420410L"

That doesn't seem right -> L

 

Its just a python print thing, I don't think it is actually transmitting that

https://stackoverflow.com/questions/17473195/how-to-avoid-the-l-in-python

  • Like 1
Link to comment
Share on other sites

For info, I think I'm having the same issue while streaming from Kodi using the EmbyCon addon. In my case, files always stop at the same exact moment if I leave them playing so it's easy to reproduce. If I just forward the video before a minute laps I can get to the end of the video. 

Last logs I see on Kodi:

2020-11-12 10:39:53.572 T:123145324613632  NOTICE: EmbyCon.resources.lib.play_utils|DEBUG|Sending Progress Update
2020-11-12 10:39:53.573 T:123145324613632  NOTICE: EmbyCon.resources.lib.play_utils|DEBUG|Sending POST progress started: {'ItemId': u'678598', 'PlaySessionId': u'4ac0b364df744c359700da59f2cc4a8e', 'QueueableMediaTypes': 'Video', 'PlaylistLength': 1, 'MediaSourceId': u'd2b931cdc97ccf80245905df1ee48e81', 'IsMuted': False, 'PositionTicks': 1519780120, 'IsPaused': False, 'CanSeek': True, 'VolumeLevel': 100, 'PlayMethod': 'DirectStream', 'PlaylistIndex': 0, 'RunTimeTicks': 14201090087}
2020-11-12 10:39:53.573 T:123145324613632  NOTICE: EmbyCon.resources.lib.downloadutils|DEBUG|downloadUrl
2020-11-12 10:39:53.579 T:123145324613632  NOTICE: EmbyCon.resources.lib.downloadutils|DEBUG|Before: {server}/emby/Sessions/Playing/Progress
2020-11-12 10:39:53.583 T:123145324613632  NOTICE: EmbyCon.resources.lib.downloadutils|DEBUG|After: https://<<hostname>>:443/emby/Sessions/Playing/Progress
2020-11-12 10:39:53.583 T:123145324613632  NOTICE: EmbyCon.resources.lib.downloadutils|DEBUG|Connection: HTTPS, Cert checked
2020-11-12 10:39:53.593 T:123145324613632  NOTICE: EmbyCon.resources.lib.downloadutils|DEBUG|EmbyCon DownloadUtils -> Returning saved UserID: 111111111
2020-11-12 10:39:53.593 T:123145324613632  NOTICE: EmbyCon.resources.lib.downloadutils|DEBUG|EmbyCon DownloadUtils -> Returning saved AccessToken: 111111111
2020-11-12 10:39:53.593 T:123145324613632  NOTICE: EmbyCon.resources.lib.downloadutils|DEBUG|EmbyCon Authentication Header: {'Accept-Charset': 'UTF-8,*', 'X-Emby-Authorization': u'MediaBrowser UserId="111111",Client="Kodi EmbyCon",Device="EmbyCon",DeviceId="402E298D8C844CAFA7622FA4743DA869",Version="1.9.106"', 'Accept-encoding': 'gzip', 'X-MediaBrowser-Token': '1111111'}
2020-11-12 10:39:53.593 T:123145324613632  NOTICE: EmbyCon.resources.lib.downloadutils|DEBUG|HEADERS: {'Accept-Charset': 'UTF-8,*', 'User-Agent': 'EmbyCon-1.9.106', 'X-Emby-Authorization': u'MediaBrowser UserId="1111111",Client="Kodi EmbyCon",Device="EmbyCon",DeviceId="402E298D8C844CAFA7622FA4743DA869",Version="1.9.106"', 'Accept-encoding': 'gzip', 'X-MediaBrowser-Token': '42ccb53c6f7245debdc0f02d54d9ff38'}
2020-11-12 10:39:53.593 T:123145324613632  NOTICE: EmbyCon.resources.lib.downloadutils|DEBUG|Content-Type: application/json
2020-11-12 10:39:53.593 T:123145324613632  NOTICE: EmbyCon.resources.lib.downloadutils|DEBUG|POST DATA: {"ItemId": "678598", "PlaySessionId": "4ac0b364df744c359700da59f2cc4a8e", "QueueableMediaTypes": "Video", "PlaylistLength": 1, "MediaSourceId": "d2b931cdc97ccf80245905df1ee48e81", "IsMuted": false, "PositionTicks": 1519780120, "IsPaused": false, "CanSeek": true, "VolumeLevel": 100, "PlayMethod": "DirectStream", "PlaylistIndex": 0, "RunTimeTicks": 14201090087}
2020-11-12 10:39:53.694 T:123145324613632  NOTICE: EmbyCon.resources.lib.downloadutils|DEBUG|HTTP response: 204 No Content
2020-11-12 10:39:53.694 T:123145324613632  NOTICE: EmbyCon.resources.lib.downloadutils|DEBUG|GET URL HEADERS: [('content-length', '0'), ('access-control-allow-methods', 'GET, POST, PUT, DELETE, PATCH, OPTIONS'), ('strict-transport-security', 'max-age=31536000'), ('server', 'nginx/1.19.3'), ('connection', 'keep-alive'), ('date', 'Thu, 12 Nov 2020 09:39:53 GMT'), ('access-control-allow-origin', '*'), ('access-control-allow-headers', 'Accept, Accept-Language, Authorization, Cache-Control, Content-Disposition, Content-Encoding, Content-Language, Content-Length, Content-MD5, Content-Range, Content-Type, Date, Host, If-Match, If-Modified-Since, If-None-Match, If-Unmodified-Since, Origin, OriginToken, Pragma, Range, Slug, Transfer-Encoding, Want-Digest, X-MediaBrowser-Token, X-Emby-Token, X-Emby-Client, X-Emby-Client-Version, X-Emby-Device-Id, X-Emby-Device-Name, X-Emby-Authorization')]
2020-11-12 10:39:53.694 T:123145324613632  NOTICE: EmbyCon.resources.lib.downloadutils|DEBUG|Closing HTTP connection: <httplib.HTTPSConnection instance at 0x60000adbf9a0>
2020-11-12 10:39:53.696 T:123145324613632  NOTICE: EmbyCon.resources.lib.tracking|INFO|timing_data|download_url|1605173993.57|1605173993.7|{server}/emby/Sessions/Playing/Progress
2020-11-12 10:39:57.706 T:123145310584832   ERROR: CCurlFile::FillBuffer - Failed: Stream error in the HTTP/2 framing layer(92)

 

Edited by Kilian
Link to comment
Share on other sites

  • 1 month later...
4 hours ago, rodainas said:

This happens to me, with embycon and embycon beta, random interruptions, server on https port 443, am using kodi leia 18.9 

Hi there, let's look at an example. Please attach the information requested in how to report a problem. Thanks !

Link to comment
Share on other sites

rodainas

Here it is @Luke

Problem: Playback randomly interrumpted using embycon/emby for Kodi on AndroidTV/Firetv OS.

Tested on Kodi 18.9 Leia on a Firestick 4K.

The logs are from embycon from stable repository. 

But just FYI the same thing happens with Emby for Kodi (stable and beta, and version 5.0.0) and embycon (beta), also happens on Nvidia Shield.

On Kodi Log: interruption ocurred on 9:15

On Emby Server Log: interruption occured at 3:15 (Same event showed on Kodi Log, but server is on another time zone).

Saw a similar problem on this topic the user reported that the admin had to do an emby server downgrade and the problem stopped EmbyCon Streams stoping during watching (randomly) - Kodi - Emby Community 

Thank you.

embyserver.txt kodi.log

Edited by rodainas
Link to comment
Share on other sites

First of all there's no http2 being used here, at least not at the emby server level. Maybe that's happening at your reverse proxy level, if you're running one?

Secondly, there's no obvious problem either. Are you running a reverse proxy? Try disabling http2 there and see if it helps.

  • Thanks 1
Link to comment
Share on other sites

rodainas

Yes I use nginx, removed http2 but the problem persisted, so I edited other options on the config file, now Kodi is playing flawlessly. Thanks for pointing me in the right direction.

Edited by rodainas
Link to comment
Share on other sites

quickmic
18 hours ago, rodainas said:

Yes I use nginx, removed http2 but the problem persisted, so I edited other options on the config file, now Kodi is playing flawlessly. Thanks for pointing me in the right direction.

Can you please explain, what you have changed? I got similar bug reports with cloudflare in proxy mode.

 

btw, I'm using an Apache proxy and never experience such issues.

 

Edited by quickmic
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...