[Xymon] RHEL EXT Script Help

Jeremy Laidman jlaidman at rebel-it.com.au
Sun Jul 31 03:12:47 CEST 2016


On Fri, 29 Jul 2016, 05:05 Foster Patch <Foster.Patch at accuweather.com>
wrote:

> Hello, I have quite a bit of experience how xymon works in Windows, and
> recently was given assignments to do some monitoring in Linux. (RHEL 6)
> Below is my script. It runs with no errors, but my Hobbit page is never
> propagated with the new monitor. I have also gone to /etc/clientlaunch.cfg
> and put in the necessary lines to run this script. I am at a loss as to
> what is wrong, and why it will not propagate. Any help? (XYMSRV has an
> actual IP Address in it)
>
>
>
> #!/bin/sh
>
>
>
> . /etc/default/xymon-client
>
>
>
> export XYMSRV="xxx.xx.xxx.xx"
>
> export BBHOME="/usr/lib/xymon/client"
>
> export OUTSIDENAME="$CLIENTHOSTNAME"
>
> export BB="${BBHOME}/bin/xymon"
>
> export BBDISP=$XYMSRV
>
> export REALMACHINE="`echo $OUTSIDENAME | sed 's/\./,/g'`"
>
> export TARGETMACHINE="${REALMACHINE}"
>
>
>
> export TEST="CFENGINE"
>
>
>
> if [ ! "$TEST" ]; then
>
>         exit
>
> fi
>
>
>
> if [ "${TARGETMACHINE}" == "${REALMACHINE}" ]; then
>
> LINE="status $REALMACHINE.$TEST green `date`<BR>
>
> <CENTER><I><FONT SIZE=+2>
>
> This machine is not actively running this service in the cluster.
>
> </FONT></I>
>
> </CENTER>
>
> ";
>
>                 # NOW USE THE BB COMMAND TO SEND THE DATA ACROSS
>
>                 #$BB $BBDISP "$LINE"                    # SEND IT TO
> BBDISPLAY
>
>                 $BB $BBDISP "$LINE"                     # SEND IT TO
> BBDISPLAY
>
>
>
>         fi
>
>
>
>
>
> Thanks
>

Foster

Check your xymon server ghost report.

Run the script like so:

~xymon/client/bin/xymoncmd sh -x scriptname

Cheers
Jeremy
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.xymon.com/pipermail/xymon/attachments/20160731/7cd9c14b/attachment.html>


More information about the Xymon mailing list