tellytv / telly

An IPTV proxy
MIT License
760 stars 104 forks source link

Recent "Unable to tune channel" issues #108

Closed tombowditch closed 6 years ago

tombowditch commented 6 years ago

Please record findings here.

tombowditch commented 6 years ago

After a quick look...

[14:00] Tom: my thoughts so far: [14:00] Tom:

Jun 15, 2018 12:59:53.331 [0x7fcdf57ff700] VERBOSE - WebSocket: processed 1 frame(s)
Jun 15, 2018 12:59:53.370 [0x7fcde83ff700] ERROR - [Transcoder] [hls,applehttp @ 0x26dad00] Start sequence (0) is bigger than the segment count (0).
Jun 15, 2018 12:59:53.459 [0x7fcdf0fff700] ERROR - [Transcoder] Option scan_all_pmts not found.
Jun 15, 2018 12:59:53.460 [0x7fcde2fff700] VERBOSE - JobManager: child process with PID 850 exited
Jun 15, 2018 12:59:53.460 [0x7fcde2fff700] DEBUG - Jobs: '/usr/lib/plexmediaserver/Plex Transcoder' exit code for process 850 is 1 (failure)

this scan_all_pmts option is causing the transcoder to exit if i copy the command that the transcoder runs directly and remove -scan_all_pmts it forks properly and i can see it trying to load in telly log [14:01] Tom: someone mentioned here it works on windows ? [14:01] Tom: i wonder if scanallpmts isnt on windows hence not this problem [14:01] Tom: https://ffmpeg.org/pipermail/ffmpeg-devel/2014-November/164943.html [14:01] Tom: ffmpeg version related ?

hazcod commented 6 years ago

So this is only related to HLS and not MPEGTS?

tombowditch commented 6 years ago

Me and @EnorMOZ been working through some debugging, think we've found the issue.

Updates to follow

nroTTron commented 6 years ago

Plex Media Server log is not logging any warnings or errors when I get the Playback error on Windows 10. Any ideas why not?

tombowditch commented 6 years ago

@nroTTron open your .m3u, find one of the URLs. Does it end in .ts?

nroTTron commented 6 years ago

It has .ts. For the sake of this open ticket, I will test with non-Vaders M3u.

nroTTron commented 6 years ago

FYI - I was just able to get a non-Vaders m3u to work on Win 10 ONLY if I select a built-in Plex EPG. I used a random service provider with US zipcode. No Playback Error.

When I try to load the provider XML, Plex fails to complete the guide setup process. It just keeps spinning the continue button on an endless loop. So I will add this in the other mapping thread as well.

tombowditch commented 6 years ago

Okay, tl;dr I think either Plex is no longer supporting .m3u8 streams or there's a bug in the recent version.

I recommend switching to using MPEG-TS (.ts) streams - most if not all providers support this by adding &format=ts to where you grab your .m3u

Keeping this open to track progress. If Plex don't fix this then I'll work on a transcoder .m3u8 -> .ts

tombowditch commented 6 years ago

Copy and pastable sed:

sed -i 's/.m3u8/.ts/g' your.m3u
hthighway commented 6 years ago

Using vaders with the&format=ts option I can get telly 0.6.2 to start without the m3u8 warings. Plex sees it as a tuner and Plex scans the channels fine, and then it will load my epg file.

But when all that is done I still get a playback error

I've tried this one two separate boxes, both running Ubuntu 16.04 and PMS 1.13.2.5154. One box uses docker and the other is just running on linux

UPDATE to add logs:


