Lately Iβve been seeing issues with HAOS running in Proxmox. It seems that most created the VM using whiskerz007βs revolutionary script that was created for an older version of Proxmox.
A new script was released in April 2022 (this guide is now using) utilizing the current advancements in PVE7. (If you create a manual install of HAOS in Proxmox, the outcome will be the exact same as the current script. The script only automates the process.)
To get current:
Make a full backup of HA and download it.
Copy the MAC address of your VM and shut it down.
Create a new HAOS VM with the new script selecting Advanced instead of using the default settings (the script will ask) so that you can insert the MAC address from the other VM (this will keep the IP the same as the old VM).
Upload and restore the backup.
If everything is working as it should, remove the old VM (never run both VMβs at the same time)
Is the MAC address the one listed on the Summary view or the one one listed under the More button under the IP address and then next to hassio in the pop up window?
Proxmox is exceptional, I just decided to migrate my entire home lab from ESXi to Proxmox.
Thank you @kanga_who for the scripts and description.
To migrate an existing HAOS VM from ESXi to Proxmox just follow their guide. You need a temporary storage mounted to Proxmox, I used a NFS share from Synology. I used the command line version if ovftool, followed by qm importovf, as described.
After import, all I had to do was edit the VM settings in Proxmox, to change:
SCSI controller type from default LSI to VirtIO SCSI
BIOS type from default SeaBIOS to OVMF (UEFI)
And of course add a network adapter of the same type (in my case it was E1000), I copied over the MAC address too, so just got the same IP address as before from DHCP.
@tteck I tried doing this today however I encountered an error in zigbee2mqtt. In the log I got the following zigbee2mqtt fatal: can only run as pid 1. Iβm using EDGE version of zigbee2mqtt so think that is the problem being incompatible with OS 9.
Iβm thinking of breaking down my VM again into individual LXCs. A few questions for you though if you donβt mind:
In your zigbee2mqtt LXC, the last few lines says about copying settings from an existing zigbee2mqtt LXC to the new one. What files are you copying? I would be looking to get the data out of the existing VM but would like to know what I need to extract. Iβve had a look at the .sh and it looks pretty complicated.
In your travels, have you come across a cloudflared LXC implementation? I wouldnβt know where to start if Iβm being honest; I have the addon installed in VM but really really donβt want to loose that moving back to separate LXCs.
Also, in your travels/scripts have you come across a file editor like the Ha addon? I know I can install Studio Code Server however that isnβt so great for editing files from a mobile/tablet
Incremental is nice. But I prefer duplication backups.
Case point:
Iβm always trying to make improvements (tinkering), then hours or a day later discover that what I thought was an improvement, turns out to be a disaster. I have 24 backups, 4 hrs apart to find a place in time before my mistake.
Proxmox Backup Server can do Incremental & Deduplication backups
trying to followβ¦Iβve set up the backup (as shown). How do I use the backup to reinstall the last good HA? Is this an incremental backup of changes onlyβ¦or is it a full backup?
I love running HA as a virtual machine and it has worked wonderfully. I discovered a little issue this morning, I had created a backup task to run at 2am this morning and had chosen the option of stopping the VMβs that were running. This morning when I got up Zigbee2MQTT had not started properly and every zigbee device was showing offline until I stopped Z2MQTT then restarted it. Is it OK to use the snapshot option when making backups rather than stopping the VM? What I have found is that if I stop the VM from the ProxMox interface the same happens, If I shutdown HA using the shutdown host option on settings the VM shuts down and when I restart Z2MQTT starts properly as well. It appears stopping the VM from ProxMox somehow interferes with Z2MQTT starting back up again.
I actually just did a manual backup using snapshot and everything remained working. If I ever need to reboot my ProxMox machine or shutdown the VM I will do it form within HA first.
I did some testing with another VM I had setup and if you stop the VM and watch the console the HA instance shuts down properly.
I found on Github yesterday that the error with Z2MQTT not starting properly is known and a fix is being tested. For now the solution was to turn off the watchdog feature in Z2MQTT. I can then shut the VM down from ProxMox and everything starts back up OK