Alternative way of running HassOS (full OS) on FreeNAS (without iocage or Docker)

No; it is an IO issue in regard of USB: different from the more established VMWare or VirtualBox, Bhyve cannot pass (at least not natively supported and free) USB devices so for the case of using RF gateways this is a shortcoming. However, there are some easy alternatives:

  • install HA as a FreeNAS plugin (although it wasn’t difficult to setup before, this is now available in FreeNAS 11.3 RC) and then pass USB devices to this instance;
  • use a secondary device (for example Rpi) as an RF to MQTT hub (ie with Hassio addons for Zigbee2MQTT, Z-Wave to MQTT) that would connect to the main HA installation; this requires a second device to use but would be relatively cheap. Although the entire Hassio can run fine (depending on the number and complexity of the smart home components) on the Rpi, at least for the ones before Rpi v4 there would be the issues with the tear & wear of MicroSD cards; with only these two addons communicating over MQTT is more likely that the MicroSD card failure won’t be a problem.

My install is as following:

  1. Main HA on Ubuntu Server on a NUC (Celeron J4005) running MQTT broker; has Zigbee, Z-wave and 433 Mhz gateways attached to it; not exposed to the internet; vs. a Rpi 3 (haven’t tried with 4) this works way faster (although there haven’t been too many problems with the Rpi, some automations would linger for several seconds which was quite annoying for the lights).
  2. Hassio on FreeNAS as a VM, communicating with main instance over MQTT; exposed to internet with Nginx Hassio addon, also connected to Google Assistant; I use this second HA for two main reasons: i) don’t want to expose to internet or to Google Assistant all my devices; ii) use the nice Hassio addons (obviously could have used a regular Docker installation for the programs I like, but would have required additional maintenance and the Hassio addons are very clean and easy to use).

I’m unsure if the Xiaomi Gateway would be available in this setup but, alongside security and privacy issues of running a cloud component there are some problems with the Gateway loosing connection (I’ve had a fair share of such problems myself):

I would totally recommend switching to a local controlled Zigbee hub (either ConBee, ZHA or Zigbee2MQTT). I use a lot of Xiaomi Zigbee devices connected to Zigbee2MQTT and they work much better than the Xiaomi Gateway.