gstreamer rtsp server - shared pipeline freezes on client connect and during connection timeout
Kyle Pennington
clowd81 at gmail.com
Mon Jan 25 08:20:02 PST 2016
So the specific incident I provided is a VLC issue.
The other issue I have is that a client suddenly disconnection can cause
other clients to disconnect or their streams to freeze. Again, this only
happens on a shared pipeline, but I've isolated the issue to be a shared
pipeline with UDP as the only set transport.
1) In gst-rtsp-server/examples/test-video.c, insert
"gst_rtsp_media_factory_set_shared(factory,
TRUE);" to line 136, and "gst_rtsp_media_factory_set_protocols(factory,
GST_RTSP_LOWER_TRANS_UDP);" to line 137.
2) Recompile the gst-rtsp-server examples (navigate to root, and run make)
3) Navigate to the example directory, and run the "test-video" shell script
4) use ifconfig to get your eth0/wlan0 IP address
5) Run the following command in a new terminal: "gst-launch-1.0 rtspsrc
location=rtsp://<eth0/wlan0 IP address>:8554/test protocols=0x1 ! fakesink"
6) Open a VLC client, and connect to the localhost IP addres - rtsp://
127.0.0.1:8554/test
7) In another terminal, execute the following command: "sudo ip link set
<eth0/wlan0> down"
This should cause the VLC client to quickly freeze it's current stream.
The gst-launch-1.0 client will take some time before it disconnects, but
during that time if you reconnect the VLC client to the localhost IP, the
stream will continue.
In short, there appears to be an issue with how UDP handles multiple
clients on a shared pipeline. I don't experience these issues if I force
TCP on the server, or if I set shared to false.
On Sat, Jan 16, 2016 at 12:20 PM, Kyle Pennington <clowd81 at gmail.com> wrote:
> Let me provide reproduction steps. I'm using Gstreamer 1.6.0 on Ubuntu
> 12.04 (required target OS for my project).
>
> 1) In gst-rtsp-server/examples/test-video.c, insert "gst_rtsp_media_factory_set_shared(factory,
> TRUE);" to line 147.
> 2) Recompile the gst-rtsp-server examples (navigate to root, and run make)
> 3) Navigate to the example directory, and run the "test-video" shell script
> 4) Connect to the running RTSP server using a local VLC client (url is
> usually rtsp://127.0.0.1:8554/test)
> 5) Connect a second local VLC client.
>
> On my setup, this results in the video in the VLC client started in step
> #4 to freeze until the VLC client started in step #5 finishes it's initial
> buffering and starts the video.
>
> Let me know if you need any additional information.
>
> On Sat, Jan 16, 2016 at 2:57 AM, Sebastian Dröge <
> sebastian at centricular.com> wrote:
>
>> On Do, 2016-01-14 at 13:30 -0500, Kyle Pennington wrote:
>> > I've been having some issues lately with my RTSP server streams
>> > freezing when a new client connects or when a client's network
>> > connection is dropped. These two interactions cause the stream to
>> > freeze for all connected clients. I have a shared pipeline,
>> > configured with gst_rtsp_media_factory_set_shared(factory, true);.
>> >
>> > From what I understand, this should force all clients to use the same
>> > pipeline, and actions of one to influence the rest (seeking, etc.).
>> > However, this is not the behavior I am seeing. This type of behavior
>> > should never interfere with the streams of other clients.
>> >
>> > I am able to recreate this by setting the shared property on the
>> > media factory in the "test-video" example bundled with the RTSP
>> > server. I connect to the example server using two separate VLC
>> > clients on the same PC. When I do this, the first client's stream
>> > freezes while waiting for the other client to finish it's initial
>> > buffering.
>> >
>> > I came across this bug on bugzilla: https://bugzilla.gnome.org/show_b
>> > ug.cgi?id=648463, but I'm not sure if it's related and it is back
>> > from 2011-2013.
>>
>> Can you add a comment there and ideally provide a testcase (i.e. gst-
>> rtsp-server application plus steps how to reproduce) too?
>>
>> The behaviour you're seeing is definitely not intended.
>>
>> --
>> Sebastian Dröge, Centricular Ltd · http://www.centricular.com
>>
>>
>> _______________________________________________
>> gstreamer-devel mailing list
>> gstreamer-devel at lists.freedesktop.org
>> http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/gstreamer-devel/attachments/20160125/1e17f825/attachment-0001.html>
More information about the gstreamer-devel
mailing list