• Login
  • Register
  • Login Register
    Login
    Username/Email:
    Password:
    Or login with a social network below
  • Forum
  • Website
  • GitHub
  • Status
  • Translation
  • Features
  • Team
  • Rules
  • Help
  • Feeds
User Links
  • Login
  • Register
  • Login Register
    Login
    Username/Email:
    Password:
    Or login with a social network below

    Useful Links Forum Website GitHub Status Translation Features Team Rules Help Feeds
    Jellyfin Forum Development Client Development Kodi Development Jellyfin For Kodi HTTP2/Curl network issues

     
    • 0 Vote(s) - 0 Average

    Jellyfin For Kodi HTTP2/Curl network issues

    Problems with HTTP2 and Curl timeout/keepalive when using Jellyfin For Kodi
    tomstephens89
    Offline

    Junior Member

    Posts: 24
    Threads: 11
    Joined: 2023 Aug
    Reputation: 0
    Country:United Kingdom
    #1
    11 hours ago (This post was last modified: 11 hours ago by tomstephens89. Edited 4 times in total.)
    Hi all,

    For quite some time I have been troubleshooting a gremlin when playback of a video on Kodi using the Jellyfin for Kodi backend in add-on mode will just exit. I narrowed this down to the buffer/cache emptying. This is particularly obvious after several minutes of PAUSE, then a resume. Kodi will not read ahead to fill the cache.

    So after some more research last night I came across a number of posts explaining that HTTP2 support within Kodi, and particularly Curl wasn't great and could cause issues if used.... Well since my Jellyfin instance is behind an Nginx reverse proxy, which is properly configured, with TLS and HTTP2 (Hosted remoteley)... I thought this could be worth digging into to. Turns out HTTP2 can be explicitly disabled in Kodi, and at the same time I came across some parameters that control Curl's connection timeout handling, as well as support for TCP keepalive so I added them into advancedsettings.xml as below.

    <advancedsettings version="1.0">
        <network>
            <disablehttp2>true</disablehttp2>
            <curlkeepaliveinterval>30</curlkeepaliveinterval>
            <curlclienttimeout>10</curlclienttimeout>
            <curllowspeedtime>20</curllowspeedtime>
            <curlretries>2</curlretries>
        </network>
    </advancedsettings>

    As soon as I restarted and continued watching, using player debug to watch the cache loading I could see an immediate difference. It was slammed solid to 100%, even with only the adaptive readfactor set, which it should be. I was able to pause the video for over 5 minutes and come back to a cache which continued to refill on resume rather than empty then exit. I mean don't get me wrong, even without the above, 70% of the time I have no issues playing 4K Remuxes at 70GB, but occasionally, or after a pause, the player just exits, which I have learned is due to the buffer emptying/essentially end of file/nothing left!. But watching the buffer behaviour without the above changes was certainly 'lesser performing' than with them. It did always reach 100%, but it wasn't so aggressive in staying there, flicked around a lot. Whereas as soon as I made the above changes, it loaded and boom its locked there at 100%, didn't move to 99% not a single time.

    Its probably too early to celebrate yet but this crash/exit issue has been plaguing me for 2 years, on LibreELEC and now OSMC, Pi4's Pi5's, the Vero V and 3 different internet connections. I really hope its as simple as this.

    Reference my thread on the Kodi forum here: https://forum.kodi.tv/showthread.php?tid=382629
    « Next Oldest | Next Newest »

    Users browsing this thread: 2 Guest(s)


    • View a Printable Version
    • Subscribe to this thread
    Forum Jump:

    Home · Team · Help · Contact
    © Designed by D&D - Powered by MyBB
    L


    Jellyfin

    The Free Software Media System

    Linear Mode
    Threaded Mode