[Icecast] Listener statistics on a fallback stream

Jeroen van Oosten jvoosten at bankai.nl
Sun Dec 6 13:41:50 UTC 2015


Hello,

On 06-12-15 13:58, Yahav Shasha wrote:
>
>     >To me it sounds like a bug; surely the fallback never needs
>     statistics,
>     only the real steam because this is where listeners connect to.
>
>  
> Well, the fallback mount is still a mount-point nonetheless. you could
> still use it as a "regular" mount-point even if its configured as a
> fallback to another.

Hmm, you have a point there. But the point is, the *listeners* connect
to a certain mount point; I want to count them there. What's happening
behind the scenes to get the music to them (be it a fallback stream or
even a file played from disk) is irrelevant.

>
> Now, as for the statistics, should we be able to help without knowing
> what system you use to gather your statistics and build those charts?
> or i missed it?

No you didn't miss it; I'm using a homebrew XSLT to present the
information in a simple, parseable format:

<xsl:stylesheet xmlns:xsl = "http://www.w3.org/1999/XSL/Transform"
version = "1.0" >
<xsl:output omit-xml-declaration="no" method="text"
doctype-public="-//W3C//DTD XHTML 1.0 Strict//EN"
doctype-system="http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"
indent="yes" encoding="UTF-8" />
<xsl:template match = "/icestats" >MountPoint,Connections,Stream
Name,Current Listeners,Description,Currently Playing,Stream URL
Global,Client:<xsl:value-of select="connections" /> Source:
<xsl:value-of select="source_connections" />,,<xsl:value-of
select="listeners" />,,
<xsl:for-each select="source">
<xsl:value-of select="@mount" />,,<xsl:value-of select="name"
/>,<xsl:value-of select="listeners" />,<xsl:value-of
select="description" />,<xsl:value-of select="artist" /> - <xsl:value-of
select="title" />,<xsl:value-of select="url" />
<xsl:text>
</xsl:text>
</xsl:for-each>
</xsl:template>
</xsl:stylesheet>


The output is a text file that I can easily parse from a script; the
output is fed into MRTG. At this moment, the 'real' mount points are
missing from this output, even though clients are connected.

> anyway, i can think of two options:
> 1. gather statistics for both mount-points.

I thought of that, but the fallback mounts are hidden so I don't get the
info at all. They are hidden simply because I don't want to show them up
to the users on the statistics page.

> 2. depend on the software you use, you can write some code to
> determinate whether a live source is connected and pull the stats from
> the relevant mount-point accordingly.

Way too complicated. Why should I bother "switching" between mount
points when my listeners connect to a single mount point?

I'm beginning to think this is a 'feature' of IceCast with unintended
consequences...

Thanks,

Jeroen

-- 
Bankai Software
Jeroen van Oosten
Telefoon: 010-4134567
E-mail: jvoosten at bankai.nl
KvK inschrijving: 24455492

"If you think it's expensive to hire a professional to do the job, wait until you hire an amateur." --Red Adair

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.xiph.org/pipermail/icecast/attachments/20151206/fd1f23d0/attachment.htm>


More information about the Icecast mailing list