ATTENTION: There is a newer release available: 0.2

My Icecast2 relay server is now up and running for more than a year. Time to celebrate it by hooking it into my benchmarking system: Cacti

All the scripts to monitor Icecast2 from Cacti that I've found so far are either outdated or simply refused to work (and used obscure PHP code to parse XML).

Conclusion: I wrote my own solution, based on the fact that I'm a lazy person and I only like clean solutions it became a data query which makes monitoring of every single stream on the server an ease. Just add the query to the device that has Icecast2 running and tick the streams that you want to get graphed. The background work is done by a Python script that uses urllib2 to retrieve the XML status data from Icecast2 and libxml2 to parse and fetch the required values from the data.

Download the scripts and documentation: i24c-0.1.tar.bz2

Here's a live traffic graph from one of my streams:

Live graph of current listeners

The source can also be retrieved from my Subversion repository: