Description of problem: For test purposes I have switched from spec.running to spec.runStrategy, what enables me to leave the vM powered off if it has crashed or was shutoff gracefully by administrator (please see: https://docs.openshift.com/container-platform/4.8/virt/virtual_machines/virt-create-vms.html#virt-about-runstrategies-vms_virt-create-vms for more details). If I shutoff the VM, VMI is being left in "Success" phase. This makes WebUI show the VM as "Starting" what is pretty misleading as this VM won’t be started until VMI will be deleted and VM started manually. Version-Release number of selected component (if applicable): 4.8.2 How reproducible: All time Steps to Reproduce: 1. Create VM 2. Use spec.runStrategy: Manual or RerunOnFailure 3. Shutdown VM gracefully from inside (shutdown -P now for an instance) 4. Observe VMI stays in "Succeeded" phase and WebUI shows VM as "Starting". Actual results: Shutoff VM is shown as "Starting" in WebUI. Expected results: VM should be shown as "Off", there should be also information that user should delete VMI before VM could be started again. Additional info:
It only happens with spec.runStrategy: Manual, not happen with spec.runStrategy: RerunOnFailure when shutdown the VM inside. BTW, follow the doc by using virtctl to start/stop/restart the VM with "spec.runStrategy: Manual" has no this issue. Manual The start, stop, and restart virtctl client commands can be used to control the VMI’s state and existence.
Verified on Client Version: 4.9.0-0.nightly-2021-07-20-125820 Server Version: 4.9.11
There isn't a fix for the bug yet, how did you verify this bug?
Verified on master/4.10.0-0.nightly-2022-01-04-214702. The VM restarts, the status label changes accordingly.
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory (Moderate: OpenShift Container Platform 4.10.3 security update), and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHSA-2022:0056