Jump to content


Photo

m3u Channels not playing

m3u Freebox live tv tcp udp

  • Please log in to reply
30 replies to this topic

#1 wbiggart OFFLINE  

wbiggart

    Newbie

  • Members
  • 5 posts
  • Local time: 03:10 AM

Posted 07 October 2017 - 07:24 AM

Hello,

 

I have setup an m3u tuner for live tv, but I am unable to play any of the channels. I have attached the ffmpeg logs which show the error. When I attempt to run the ffmpeg command by hand without the "rtsp_transport tcp" flag, it runs just fine. Is there any way to make it so that emby doesn't try and force tcp?

 

Thanks in advance.

 

Attached Files



#2 revengineer OFFLINE  

revengineer

    Advanced Member

  • Members
  • 749 posts
  • Local time: 10:10 PM

Posted 07 October 2017 - 08:57 AM

I just had similar issues reported in this post https://emby.media/c...basics-of-iptv/. It turns out that my issues where all due to my own ignorance: I had a bad m3u file.

 

Have you tested the m3u file in VLC? If that does not work the issue is outside emby.



#3 wbiggart OFFLINE  

wbiggart

    Newbie

  • Members
  • 5 posts
  • Local time: 03:10 AM

Posted 07 October 2017 - 09:09 AM

Thanks for the reply. Yes, I have tested the file with VLC and it works.

#4 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 134450 posts
  • Local time: 10:10 PM

Posted 07 October 2017 - 12:45 PM

It would appear that your ffmpeg build does not have support for the rtsp protocol. Where did you get this build? thanks.



#5 wbiggart OFFLINE  

wbiggart

    Newbie

  • Members
  • 5 posts
  • Local time: 03:10 AM

Posted 07 October 2017 - 12:59 PM

I installed ffmpeg via brew. 

 

The version of ffmpeg I am using can handle rtsp.

 

It's my understanding the error "Protocol not supported" is being thrown because the server doesn't handle TCP. For instance, if I manual type the command omitting the rtsp_transport flag it will connect over UDP.  

 

So this command fails:

ffmpeg -analyzeduration 3000000 -rtsp_transport tcp -fflags +igndts -f rtsp -i "rtsp://mafreebox.freebox.fr/fbxtv_pub/stream?namespace=1&service=201"

But omitting the "rtsp_transport tcp" works just fine

ffmpeg -analyzeduration 3000000 -fflags +igndts -f rtsp -i "rtsp://mafreebox.freebox.fr/fbxtv_pub/stream?namespace=1&service=201"

Edited by wbiggart, 07 October 2017 - 01:09 PM.


#6 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 134450 posts
  • Local time: 10:10 PM

Posted 07 October 2017 - 01:04 PM

server doesn't handle TCP

I really have no idea what you mean here sorry. This really has nothing to do with emby server because you could just as easily run the same command line from the terminal without emby server

/usr/local/bin/ffmpeg -analyzeduration 3000000 -rtsp_transport tcp -fflags +igndts -f rtsp -i "rtsp://mafreebox.freebox.fr/fbxtv_pub/stream?namespace=1&service=210&flavour=ld" -map_metadata -1 -map_chapters -1 -threads 0 -map 0:0 -map 0:1 -map -0:s -codec:v:0 libx264 -pix_fmt yuv420p -preset veryfast -crf 23 -maxrate 5000000 -bufsize 10000000 -profile:v high -level 4.1 -x264opts:0 subme=0:me_range=4:rc_lookahead=10:me=dia:no_chroma_me:8x8dct=0:partitions=none -force_key_frames "expr:gte(t,n_forced*3)" -vf "yadif=0:-1:0,scale=trunc(min(max(iw\,ih*dar)\,1920)/2)*2:trunc(ow/dar/2)*2" -flags -global_header -vsync -1 -codec:a:0 copy -f segment -max_delay 5000000 -avoid_negative_ts disabled -start_at_zero -segment_time 3  -individual_header_trailer 0 -segment_format mpegts -segment_list_entry_prefix "hls/539ef476f196721cec782dd8ba4f33ac/" -segment_list_type m3u8 -segment_start_number 0 -segment_list "/Users/wbiggart/.config/emby-server/transcoding-temp/539ef476f196721cec782dd8ba4f33ac.m3u8" -y "/Users/wbiggart/.config/emby-server/transcoding-temp/539ef476f196721cec782dd8ba4f33ac%d.ts"



