brewedbits.dev

Personal blog with guides and news on selfhosting, Linux and AI, from the Netherlands

nextDash nextdash --aboutYour bookmarks. Your terminal. checks your links knows your Docker host one container, no cloudLive demo →nextdash.cc ↗

Tip: ha core update --backup makes a partial backup before Home Assistant Core updates

Backup
~/tips/tip-home-assistant-ha-core-update-backup

ha core update --backup

Creates a partial backup first, then updates Home Assistant Core, from the ha command line.

Updating Home Assistant is one click, and rolling back is the part people think about afterwards. The command line can take a safety copy first.

On Home Assistant OS the ha command has a core section. The docs list this one:

ha core update --backup

It updates Core and first creates a partial backup, which helps if you need to downgrade. To go to one specific release, the docs show ha core update --version x.y.z. Backups are managed with ha backups list, which shows each backup with its slug name, and ha backups restore slugname restores one. You can also create one yourself with ha backups new --name nameofbackup.

Run ha core check after the update to check the configuration.

Caveat: this page is about Home Assistant OS, where the ha command talks to the Supervisor. I run Home Assistant as a container, and I would not expect these commands to exist there, so check on your own install before you plan around them. Also, a partial backup is partial. It is meant for going back after an update, and it does not replace a full backup that lives off the machine.

Further reading: Home Assistant OS common tasks (Home Assistant documentation)

Going deeper: Guide: Home Assistant backups in Docker, with a failure alert on your phone and a copy off the box

More Backup tips restic snapshots --group-by host,paths mysqldump --routines --events mydb > mydb.sql rsync -a --files-from=list.txt /home/me/ backup:/backup/ restic find "*.txt" restic stats All Backup tips (45) All topics

Link