Xymon Mailing List Archive search

Hobbit Average Data

list Phil Wild
Tue, 27 Nov 2007 15:08:22 +0900
Message-Id: <user-155e0258b62f@xymon.invalid>

I'll ask a question first, what is it that is wrong with the current
implementation. If the "people" want the ability to zoom into a five
minute period from a year back, then you need to modify the rrd files.

We had a sort of similar requirement for capacity planning in that for
servers that peak during the day, and are completely idle at night.
After a period of time, the average down to one sample per day would
not give a good indication of how the server is performing over time.
What we did was create an rrd database that stored MAX values, that
way when the data is reduced to one sample per day, it was the max
value for the day. We only did this for a 15 minute uptime value chart
and from memory, we set up a script that created the rrd file to our
spec the first time a sample flowed through based on current
functionality within hobbit to add custom processing for different
alerts. I don't have access to the system right now to check how it
was done.

Cheers

Phil

On 27/11/2007, Henrik Stoerner <user-ce4a2c883f75@xymon.invalid> wrote:
On Mon, Nov 26, 2007 at 10:22:01PM +0100, Henrik Stoerner wrote:
The simplest solution is probably to setup a pipe to a child process,
and then write a line with the RRD filename, the template and the data
to that pipe - the child process can then take care of splitting the
data into individual records, and store them in the database.
There's an implementation of this in the current snapshot, including
a new hobbitd_rrd manpage that describes how to run it, and what the
input to your custom script looks like:

 --processor=COMMAND
    Feed the raw RRD data into COMMAND via standard  input.  COMMAND
    must  be a simple command with no options; if necessary, COMMAND
    can be a script that runs the real command  with  the  necessary
    options.  The  data sent to COMMAND consists of lines of text of
    the form
       dsname1[:dsname2] time:value1[:value2] rrdtype [key1] [key2]
    First the dataset names, corresponding to the DS definitions  in
    the  RRD  files.   Next the timestamp of the update, followed by
    the values in the same order as the dsname-list. Third  item  is
    the  type of RRD file. After that there may be between 0-2 addi-
    tional keys: For "disk" this is the filesystem  mountpoint,  for
    "tcp" tests it is the service name, for "tcp" "http" tests there
    is also the URL checked. Note that  filesystem  names  and  URLs
    have  forwardslash substituted by comma. See the hobbitd/rrd/*.c
    sourcecode for details, look for the "setupfn"  function  calls.
    An example:

    la 1196115478:7 la
    la 1196115478:169 procs
    la 1196115478:1 users
    la 1196115478:244 clock
    pct:used 1196115478:63:62338144 disk ,root
    realmempct 1196115478:76 memory real
    realmempct 1196115478:0 memory swap
    realmempct 1196115478:20 memory actual
    sec 1196115478:0.03 tcp conn
    sec 1196115478:1.38 tcp http osiris.hswn.dk,


Regards,
Henrik

-- 
Tel: XXXX XXX XXX
Fax: XXXX XXX XXX
email: user-e365c1418192@xymon.invalid