gstreamer threads not terminated if gst-application started as daemon ...
ensonic at hora-obscura.de
Mon Feb 21 12:56:14 PST 2011
Am 20.02.2011 18:05, schrieb Wolfgang Esslinger:
> Hello all,
> I am faced with a strange problem if I want to run a gstreamer based program as
> a daemon (i.e. start it right from init/system startup).
> A) First case, working as expected:
> If I start e.g. gst123 in a terminal after login giving a directory containing
> mediafiles as argument, everything works as expected, i.e. all the titles are
> played and if I continuously check for the number of threads of the process,
> this number is constant (usually about 5).
> gst123 /home/we/MyMedia 2>&1 >/tmp/gst.log &
> Checking number of threads with
> while : ; do ps -eLf | grep gst | wc -l ; sleep 1; done
> B) Second, case with problem:
> In order to have the media being played back automatically after startup of the
> computer, I have the following line in a file in the /etc/init.rd directory:
> (sleep 30; cd /home/we; gst123 /home/we/MyMedia 2>&1 >/tmp/gst.log & )&
> This also seems to work and starts playing the titles after the delay for some
> time when the system is started, but if I check for the number of threads the
> program uses, I find out that for every mediafile it seems that a new thread is
> created and will not be terminated at end of playback of that file, i.e. stays
> active until I kill the program explicitely. If the program runs for several
> hours, it finally is stuck or dies, because it can no longer start new threads,
> since the number of threads is too high (several dozens or even hundreds...)!
You would need to debug this on gst123. This app is not maintained by the
gstreamer team. Alternatively having a test case for playbin2 (assuming that it
uses playbin2) would be good to know that there problem is not caused by that.
Finally you could try the gstreamer developer PPA to test it with the latest
release gstreamer version.
> Is there anyone out there who can explain the effect and maybe even propose a
> solution (is it a bug? maybe even a fix being underway?)
> (as a workaround, what comes to my mind is starting a new gst123 instance for
> every mediafile, but I don't think of this as a really elegant way)
> (Running ubuntu 10.10, with libgstreamer-0.10.30)
> Regards & Thanks
> gstreamer-devel mailing list
> gstreamer-devel at lists.freedesktop.org
More information about the gstreamer-devel