You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Powersync doesn't sync VM states after power outtage #12411
After a power outtage, the host comes online and ssvm/cpvm on it start but not VRs, and the HA-enabled (via compute offering) user VMs are powered on in ACS but not running (off) on the KVM host. I'm not sure if some config is required, I expected this to work out of the box to sync VM states (i.e. set vm to stopped when it's not really running on the hypervisor host), or try to get the VM to run as it's on VM-HA enabled offering.
versions
ACS 4.22, on both x86 mini pc and arm64/raspberrypi5 KVM hosts; in adv zone using HA-enabled compute offering and uses NFS & local storage only.
The steps to reproduce the bug
...
What to do about it?
Ideally the power state of the VM should sync, and shutdown VMs on a rebooted/started KVM host after power outtage should try to bring up the user VMs (which are HA enabled).
Able to reproduce the issue if both control plane (mgmt server) and KVM host are down at the same time.
When the mgmt server and kvm host comes up later, the ha enabled vm and router says its running on kvm host but there is no vm running on the host ( virsh list --all)
Agent log
2026-01-13 13:04:35,239 WARN [kvm.resource.LibvirtConnection] (AgentRequest-Handler-2:[]) (logid:f3f12b6e) Can not find a connection for Instance r-154-VM. Assuming the default connection.
2026-01-13 13:04:35,239 WARN [resource.wrapper.LibvirtGetVmStatsCommandWrapper] (AgentRequest-Handler-2:[]) (logid:f3f12b6e) Can't get vm stats: org.libvirt.LibvirtException: Domain not found: no domain with matching name 'r-154-VM', continue
2026-01-13 13:04:35,240 INFO [kvm.resource.LibvirtConnection] (AgentRequest-Handler-2:[]) (logid:f3f12b6e) No existing libvirtd connection found. Opening a new one
2026-01-13 13:04:35,240 WARN [kvm.resource.LibvirtConnection] (AgentRequest-Handler-2:[]) (logid:f3f12b6e) Can not find a connection for Instance r-104-VM. Assuming the default connection.
2026-01-13 13:04:35,240 WARN [resource.wrapper.LibvirtGetVmStatsCommandWrapper] (AgentRequest-Handler-2:[]) (logid:f3f12b6e) Can't get vm stats: org.libvirt.LibvirtException: Domain not found: no domain with matching name 'r-104-VM', continue
2026-01-13 13:04:35,241 INFO [kvm.resource.LibvirtConnection] (AgentRequest-Handler-2:[]) (logid:f3f12b6e) No existing libvirtd connection found. Opening a new one
2026-01-13 13:04:35,241 WARN [kvm.resource.LibvirtConnection] (AgentRequest-Handler-2:[]) (logid:f3f12b6e) Can not find a connection for Instance i-2-155-VM. Assuming the default connection.
Activity
kiranchavala commentedon Jan 13, 2026
@yadvr Not able to reproduce the issue
Launched a 2 vm's one with HA enabled and another not ha enable on a KVM host 1
Made sure the global setting 'commands.timeout' value to a suitable value like "CheckHealthCommand=5,CheckOnHostCommand=5"
Shutdown the kvm host 1
The router and HA enabled vm restarted on another kvm host
The non-ha enabled vm went into stopped state
logs of ha enabled vm
Logs for Non ha enabled vm
yadvr commentedon Jan 13, 2026
@kiranchavala try to poweroff both control plane (mgmt server) and KVM host at the same time and try ?
The commands.timeout is empty in my env, is that required to make this work?
kiranchavala commentedon Jan 13, 2026
Thanks @yadvr
Able to reproduce the issue if both control plane (mgmt server) and KVM host are down at the same time.
When the mgmt server and kvm host comes up later, the ha enabled vm and router says its running on kvm host but there is no vm running on the host ( virsh list --all)
Agent log
yadvr commentedon Jan 15, 2026
requesting for a higher priority issue as this is related to VM HA being broken cc @DaanHoogland
kiranchavala commentedon Feb 4, 2026
Resolved with #12463