My HomeAssistant install was up and running, but I was not happy with it. Errors and warnings in the logs, filesystem layout not aligning with standard FreeBSD practice. So I decided to fix this stuff.

Overview
What will this blog-post address
- SSDP errors (due to install in Jail)
- Warnings and errors in UI
- Logs not rotating
- Configuration not in
/usr/local/etc(but in homeassistant install dir) - Logs not in
/var/log(but in config dir) - Backups not in
/var/backups(but in config dir) - Cache directory not in
/var/cache(but in config dir)
The default setup probably makes sense when runnig this as a container, it doesn't when running in FreeBSD.
I like my things to follow the standard FreeBSD hierarchy as documented in hier(7).
Fixing errors and warnings
Multiple things going on, missing dependencies, network issues.
SSDP errors in the logs
Documentation on this is "meh"...
Finding the issue is easy, finding a fix is not.
The issue is with the default_config, and once you know you can find things in the docs.
Process is something like
- Disable
default_configinconfiguration.yaml - Find out what "Integrations" should be enabled
- Enumerate the integrations in
configuration.yaml
# Disable default_config (pulls in default integrations)
# default_config:
# The default enabled stuff can be found in
# /usr/local/homeassistant/lib/python3.14/site-packages/homeassistant/components/default_config/manifest.json
#assist_pipeline:
#bluetooth:
#cloud:
#conversation:
dhcp:
energy:
file:
#go2rtc: Fails to start
history:
homeassistant_alerts:
logbook:
#media_source:
mobile_app:
my:
#ssdp: # Broken in jails, uses broadcast
#stream:
sun:
#usage_prediction:
#usb:
webhook:
#zeroconf:
I ended up listing all entries from the default_config manifest, but disabling even more.
In the UI there was an issue with setting up stream so disabled that as well.
You can find descriptions about what the configs do using Integrations search.
Throw the label in search and check details.
Missing dependencies
Install zlib-ng and googletest packages. pip install zlib_ng. uninstall googletest.
Install libjpeg-turbo.
Filesystem layout
| Location | Use |
|---|---|
/usr/local/homeassistant |
1. Home directory 2. Python VirtualEnv |
/usr/local/etc/homeassistant |
Configuration directory |
/var/cache/homeassistant |
Cache directory (originally in config dir) |
/var/logs/homeassistant |
Logs (originall in config dir) |
/backups |
Backup (originally in config dir) |
Preparing the directories
install -d -o homeassistant /usr/local/etc/homeassistant
install -d -o homeassistant /var/log/homeassistant
install -d -o homeassistant /var/cache/homeassistant
install -d -o homeassistant /backups
Fixing configuration and logs directories
These are configured using command-line switches.
In the startup script, these are configured via hass_confdir and hass_args.
The startup script I have, supports setting the configdir using hass_confdir.
Logs are configured using the hass_args in the jail's /etc/rc.conf.
hass_confdir="-c /usr/local/etc/homeassistant " # Set the configuration dir
hass_args="--log-file /var/log/homeassistant/homeassistant.log "
hass_args+="--log-rotate-days 7"
Rotation reduces the size of logs used.
Move around data
Stop HomeAssistant, move all content from the old to the new configuration directory.
cd /usr/local/homeassistant/.homeassistant
mv * /usr/local/etc/homeassistant/
cd /usr/local/etc/homeassistant
mv backups/* /backups/
rmdir backups
ln -s /backups backups
mv .cache/* /var/cache/homeassistant/
rmdir .cache
ln -s /var/cache/homeassistant .cache
Start HomeAssistant
