1#!/bin/sh 2 3# Xymon data collector for MQ 4# 5# 6# Collect data from the MQ utility "runmqsc": 7# - queue depth 8# - channel status 9# for all of the queue managers given as parameters. 10# 11# Wrap this in a client data message, tagged as 12# coming from an "mqcollect" client collector. 13# 14# Requires Xymon server ver. 4.3.0 15# 16# 17# Called from xymonlaunch with 18# 19# CMD $XYMONHOME/ext/mq.sh QUEUEMGR1 [QUEUEMGR2...] 20# 21# where QUEUEMGR* are the names of the queue managers. 22# 23# $Id: mq.sh 6648 2011-03-08 13:05:32Z storner $ 24 25TMPFILE="$XYMONTMP/mq-$MACHINE.$$" 26 27echo "client/mqcollect $MACHINE.mqcollect mqcollect" >$TMPFILE 28 29while test "$1" -ne "" 30do 31 QMGR=$1; shift 32 (echo 'dis ql(*) curdepth'; echo 'dis chs(*)'; echo 'end') | runmqsc $QMGR >> $TMPFILE 33done 34 35$XYMON $XYMSRV "@" < $TMPFILE 36rm $TMPFILE 37 38exit 0 39 40