diy solar

diy solar

HA on RPi?

SeaGal

Photon Sorceress
Joined
Aug 17, 2022
Messages
2,948
Location
UK
Just trying to get my head around installing HA on a Raspberry Pi 5 running Raspbian.

The HA guides recommend completely imaging the RPi with the HA 'specific purpose OS'.

Is it not possible to just run HA as a stand-alone application alongside other stuff? Anyone done this? Have RPi 5 with 8G RAM and SSD, so have plenty of processing power.
 
HA on a Raspbian is unsupported and will not install unless you get round some deliberate code set to stop you, even then it fails. Been there and got the T shirt. Went instead for HA OS on a mini Windows PC, everytime it rebooted it took my router out and the home network died. Now I just use Raspbian with node-red display pulling data from MQTT.

I followed this unsuccessfully

 
Last edited:
I outgrew using my RPi4 for Home Assistant, it just didn't have the grunt, storage or backup capability I felt important as Home Assistant grew and became more important to our home's operation. I migrated to a mini PC using Proxmox to set up virtual machines, one of which is Home Assistant.

I recently repurposed the RPi4 as a second instance of Solar Assistant dedicated to monitoring my LiFePO4 batteries.
 
grab a cheap used USFF pc, you'll get the full power of a computer, even out performing older servers. as @wattmatters mentioned, HA is a bit of a resource hog, especially as you add more and more to it. storing, and specifically computing all of that statistical data can add up fast.

i'm using a HP t640 thinclient ( was $50 used ), running a whole hypervisor ( proxmox ) on it with a few vms! basically a home server on a THINCLIENT ( which is normally just used to remote into your virtual workstation ), so it's theoretically less powerful than a USFF, but more than enough oompf.

a usff is basically a laptop in a box, but smaller, and thus more energy efficient, can expect a draw of ~5-10 watts if you use a ssd in it.
when you include the used electronics market in your decision making, rasperry pis suddenly become a total rip off :(

--

if your lucky enough to find a used hp microserver for cheap, that's probably an ideal setup. 25 watts and you have a full fledged server with raid. dual eth, so you could toss your router and plop on pfsense in a vm... but now i'm going overboard :p
 
I was killing a SD card a week, having only connected 2 inverters and a few temperature sensors :D.
Raspi is great if you really have to store a few measuremnts per hour in my opinion, unless you can connect a HDD/SSD (been threre too).
I had many versions of HA installed, starting from running from docker, then CORE, and finally using a dedicated VM.
Over time I moved all telemetry data to INFLUX, and have Grafana to visualize it, Node Red to sync, and at the end of the day, HA is used to be an on/off solution and quick battery overview.

1715446927307.png
1715446955618.png

now my data on grafana dashboard
1715447016678.png
 
Just trying to get my head around installing HA on a Raspberry Pi 5 running Raspbian.

The HA guides recommend completely imaging the RPi with the HA 'specific purpose OS'.

Is it not possible to just run HA as a stand-alone application alongside other stuff? Anyone done this? Have RPi 5 with 8G RAM and SSD, so have plenty of processing power.
You can install HA core as a docker image, It's far more complex (steeper learning curve) and you would have to install each add-on independently but from what I've heard from others is it's far more stable than OS atleast on RPi 4.

look at Home Assistant Container install in the install options.

 
Install home assistance bare metal on a micro PC and you will have a far better long-term experience. Use an SSD to speed it up substantially.
 
(y) thanks. Do you have any recommendations on the micro PC? Not an area I have looked into before.
Are you worried about power usage? If not I'd recommend an old office thin client they don't use much but considerably more than a DC system like a mini pc or RPi you can normally pick them up for £50 or so like the Lenovo think center, then if one isn't fitted it's matter of a small SSD. If your looking at micro pc's it's hard as the range is so varied personally I like beelink they are reasonably priced but still a Chinese brand that possibly has malware( they get wiped and Linux so I don't really care).
 
Have run HA on an RPi 3B+ for a few years now. SD card died after a few months. Some say it's an issue with RPi and some say not. Changed to boot from 16gb USB stick and has been rock steady. Not the fastest but consumes very little power and space. Have 24 devices attached and monitors my off grid system. Can be slow loading history data and compiling esphome code but the later is easily done on faster laptops I have lying around.
 
Have run HA on an RPi 3B+ for a few years now. SD card died after a few months. Some say it's an issue with RPi and some say not. Changed to boot from 16gb USB stick and has been rock steady. Not the fastest but consumes very little power and space. Have 24 devices attached and monitors my off grid system. Can be slow loading history data and compiling esphome code but the later is easily done on faster laptops I have lying around.
With sd cards and usb sticks it's more to do with the limitations of the nand chip, you might currently have better luck with usb but I would say given time that's going to fail also they just aren't designed for that many writes and will slowly corrupt/die. If you want to keep your data id recommend offloading backups regularly to your laptop and eventually get yourself an SSD for the pi.
 
I'd use an OrangePi with an EMMC. SD cards just don't hold up well. You can also get one with up to 16G of RAM, which keeps you from trashing whatever flash storage with excessive writes/swap.
 
(y) thanks. Do you have any recommendations on the micro PC? Not an area I have looked into before.
I have always used Dell in my professional life and installed thousands of them, very little issues. I just got another one of these -
Optiplex 3020 Micro Desktop Computer PC, Intel Core i3-4160T 3.1GHz, 8G DDR3, 500G, WiFi, BT, DP, VGA, Windows 10 Pro 64
Install HA from a bootable drive and off you go !!!
 
On another forum I got shot down in flames for saying that ;)
oof.

there are "high endurance" microsd cards, but those probably still have less write cycles before failure than eMMC or other SSD.

raspi 5 has more cpu ability than rpi4; small pc devices still seem more optimal tradeoff for compute vs cost. definitely avoid SD card for boot media.
 
Lenovo and dell both have the Micro PC's. or an Intel NUC, can be had for less than $50. Stuff an old 500G or smaller SSD in it and roll.

Something like:
I'd consider these thin clients or sff (small form factor)really, but exactly what I would suggest to run Home Assistant. Micro pc's should actually be micro as in not much bigger than a pi but this is all semantics and better left for another day😉

one thing I would point out is if you intend to use HA for CCTV at some point look out for computers with usb 3.0 or more as running a tpu on usb 2 kinda sucks, also if your running other things in the house like private DNS, wifi controllers, docker, etc you can consolidate it all to one of these systems by going down the proxmox route and virtualizing everything given it has enough ram.


Is a god send for installing everything once you have proxmox up and running.
 
With sd cards and usb sticks it's more to do with the limitations of the nand chip, you might currently have better luck with usb but I would say given time that's going to fail also they just aren't designed for that many writes and will slowly corrupt/die. If you want to keep your data id recommend offloading backups regularly to your laptop and eventually get yourself an SSD for the pi.
I run a duplicate HA in vmware on a spare laptop so there is always a backup. My experience with the RPi though is that it's been very reliable. As for storage I've had a lot more sd card failures than usb thumb drives but ymmv.
 

diy solar

diy solar
Back
Top