News for hackers. Stuff that matters.
Re:How I Use Home Assistant in 2025 by nicce on Friday January 24, 2025 @11:21AM (#42814642)
Does SQLite really start choking? I feel like the issue is on configuration/ code side rather than on the database itself. It should handle thousands of writes per second, even on older Raspberry.

For this use-case, you can even likely implement own writer queue for every sensor type, and then batch insert them.

Re:How I Use Home Assistant in 2025 by CT4u8798 on Friday January 24, 2025 @03:27PM (#42816601)
I would like further detail about this also. I suspect that SQLite wasn't choking and it was something else. I cannot imagine a single home being able to overwhelm SQLite [0]. Unless the OP has a couple thousand devices all looking to write to it at the same time and they cannot queue and take turns.

[0] https://sqlite.org/whentouse.html

Re:How I Use Home Assistant in 2025 by jmmv on Friday January 24, 2025 @04:01PM (#42816891)
Came here to question this too. I have trouble with this claim because I do not see how a bunch of sensors could produce so much data as to overwhelm a Raspberry Pi...

Maybe the problem was having the database on a super-slow micro-SD card?

Re:How I Use Home Assistant in 2025 by baq on Friday January 24, 2025 @04:13PM (#42816992)
Yeah the microSD will die eventually even if it’s a high endurance one - but it’s fine for a small installation, I’ve been running a quality one until I really started building out the sensor network. With just switches it was fine. Now running on a mid tier usb3 ssd.
Re:How I Use Home Assistant in 2025 by ImaCake on Friday January 24, 2025 @11:07PM (#42819404)
Low power sensors are only being polled every few minutes anyway. I have a dozen temp/humidity sensors and several dozen lights etc and my HA on a Pi 4 has no lag issues from it.
Re:How I Use Home Assistant in 2025 by mvip on Saturday January 25, 2025 @04:36AM (#42820585)
Author here. The problem with SQLite is when you start having a lot of sensors. That's when SQLite failed to keep up on a Pi. Mind you, this was back on Pi 3s. It might be better today, and I know there has been performance improvements to SQLite, but for me moving to Influx for time series and MySQL for the database solved things.

Also, even on the best SD cards, you will eventually break them if you write this much.