Xymon Mailing List Archive search

Highlights of the 4.3.0 version

list Greg L Hubbard
Tue, 24 Jul 2007 15:55:02 -0500
Message-Id: <user-b38d63a88282@xymon.invalid>

Wonder if there is any way to tell a client what it's status is so it
can be autonomous?  What I mean is this:  suppose there was a way for
the Hobbit client to tell the server that service X was now in state Y,
and a client-side module could then activate response Z on its own?

I know the Hobbit model is to have the server own the configurations,
but how do we solve the "trust" problem?

GLH 

-----Original Message-----
From: Henrik Stoerner [mailto:user-ce4a2c883f75@xymon.invalid] 
Sent: Tuesday, July 24, 2007 3:41 PM
To: user-ae9b8668bcde@xymon.invalid
Subject: Re: [hobbit] Highlights of the 4.3.0 version

On Sun, Jul 22, 2007 at 08:01:12PM -0400, Asif Iqbal wrote:
Here is another feature I like to see.

A way for the hobbit server to request hobbit clent to run a command 
locally based on an alert.
[snip]
So whenever there is a msgs alert run that command locally on the 
client
Run this as a client extension:

  #!/bin/sh

  # Get the current status of the "msgs" column
  MSGSSTATUS=`$BB $BBDISP "query $MACHINE.msgs" | awk '{ print $1 }`

  # Get the command we must run from the client config
  CMD=`grep "^msgsrecovercmd:" $BBTMP/logfetch.$MACHINEDOTS.cfg | sed -e
's!^msgsrecovercmd:!!'`

  # If "msgs" is red and there is a command, run it
  if test "$MSGSSTATUS" = "red" -a "$CMD" != ""
  then
     $CMD
  fi

  exit 0

Before doing this, consider the security implications of having your
servers run commands that they fetch from a remote host without
authentication.


Regards,
Henrik