#7 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 134450 posts
  • Local time: 10:10 PM

Posted 07 October 2017 - 01:11 PM

@ pünktchen

 

Can we set multiple instead of just one?

rtsp_transport
Set RTSP transport protocols.

It accepts the following values:

‘udp’
Use UDP as lower transport protocol.

‘tcp’
Use TCP (interleaving within the RTSP control channel) as lower transport protocol.

‘udp_multicast’
Use UDP multicast as lower transport protocol.

‘http’
Use HTTP tunneling as lower transport protocol, which is useful for passing proxies.

Multiple lower transport protocols may be specified, in that case they are tried one at a time (if the setup of one fails, the next one is tried). For the muxer, only the ‘tcp’ and ‘udp’ options are supported.




#8 19thRose OFFLINE  

19thRose

    Newbie

  • Members
  • 1 posts
  • Local time: 04:10 AM

Posted 10 October 2017 - 01:42 PM

I have the same issue as wbiggart. In my case the streaming server is a FRITZ!Box cable modem (it's dvbc feature). This started recently and could be caused by an update of the FRITZ!Box software (currently 06.84), or an update to the emby server. if I try to capture the stream by hand, omitting the -rtsp_transport flag also fixes the problem for me.



#9 wbiggart OFFLINE  

wbiggart

    Newbie

  • Members
  • 5 posts
  • Local time: 03:10 AM

Posted 10 October 2017 - 01:52 PM

I think the solution would be to edit the following entry in the EncodingHelper.cs file:

 

from:

if (state.InputProtocol == MediaProtocol.Rtsp)
{
inputModifier += " -rtsp_transport tcp";
}

to:

if (state.InputProtocol == MediaProtocol.Rtsp)
{
inputModifier += " -rtsp_transport tcp -rtsp_transport udp -rtsp_flags prefer_tcp";
}


#10 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 134450 posts
  • Local time: 10:10 PM

Posted 10 October 2017 - 01:54 PM

thanks @ wbiggart !



#11 wbiggart OFFLINE  

wbiggart

    Newbie

  • Members
  • 5 posts
  • Local time: 03:10 AM

Posted 10 October 2017 - 03:29 PM

Glad to helpful, and thanks for a great product!



#12 kro OFFLINE  

kro

    Member

  • Members
  • 26 posts
  • Local time: 02:10 AM

Posted 20 November 2018 - 01:10 PM

same issue in 2018, the file has not been updated...

I tried in command line : -rtsp_transport tcp -rtsp_transport udp -rtsp_flags prefer_tcp did the trick



#13 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 134450 posts
  • Local time: 10:10 PM

Posted 20 November 2018 - 01:18 PM

Please attach the information requested in how to report a problem:
https://emby.media/c...view=getnewpost
Thanks.

#14 kro OFFLINE  

kro

    Member

  • Members
  • 26 posts
  • Local time: 02:10 AM

Posted 20 November 2018 - 01:26 PM

actually my issue might be somehow different :

ffprobe version 3.4.2 Copyright (c) 2007-2018 the FFmpeg developers
  built with gcc 6.4.0
  configuration: --prefix=/usr --enable-avresample --enable-avfilter --enable-gnutls --enable-gpl --enable-libass --enable-libmp3lame --enable-librtmp --enable-libvorbis --enable-libvpx --enable-libxvid --enable-libx264 --enable-libx265 --enable-libtheora --enable-libv4l2 --enable-postproc --enable-pic --enable-pthreads --enable-shared --enable-libxcb --disable-stripping --disable-static --enable-vaapi --enable-vdpau --enable-libopus --disable-debug
  libavutil      55. 78.100 / 55. 78.100
  libavcodec     57.107.100 / 57.107.100
  libavformat    57. 83.100 / 57. 83.100
  libavdevice    57. 10.100 / 57. 10.100
  libavfilter     6.107.100 /  6.107.100
  libavresample   3.  7.  0 /  3.  7.  0
  libswscale      4.  8.100 /  4.  8.100
  libswresample   2.  9.100 /  2.  9.100
  libpostproc    54.  7.100 / 54.  7.100
[rtsp @ 0x5648b62908e0] UDP timeout, retrying with TCP
[rtsp @ 0x5648b62908e0] method PAUSE failed: 551 Option Not Supported
rtsp://mafreebox.freebox.fr/fbxtv_pub/stream?namespace=1&service=204&flavour=ld: Operation not permitted

I could not reproduce this error "Operation not permitted" using ffmpeg in command line though.
But still, with "-rtsp_transport tcp -rtsp_transport udp -rtsp_flags prefer_tcp" we don't loose time trying udp, so I guess it would be a nice add.

I'm running emby-server 3.5.0.0
This issue occures whatever browser (firefox) / client (emby for android) I use.

 


Edited by kro, 20 November 2018 - 01:35 PM.


#15 kro OFFLINE  

kro

    Member

  • Members
  • 26 posts
  • Local time: 02:10 AM

Posted 20 November 2018 - 02:37 PM

Same issue after upgrading to 3.5.3.0

 

I use docker with these ports exposed :
- "8097:8096"
- "554:554"
- "7359:7359/udp"

 

I could not open port 1900/udp because some python script already seems to be using it. Would it be related ?

// edit : that was uPnP option in deluge (in my case), I disabled it so I could open it for emby, but that doesn't solve the problem.


Edited by kro, 20 November 2018 - 02:52 PM.


#16 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 134450 posts
  • Local time: 10:10 PM

Posted 21 November 2018 - 02:16 AM

Please attach the complete ffmpeg log, thanks.



#17 kro OFFLINE  

kro

    Member

  • Members
  • 26 posts
  • Local time: 02:10 AM

Posted 21 November 2018 - 07:10 PM

here it is :
(thank !)

 

2018-11-21 23:08:35.192
Application version: 3.5.3.0

http://localhost:8096/videos/2a31ada4635e9ca062cd3867ef24a65a/live.m3u8?DeviceId=5aca0f4b96589c7eda94caa30aff95e7f1043f3c&MediaSourceId=fb20f2f316403883923f68d744c507fe&VideoCodec=h264&AudioCodec=aac&AudioStreamIndex=-1&VideoBitrate=419808000&AudioBitrate=192000&PlaySessionId=197ed223b66b46cd87c3e55e485d8391&api_key=5a085a055925453c9b89202a4aaa15c0&LiveStreamId=a17c75760a04e99b68cf766e11316e1c_09efa0d56b934a82adec00a87b837fb0_fb20f2f316403883923f68d744c507fe&TranscodingMaxAudioChannels=2&RequireAvc=false&SegmentContainer=ts&MinSegments=1&BreakOnNonKeyFrames=True&h264-profile=high,main,baseline,constrainedbaseline&h264-level=51&TranscodeReasons=ContainerNotSupported,VideoCodecNotSupported,AudioCodecNotSupported

{"Protocol":"Rtsp","Id":"fb20f2f316403883923f68d744c507fe","Path":"rtsp://mafreebox.freebox.fr/fbxtv_pub/stream?namespace=1&service=201&flavour=ld","Type":"Default","IsRemote":true,"ReadAtNativeFramerate":false,"IgnoreDts":true,"IgnoreIndex":false,"GenPtsInput":false,"SupportsTranscoding":true,"SupportsDirectStream":false,"SupportsDirectPlay":true,"IsInfiniteStream":true,"RequiresOpening":true,"RequiresClosing":true,"LiveStreamId":"a17c75760a04e99b68cf766e11316e1c_09efa0d56b934a82adec00a87b837fb0_fb20f2f316403883923f68d744c507fe","RequiresLooping":false,"SupportsProbing":true,"MediaStreams":[{"VideoRange":"SDR","DisplayTitle":"","IsInterlaced":true,"BitRate":20000000,"IsDefault":false,"IsForced":false,"Type":"Video","Index":-1,"IsExternal":false,"IsTextSubtitleStream":false,"SupportsExternalStream":false},{"DisplayTitle":"","IsInterlaced":false,"IsDefault":false,"IsForced":false,"Type":"Audio","Index":-1,"IsExternal":false,"IsTextSubtitleStream":false,"SupportsExternalStream":false}],"Formats":[],"Bitrate":20000000,"RequiredHttpHeaders":{},"AnalyzeDurationMs":3000}

User policy for kro: EnablePlaybackRemuxing: True EnableVideoPlaybackTranscoding: True EnableAudioPlaybackTranscoding: True

/bin/ffmpeg -analyzeduration 3000000 -rtsp_transport tcp -rtsp_transport udp -rtsp_flags prefer_tcp -fflags +igndts -i "rtsp://mafreebox.freebox.fr/fbxtv_pub/stream?namespace=1&service=201&flavour=ld" -map_metadata -1 -map_chapters -1 -threads 0 -sn -codec:v:0 libx264 -pix_fmt yuv420p -preset medium -crf 23 -maxrate 20000000 -bufsize 40000000 -profile:v high -level 4.1 -x264opts:0 subme=0:me_range=4:rc_lookahead=10:me=dia:no_chroma_me:8x8dct=0:partitions=none -force_key_frames "expr:gte(t,n_forced*3)" -vf "yadif=0:-1:0,scale=trunc(min(max(iw\,ih*dar)\,1920)/2)*2:trunc(ow/dar/2)*2" -flags -global_header -vsync -1 -codec:a:0 aac -strict experimental -ac 2 -ab 192000  -f segment -max_delay 5000000 -avoid_negative_ts disabled -start_at_zero -segment_time 3  -individual_header_trailer 0 -segment_format mpegts -segment_list_entry_prefix "hls/437164b0372e845d2c757f7f1d9af1d0/" -segment_list_type m3u8 -segment_start_number 0 -segment_list "/config/transcoding-temp/437164b0372e845d2c757f7f1d9af1d0.m3u8" -y "/config/transcoding-temp/437164b0372e845d2c757f7f1d9af1d0%d.ts"

ffmpeg version 4.0.2-emby_2018_09_13 Copyright (c) 2000-2018 the FFmpeg developers
  built with gcc 6.3.0 (crosstool-NG crosstool-ng-1.23.0)
  configuration: --cc=x86_64-pc-linux-gnu-gcc --arch=x86_64 --prefix=/home/embybuilder/Buildbot/x64/ffmpeg-x64/staging --pkg-config=pkg-config --disable-doc --disable-ffplay --disable-vdpau --disable-xlib --enable-fontconfig --enable-gnutls --enable-gpl --enable-iconv --enable-libass --enable-libfreetype --enable-libfribidi --enable-libmp3lame --enable-libopus --enable-libtheora --enable-libvorbis --enable-libwebp --enable-libx264 --enable-libzvbi --enable-version3 --disable-decoders --disable-encoders --enable-decoder=aac --enable-decoder=aac_fixed --enable-decoder=aac_latm --enable-decoder=ac3 --enable-decoder=ac3_fixed --enable-decoder=alac --enable-decoder=apng --enable-decoder=ass --enable-decoder=ayuv --enable-decoder=bmp --enable-decoder=dca --enable-decoder=dirac --enable-decoder=dvbsub --enable-decoder=dvdsub --enable-decoder=eac3 --enable-decoder=flac --enable-decoder=gif --enable-decoder=h264 --enable-decoder=hevc --enable-decoder=huffyuv --enable-decoder=mjpeg --enable-decoder=mlp --enable-decoder=mov_text --enable-decoder=mp3 --enable-decoder=mp3float --enable-decoder=mpeg4 --enable-decoder=opus --enable-decoder=pcm_alaw --enable-decoder=pcm_bluray --enable-decoder=pcm_dvd --enable-decoder=pcm_f16le --enable-decoder=pcm_f24le --enable-decoder=pcm_f32be --enable-decoder=pcm_f32le --enable-decoder=pcm_f64be --enable-decoder=pcm_f64le --enable-decoder=pcm_lxf --enable-decoder=pcm_mulaw --enable-decoder=pcm_s16be --enable-decoder=pcm_s16be_planar --enable-decoder=pcm_s16le --enable-decoder=pcm_s16le_planar --enable-decoder=pcm_s24be --enable-decoder=pcm_s24daud --enable-decoder=pcm_s24le --enable-decoder=pcm_s24le_planar --enable-decoder=pcm_s32be --enable-decoder=pcm_s32le --enable-decoder=pcm_s32le_planar --enable-decoder=pcm_s64be --enable-decoder=pcm_s64le --enable-decoder=pcm_s8 --enable-decoder=pcm_s8_planar --enable-decoder=pcm_u16be --enable-decoder=pcm_u16le --enable-decoder=pcm_u24be --enable-decoder=pcm_u24le --enable-decoder=pcm_u32be --enable-decoder=pcm_u32le --enable-decoder=pcm_u8 --enable-decoder=pcm_zork --enable-decoder=pgssub --enable-decoder=png --enable-decoder=r210 --enable-decoder=rawvideo --enable-decoder=ssa --enable-decoder=subrip --enable-decoder=srt --enable-decoder=text --enable-decoder=theora --enable-decoder=truehd --enable-decoder=v210 --enable-decoder=v210x --enable-decoder=v308 --enable-decoder=v408 --enable-decoder=v410 --enable-decoder=vorbis --enable-decoder=vp8 --enable-decoder=vp9 --enable-decoder=webp --enable-decoder=webvtt --enable-decoder=wmalossless --enable-decoder=wmapro --enable-decoder=wmav1 --enable-decoder=wmav2 --enable-decoder=wmavoice --enable-decoder=wmv1 --enable-decoder=wmv2 --enable-decoder=wmv3 --enable-decoder=wmv3image --enable-decoder=y41p --enable-decoder=yuv4 --enable-decoder=zero12v --enable-encoder=aac --enable-encoder=ac3 --enable-encoder=ac3_fixed --enable-encoder=ass --enable-encoder=dvbsub --enable-encoder=dvdsub --enable-encoder=flac --enable-encoder=libmp3lame --enable-encoder=libopus --enable-encoder=libtheora --enable-encoder=libvorbis --enable-encoder=libwebp --enable-encoder=libx264 --enable-encoder=mjpeg --enable-encoder=mov_text --enable-encoder=png --enable-encoder=srt --enable-encoder=ssa --enable-encoder=subrip --enable-encoder=text --enable-encoder=webvtt --enable-libsmbclient --enable-decoder=mp1 --enable-decoder=mp2 --enable-decoder=mpegvideo --enable-decoder=mpeg1video --enable-decoder=mpeg2video --enable-decoder=vc1 --enable-cuda --enable-cuvid --enable-nvenc --enable-vaapi --enable-decoder=h264_cuvid --enable-decoder=hevc_cuvid --enable-decoder=mjpeg_cuvid --enable-decoder=mpeg1_cuvid --enable-decoder=mpeg2_cuvid --enable-decoder=mpeg4_cuvid --enable-decoder=vc1_cuvid --enable-decoder=vp8_cuvid --enable-decoder=vp9_cuvid --enable-encoder=h264_nvenc --enable-encoder=h264_vaapi --enable-encoder=hevc_nvenc --enable-encoder=hevc_vaapi --enable-encoder=mjpeg_vaapi --enable-cross-compile --cross-prefix=x86_64-pc-linux-gnu- --extra-libs='-ldl -lexpat -lfreetype -lfribidi -lfontconfig -liconv -lpng -luuid -lz -lvorbis -logg -lnettle -lhogweed -lgmp -laddns-samba4 -lasn1util-samba4 -lauthkrb5-samba4 -lCHARSET3-samba4 -lcliauth-samba4 -lcli-cldap-samba4 -lcli-ldap-common-samba4 -lcli-nbt-samba4 -lcli-smb-common-samba4 -lcom_err -lcommon-auth-samba4 -ldbwrap-samba4 -ldcerpc-binding -ldcerpc-samba-samba4 -lflag-mapping-samba4 -lgenrand-samba4 -lgensec-samba4 -lgse-samba4 -lgssapi_krb5 -llibcli-lsa3-samba4 -llibsmb-samba4 -linterfaces-samba4 -liov-buf-samba4 -lk5crypto -lkrb5 -lkrb5samba-samba4 -lkrb5support -lldb -lldbsamba-samba4 -lmessages-dgm-samba4 -lmessages-util-samba4 -lmsghdr-samba4 -lmsrpc3-samba4 -lndr -lndr-krb5pac -lndr-nbt -lndr-samba-samba4 -lndr-standard -lreplace-samba4 -lsamba-cluster-support-samba4 -lsamba-credentials -lsamba-debug-samba4 -lsamba-errors -lsamba-hostconfig -lsamba-modules-samba4 -lsamba-security-samba4 -lsamba-sockets-samba4 -lsamba-util -lsamba3-util-samba4 -lsamdb -lsamdb-common-samba4 -lsecrets3-samba4 -lserver-id-db-samba4 -lserver-role-samba4 -lsmbconf -lsmbd-shim-samba4 -lsmb-transport-samba4 -lsocket-blocking-samba4 -lsys-rw-samba4 -ltalloc -ltalloc-report-samba4 -ltdb -ltdb-wrap-samba4 -ltevent -ltevent-util -ltime-basic-samba4 -lutil-cmdline-samba4 -lutil-reg-samba4 -lutil-setid-samba4 -lutil-tdb-samba4 -lwbclient -lwinbind-client-samba4 -ldrm' --target-os=linux --enable-shared --disable-static
  libavutil      56. 14.100 / 56. 14.100
  libavcodec     58. 18.100 / 58. 18.100
  libavformat    58. 12.100 / 58. 12.100
  libavdevice    58.  3.100 / 58.  3.100
  libavfilter     7. 16.100 /  7. 16.100
  libswscale      5.  1.100 /  5.  1.100
  libswresample   3.  1.100 /  3.  1.100
  libpostproc    55.  1.100 / 55.  1.100
rtsp://mafreebox.freebox.fr/fbxtv_pub/stream?namespace=1&service=201&flavour=ld: could not find codec parameters


#18 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 134450 posts
  • Local time: 10:10 PM

Posted 21 November 2018 - 10:02 PM

Doesn't that error usually mean that it had trouble reading the source stream?



#19 kro OFFLINE  

kro

    Member

  • Members
  • 26 posts
  • Local time: 02:10 AM

Posted 21 November 2018 - 11:34 PM

I don't know.

 

Anyway I have absolutely no issue reading any of these streams with VLC from the host machine. They are TV channels.

I have exposed the port 554 which seems to be the default one for rtsp with no success.

 

Still I know how to run command line from within the container (but I don't know how to install anything yet, what distro is it based on ?), so tell me if there is anything I should try.


Edited by kro, 21 November 2018 - 11:35 PM.


#20 kro OFFLINE  

kro

    Member

  • Members
  • 26 posts
  • Local time: 02:10 AM

Posted 21 November 2018 - 11:54 PM

Here are the info I can get with VLC about the media :

 

H264 - MPEG-4 AVC (part 10)

res 720x578

display res 720x576

25fps

Planar 4:2:0 YUV

 

Audio MPEG AAC (mp4a)

Stereo

48000Hz

extension SBR

... some other stuff (more audio and teletext)

 

nothing weird from my persperctive

 

the trick might be that mafreebox.freebox.fr is a special domain closely tight to the ISP, that doesn't answer ping from another ISP, but I have no issue grabbing the m3u data on the same domain, and it answers ping from the container.

 







Also tagged with one or more of these keywords: m3u, Freebox, live tv, tcp, udp

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users