On Mon, 2023-10-23 at 13:19 -0400, Jonathan Proulx wrote:
I've seen similar log traces with overcommitted memory when the hypervisor runs out of physical memory and OOM killer gets the VM process.
This is an unusuall configuration (I think) but if the VM owner claims they didn't power down the VM internally you might look at the local hypevisor logs to see if the VM process crashed or was killed for some other reason.
yep OOM events are one common causes fo this. nova is bacialy just saying "hay you said this vm should be active but its not, im going to update the db to reflect reality." you can turn that off with https://docs.openstack.org/nova/latest/configuration/config.html#workarounds... or https://docs.openstack.org/nova/latest/configuration/config.html#DEFAULT.syn... either disabel the sync via setign the interval to -1 or disable haneling the virt lifecycle events. i would recommend the sync_power_state_interval approach but again if vms are stopping and you dont know why you likely should discover why rahter then just turning if the update of the nova db to reflect the actual sate.
-Jon
On Mon, Oct 23, 2023 at 02:02:26PM +0100, smooney@redhat.com wrote: :On Mon, 2023-10-23 at 17:45 +0530, AJ_ sunny wrote: :> Hi team, :> :> I am using openstack kolla ansible on wallaby version and currently I am :> facing issue with virtual machine, vm is shutoff by itself and and from log :> it seems libvirt lifecycle stop event triggering again and again :> :> Logs:- :> 2023-10-16 08:48:10.971 7 WARNING nova.compute.manager :> [req-c7b731db-2b61-400e-917f-8645c9984696 f226d81a45dd46488fb2e19515 848 :> 316d215042914de190f5f9e1c8466bf0 default default] [instance: :> 4b04d3f1-1fbd-4b63-b693-a0ef316ecff3] Received unexpected - vent :> network-vif-plugged-f191f6c8-dff5-4c1b-94b3-8d91aa6ff5ac for instance with :> vm_state active and task_state None. 2023-10-21 22:42:44.589 7 INFO :> nova.compute.manager [-] [instance: 4b04d3f1-1fbd-4b63-b693-a0ef316ecff3] :> VM Stopped (Lifecyc Event) :> :> 2023-10-21 22:42:44.683 7 INFO nova.compute.manager :> [req-1d99b87b-7ff7-462d-ab18-fbdec6bda71d -] [instance: 4b04d3f1- :> fbd-4b63-b693-a0ef316ecff3] During _sync_instance_power_state the DB :> power_state (1) does not match the vm_power_state from ti e hypervisor (4). :> Updating power_state in the DB to match the hypervisor. :> :> 2023-10-21 22:42:44.811 7 WARNING nova.compute.manager :> [req-1d99b87b-7ff7-462d-ab18-fbdec6bda71d ----] [instance: 4b04d3f :> 1-1fbd-4b63-b693-a0ef316ecff3] Instance shutdown by itself. Calling the :> stop API. Current vm_state: active, current task_state : None, original DB :> power_state: 1, current VM power_state: 4 2023-10-21 22:42:44.977 7 INFO :> nova.compute.manager [req-1d99b87b-7ff7-462d-ab18-fbdec6bda71d -] :> [instance: 4b04d3f1-1 :> :> fbd-4b63-b693-a0ef316ecff3] Instance is already powered off in the :> hypervisor when stop is called. : :that sounds like the guest os shutdown the vm. :i.e. somethign in the guest ran sudo poweroff :then nova detected teh vm was stoped by the user and updated its db to match :that. : :that is the expected beahvior wehn you have the power sync enabled. :it is enabled by default. :> :> :> Thanks & Regards :> Arihant Jain :> +91 8299719369 :