[mrtg] run "RRDtool graph" from windows cmdline on file.rrd created by MRTG

Petr Lázňovský lazna at volny.cz
Sat Jan 4 16:31:14 CET 2014


> When MRTG creates an RRD file, it will always create two DS (called ds0 and ds1, corresponding to octets IN and OUT) and eight RRAs (corresponding to d/w/m/y in AVG and MAX).  You can see this by using 'rrdtool info file.rrd'

> So, your example will not work because you are looking for a DS called 'traffic'.  Try this instead:

> DEF:traffic=file.rrd:ds0:AVERAGE


Thanks Steve. Now it does not produce error message (errorlevel 0), but does not produce any graphs also. I am use following command:

rrdtool graph graph.png --start=-86400 --end=-300 DEF:traffic=file.rrd:ds0:AVERAGE

Can you tell me what parameters are mandatory? I find with google few exaples with many, many parameters, but I want to experiment with minimum parameters as possible until I am able to create any graph. Have RRDtool any 'debug' mode? Something like "mrtg --debug=base,snmp,..."

L.

c:\rrdtool info file.rrd
filename = "file.rrd"
rrd_version = "0003"
step = 300
last_update = 1388848544
header_size = 2800
ds[ds0].index = 0
ds[ds0].type = "GAUGE"
ds[ds0].minimal_heartbeat = 600
ds[ds0].min = 0,0000000000e+000
ds[ds0].max = 1,0100000000e+002
ds[ds0].last_ds = "0"
ds[ds0].value = 0,0000000000e+000
ds[ds0].unknown_sec = 0
ds[ds1].index = 1
ds[ds1].type = "GAUGE"
ds[ds1].minimal_heartbeat = 600
ds[ds1].min = 0,0000000000e+000
ds[ds1].max = 1,0100000000e+002
ds[ds1].last_ds = "0"
ds[ds1].value = 0,0000000000e+000
ds[ds1].unknown_sec = 0
rra[0].cf = "AVERAGE"
rra[0].rows = 800
rra[0].cur_row = 649
rra[0].pdp_per_row = 1
rra[0].xff = 5,0000000000e-001
rra[0].cdp_prep[0].value = NaN
rra[0].cdp_prep[0].unknown_datapoints = 0
rra[0].cdp_prep[1].value = NaN
rra[0].cdp_prep[1].unknown_datapoints = 0
rra[1].cf = "AVERAGE"
rra[1].rows = 800
rra[1].cur_row = 448
rra[1].pdp_per_row = 6
rra[1].xff = 5,0000000000e-001
rra[1].cdp_prep[0].value = 1,4666666667e+000
rra[1].cdp_prep[0].unknown_datapoints = 0
rra[1].cdp_prep[1].value = 1,4666666667e+000
rra[1].cdp_prep[1].unknown_datapoints = 0
rra[2].cf = "AVERAGE"
rra[2].rows = 800
rra[2].cur_row = 580
rra[2].pdp_per_row = 24
rra[2].xff = 5,0000000000e-001
rra[2].cdp_prep[0].value = 4,0033333333e+001
rra[2].cdp_prep[0].unknown_datapoints = 0
rra[2].cdp_prep[1].value = 4,0033333333e+001
rra[2].cdp_prep[1].unknown_datapoints = 0
rra[3].cf = "AVERAGE"
rra[3].rows = 800
rra[3].cur_row = 671
rra[3].pdp_per_row = 288
rra[3].xff = 5,0000000000e-001
rra[3].cdp_prep[0].value = 4,0033333333e+001
rra[3].cdp_prep[0].unknown_datapoints = 0
rra[3].cdp_prep[1].value = 4,0033333333e+001
rra[3].cdp_prep[1].unknown_datapoints = 0
rra[4].cf = "MAX"
rra[4].rows = 800
rra[4].cur_row = 490
rra[4].pdp_per_row = 1
rra[4].xff = 5,0000000000e-001
rra[4].cdp_prep[0].value = NaN
rra[4].cdp_prep[0].unknown_datapoints = 0
rra[4].cdp_prep[1].value = NaN
rra[4].cdp_prep[1].unknown_datapoints = 0
rra[5].cf = "MAX"
rra[5].rows = 800
rra[5].cur_row = 352
rra[5].pdp_per_row = 6
rra[5].xff = 5,0000000000e-001
rra[5].cdp_prep[0].value = 8,5333333333e+000
rra[5].cdp_prep[0].unknown_datapoints = 0
rra[5].cdp_prep[1].value = 8,5333333333e+000
rra[5].cdp_prep[1].unknown_datapoints = 0
rra[6].cf = "MAX"
rra[6].rows = 800
rra[6].cur_row = 185
rra[6].pdp_per_row = 24
rra[6].xff = 5,0000000000e-001
rra[6].cdp_prep[0].value = 1,7066666667e+001
rra[6].cdp_prep[0].unknown_datapoints = 0
rra[6].cdp_prep[1].value = 1,7066666667e+001
rra[6].cdp_prep[1].unknown_datapoints = 0
rra[7].cf = "MAX"
rra[7].rows = 800
rra[7].cur_row = 355
rra[7].pdp_per_row = 288
rra[7].xff = 5,0000000000e-001
rra[7].cdp_prep[0].value = 1,7066666667e+001
rra[7].cdp_prep[0].unknown_datapoints = 0
rra[7].cdp_prep[1].value = 1,7066666667e+001
rra[7].cdp_prep[1].unknown_datapoints = 0 




More information about the mrtg mailing list