[rrd-users] First rrd gets only "nan" data with fetch

scott.list scott.list at mlec.net
Sat Mar 23 15:19:46 MET 2002


Greetings:

I'm an old mrtg user but new to rrd, I have read the tutorials but am having
trouble getting my first rrd to work.  I'm setting up a rrd to track some
modem usage.  I'm starting slow with one value, I think once I get that,
I'll be on my way.

I have done:

rrdtool create modem.rrd     \
        --step 60         \
        --start  N          \
        DS:Total:GAUGE:120:1:200    \
        RRA:MAX:0.5:1:600    \

I understand that to mean:
-Set up a rrd named modem.rrd which starts when I run the command (N).
-It holds one Data Source named "Total" that gets built from gauge type of
data.  The counter is read every 60 seconds.  It will consider the value of
the data source unknown if it has not gotten more data in 120 seconds,
Minimum value of the data is 0 max is 200.

In this rrd, I have one archive stored that is consoladated as a maximum,
uses .5 for amount of data that can be made up from unknown data (still
fuzzy on this). collects data for 600 steps (minutes in this case, = one
hour).

My data for counting the modems is externally generated and placed in a
file.  I have a perl script that reads this file and executes the command to
add data to the rrd.  I have this script executed once per minute via cron.
I am not using the perl modules yet, one thing at a time <g>.  I have
verified the script is working and it executes the command:
$now=time();
$tmodem <- this is determined from the data file
@args=("rrdtool", "update", "/home/root/PGMS/rrd/myrrd/modem.rrd",
"$now:$tmodem");
system(@args);

To test that the command above was being generated correctly, right after
that command I had the @args list print out.  It produces the arguments I
indended (whether or not the command is correct I'm not sure):

foreach (@args) {
 print "$_ ";
}

example:
rrdtool update /home/root/PGMS/rrd/myrrd/modem.rrd 1016891780:71

I understand this to mean:
update the rrd with the timestamp of 1016891780 and a value of 71

So, to the problem...  I let this run for a while (over an hour) and I try
to run fetch to see the data.  I execute:

rrdtool fetch modem.rrd MAX

I get a list of data lines but each only has the timestamp with 'not a
number' values i.e.:

<snip>
1016891880: nan
1016891940: nan
1016892000: nan
1016892060: nan

Shouldn't I see data if this is working correctly?  I tried running the
command mannually, but that didn't seem to add any data, either.

Can someone see what I'm doing wrong, misunderstanding and help me
straighten it out?

Thanks very much for the help,
Scott












--
Unsubscribe mailto:rrd-users-request at list.ee.ethz.ch?subject=unsubscribe
Help        mailto:rrd-users-request at list.ee.ethz.ch?subject=help
Archive     http://www.ee.ethz.ch/~slist/rrd-users
WebAdmin    http://www.ee.ethz.ch/~slist/lsg2.cgi



More information about the rrd-users mailing list