Hi,
I'm wanting to use Simple::RRD to build stats graphics from a program
that is intended to run infrequently (say once or twice a day). I've got
this working reasonably well, except that it's showing single dots on
the update times, and I'd like it to extrapolate lines between the dots.
What's the recommended best practice for this sort of usage? Should I be
adjusting frequency?
Here's what I'm using now:
use RRD::Simple;
...
# Prepare the RRD files
my ( $ldmsrrd, $ldmsrrdfile );
$ldmsrrdfile = "ldmsstats.rrd";
if (! -e $ldmsrrdfile ) {
# LDMS RRD file didn't exist, so create and initialize it
$ldmsrrd = RRD::Simple->new( file => "$ldmsrrdfile" );
$ldmsrrd->create( $ldmsrrdfile, "mrtg",
AllDevices => "GAUGE",
DayDevices => "GAUGE",
WeekDevices => "GAUGE",
);
} else {
# LDMS RRD file did exist, so we just need to initialize it
$ldmsrrd = RRD::Simple->new( file => $ldmsrrdfile );
}
...
# Update RRD too
$ldmsrrd->update(
AllDevices => $allmachines,
DayDevices => $dbscans,
WeekDevices => $dbscansweek
);
my %rtn = $ldmsrrd->graph(
destination => "$reportdir",
title => "LDMS Inventory Statistics",
vertical_label => "Devices / Daily / Weekly",
interlaced => ""
);
if ($DEBUG) {
&LogDebug("Logged LDMS RRD statistics: "
. map { $rtn{$_}->[0] } keys %rtn
);
}
Thanks,
Jack
_______________________________________________
rrd-users mailing list
[email protected]
https://lists.oetiker.ch/cgi-bin/listinfo/rrd-users