#!/bin/sh # -*- sh -*- : << =cut =head1 NAME icecast yp stats - Plugin to monitor Icecast YP stats =head1 CONFIGURATION No configuration =head1 AUTHOR Unknown author =head1 LICENSE Unknown license =head1 BUGS =over 4 =item SuSE: passive connections rejected At least one SuSE netstat appears to report "passive connections rejected because of time stamp" We have never seen that, patch requested. =back =head1 MAGIC MARKERS #%# family=auto #%# capabilities=autoconf =cut . $MUNIN_LIBDIR/plugins/plugin.sh if [ "$1" = "autoconf" ]; then # if ( netstat -s 2>/dev/null >/dev/null ); then # echo yes # exit 0 # else # if [ $? -eq 127 ] # then # echo "no (netstat program not found)" # exit 0 # else # echo no # exit 0 # fi # fi echo yes exit 0 fi if [ "$1" = "config" ]; then echo 'graph_title Icecast YP listener stats' echo 'graph_args --base 1000 -l 0' echo 'graph_vlabel active listeners' echo 'graph_category yp' # echo 'graph_period second' echo 'graph_info This graph shows the activity of listeners for all stations in YP.' echo 'total.label total' echo 'total.type GAUGE' echo 'total.min 0' echo 'total.info The total number of listeners on all listed streams.' echo 'vorbis.label vorbis' echo 'vorbis.type GAUGE' echo 'vorbis.min 0' echo 'vorbis.info The number of vorbis stream listeners.' echo 'opus.label opus' echo 'opus.type GAUGE' echo 'opus.min 0' echo 'opus.info The number of opus stream listeners.' echo 'theora.label theora' echo 'theora.type GAUGE' echo 'theora.min 0' echo 'theora.info The number of theora stream listeners.' echo 'webm.label WebM' echo 'webm.type GAUGE' echo 'webm.min 0' echo 'webm.info The number of WebM stream listeners.' echo 'mp3.label mp3' echo 'mp3.type GAUGE' echo 'mp3.min 0' echo 'mp3.info The number of MP3 stream listeners.' echo 'aac.label AAC' echo 'aac.type GAUGE' echo 'aac.min 0' echo 'aac.info The number of AAC stream listeners.' echo 'aacp.label AAC+' echo 'aacp.type GAUGE' echo 'aacp.min 0' echo 'aacp.info The number of AAC+ stream listeners.' echo 'nsv.label NSV' echo 'nsv.type GAUGE' echo 'nsv.min 0' echo 'nsv.info The number of NSV stream listeners.' echo 'other.label other' echo 'other.type GAUGE' echo 'other.min 0' echo 'other.info The number of other stream listeners.' echo 'radionomy.label radionomy' echo 'radionomy.type GAUGE' echo 'radionomy.min 0' echo 'radionomy.info The number of other stream listeners.' echo 'totalmr.label total minus radionomy' echo 'totalmr.type GAUGE' echo 'totalmr.min 0' echo 'totalmr.info The total number of stream listeners, excluding Radionomy.' exit 0 fi ENVIRONMENT=prod php5 /var/www/dir.xiph.org/munin/munin_listeners.php