GNOME Bugzilla – Bug 771754
Got EOS from element "playbin0" ( for slow network connections )
Last modified: 2018-01-12 12:14:12 UTC
Steps to reproduce: 1. Reduce link speed as below: root@unstable:~# wondershaper eth0 100 512 2. Run gst-launch on internet radio url: dev@unstable:~/Music$ gst-launch-1.0 playbin buffer-duration=20000000000 uri=http://s4.streammonster.com:8888/stream Setting pipeline to PAUSED ... Pipeline is PREROLLING ... Redistribute latency... Prerolled, waiting for buffering to finish... Pipeline is PREROLLED ... Setting pipeline to PLAYING ... New clock: GstPulseSinkClock Buffering, setting pipeline to PAUSED ... Done buffering, setting pipeline to PLAYING ... Got EOS from element "playbin0". Execution ended after 0:01:23.338472890 Setting pipeline to PAUSED ... Setting pipeline to READY ... Setting pipeline to NULL ... Freeing pipeline ... Here, the radio station was playing for a while, and gst-launch-1.0 exited with "Got EOS from element playbin0", as above.
Please get a debug log with GST_DEBUG=2,soup*:9 and attach it here, thanks!
Created attachment 336007 [details] export GST_DEBUG=2,soup*:9
This looks like the server just closed the connection at some point. Not much we can do about that, and because of how HTTP works we also can't distinguish this reliable from the server closing the connection because the stream is actually finished.
(In reply to Sebastian Dröge (slomo) from comment #3) > This looks like the server just closed the connection at some point. Not > much we can do about that, and because of how HTTP works we also can't > distinguish this reliable from the server closing the connection because the > stream is actually finished. Ok. Is there any way to make the server not close the connection, unless we tell it to do so ( or a reasonable amount of idle time has passed ( say, 1 minute ) ?
That's for the server to decide, if you can configure the server yourself then you can adjust this.
(In reply to Sebastian Dröge (slomo) from comment #5) > That's for the server to decide, if you can configure the server yourself > then you can adjust this. Ok. Is there a way ( streaming gobject property ) to tell gstreamer to keep playing as long as possible, if possible. Meaning: if the http server closes the connection, open a new connection and keep streaming. This property can be off by default.
Created attachment 336043 [details] Wireshark streaming conversation of mplayer / gst-launch / vlc I just did a quick experiment ( not sure if it helps ). The attachment shows TCP conversations happening on port 8888 ( radio station ), for the following 5 commands: M1: mplayer http://s4.streammonster.com:8888/stream M2: mplayer http://s4.streammonster.com:8888/stream ( same as M1 ) G1: gst-launch-1.0 playbin uri=http://s4.streammonster.com:8888/stream G2: gst-launch-1.0 playbin uri=http://s4.streammonster.com:8888/stream ( same as G1 ) V1: vlc http://s4.streammonster.com:8888/stream TCP conversations in attachment: Line 1 -> M1 ( mplayer exits ) Line 2 -> M2 ( mplayer exits ) Line 3 -> G1 ( gst-launch exits ) Line 4 -> G2 ( gst-launch exits ) Line 5,6,7,8 -> V1 ( vlc keeps playing ) Here, vlc seems to keep playing without exiting. The number of conversations for vlc is 4, since I closed vlc after a few minutes of playing.
Wireshark tcpdump is 8M. So, I'll just paste the vlc conversation here. Will split and attach the capture, if required. VLC - TCP stream 1: ------------------- GET /stream HTTP/1.1 GET /stream HTTP/1.1 Host: s4.streammonster.com:8888 User-Agent: VLC/2.2.4 LibVLC/2.2.4 Range: bytes=0- Connection: close Icy-MetaData: 1 HTTP/1.0 200 OK Accept-Ranges: bytes Content-Type: audio/mpeg icy-br:128 ice-audio-info: bitrate=128 icy-description:Global Swing Broadcast and all that Jazz... icy-genre:Swing icy-name:Global Swing Broadcast icy-pub:0 icy-url:http://www.gsb.fm Server: Icecast 2.4.0-kh2 Cache-Control: no-cache, no-store Pragma: no-cache Access-Control-Allow-Origin: * Access-Control-Allow-Headers: Origin, Accept, X-Requested-With, Content-Type Access-Control-Allow-Methods: GET, OPTIONS, HEAD Connection: Close Expires: Mon, 26 Jul 1997 05:00:00 GMT icy-metaint:16000 VLC - TCP stream 2: ------------------- GET /stream HTTP/1.1 GET /stream HTTP/1.1 Host: s4.streammonster.com:8888 User-Agent: VLC/2.2.4 LibVLC/2.2.4 Range: bytes=1263626- Connection: close Icy-MetaData: 1 HTTP/1.0 200 OK Accept-Ranges: bytes Content-Type: audio/mpeg icy-br:128 ice-audio-info: bitrate=128 icy-description:Global Swing Broadcast and all that Jazz... icy-genre:Swing icy-name:Global Swing Broadcast icy-pub:0 icy-url:http://www.gsb.fm Server: Icecast 2.4.0-kh2 Cache-Control: no-cache, no-store Pragma: no-cache Access-Control-Allow-Origin: * Access-Control-Allow-Headers: Origin, Accept, X-Requested-With, Content-Type Access-Control-Allow-Methods: GET, OPTIONS, HEAD Connection: Close Expires: Mon, 26 Jul 1997 05:00:00 GMT icy-metaint:16000 VLC - TCP stream 3: ------------------- GET /stream HTTP/1.1 GET /stream HTTP/1.1 Host: s4.streammonster.com:8888 User-Agent: VLC/2.2.4 LibVLC/2.2.4 Range: bytes=2166850- Connection: close Icy-MetaData: 1 HTTP/1.0 200 OK Accept-Ranges: bytes Content-Type: audio/mpeg icy-br:128 ice-audio-info: bitrate=128 icy-description:Global Swing Broadcast and all that Jazz... icy-genre:Swing icy-name:Global Swing Broadcast icy-pub:0 icy-url:http://www.gsb.fm Server: Icecast 2.4.0-kh2 Cache-Control: no-cache, no-store Pragma: no-cache Access-Control-Allow-Origin: * Access-Control-Allow-Headers: Origin, Accept, X-Requested-With, Content-Type Access-Control-Allow-Methods: GET, OPTIONS, HEAD Connection: Close Expires: Mon, 26 Jul 1997 05:00:00 GMT icy-metaint:16000 VLC - TCP stream 4: ------------------- GET /stream HTTP/1.1 GET /stream HTTP/1.1 Host: s4.streammonster.com:8888 User-Agent: VLC/2.2.4 LibVLC/2.2.4 Range: bytes=3399811- Connection: close Icy-MetaData: 1 HTTP/1.0 200 OK Accept-Ranges: bytes Content-Type: audio/mpeg icy-br:128 ice-audio-info: bitrate=128 icy-description:Global Swing Broadcast and all that Jazz... icy-genre:Swing icy-name:Global Swing Broadcast icy-pub:0 icy-url:http://www.gsb.fm Server: Icecast 2.4.0-kh2 Cache-Control: no-cache, no-store Pragma: no-cache Access-Control-Allow-Origin: * Access-Control-Allow-Headers: Origin, Accept, X-Requested-With, Content-Type Access-Control-Allow-Methods: GET, OPTIONS, HEAD Connection: Close Expires: Mon, 26 Jul 1997 05:00:00 GMT icy-metaint:16000
It would make sense for souphttpsrc to retry the connection (and seek to the previous position) when it gets disconnected, yes. This should however be implemented already, so question is why this doesn't trigger here. Someone would have to debug this in more detail, together with the code of souphttpsrc.
I think souphttpsrc now does that. Can you try with latest gstreamer ?
Closing since it should be implemented nowadays. Please re-open if it's still a problem with recent versions of GStreamer, thanks!