I’m using rrd4j for my loggings and have setup the rrd4j.cfg for my needs like:
PreisLogger.def=GAUGE,90,0,3,60
PreisLogger.archives=MAX,.5,1,1440:MAX,.5,5,2016:MAX,.5,15,2668
PreisLogger.items=E10_1,E10_2,E10_3,E5_1,E5_2,E5_3,Diesel_1,Diesel_2,Diesel_3,Temperature,Light_TH_Temperature,Light_TH_Humidity
I would have expected all .rrd files to be of the same size, however the first 9 (E10_1 to Diesel_3) have a size of 49412 while the other are 28280.
When checking with REST API the datapoints for the last 24 houres I get 1440 datapoints (as expected from the archive 1 setting), for the one with a smaller filesize I get only 360 datapoints. That would be a datapoint for every 4 minutes only.
Using DEBUG logging I see that values with bigger filesizes get 2 entries every minute like:
21:08:02.516 [DEBUG] [rsistence.rrd4j.internal.RRD4jService] - Stored 'E10_1' with state '1.2889999999999999236166559057892300188541412353515625' in rrd4j database (again)
21:08:02.722 [DEBUG] [rsistence.rrd4j.internal.RRD4jService] - Stored 'E10_1' with state '1.289' in rrd4j database
while the other only get:
21:09:03.634 [DEBUG] [rsistence.rrd4j.internal.RRD4jService] - Stored 'Light_TH_Temperature' with state '19.7' in rrd4j database
Checking a chart for an item with the smaller filesize I see that a changed value is kept for at least 4 minutes, although the chart (n3-line chart in habpanel) seems to have points for every minute.
I did figure a problem with my .cfg, which was initially build for fuel-prices (E10_1,…). The max and min value are set to 0 and 3. The later logged temperatures and humidities are logging values beyond those. Would that be the reason for the different filesize? The observations of @binderth in here do not go into that direction.
I’m just curious and want to understand!