From 181b8dd6e43faee09caf1bef15fe8f680402640f Mon Sep 17 00:00:00 2001 From: "P.Holzleitner" Date: Thu, 21 Aug 2008 20:21:19 +0200 Subject: [PATCH] Initial version --- plugins/other/scalix_clients | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100755 plugins/other/scalix_clients diff --git a/plugins/other/scalix_clients b/plugins/other/scalix_clients new file mode 100755 index 00000000..a0c92d1a --- /dev/null +++ b/plugins/other/scalix_clients @@ -0,0 +1,35 @@ +#!/bin/sh +# +# Plugin to monitor the Scalix email system: Client statistics +# +# (C) 2008 P.Holzleitner +# +#%# family=contrib + +OMSTAT="/opt/scalix/bin/omstat" + +if [ "$1" = "config" ]; then + + echo 'graph_title Scalix client connections' + echo 'graph_args --lower-limit 0' + echo 'graph_vlabel number' + echo 'graph_category Scalix' + echo 'swa.label Webmail connections' + echo 'swa.draw AREA' + echo 'imap.label IMAP connections' + echo 'imap.draw STACK' + echo 'outlook.label Outlook/Scalix10 connections' + echo 'outlook.draw STACK' + echo 'outlook11.label Outlook/Scalix11 connections' + echo 'outlook11.draw STACK' + exit 0 +fi + +IMAP=`nice -10 $OMSTAT -u rci -c | grep 'IMAP client' | wc -l` +SWEB=`nice -10 $OMSTAT -u rci -c | grep 'SWA client' | wc -l` +OLOK10=`pgrep -f "Connect for Microsoft Outlook 10" | wc -l` +OLOK11=`pgrep -f "Connect for Microsoft Outlook 11" | wc -l` +echo "swa.value $SWEB" +echo "imap.value $IMAP" +echo "outlook.value $OLOK10" +echo "outlook11.value $OLOK11"