According to the docs the default resolutions are:
It defines 5 archives:
granularity of 10s for the last hour
granularity of 1m for the last week
granularity of 15m for the last year
granularity of 1h for the last 5 years
granularity of 1d for the last 10 years
So IIUC you want to introduce a new datasource for 12h with a granularity of 10s.
No but there are many examples in the docs you linked to as well as an explanation of each of the fields and the math you’ll need to do to figure out the proper values to enter for each field. But having an example is going to have limited value for you because rrd4j is pretty arcane and all the properties interact with each other. You kind of have to be knowledgable in rrd4j internals to use the examples anyway.
But the defaults are in the docs:
That doesn’t use the last line because it applies to all Items that are not otherwise listed elsewhere in an rrd4j.cfg file.
Doesn’t really help much to have the example, does it.
services folder in
$OH_CONF. Where is
$OH_CONF? Depends on how you installed OH. There is a table in the installation instructions explaining where each important folder is. For Linux see openHAB on Linux | openHAB. You already know where to put this because the .persist file is
It will almost certainly become corrupted for that Item (note that custom datasource definitions get applied to individual Items, not across all of your Items).
I’ve never tried to move from the default datasources in rrd4j. But based on the docs I’d expect it to look something like the following:
The above datasource has two changes from the default (see above).
The first archive has been expanded to 12 hours by increasing the ` field (archive time = sampleInterval * samplePerBox * boxCount). Multiplying the box count by 12 increases the first archive to cover the first 12 hours instead of the first hour. You could multiply any of the fields by 12 and get the same result, but I’m not sure what the implications are to changing the sampleInterval or samplePerBox on the down stream compression.
The second change is the addition of the
my12h.items line. You have to list the names of the Items individually that will use this datasource instead of the default. Put those three lines in under $OH_CONF/services/rrd4j.cfg.