2008-08-21 20:25:03 +02:00
|
|
|
#!/bin/sh
|
2018-08-02 02:03:42 +02:00
|
|
|
#
|
2008-08-21 20:25:03 +02:00
|
|
|
# Plugin to monitor the Scalix email system: Process statistics
|
|
|
|
#
|
|
|
|
# (C) 2008 P.Holzleitner
|
|
|
|
#
|
|
|
|
#%# family=contrib
|
|
|
|
|
|
|
|
if [ "$1" = "config" ]; then
|
|
|
|
|
|
|
|
echo 'graph_title Scalix processes'
|
|
|
|
echo 'graph_args --lower-limit 0'
|
|
|
|
echo 'graph_vlabel number'
|
2017-02-23 22:27:37 +01:00
|
|
|
echo 'graph_category mail'
|
2008-08-21 20:25:03 +02:00
|
|
|
echo 'mimeb.label MIME Browser processes'
|
|
|
|
echo 'indexb.label Index Browser processes'
|
|
|
|
echo 'imap.label IMAP Server processes'
|
|
|
|
echo 'pop3.label POP3 Server processes'
|
|
|
|
echo 'postgres.label Postgres threads'
|
|
|
|
echo 'ualr.label UAL Remote (RCI) processes'
|
|
|
|
echo 'xport.label xport.out processes'
|
|
|
|
echo 'jthread.label Java threads'
|
|
|
|
exit 0
|
|
|
|
fi
|
|
|
|
|
|
|
|
MIMEB=`pgrep mime.browse | wc -l`
|
|
|
|
INDEXB=`pgrep index.browse | wc -l`
|
|
|
|
IMAP=`pgrep in.imap41d | wc -l`
|
|
|
|
POP3=`pgrep pop3.server | wc -l`
|
|
|
|
POSTGRES=`pgrep -f postgres | wc -l`
|
|
|
|
UALR=`pgrep ual.remote | wc -l`
|
|
|
|
XPORT=`pgrep xport.out | wc -l`
|
|
|
|
JPID=`pgrep java`
|
|
|
|
JTHREAD=`ls -1 /proc/$JPID/task | wc -l`
|
|
|
|
echo "mimeb.value $MIMEB"
|
|
|
|
echo "indexb.value $INDEXB"
|
|
|
|
echo "imap.value $IMAP"
|
|
|
|
echo "pop3.value $POP3"
|
|
|
|
echo "postgres.value $POSTGRES"
|
|
|
|
echo "ualr.value $UALR"
|
|
|
|
echo "xport.value $XPORT"
|
|
|
|
echo "jthread.value $JTHREAD"
|