1.29.0 1.27.0 IPTV does not consistently connect. Mediaportal client times out before Tv Server establishes timeshifting? (1 Viewer)

doskabouter

Development Group
  • Team MediaPortal
  • September 27, 2009
    4,030
    2,265
    Nuenen
    Home Country
    Netherlands Netherlands
    Country flag
    well 2 providers*2 servers*2vpns is a lot of combinations to check :)
    In the end, I would expect that if headers are wrong that you at least get consistent errors and not one day a 302 and the other a 400.
    As a (very) last resort you could check the headers that vlc sends and mimic them in the tvserver, but that's a pretty long shot.
    intermittent errors are indeed the most annoying to debug and fix.
    To get back at your cache thing: As far as I know there isn't anything cached on disk, only thing cached is possibly something in-memory, but nothing a restart of the tvservice wouldn't cure.

    Partly related question: do you use onlinevideos? That also uses MPUrlSourceSplitter as a download-plugin, and could eliminate at least some (tvservice/tvserver) variables here.
    If so (and if you indeed wish to test it that way) I can create a siteutil where you can speficy url and optional headers to be used. Its a bit more flexible to tweak than tvservice, so that might help?
     

    Gcarr

    MP Donator
  • Premium Supporter
  • August 17, 2014
    186
    66
    Home Country
    United States of America United States of America
    Country flag
    Yeah, it's a lot of stuff to manage... but it was all done with hopes it would help isolate the problem. I think it did help to prove that my installation wasn't corrupted but I don't think it's necessary to bother with the laptop anymore.
    The siteutil thing might be interesting to try. Earlier I was trying to figure out how to use curl to do something like that but that would take a person of my experience a long time to get right.
    I've never really used onlinevideos, tinkered with it a time or two. Can I use it with these urls?
     

    doskabouter

    Development Group
  • Team MediaPortal
  • September 27, 2009
    4,030
    2,265
    Nuenen
    Home Country
    Netherlands Netherlands
    Country flag
    not yet, I first have to prepare a piece where you can fill in your urls and what not. I'll notify you when ready. might take a couple of days though...
     

    Gcarr

    MP Donator
  • Premium Supporter
  • August 17, 2014
    186
    66
    Home Country
    United States of America United States of America
    Country flag
    The provider still says there were no changes to the service, but he did give me a new account to try and the results were the same. I was able to get a debug log of VLC connecting. There were a few slight differences in the headers between MP and VLC. Which reminds me, I could have sworn I had seen a user agent string in the logs that was for "VLC 1.01". I cannot find that in the logs now.
    Code:
    ***MP***
    CurlWorker(): Start, url: 'http://website.xyz:8080/username/password/7955'
    CurlDebug(): CURL message: 'Hostname was NOT found in DNS cache'
    CurlDebug(): CURL message: 'Trying 200.20.20.20...'
    CurlDebug(): CURL message: 'Connected to website.xyz (200.20.20.20) port 8080 (#11068)'
    CurlDebugCallback(): sent HTTP header: 'GET /username/password/7955 HTTP/1.1
    Range: bytes=0-
    Host: website.xyz:8080
    Accept: */*
    '
    CurlDebug(): received HTTP header: 'HTTP/1.1 401 Unauthorized'
    CurlDebug(): error response code: 401
    
    ***VLC***
    main debug: creating access: http://website.xyz:8080/username/password/2228
    main debug:  (path: \\website.xyz:8080\username\password\2228)
    http debug: resolving website.xyz ...
    http debug: outgoing request:
    GET /username/password/2228 HTTP/1.1
    Host: website.xyz:8080
    Accept: */*
    Accept-Language: en_US
    User-Agent: VLC/3.0.16 LibVLC/3.0.16
    Range: bytes=0-
    http debug: incoming response:
    HTTP/1.1 302 Found
    Date: Mon, 15 Aug 2021 19:09:23 GMT
    Content-Type: text/html; charset=UTF-8
    Transfer-Encoding: chunked
    Connection: keep-alive
    access-control-allow-origin: *
    location: http://abc1.website.xyz:8080/username/password/2228?token=GBVdBBF1==
    
    CF-Cache-Status: DYNAMIC
    Report-To: {"endpoints":[{"url":"https:\/\/cloudflare.com\/report\/v3?s=123"}],"group":"grp","max_age":604800}
    NEL: {"success_fraction":0,"report_to":"grp","max_age":604800}
    Server: cloudflare
    CF-RAY: 5555555123-IAD
    alt-svc: h3-27=":443"; ma=86400, h3-28=":443"; ma=86400, h3-29=":443"; ma=86400, h3=":443"; ma=86400
    
    http debug: connection failed
    main debug: no access modules matched
    main debug: redirecting to: http://abc1.website.xyz:8080/username/password/2228?token=GBVdBBF1==
    main debug: creating access: http://abc1.website.xyz:8080/username/password/2228?token=GBVdBBF1==
    main debug:  (path: \\abc1.website.xyz:8080\username\password\2228)
    main debug: looking for access module matching "http": 27 candidates
    http debug: resolving abc1.website.xyz ...
    
    http debug: outgoing request:
    GET /username/password/2228?token=GBVdBBF1== HTTP/1.1
    Host: abc1.website.xyz:8080
    Accept: */*
    Accept-Language: en_US
    User-Agent: VLC/3.0.16 LibVLC/3.0.16
    Range: bytes=0-
    
    http debug: incoming response:
    HTTP/1.1 200 OK
    Server: nginx
    Date: Mon, 16 Aug 2021 21:09:31 GMT
    Content-Type: video/mp2t
    Connection: close
    Access-Control-Allow-Origin: *
     
    Last edited:

    doskabouter

    Development Group
  • Team MediaPortal
  • September 27, 2009
    4,030
    2,265
    Nuenen
    Home Country
    Netherlands Netherlands
    Country flag
    Hm, it could indeed be the missing useragent causing the problems.
    You should be able to specify that in the tvservice somehow.

    Can and would you pm me the full urls so I can do some small tests?
    Way easier then programming the lot, publish it in onlinevideos and explain to you how you should test... (I'm going to do that anyway, but takes a bit more time)
     

    Gcarr

    MP Donator
  • Premium Supporter
  • August 17, 2014
    186
    66
    Home Country
    United States of America United States of America
    Country flag
    Hm, it could indeed be the missing useragent causing the problems.
    You should be able to specify that in the tvservice somehow.
    Omigod, that was it! :LOL: I had no idea but, there was a setting in the plugin for this. Apparently I'll need to specify that when I import playlists in the future. Weird that I was "Unauthorized" for not specifying a user agent though.

    I do distinctly remember seeing the VLC 1version 1 user agent in the logs because it struck me as odd since that version was so old. I'm pretty sure I didn't accidentally change the user agent for every channel but I don't know how it could have changed itself either.

    Anyway, for future reference In the Plugin, go to the database editor tab. Then in the HTTP section you'll see option to enter the user agent.

    And thank you for hanging in there and helping me with this. I never would have figured this out on my own. :)

    Range: bytes=0-
    User-Agent: VLC/3.0.16 LibVLC/3.0.16
    Host: website.xyz:8080
    Accept: /
     

    Gcarr

    MP Donator
  • Premium Supporter
  • August 17, 2014
    186
    66
    Home Country
    United States of America United States of America
    Country flag
    @doskabouter Turns out there is one more issue, I think this was the probably original problem since this causes the same error I reported in the first post (unknown error - http 400) and the other problem we fixed yesterday (http 401 - unauthorized) must have happened somewhere along the line somehow. But, the good news is, I think I found a pattern to this problem. It seems that if you change the MP version, you have to follow up with an installation of the MediaPortalUrlSourceSplitter plugin. Doesn't matter which version, you can reinstall the same one. Then everything works good again. Here's the summary of the testing I performed.

    Yesterday after adding user agent - ver 1.26 with 2.2.22 works fine (not sure what order I did this in)
    Today upgraded to ver 1.29pre with 2.2.25 failed with http 400 error (not sure what order I did this in)
    downgraded to ver 1.26 with 2.2.22 works fine (not sure what order I did this in)
    Upgrade to 2.2.25 works fine
    upgrade to 1.27 = 400 error
    downgrade to 1.26 = 400 error
    downgrade to 2.2.22 works fine
    upgrade to 1.27 = 400 error
    downgrade to 1.26 = 400 error
    reinstall 2.2.22 works fine
    upgrade to 1.27 = 400 error
    reinstall 2.2.22 works fine
    upgrade to 1.28 = 400 error
    upgrade to 2.2.23 works fine
    upgrade to 1.29pre 400 error
    upgrade to 2.2.25 works fine
     

    doskabouter

    Development Group
  • Team MediaPortal
  • September 27, 2009
    4,030
    2,265
    Nuenen
    Home Country
    Netherlands Netherlands
    Country flag
    That sounds completely plausible, that MPIPTV plugin (which comes with official TVServer installation) is always used after an upgrade, despite MPUrlSourceSplitter being installed and used in the original version.
    I'm going to do some tests to see if I can replicate that and possibly fix it
     

    Gcarr

    MP Donator
  • Premium Supporter
  • August 17, 2014
    186
    66
    Home Country
    United States of America United States of America
    Country flag
    Ah that makes sense now. Let me know if you need some testing.
     

    doskabouter

    Development Group
  • Team MediaPortal
  • September 27, 2009
    4,030
    2,265
    Nuenen
    Home Country
    Netherlands Netherlands
    Country flag
    Just did an update of my tvserver from 1.28 and 1.29 and ideed, it's forgotten that is uses mpurlsourcesplitter...
    Have to fix that quickly to keep the WAF ok

    Edit: an install of MPUrlSourceSplitter fixes it indeed. I'm going to investigate what happens exactly and try to fix it for the next release of Mediaportal
     

    Users who are viewing this thread

    Similar threads

    P.S. - Strangely, the TV Server my single seat setup (1.27 on a modest machine running Windows 10 Pro x64) is working from my office machine MP client. Same exact network, firewall, Defender settings. It's a slightly older version of Win 10 though - I haven't updated to 20Hx on it yet. Maybe I shouldn't (or maybe I should image it...
    P.S. - Strangely, the TV Server my single seat setup (1.27 on a modest machine running Windows 10 Pro x64) is working from my...
    Let me start by asking if anyone has TV Server running PROPERLY on a Windows 10 machine, and if so are you using RTSP or UNC share...
    Replies
    9
    Views
    775
    We'll, again I have posted a problem then found the solution myself :whistle: I incorrectly used "Multi seat setup: use UNC paths" when I was setting up initially and having some trouble with paths. I had clicked help for that setting before I tried using it, but many of the help links in the config utility are broken. Today I...
    We'll, again I have posted a problem then found the solution myself :whistle: I incorrectly used "Multi seat setup: use UNC paths"...
    I've been a MP1 user for a very long time. I had been using Argus for OTA ATSC recording and viewing which has been flawless...
    Replies
    1
    Views
    2K
    Well it's been a couple of days and we've had no more unable to play errors .
    Well it's been a couple of days and we've had no more unable to play errors .
    I've just upgraded the motherboard, CPU, ram, boot drives and PSU in my TV Server (always on), and am now having intermittent...
    Replies
    8
    Views
    986
    I'm bad with TV-stuff. IMaybe @morpheus_xx has an idea. After that endless following errors:
    I'm bad with TV-stuff. IMaybe @morpheus_xx has an idea. After that endless following errors:
    Before you create this bug report: Make sure that your system (Windows, codecs and drivers) is up to date, matching the...
    Replies
    1
    Views
    479
    Good afternoon. I realized I never got back to posting the solution I found. Basically, I think I broke this on my own. I had made some registry changes to attempt to increase the video quality, which ended up not being supported by Kodi. Attached is a screenshot of what my final (working) settings are, just in case anyone else...
    Good afternoon. I realized I never got back to posting the solution I found. Basically, I think I broke this on my own. I had...
    Good morning. Back a few months ago, I replaced my original HTPC with updated hardware. I have a few Hauppauge ATSC tuners I'm...
    Replies
    2
    Views
    977
    Top Bottom