Xymon Mailing List Archive search

DATA messages

3 messages in this thread

list David Boldt · Mon, 28 Sep 2015 17:04:36 -0400 ·
Hello,

Pardon the newbie questions.

I can't seem to find any references on the format for "data messages".
Have tried sending the following, and no rrd file appears on the server:

data igskahcmasmx01,cr,usgs,gov.msgRate
messageRate:  1.3980


A second question is on best practices; How should one launch the data
collecting program, with respect to the definition of the associated test?
Below are the current pair of definitions I am using in clientlaunch.cfg:

[msgRate]
        ENVFILE $XYMONCLIENTHOME/etc/xymonclient.cfg
        CMD $XYMONCLIENTHOME/ext/msgRate
        LOGFILE $XYMONCLIENTLOGS/msgRate.log
        INTERVAL 5m

[msgRate.data]
        ENVFILE $XYMONCLIENTHOME/etc/xymonclient.cfg
        CMD $XYMONCLIENTHOME/ext/data/msgRate
        LOGFILE $XYMONCLIENTLOGS/msgRate-data.log
        INTERVAL 5m


I'm assuming that I can't run multiple "CMD"s in a single task definition.
Similarly I'm assuming that I can't reuse the same task identifier.


-- 
                                         -- David Boldt
                                            <user-945c7be1b8e4@xymon.invalid>


   "I stopped believing in Santa Claus when my mother took me to see him in
a department store, and he asked for my autograph."
    --Shirley Temple (1928 - )
list Japheth Cleaver · Mon, 28 Sep 2015 16:18:17 -0700 ·
quoted from David Boldt
On 9/28/2015 2:04 PM, Boldt, David wrote:
Hello,

Pardon the newbie questions.

I can't seem to find any references on the format for "data messages".
Have tried sending the following, and no rrd file appears on the server:

data igskahcmasmx01,cr,usgs,gov.msgRate
messageRate:  1.3980

Hi David,

No worries :)

Your "data" message syntax is correct, however that by itself isn't sufficient to generate an RRD file. For that, you generally need to tell something that listens to the "data" channel that there's something it should do with "msgRate" data messages. This is typically done with a configuration in xymonserver.cfg that indicates a) to listen for the msgRate message, and b) that it's (probably) in a NameColonValue (NCV) format.

As a shortcut, and for advanced uses when you want more control over the specifics of how the RRDs are build, you can use a special "trends" message

The mechanics for both of these are detailed at https://www.xymon.com/help/howtograph.html
quoted from David Boldt
A second question is on best practices; How should one launch the data collecting program, with respect to the definition of the associated test? Below are the current pair of definitions I am using in clientlaunch.cfg:

[msgRate]
        ENVFILE $XYMONCLIENTHOME/etc/xymonclient.cfg
        CMD $XYMONCLIENTHOME/ext/msgRate
        LOGFILE $XYMONCLIENTLOGS/msgRate.log
        INTERVAL 5m

[msgRate.data]
        ENVFILE $XYMONCLIENTHOME/etc/xymonclient.cfg
        CMD $XYMONCLIENTHOME/ext/data/msgRate
        LOGFILE $XYMONCLIENTLOGS/msgRate-data.log
        INTERVAL 5m


I'm assuming that I can't run multiple "CMD"s in a single task definition.
Similarly I'm assuming that I can't reuse the same task identifier.
This is correct, each identifier must be unique and is represented by a single CMD.

Your script, however, is not simply returning data on STDOUT, but is probably executing the $XYMON command itself to send a message. Depending on the data collection you're doing, there's likely little that would stop you from sending both of the messages from a single script, though.

Especially if these are related messages or concept, it's often simpler to keep collection, evaluation, and other bits relating to a single logical unit together in one script. Doubly-so if they'd be running at the same interval anyway.


HTH

-jc
list David Boldt · Tue, 29 Sep 2015 14:29:54 -0400 ·
I had originally started down the path of using the NCV method against a
status message. For this particular test I am displaying a date-time range,
which because of the colons ends up introducing spurious variables into the
rrd file.

Is there a way I can configure  xymonserver.cfg  to ignore any "variables"
in status messages and only pay attention to data messages?


And thank you for the answer to the clientlaunch.cfg question. Obvious once
pointed out, it makes perfect sense to return both kinds of responses in a
single program; Pointing out that the output is not going to stdout was a
good clarification.


On Mon, Sep 28, 2015 at 7:18 PM, Japheth Cleaver <user-87556346d4af@xymon.invalid>
quoted from Japheth Cleaver
wrote:
On 9/28/2015 2:04 PM, Boldt, David wrote:

Hello,

Pardon the newbie questions.

I can't seem to find any references on the format for "data messages".
Have tried sending the following, and no rrd file appears on the server:

data igskahcmasmx01,cr,usgs,gov.msgRate
messageRate:  1.3980


Hi David,

No worries :)

Your "data" message syntax is correct, however that by itself isn't
sufficient to generate an RRD file. For that, you generally need to tell
something that listens to the "data" channel that there's something it
should do with "msgRate" data messages. This is typically done with a
configuration in xymonserver.cfg that indicates a) to listen for the
msgRate message, and b) that it's (probably) in a NameColonValue (NCV)
format.

As a shortcut, and for advanced uses when you want more control over the
specifics of how the RRDs are build, you can use a special "trends" message

The mechanics for both of these are detailed at
https://www.xymon.com/help/howtograph.html


A second question is on best practices; How should one launch the data
collecting program, with respect to the definition of the associated test?
Below are the current pair of definitions I am using in clientlaunch.cfg:

[msgRate]
        ENVFILE $XYMONCLIENTHOME/etc/xymonclient.cfg
        CMD $XYMONCLIENTHOME/ext/msgRate
        LOGFILE $XYMONCLIENTLOGS/msgRate.log
        INTERVAL 5m

[msgRate.data]
        ENVFILE $XYMONCLIENTHOME/etc/xymonclient.cfg
        CMD $XYMONCLIENTHOME/ext/data/msgRate
        LOGFILE $XYMONCLIENTLOGS/msgRate-data.log
        INTERVAL 5m


I'm assuming that I can't run multiple "CMD"s in a single task definition.
Similarly I'm assuming that I can't reuse the same task identifier.


This is correct, each identifier must be unique and is represented by a
single CMD.

Your script, however, is not simply returning data on STDOUT, but is
probably executing the $XYMON command itself to send a message. Depending
on the data collection you're doing, there's likely little that would stop
you from sending both of the messages from a single script, though.

Especially if these are related messages or concept, it's often simpler to
keep collection, evaluation, and other bits relating to a single logical
unit together in one script. Doubly-so if they'd be running at the same
interval anyway.


HTH

-jc

-- 
                                         -- David Boldt
                                            <user-945c7be1b8e4@xymon.invalid>


   "I stopped believing in Santa Claus when my mother took me to see him in
a department store, and he asked for my autograph."
    --Shirley Temple (1928 - )