|
发表于 2023-1-17 16:05:24
|
显示全部楼层
本帖最后由 dscao 于 2023-1-17 16:46 编辑
刚刚也看了一下,搜索到一篇文档: https://community.home-assistant.io/t/long-term-statistics-what-is-the-retention-policy-and-how-can-it-be-changed/335050/7
二楼的方法就好了,带long-term statistic的sensor,新版自带的功能就可以了。
当然还是要看需要这个历史记录数据做什么用才知道是否能满足需求。
First of all: recorder save all the data from any sensor and any change is recorded. Recorder will purge old data after some days (default to 10) and you can include or exclude some sensor from recording to help reduce the size, that can become huge. Recorder data can be seen in history graphs and this are NOT statistics.
Only sensors that complies with long-term statistic are also packed by a totally different module. These data are NOT viewable from the history graphs, but from statistics graphs 151. When recoreder purges data, statistics are not affected. Statistics are like diamonds, they’re forever.
After all, only sensors configured to comply with statistics are tracked, and sensor tracked will just add a few bytes every day (24 hourly measures with max, min, mean value). Hence nothing to be worried about in decades.
|
|