<html><head><meta http-equiv="Content-Type" content="text/html charset=us-ascii"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Hello All,<div><br></div><div><div>I've found something interesting about the DS names.</div><div><br></div><div>Based on the rrdcreate command, the period character is invalid for DS names. I mean, the following command is going to generate an error:</div></div><div><br></div><div><font face="Courier"><span style="font-size: 14px; ">$ rrdtool create temperature.rrd --step 300 DS:temp.kelvin:GAUGE:600:-273:5000 RRA:AVERAGE:0.5:1:100</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">ERROR: Invalid DS name</span></font></div><div><br></div><div>So, I did the following:</div><div><br></div><div>1) Create the RRD with a valid name:</div><div><br></div><div><font face="Courier"><span style="font-size: 14px; ">$ rrdtool create temperature.rrd --step 300 DS:temp:GAUGE:600:-273:5000 RRA:AVERAGE:0.5:1:100</span></font></div><div><div><font face="Courier"><span style="font-size: 14px; ">$ rrdtool info temperature.rrd </span></font></div><div><font face="Courier"><span style="font-size: 14px; ">filename = "temperature.rrd"</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">rrd_version = "0003"</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">step = 300</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">last_update = 1377095699</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">header_size = 584</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">ds[temp].index = 0</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">ds[temp].type = "GAUGE"</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">ds[temp].minimal_heartbeat = 600</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">ds[temp].min = -2.7300000000e+02</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">ds[temp].max = 5.0000000000e+03</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">ds[temp].last_ds = "U"</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">ds[temp].value = 0.0000000000e+00</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">ds[temp].unknown_sec = 299</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">rra[0].cf = "AVERAGE"</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">rra[0].rows = 100</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">rra[0].cur_row = 35</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">rra[0].pdp_per_row = 1</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">rra[0].xff = 5.0000000000e-01</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">rra[0].cdp_prep[0].value = NaN</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">rra[0].cdp_prep[0].unknown_datapoints = 0</span></font></div></div><div><br></div><div>2) Dump the RRD into XML:</div><div><br></div><div><font face="Courier"><span style="font-size: 14px; ">$ rrdtool dump temperature.rrd > temperature.xml</span></font></div><div><br></div><div>3) Manually edit the XML file and change the DS name from "temp" to "temp.kelvin" and save it.</div><div><br></div><div>4) Restore the XML into a new RRD:</div><div><br></div><div><font face="Courier"><span style="font-size: 14px; ">$ rrdtool restore temperature.xml temperature-2.rrd</span></font></div><div><div><font face="Courier"><span style="font-size: 14px; ">$ rrdtool info temperature-2.rrd </span></font></div><div><font face="Courier"><span style="font-size: 14px; ">filename = "temperature-2.rrd"</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">rrd_version = "0003"</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">step = 300</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">last_update = 1377096600</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">header_size = 584</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">ds[temp.kelvin].index = 0</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">ds[temp.kelvin].type = "GAUGE"</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">ds[temp.kelvin].minimal_heartbeat = 600</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">ds[temp.kelvin].min = -2.7300000000e+02</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">ds[temp.kelvin].max = 5.0000000000e+03</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">ds[temp.kelvin].last_ds = "120"</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">ds[temp.kelvin].value = 0.0000000000e+00</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">ds[temp.kelvin].unknown_sec = 0</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">rra[0].cf = "AVERAGE"</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">rra[0].rows = 100</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">rra[0].cur_row = 4</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">rra[0].pdp_per_row = 1</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">rra[0].xff = 5.0000000000e-01</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">rra[0].cdp_prep[0].value = NaN</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">rra[0].cdp_prep[0].unknown_datapoints = 0</span></font></div></div><div><br></div><div>As you can see, the temperature-2.rrd was created successfully and it has a DS that is supposed to be invalid ;)</div><div><br></div><div><div>I can perform rrdupdates without issues against temperature-2.rrd, and I can fetch the data from it:</div><div><br></div><div><div><font face="Courier"><span style="font-size: 14px; ">$ perl -e 'print time - (time % 300) + 300, "\n"'</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">1377096600</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">$ rrdtool update temperature-2.rrd 1377096600:100</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">$ rrdtool update temperature-2.rrd 1377096900:110</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">$ rrdtool update temperature-2.rrd 1377097200:120</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">$ rrdtool update temperature-2.rrd 1377097500:130</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">$ rrdtool update temperature-2.rrd 1377097800:140</span></font></div><div><div><font face="Courier"><span style="font-size: 14px; ">$ rrdtool fetch temperature-2.rrd AVERAGE --start 1377096300 --end 1377097800 </span></font></div><div><font face="Courier"><span style="font-size: 14px; "> temp.kelvin</span></font></div><div><font face="Courier"><span style="font-size: 14px; "><br></span></font></div><div><font face="Courier"><span style="font-size: 14px; ">1377096600: nan</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">1377096900: 1.1000000000e+02</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">1377097200: 1.2000000000e+02</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">1377097500: 1.3000000000e+02</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">1377097800: 1.4000000000e+02</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">1377098100: nan</span></font></div></div></div><div><br></div><div>But, I can't graph the data:</div></div><div><br></div><div><div><font face="Courier"><span style="font-size: 14px; ">$ rrdtool graph temperature.pnd --start 1377096300 --end 1377097800 --title="Temperature" DEF:temp=temperature-2.rrd:temp.kelvin:AVERAGE LINE:temp#ff0000:Temp</span></font></div><div><font face="Courier"><span style="font-size: 14px; ">ERROR: Cannot parse DS in 'DEF:temp=temperature-2.rrd:temp.kelvin:AVERAGE'</span></font></div></div><div><br></div><div><div>So, it seems that rrdcreate and rrdgraph are consistent, but I guess that this also means that rrdrestore is not validating the DS names, and should generate a similar error to be consistent. Is that correct?</div><div><br></div><div>Considering that temperature-2.rrd is working in terms of restoring, updating and fetching the data, why the period character is invalid ? Are there other invalid characters ?</div></div><div><br></div><div>Alejandro.</div><div><br></div></body></html>