My home assistant database has grown from 148mb to 902mb in seven months. I didn’t pay too much attention at first as I assumed it was the impact of long term statistics. As the backups were taking progressively longer to run, I decided to check my purge settings.
In configuration.yaml:
recorder:
db_url: mysql://hass:xxxxxxx@core-mariadb/homeassistant
purge_keep_days: 10
I then ran Recorder:Purge through developer tools:
service: recorder.purge
data:
apply_filter: false
keep_days: 10
repack: true
This appeared to run with no errors in the log and CPU rising from 5% to around 50% for about 5 minutes. However, an entity history enquiry shows data is still present back to 5th June 2022 and the database size hasn’t changed. I’m wondering if this could be connected to the 2022.6 release as it references database improvements?
Apart from the increasing database size my system runs perfectly with no log errors or problems.
I’m hoping someone can suggest how I could go about diagnosing and correcting this problem as I would rather not delete the database and lose my long term statistics.