PVR IPTV Simple Client - 404s

Hi,

I’m trying to use the PVR IPTV Simple Client add-on to stream video but I cannot get it to work.
My IPTV provider seems to redirect from the urls given in their M3U and the OSMC builds do not seem to support this.
In the logs I get a 404, but when I execute wget from the shell I get a 302 with the correct URL.
I have tried this on a Vero, a Rasberry PI 1 and Raspberry PI 2, all with the same results.
Recently I tried the beta of Kodi 17 and this still did not work.
On the Rasperry PI v2 I installed LibreElec last night and everything worked fine, leading me to assume that the curl method used in the OSMC build isn’t correctly handling the redirect.

Can anyone help?

Phil.

Are you saying that using the same version of the same addon this works in libreElec but not in OSMC?

Can you use curl from the CLI to get to the same URLs? Can ypu poat the output of that and a full debug log?

Yes, Kodi 17 on OSMC does not work, but it does on LibreElec with the same version of the plugin.
(It doesn’t work on Kodi 16 either on OSMC)

I’ll get the curl results from both set-ups and the logs tonight.

Ok got it, well almost, I’ve executed wget from the CLI as I’m not sure of the curl syntax.

Working LibreElec debug log:

17:17:23 167657.125000 T:1493169056 DEBUG: PVRManager - OpenLiveStream - opening live stream on channel ‘beIN Sport 13 HD ARB’
17:17:23 167657.125000 T:1493169056 DEBUG: opening live stream on url ‘http:||clientportal.link:8080/live/XXXXXXXXXXX/YYYYYYYYYY/6640.ts’
17:17:23 167657.171875 T:1493169056 DEBUG: CDVDInputStreamPVRManager - Open - playback has started on filename pvr://channels/tv/All channels/pvr.iptvsimple_1106705199.pvr
17:17:23 167657.171875 T:1493169056 DEBUG: CurlFile::Open(0x58ffe758) http:||clientportal.link:8080/live/XXXXXXXXXXX/YYYYYYYYYY/6640.ts
17:17:23 167657.171875 T:1493169056 INFO: easy_aquire - Created session to http:||clientportal.link
17:17:23 167657.187500 T:1803547552 DEBUG: PushCecKeypress - received key b duration 113 (rep:0 size:0)
17:17:23 167657.187500 T:1803547552 DEBUG: PushCecKeypress - ignored key b
17:17:23 167657.296875 T:1803547552 DEBUG: PushCecKeypress - received key b duration 0 (rep:0 size:0)
17:17:23 167657.296875 T:1803547552 DEBUG: PushCecKeypress - added key b
17:17:23 167657.421875 T:1803547552 DEBUG: PushCecKeypress - received key b duration 129 (rep:0 size:1)
17:17:23 167657.421875 T:1803547552 DEBUG: PushCecKeypress - ignored key b
17:17:23 167657.531250 T:1493169056 DEBUG: CCurlFile::Open - effective URL: http:||185.2.83.25:8080//streaming/clients_live.php?username=XXXXXXXXXXX&password=YYYYYYYYYY&stream=6640&extension=ts&hash=3f4d1767bddde90c4503934446259efd&time=1477588653&pid=23172&external_device=&on_demand=0&isp=&bitrate=1419
17:17:23 167657.546875 T:1493169056 DEBUG: CFileCache::Open - opening </streaming/clients_live.php> using cache
17:17:23 167657.546875 T:1493169056 DEBUG: CurlFile::Open(0x34f06c0) http:||185.2.83.25:8080//streaming/clients_live.php?username=XXXXXXXXXXX&password=YYYYYYYYYY&stream=6640&extension=ts&hash=3f4d1767bddde90c4503934446259efd&time=1477588653&pid=23172&external_device=&on_demand=0&isp=&bitrate=1419
17:17:23 167657.546875 T:1493169056 INFO: easy_aquire - Created session to http:||185.2.83.25
17:17:23 167657.609375 T:1493169056 DEBUG: CDVDInputStreamPVRManager::Open - stream opened: http:||clientportal.link:8080/live/XXXXXXXXXXX/YYYYYYYYYY/6640.ts
17:17:23 167657.609375 T:1493169056 NOTICE: Creating Demuxer
17:17:23 167657.609375 T:1873802144 DEBUG: Thread FileCache start, auto delete: false
17:17:23 167657.609375 T:1493169056 DEBUG: Open - probing detected format [mpegts]
17:17:23 167657.625000 T:1493169056 DEBUG: Open - avformat_find_stream_info starting
17:17:24 167657.796875 T:1493169056 DEBUG: Open - av_find_stream_info finished
17:17:24 167657.796875 T:1493169056 INFO: ffmpeg[58FFF3A0]: Input #0, mpegts, http:||clientportal.link:8080/live/XXXXXXXXXXX/YYYYYYYYYY/6640.t’:
17:17:24 167657.796875 T:1493169056 INFO: ffmpeg[58FFF3A0]: Duration: N/A, start: 1923.564800, bitrate: N/A
17:17:24 167657.796875 T:1493169056 INFO: ffmpeg[58FFF3A0]: Program 1
17:17:24 167657.796875 T:1493169056 INFO: ffmpeg[58FFF3A0]: Metadata:
17:17:24 167657.796875 T:1493169056 INFO: ffmpeg[58FFF3A0]: service_name : Service01
17:17:24 167657.796875 T:1493169056 INFO: ffmpeg[58FFF3A0]: service_provider: FFmpeg
17:17:24 167657.796875 T:1493169056 INFO: ffmpeg[58FFF3A0]: Stream #0:0[0x100]: Video: h264 (High) ([27][0][0][0] / 0x001B), yuvj420p(pc, bt709), 1364x768, 29.97 fps, 29.97 tbr, 90k tbn, 59.94 tbc
17:17:24 167657.796875 T:1493169056 INFO: ffmpeg[58FFF3A0]: Stream #0:1[0x101]: Audio: aac (LC) ([15][0][0][0] / 0x000F), 44100 Hz, mono, fltp, 161 kb/s

