The London Perl and Raku Workshop takes place on 26th Oct 2024. If your company depends on Perl, please consider sponsoring and/or attending.

NAME

Xymon::Plugin::Server::Devmon - Devmon data object

SYNOPSIS

    my $devmon = Xymon::Plugin::Server::Devmon
        ->new(ds0 => 'GAUGE:600:0:U',
              ds1 => 'GAUGE:600:0:U');

    $devmon->add_data(device1 => { ds0 => 0, ds1 => 2 });
    $devmon->add_data(device2 => { ds0 => 0, ds1 => 2 });

    # add to data to be reported.
    my $status = Xymon::Plugin::Server::Status
                 ->new("localhost.localdomain", "test1");

    $status->add_devmon($devmon);

DESCRIPTION

This module handles data structure for Xymon 'devmon' module. To store data into RRD database, add entry to TEST2RRD variable in server config.

(named hobbitserver.cfg in Xymon 4.2, xymonserver.cfg in Xymon 4.3)

 ex.
  TEST2RRD="cpu=la,disk,...(snipped)...,test1=devmon"

SUBROUTINES/METHODS

new(ds1 => dsdef1, ...)

Create devmon object with data store definition. (To know meanings of dsdef field, please read document in RRDTool.)

add_data(devname, { ds1 => ds1value, ...})

Set values for devname.

format

Format data structure to report to Xymon.