usr/lib/plexmediaserver/Resources/' X_PLEX_TOKEN='xxxxxxxxxxxxxxxxxxxx' '/usr/lib/plexmediaserver/Plex Transcoder' '-noaccurate_seek' '-ignore_unknown' '-scan_all_pmts' '-1' '-rw_timeout' '30000000' '-fflags' '+discardcorruptts+fillwallclockdts' '-i' 'http://192.168.1.153/stream/XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX==?transcode=internet240' '-map' '0:V?' '-codec:V' 'copy' '-map' '0:a?' '-codec:a' 'copy' '-copypriorss:a' '0' '-map' '0:s?' '-codec:s' 'copy' '-segment_format' 'mpegts' '-f' 'ssegment' '-individual_header_trailer' '0' '-segment_time' '1' '-segment_start_number' '0' '-segment_time_delta' '0.0625' '-segment_list' 'http://127.0.0.1:32400/video/:/transc
ode/session/0ffb2eb3-93fa-4e05-a6c6-cb0b60d38825/22e82740-560a-4417-acc9-77c45860297e/seglist' '-segment_list_type' 'csv' '-segment_list_size' '2147483647' '-segment_list_separate_stream_times' '1' '-max_delay' '5000000' '-map_metadata' '-1' '-map_chapters' '-1' 'media-%05d.ts' '-y' '-nostats' '-loglevel' 'quiet' '-loglevel_plex' 'error' '-progressurl' 'http://127.0.0.1:32400/video/:/
transcode/session/0ffb2eb3-93fa-4e05-a6c6-cb0b60d38825/22e82740-560a-4417-acc9-77c45860297e/progress'
Jun 15, 2018 10:21:43.231 [0x7f8f033ff700] DEBUG - Jobs: Starting child process with pid 19518
Jun 15, 2018 10:21:43.263 [0x7f8ee7fff700] ERROR - [Transcoder] [tcp @ 0x206da40] Connection to tcp://192.168.1.153:80 failed: Connection refused
Jun 15, 2018 10:21:43.263 [0x7f8eabbfd700] ERROR - [Transcoder] http://192.168.1.153/stream/aHR0cDovL3ZhcGkudmFkZXJzLnR2L3BsYXkvNzI2OTIudHM/XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX==?transcode=internet240: Connection refused
Jun 15, 2018 10:21:43.264 [0x7f8eff3ff700] DEBUG - Jobs: '/usr/lib/plexmediaserver/Plex Transcoder' exit code for process 19518 is 1 (failure)
Jun 15, 2018 10:21:46.226 [0x7f8f007fe700] DEBUG - Activity: updated activity a1a282fe-3211-4abe-8423-a33f37b76799 - completed 1% - Recording
Jun 15, 2018 10:21:49.227 [0x7f8f007fe700] DEBUG - Activity: updated activity a1a282fe-3211-4abe-8423-a33f37b76799 - completed 2% - Recording
Jun 15, 2018 10:21:52.228 [0x7f8f007fe700] DEBUG - Activity: updated activity a1a282fe-3211-4abe-8423-a33f37b76799 - completed 3% - Recording
Jun 15, 2018 10:21:52.708 [0x7f8ee77fe700] DEBUG - DVR:Subscription: Moving end of rolling sub for 'Live TV - Session' to 2018-06-15 10:26:52.
Jun 15, 2018 10:21:52.709 [0x7f8ee77fe700] DEBUG - Activity: registered new activity e1bd1768-d8f4-49fb-b1d9-5c1f81103a13 - Processing subscriptions
Jun 15, 2018 10:21:52.710 [0x7f8ee77fe700] DEBUG - DVR:Subscription: Scheduling subscriptions.
Jun 15, 2018 10:21:52.714 [0x7f8ee77fe700] DEBUG - DVR:Subscription: Initialized 1 schedulers.
Jun 15, 2018 10:21:52.714 [0x7f8ee77fe700] DEBUG - DVR:Schedule: Scheduled an active operation 'Live TV - Session' on tuner 0 between 2018-06-15 10:21:43 and 2018-06-15 10:26:52 on channel I283.67331.schedulesdirect.org
Jun 15, 2018 10:21:52.714 [0x7f8ee77fe700] DEBUG - DVR:Grabber: Setting timer to stop grab of 'Live TV - Session' in 300 seconds.
Jun 15, 2018 10:21:52.714 [0x7f8ee77fe700] DEBUG - DVR:Subscription: Starting with 1 grabs, scheduled 1 active ones preemptively.
Jun 15, 2018 10:21:52.715 [0x7f8ee77fe700] DEBUG - DVR:Subscription: Scheduled all subscriptions in 4 ms.
Jun 15, 2018 10:21:52.715 [0x7f8ee77fe700] DEBUG - Activity: Ended activity e1bd1768-d8f4-49fb-b1d9-5c1f81103a13.
Jun 15, 2018 10:21:52.715 [0x7f8ee77fe700] DEBUG - DVR:Subscription: There are 1 grabs at the end.
Jun 15, 2018 10:21:58.229 [0x7f8f007fe700] DEBUG - Activity: updated activity a1a282fe-3211-4abe-8423-a33f37b76799 - completed 4% - Recording
Jun 15, 2018 10:22:01.230 [0x7f8ee77fe700] DEBUG - Activity: updated activity a1a282fe-3211-4abe-8423-a33f37b76799 - completed 5% - Recording
Jun 15, 2018 10:22:04.231 [0x7f8f007fe700] DEBUG - Activity: updated activity a1a282fe-3211-4abe-8423-a33f37b76799 - completed 6% - Recording
Jun 15, 2018 10:22:07.232 [0x7f8f007fe700] DEBUG - Activity: updated activity a1a282fe-3211-4abe-8423-a33f37b76799 - completed 7% - Recording
Jun 15, 2018 10:22:10.234 [0x7f8ee77fe700] DEBUG - Activity: updated activity a1a282fe-3211-4abe-8423-a33f37b76799 - completed 8% - Recording
Jun 15, 2018 10:22:13.231 [0x7f8f033ff700] DEBUG - Using default transcode duration of 120 minutes
Jun 15, 2018 10:22:13.231 [0x7f8f033ff700] DEBUG - Started session successfully: 0ffb2eb3-93fa-4e05-a6c6-cb0b60d38825
Jun 15, 2018 10:22:13.232 [0x7f8f033ff700] DEBUG - DVR:Recorder: It took 30.0 sec to start the session for http://192.168.1.153/stream/XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX==?transcode=internet240
Jun 15, 2018 10:22:13.232 [0x7f8f033ff700] DEBUG - DVR:Grabber: Merging EPG item with live item.
Jun 15, 2018 10:22:13.232 [0x7f8f033ff700] ERROR - DVR:Recorder: No part because session isn't reporting one.
Jun 15, 2018 10:22:13.234 [0x7f8f033ff700] DEBUG - DVR:Grabber: Operation for Live TV - Session completed with status error (Could not start recording)
Jun 15, 2018 10:22:13.234 [0x7f8f033ff700] DEBUG - Activity: Ended activity a1a282fe-3211-4abe-8423-a33f37b76799.
Jun 15, 2018 10:22:13.234 [0x7f8f033ff700] DEBUG - DVR:Grabber: Cleaning up rolling grab for channel I283.67331.schedulesdirect.org.
Jun 15, 2018 10:22:13.234 [0x7f8f033ff700] DEBUG - DVR:Recorder: Asked to stop recording 'Live TV - Session'.
Jun 15, 2018 10:22:13.234 [0x7f8f033ff700] DEBUG - DVR:Recorder: Stopping transcode session.
Jun 15, 2018 10:22:13.234 [0x7f8f033ff700] DEBUG - Killing job.
Jun 15, 2018 10:22:13.234 [0x7f8f033ff700] DEBUG - Signalling job ID 19518 with 9
Jun 15, 2018 10:22:13.234 [0x7f8f033ff700] DEBUG - Job was already killed, not killing again.
Jun 15, 2018 10:22:13.234 [0x7f8f033ff700] DEBUG - Stopping transcode session 0ffb2eb3-93fa-4e05-a6c6-cb0b60d38825
Jun 15, 2018 10:22:13.234 [0x7f8ee77fe700] DEBUG - Cleaning directory for session 0ffb2eb3-93fa-4e05-a6c6-cb0b60d38825 (/var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Cache/Transcode/Sessions/plex-transcode-0ffb2eb3-93fa-4e05-a6c6-cb0b60d38825)
Jun 15, 2018 10:22:13.235 [0x7f8f033ff700] DEBUG - DVR:Grabber: Freed a tuner (now 1 available)
Jun 15, 2018 10:22:13.235 [0x7f8eab3fc700] ERROR - DVR:Subscription: Rolling media grab failed to start.
Jun 15, 2018 10:22:13.235 [0x7f8eab3fc700] DEBUG - DVR:Grabber: Cancelling operation for 'Live TV - Session' with status cancelled.
Jun 15, 2018 10:22:13.239 [0x7f8eab3fc700] DEBUG - Activity: registered new activity 85f23268-1434-4643-8076-09ea237240b1 - Processing subscriptions
Jun 15, 2018 10:22:13.240 [0x7f8eab3fc700] DEBUG - DVR:Subscription: Scheduling subscriptions.
Jun 15, 2018 10:22:13.242 [0x7f8eab3fc700] DEBUG - DVR:Subscription: Initialized 1 schedulers.
Jun 15, 2018 10:22:13.242 [0x7f8eab3fc700] DEBUG - DVR:Subscription: Starting with 1 grabs, scheduled 0 active ones preemptively.
Jun 15, 2018 10:22:13.242 [0x7f8eab3fc700] DEBUG - DVR:Subscription: Scheduled all subscriptions in 2 ms.
Jun 15, 2018 10:22:13.242 [0x7f8eab3fc700] DEBUG - Activity: Ended activity 85f23268-1434-4643-8076-09ea237240b1.
Jun 15, 2018 10:22:13.242 [0x7f8eab3fc700] DEBUG - DVR:Subscription: There are 0 grabs at the end.
Jun 15, 2018 10:22:13.243 [0x7f8f047fe700] DEBUG - Completed: [107.72.96.60:59239] 200 POST /livetv/dvrs/13/channels/I283.67331.schedulesdirect.org/tune (7 live) TLS GZIP 30038ms 512 bytes (pipelined: 1)
Jun 15, 2018 10:22:13.456 [0x7f8f047fe700] DEBUG - Auth: authenticated user 1 as hthighway
Jun 15, 2018 10:22:13.457 [0x7f8ee7fff700] DEBUG - Request: [107.72.96.60:12540 (WAN)] GET /status/sessions/background (7 live) TLS GZIP Signed-in Token (hthighway)
Jun 15, 2018 10:22:13.458 [0x7f8f047fe700] DEBUG - Completed: [107.72.96.60:12540] 200 GET /status/sessions/background (7 live) TLS GZIP 1ms 470 bytes (pipelined: 1)
Jun 15, 2018 10:22:14.228 [0x7f8ef03fd700] DEBUG - DVR:Recorder: Asked to stop recording 'Live TV - Session'.```
nroTTron commented 6 years ago

I am getting Playback error when I use my external XML now.

SdlasHeras commented 6 years ago

Hi @tombowditch Video working on Windows 10 Pro, telly v0.6 and Plex 1.13.2.5154

Man-in-Black commented 6 years ago

How did you get this to work? My m3u-File does not end in .ts

Joost1991 commented 6 years ago

Using .ts m3u file and I also got a Playback error.

Using Plex 1.13.2.5154 on Ubuntu 16.04 and telly 0.6.2 and also with telly 0.6.

mediaman88 commented 6 years ago

Everything was working great for the last two days, now all of a sudden I can't play anything. Both PMS and Telly running on Windows 10. I am using the .ts version of Vaders m3u.

All channels work fine using the plug-in method through plex, but nothing will play from the DVR Guide.

soosthui commented 6 years ago

Running Telly on Windows 10 NUC pc, Running Plex Server on QNAP servers. Using IPTV m3u_plus file with .ts streams inside.

I get playback errors when using Telly 6.2 or 6.0 but if I use version 5.0 or 4.5 all my channels play perfectly fine in Plex.

What is different from Telly 5.0 to 6.2?

willbeeching commented 6 years ago

I'm also getting 'Unable to tune channel' using the latest Telly version and latest PMS. All the streams contained within my m3u file are .ts, when I click on the channel and see Telly redirecting to the stream in terminal I can copy and paste that into VLC and it starts fine, so the right stream is definitely getting parsed.

Has anyone found a solution to this?

Man-in-Black commented 6 years ago

Same issue here. If I copy the redirected URL directly into VLC it works like a charm. With PMS I cannot stream anything. This issue occurs with telly 5.0 and 6.2.

porkie02 commented 6 years ago

There is a few things you need to checklist.

For me using the docker container -base was enough for me for it to work, also whenever you change any setting make sure just in case to restart pms. I hope this helps some people.

BDS369 commented 6 years ago

I also cannot view my vader stream in plex due to the m38u file type error. so close to having this working :(

porkie02 commented 6 years ago

So get a m3u instead of m3u8 from vader.

BDS369 commented 6 years ago

can you please explain how? FYI, I am using xtreme-editor to edit the playlist. So it might have to be done on there- but I can't figure out how

porkie02 commented 6 years ago

just change the output of the link from Vader, Vader are very good at you being able to use different links but that can cause a lot of confusion also. I use XE to and I just use the api link they provide through minihosts which is http://api.vaders.tv/vget?username=xxxx&password=xxxxx&format=ts

BDS369 commented 6 years ago

thank you very much! working now

MichealX64 commented 6 years ago

I was also receiving this error message and setting the -base= parameter fixed it for me!

Have you set the base url command? Do not use localhost or 0.0.0.0, -base=192.168.x.x:6077

Thank you @porkie02

ArtursGailis1995 commented 6 years ago

My IPTV is only available in M3U or M3U8 format which then contains chunks of TS files.

This is the format I receive it:

playlist.m3u8?authtoken=blahblah > chunklist_channelname_id.m3u8?authtoken=blahblah > media_channelname_id_id.ts?authtoken=blahblah.

Any chance it will be fixed soon? Just moved from Emby to Plex.

live4ever commented 6 years ago

I got around this by adding the base var to the docker container as well (m3u file with .ts):

base

b101marc commented 6 years ago

Having an issue with crashing. I'm using PlayersKlub using the .ts output with no success. Any other suggestions? Relative newcomer.

causefx commented 6 years ago

Heads up, if guide xml has a space in the channel ID, you will get the tune error.

91ajames commented 6 years ago

where do you put this "sed -i 's/.m3u8/.ts/g' your.m3u" does it work or is there no solutions to this yet?

tried using that last 3 old versions of plex but still unable to stream from it without having a playback error.

robbiet480 commented 6 years ago

I found a script on StackOverflow which filters out arguments passed into a script. I moved /usr/lib/plexmediaserver/Plex Transcode to /usr/lib/plexmediaserver/old-PT and then put the script at /usr/lib/plexmediaserver/Plex Transcode (taking care to match permissions. Now i've got a working telly 😎!

Here's my slightly modified version of the linked script to remove the debug echo's and specifically strip out scan_all_pmts.

#!/bin/bash

function arg_remove ()
{
    local array=("${@:3}")

    for ((i=0; i<"${#array[@]}"; ++i)); do
        case ${array[i]} in
            "$2") unset array[i]; unset array[i+1]; break ;;
        esac
    done

    # clean up unset array indexes
    for i in "${!array[@]}"; do
        new_array+=( "${array[i]}" )
    done
    array=("${new_array[@]}")
    unset new_array

    # assign array outside function scope
    local -g "$1=(  )"
    eval ${1}='("${array[@]}")'
}

arg_remove ARG_PASS '-scan_all_pmts' "$@"
/usr/lib/plexmediaserver/old-PT "${ARG_PASS[@]}"
simonk83 commented 6 years ago

Just chiming in here that I'm trying to work through this as well. I'm using the following link for Australian Freeview channels, which unfortunately are all m3u8 (I haven't found any other working options as yet) - https://raw.githubusercontent.com/matthuisman/iptv/a3dd5861a72dafc46545bead266e37f777212eaf/au/Melbourne/raw-tv.m3u8

Getting the tune error, which is to be expected I suppose :) Other than that, everything is showing up in Plex perfectly, well done Tom. Looking forward to being able to get this fully working,

robbiet480 commented 6 years ago

Should be fixed by https://github.com/tellytv/telly/commit/2130ad62bf17f6279a2201a7badaeecd60070fe9, using ffmpeg to transcode streams to a Plex acceptable format