我已经(成功地)记录和绘制了 3 个差异。温度值(预设、室内和室外)。
"rrdtool create " + config.app_dir + "/" + config.rrd_name + " " + //
"--start N --step 300 " + // data bucket 5 min long
"DS:temp_preset:GAUGE:600:-30:40 " + // human defined
"DS:temp_living:GAUGE:600:-30:40 " + // measured in living room
"DS:temp_outside:GAUGE:600:-30:40 " + // online value
"RRA:AVERAGE:0.5:1:288 " + // 5 min avg., last 24 hours
"RRA:AVERAGE:0.5:12:168 " + // 1 hour avg., last 7 days
"RRA:AVERAGE:0.5:48:315 " + // 4 hour avg., last 30 days
"RRA:AVERAGE:0.5:288:365" // 1 day avg., last 365 days
假设我想添加另一个DS
,但这个用于记录开/关 (1/0) 值——加热器工作/加热器不工作。
这是否是正确的DST和xfiles 因素:
DS:heater_state:GAUGE:600:0:1 \
RRA:LAST:0:1:288