Issue: Windows Server 2022 VM in OpenNebula Stuck in "Running" State After Shutdown Attempt

I am working on a Windows Server 2022 Standard VM running on OpenNebula.
While attempting to shut down the VM either via the Nebula VNC console or over RDP, the connectivity broke during the shutdown process. However, in the OpenNebula dashboard, the VM state still shows as “Running” instead of “Powered Off.”
Additionally, no shutdown logs were generated.

Could anyone suggest what might be causing this issue and how to fix it?

Check the monitoring logs at /var/log/one/monitor.log to see what is happening with the VM. The VM also has a dedicated log file at /var/log/one/<vm_id>.log that you could check. You can also check the actual VM state on libvirt by running virsh dominfo one-<vm_id> on the KVM node where the VM is running.

[oneadmin@HOST~]$ tail -f /var/log/one/245158.log
Tue Apr 29 12:53:10 2025 [Z0][VMM][I]: from /var/tmp/one/datastore/xpath.rb:64:in `’
Tue Apr 29 12:53:10 2025 [Z0][VMM][I]: Datastore path not found
Tue Apr 29 12:53:10 2025 [Z0][VMM][I]: ExitCode: 0
Tue Apr 29 12:53:10 2025 [Z0][VMM][I]: Successfully execute virtualization driver operation: cancel.
Tue Apr 29 12:53:10 2025 [Z0][VMM][I]: clean: Executed “sudo -n ovs-ofctl del-flows private dl_dst=02:00:a4:34:c8:ed”.
Tue Apr 29 12:53:10 2025 [Z0][VMM][I]: clean: Executed “sudo -n ovs-ofctl del-flows private dl_dst=02:00:0a:14:76:06”.
Tue Apr 29 12:53:10 2025 [Z0][VMM][I]: ExitCode: 0
Tue Apr 29 12:53:10 2025 [Z0][VMM][I]: Successfully execute network driver operation: clean.
Tue Apr 29 12:53:10 2025 [Z0][VM][I]: New state is POWEROFF
Tue Apr 29 12:53:10 2025 [Z0][VM][I]: New LCM state is LCM_INIT

When we are powering off the node , the windows node went power off, after 5 minutes automatically node is getting fake running state . but node is in power off.

Tue Apr 29 12:53:10 2025 [Z0][VMM][I]: Successfully execute virtualization driver operation: cancel.
Tue Apr 29 12:53:10 2025 [Z0][VMM][I]: clean: Executed “sudo -n ovs-ofctl del-flows private dl_dst=02:00:a4:34:c8:ed”.
Tue Apr 29 12:53:10 2025 [Z0][VMM][I]: clean: Executed “sudo -n ovs-ofctl del-flows private dl_dst=02:00:0a:14:76:06”.
Tue Apr 29 12:53:10 2025 [Z0][VMM][I]: ExitCode: 0
Tue Apr 29 12:53:10 2025 [Z0][VMM][I]: Successfully execute network driver operation: clean.
Tue Apr 29 12:53:10 2025 [Z0][VM][I]: New state is POWEROFF
Tue Apr 29 12:53:10 2025 [Z0][VM][I]: New LCM state is LCM_INIT
Tue Apr 29 12:56:50 2025 [Z0][VMM][I]: VM found again by the drivers
Tue Apr 29 12:56:50 2025 [Z0][VM][I]: New state is ACTIVE
Tue Apr 29 12:56:50 2025 [Z0][VM][I]: New LCM state is RUNNING