[icecast-dev] spawning a source
melanie at t-data.com
Thu Jan 8 15:08:34 PST 2004
On 2004.01.08 20:33 Rafael Jannone wrote:
> * Is there a simple way to make icecast spawn a process (to serve as a
> source) when a listener is connecting and no source is available?
Something close to what you're looking for could be accomplished with the
series of patches I have recently released. The patches provide a fallback
mechanism and a command execution facility.
So, a fallback source could be configured and you could pipe zeroes into it
to keep it active, that would keep it active, permitting connections to the
Upon connection, the real source could be started by the connect command
facility. When a listener disconnects, the disconnect command facility
could extract the remaining listener count from the stats page and, if
there are no more listeners, kill the real source again.
> This is part of my quest for reducing CPU hog when there are no
> listeners connected. Of course, once the last listener is disconnected,
> there should be a way to kill the source's process, but that's another
> step :)
There is really only one thing that consumes a lot of CPU: the encoding of
streams. This is not commonly done on the server machine, more often the
server is hosted on a large bandwidth connection, while encoding takes
place on the sender's machine. In that case, CPU load on the server is
negligible when there are no listeners connected.
--- >8 ----
List archives: http://www.xiph.org/archives/
icecast project homepage: http://www.icecast.org/
To unsubscribe from this list, send a message to 'icecast-dev-request at xiph.org'
containing only the word 'unsubscribe' in the body. No subject is needed.
Unsubscribe messages sent to the list will be ignored/filtered.
More information about the Icecast-dev