I thought I would share my experience moving my hass.io configuration from my rpi3+ to a mini pc.
First, why?
Hass.io works great on the Pi3, and if i wasn’t constantly changing things, I would leave it on the Pi3+
For those that haven’t used a Pi3 for hass.io… reloading the configuration (which you have to do for sensors, switches, basically anything that has an entity_id, changes), is extremely slow! were talking up to a minute or more, where as a computer, even a dual core celeron i’m using, is like 5-10 seconds (ssd drive).
Things I did
- Have a Computer (second instance of HA) fully running and tested. Lots of great setup instructions in the official documents on how to do this. I chose to do it via Python3.6 Virtual Environment on a Ubuntu 18.10 LTS minimal server install.
- Stop HA on both systems.
- On the New (Computer ill call it now), delete the “.homeassistant” files (I kept a backup of working test config).
- Copy all the files from the Pi3 config directory to the Computer config directory. Don’t forget the “.” hidden folders.
- Move the z-wave stick from the Pi3 to Computer
- Make sure computer see’s the usb stick as per your configuration, typically /dev/ttyUSB0 (but some i have seen have different names, point is, make sure computer loads it, and has the name in your configuration.yaml file. For some reason, my computer didn’t see the new stick at first).
-
EDIT configuration.yaml - i forgot this step and had loads of errors/issues at first.
a. look for any paths that were used, like location of zwave/zigbee configurations, and update the path to the new on on the Computer, typically on Hass.io/config/filename.txt
would become/home/username/.homeassistant/filename.txt
b. removehassio:
line, or comment out.
c. remove any custom hardware sensors; i.e. i had acommand:
sensor that pulled cpu information from the Pi3, which of course didn’t work on the Computer, and would cause the startup of HA to hang. - Startup HA on Computer, making sure to watch the log file, or first time do
hass --open-ui
from a console to watch the output and ensure no errors happen.
After a few hiccups that i think i covered above, things appear to be working on my mini-computer HA environment now exactly as the Pi3, but much faster to load!
Speed UP "Tips"
Other thing i did that appears to make HA web browsing, particularly sensor history, WAY faster, is to setup MySQL as the database, rather than sqllite file, the default. Since i’m now running on a computer, it has plenty of resources to do this. I’ve also setup dockers to run MQTT and Node-Red on the same machine.
Hope this helps someone who is worried about moving hardware, and isn’t sure of the processes.