[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Fwd: wrong status of server side extention script in xymon-4.2.2..pl help...
- To: hobbit (at) hswn.dk
- Subject: Fwd: wrong status of server side extention script in xymon-4.2.2..pl help...
- From: pankaj dorlikar <pankaj.dorlikar (at) gmail.com>
- Date: Sat, 9 May 2009 14:42:37 +0530
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:date:message-id:subject :from:to:content-type; bh=MYynULQLhhd/xeFzm9thR8xyTQ67iltGjJ3Cc+K4Gcg=; b=G7zq7MWT7mEPbjCgBRoqHN/R/Qc+lRh5/uCmBDgNcQYKZuzqxjJTTvaMFnd6X6c8Xh QQS8Tp5Uh0jwier3eT6ZvH5vLJ1ZdDxQKLQzTMjq+tTm4t5xt+ywtloc+OEpLE/yWWdl o6r6gbmx+4yQfisFTlRcvMGF8KistcWajVz7g=
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=bPUU7tRoPTqoZIdeWQCR/KcTMORqH4FIddCkrUH5coMbkBQiYP2evlFAaPoUgjDF9L +4y13mVgK21sBFidyAggiW5ANueN2dm6flrH4BHSFJCsY8PbugYsI4PH4VROqmhqWJh7 pvYZkyPCVXLmkgt4dO65BcnI5i1KxdJ1BL91s=
---------- Forwarded message ----------
From: pankaj dorlikar <pankaj.dorlikar (at) gmail.com>
Date: Fri, May 8, 2009 at 11:08 PM
Subject: wrong status of server side extention script in xymon-4.2.2
To: hobbit (at) hswn.dk
hi,
i am using xymon -4.2.2.
I have written one extension script (server side script) for monitoring k3b
service on each machine including server and clients also.On one of my
clients and on server itself,the service is not running.on other two clients
service is running.
I am getting same green status on all clients as well as server stating k3b
is running.when i checked on each client,server and 2 clients do not run
this service.;but i am getting green for that also....wt is wrong?
steps i fallowd are,
In ~/server/etc/hobbitlaunch.cfg added
k3b]
ENVFILE /home/hobbit/server/etc/hobbitserver.cfg
NEEDS hobbitd
CMD $BBHOME/ext/k3b
LOGFILE $BBSERVERLOGS/k3b.log
INTERVAL 5m
in bb-hosts,added k3b for every host..
In ~/server/ext/k3b, added:
#!/bin/sh
BBHTAG=k3b # What we put in bb-hosts to trigger this test
COLUMN=k3b # Name of the column, often same as tag in bb-hosts
$BBHOME/bin/bbhostgrep $BBHTAG | while read L
do
set $L # To get one line of output from bbhostgrep
HOSTIP="$1"
MACHINEDOTS="$2"
MACHINE=`echo $2 | $SED -e's/\./,/g'`
MSG="$BBHTAG status for host $MACHINEDOTS"
op=`ps -aef | grep k3b | grep -v grep|grep -v vim`
/*
some logic placed which will lead to results
*/
if test $op != "";then
then
COLOR=green
else
COLOR=red
fi
$BB $BBDISP "status $MACHINE.$COLUMN $COLOR `date`
${MSG}
"
done
exit 0
------------------
logs alos do not show anything except bb-hosts enties..
help me..abt how can i get correct status for all clients and serverm
using server side xternal script
Pankaj V. Dorlikar
--
Pankaj V. Dorlikar