NAME RRDp - Attach rrdtool from within a perl script via a set of pipes; SYNOPSIS use RRDpo my $rrd = RRDpo->new *path to rrdtool executable* my $answer = $rrd->doCommand *rrdtool commandline* my $status = $rrd->end DESCRIPTION With this module you can safely communicate with the rrdtool. use RRDpo Load the RRDpo module. $rrd = RRDp->new *path to rrdtool executable* start rrdtool. The argument must be the path to the rrdtool executable $answer = $rrd->doCommand *rrdtool commandline* pass commands on to rrdtool. check the rrdtool documentation for more info on the rrdtool commands. This returns rrdtools response. Note that the $answer variable will only contain a pointer to the returned data. The reason for this is, that rrdtool can potentially return quite excessive amounts of data and we don't want to copy this around in memory. So when you want to access the contents of $answer you have to use $$answer which dereferences the variable. $status = $rrd->end terminates rrdtool and returns rrdtools status ... EXAMPLE use RRDpo; my $rrd = new RRDpo ("/usr/local/bin/rrdtool"); my $answer = $rrd->doCommand ('create demo.rrd --step 100 DS:in:GAUGE:100:U:U RRA:AVERAGE:0.5:1:10'); print $$answer; SEE ALSO For more information on how to use rrdtool, check the manpages. AUTHOR Tobias Oetiker Modified by Teun van Eijsden