Working LibreElec wget

wget http:||clientportal.link:8080/live/XXXXXXXXXXX/YYYYYYYYYY/6640.ts
Connecting to clientportal.link:8080 (185.147.12.147:8080)
Connecting to 185.2.83.25:8080 (185.2.83.25:8080)
6640.ts 3745k --:–:-- ETA

Not working OSMC debug log

18:51:32 957.416321 T:2581328880 DEBUG: PVRManager - OpenLiveStream - opening live stream on channel ‘Cine Afrik AF’
18:51:32 957.418152 T:2581328880 DEBUG: opening live stream on url ‘http:||clientportal.link:8080/live/XXXXXXXXXXX/YYYYYYYYYY/10999.m3u8’
18:51:32 957.904297 T:3024081840 DEBUG: ------ Window Init (DialogBusy.xml) ------
18:51:36 961.705078 T:2581328880 DEBUG: PVRFile - Open - playback has started on filename pvr://channels/tv/All channels/pvr.iptvsimple_1506690313.pvr
18:51:36 961.709351 T:2581328880 DEBUG: CFileCache::Open - opening <live/XXXXXXXXXXX/YYYYYYYYYY/10999.m3u8> using cache
18:51:36 961.762268 T:2581328880 DEBUG: CurlFile::Open(0x565b3e8) http:||clientportal.link:8080/live/XXXXXXXXXXX/YYYYYYYYYY/10999.m3u8
18:51:36 961.844177 T:2581328880 INFO: easy_aquire - Created session to http:||clientportal.link
18:51:36 961.914917 T:3024081840 DEBUG: SECTION:LoadDLL(special://xbmcbin/system/ImageLib-arm.so)
18:51:36 961.916504 T:3024081840 DEBUG: Loading: /usr/lib/kodi/system/ImageLib-arm.so
18:51:36 962.051514 T:2581328880 ERROR: CCurlFile::Open failed with code 404 for http:||clientportal.link:8080/live/XXXXXXXXXXX/YYYYYYYYYY/10999.m3u8
18:51:36 962.052856 T:2581328880 ERROR: Open - failed to open source http:||clientportal.link:8080/live/XXXXXXXXXXX/YYYYYYYYYY/10999.m3u8
18:51:36 962.054565 T:2581328880 DEBUG: CDVDInputStreamPVRManager::Open - stream opened: http:||clientportal.link:8080/live/XXXXXXXXXXX/YYYYYYYYYY/10999.m3u8

Not working OSMC wget

wget http:||clientportal.link:8080/live/XXXXXXXXXXX/YYYYYYYYYY/6640.ts
converted ‘http:||clientportal.link:8080/live/XXXXXXXXXXX/YYYYYYYYYY/6640.ts’ (ANSI_X3.4-1968) -> ‘http:||clientportal.link:8080/live/XXXXXXXXXXX/YYYYYYYYYY/6640.ts’ (UTF-8)
–2016-10-27 18:25:23-- http:||clientportal.link:8080/live/XXXXXXXXXXX/YYYYYYYYYY/6640.ts
Resolving clientportal.link (clientportal.link)… 185.147.12.147, 109.236.90.125
Connecting to clientportal.link (clientportal.link)|185.147.12.147|:8080… connected.
HTTP request sent, awaiting response… 302 Found
Location: http:||185.2.83.25:8080//streaming/clients_live.php?username=XXXXXXXXXXX&password=YYYYYYYYYY&stream=6640&extension=ts&hash=293d867dc3a6324e3e64f82052382a87&time=1477589133&pid=23172&external_device=&on_demand=0&isp=&bitrate=1474 [following]
converted ‘http:||185.2.83.25:8080//streaming/clients_live.php?username=XXXXXXXXXXX&password=YYYYYYYYYY&stream=6640&extension=ts&hash=293d867dc3a6324e3e64f82052382a87&time=1477589133&pid=23172&external_device=&on_demand=0&isp=&bitrate=1474’ (ANSI_X3.4-1968) -> ‘http:||185.2.83.25:8080//streaming/clients_live.php?username=XXXXXXXXXXX&password=YYYYYYYYYY&stream=6640&extension=ts&hash=293d867dc3a6324e3e64f82052382a87&time=1477589133&pid=23172&external_device=&on_demand=0&isp=&bitrate=1474’ (UTF-8)
–2016-10-27 18:25:23-- http:||185.2.83.25:8080//streaming/clients_live.php?username=XXXXXXXXXXX&password=YYYYYYYYYY&stream=6640&extension=ts&hash=293d867dc3a6324e3e64f82052382a87&time=1477589133&pid=23172&external_device=&on_demand=0&isp=&bitrate=1474
Connecting to 185.2.83.25:8080… connected.
HTTP request sent, awaiting response… 200 OK
Length: unspecified [video/mp2t]
Saving to: ‘6640.ts’

I’ve replaced the username and password in the URLs with placeholders, and as I’m new and cannot post more than 5 links I’ve replaced the http:// with http:||, but hopefully the difference can be seen, especially in the wget output.

If there’s any more info that I can grab please just let me know

Phil.

RTMP etc is up to date in OSMC

Can you capture the stream and upload a small sample or MediaInfo?

I’ll then take a look :slight_smile:

Sam

I would if I knew how! Could you let me know how to capture a sample from the shell and I’ll get it done asap.

Although I was assuming (not that I presume to know more about this than you Sam) that the issue is Curl/HTTP related and 302 is not being followed correctly. I’m extra confused by the wget output from the two installs being different.

It’s possible there’s a problem with the redirect.

However I’d also like to be able to access the stream.

If I can replicate it here, I can probably fix it :slight_smile:

Is there an IPTV service I can access to test this?

Sam

Hi Sam,

I’ve managed to get a sample uploaded to dropbox here.
The provider is Rapid IPTV, the challenge is that I’m testing with the account of my friend who recommended it to me (and it’s only one concurrent user, so his wife is already complaining!).
If the upload doesn’t help, let me know a way that I can privately share a link, and a pre-arranged time and I’ll clear it with my friend (so as not to interrupt while they’re using it).

MediaInfo (just in case it helps)

General
ID : 1 (0x1)
Complete name : test.mpeg
Format : MPEG-TS
File size : 10.3 MiB
Duration : 58 s 491 ms
Overall bit rate mode : Variable
Overall bit rate : 1 483 kb/s

Video
ID : 256 (0x100)
Menu ID : 1 (0x1)
Format : AVC
Format/Info : Advanced Video Codec
Format profile : High@L3.2
Format settings, CABAC : Yes
Format settings, ReFrames : 4 frames
Codec ID : 27
Duration : 58 s 558 ms
Width : 1 364 pixels
Height : 768 pixels
Display aspect ratio : 16:9
Frame rate : 29.970 (30000/1001) FPS
Color space : YUV
Chroma subsampling : 4:2:0
Bit depth : 8 bits
Scan type : Progressive
Color range : Full
Color primaries : BT.709
Transfer characteristics : BT.709
Matrix coefficients : BT.709

Audio
ID : 257 (0x101)
Menu ID : 1 (0x1)
Format : AAC
Format/Info : Advanced Audio Codec
Format version : Version 4
Format profile : LC
Muxing mode : ADTS
Codec ID : 15
Duration : 58 s 284 ms
Bit rate mode : Variable
Channel(s) : 1 channel
Channel positions : Front: C
Sampling rate : 44.1 kHz
Frame rate : 43.066 FPS (1024 spf)
Compression mode : Lossy
Delay relative to video : -51 ms

Menu
ID : 4096 (0x1000)
Menu ID : 1 (0x1)
Duration : 58 s 491 ms
List : 256 (0x100) (AVC) / 257 (0x101) (AAC)
Service name : Service01
Service provider : FFmpeg
Service type : digital television

Phil.

Stream looks normal. Are you able to play it back locally without issue?

If you can pass me some details, I will have a look, as it may benefit other users.

Sam

It plays fine locally.
I’ve sent you a Skype contact request to share the link.

Phil.

Hi! Im having the same problem here, was this resolved?

No, unfortunately I didn’t hear anything back