iOS icon indicating copy to clipboard operation
iOS copied to clipboard

Restoring / migrating from a Time Machine backup loses settings

Open deviantintegral opened this issue 2 years ago • 1 comments

Device model, version and app version

Model Name: MacBook Pro (16-inch, 2019) macOS Version: 12.1 App Version: 2021.322 Safari Version: 15.2

Home Assistant Core Version

2021.12.9

Describe the bug

I recently had a hardware failure and had to restore from a Time Machine backup. I used the first-boot migration assistant to restore everything. First, the copy of Home Assistant from TestFlight had expired (it was a month old) so I updated it. However, after opening the entire app behaves like I've never used it. Neither of the 2 servers I had set up are present. I went to add one server, and it warned me that I needed to rename the Mac since one was already registered with the same name.

To Reproduce

Restore from a Time Machine backup? Though it's possible the new build is the real cause of the problem.

Expected behavior

  1. Home Assistant server configuration shouldn't be lost.
  2. When signing into a server, the app should offer to "inherit" the previous app's device and entities. I'm not sure what unique ID is used, but if it's tied to the hardware that probably needs to be abstracted somehow. As a suggestion around the workflow, TIme Machine itself offers on first backup to either inherit the previous backup history, or to start as if it's a new computer.

As I still have my backups, I'm glad to look into them to see if the data is being backed up at all when I'm next plugged into the drive.

deviantintegral avatar Jan 20 '22 02:01 deviantintegral

I tried removing and restoring the Home Assistant related directories in ~/Library/Containers and ~/Library/Group Containers. That didn't seem to have any effect. I went ahead and completed onboarding, and I had to choose a new device name. I guess I can just delete the old device and then rename the new one? Regardless, I'm curious why this particular app had trouble restoring.

deviantintegral avatar Jan 25 '22 18:01 deviantintegral