Description of problem: If a VM is using local PV and its evictionStrategy: LiveMigrate, OCP upgrade would result with nodes in "Ready,SchedulingDisable" state. As a VM with local PVs and evictionStrategy: LiveMigrate is not a supported use case at the moment, such VMs should be blocked from running. Version-Release number of selected component (if applicable): CNV 2.4
Doc BZ for 2.4: https://bugzilla.redhat.com/show_bug.cgi?id=1859129
The same block logic should also be applied to VMs with pass-through features such as SRIOV and GPU
I addressed both SRIOV and GPUs there: https://github.com/kubevirt/kubevirt/pull/3944 Local PVs is more complicated, since we don't know at VMI creation if PVs are local or not.
Further design work needs to be done for this bug and so we plan to move it to future for now.
name: VMCannotBeEvicted expr: kubevirt_vmi_non_evictable > 0 for: 1m labels: severity: warning annotations: description: Eviction policy for {{ $labels.name }} (on node {{ $labels.node }}) is set to Live Migration but the VM is not migratable summary: The VM's eviction strategy is set to Live Migration but the VM is not migratable --- Created a VM with HostPathProvisioner as the StorageClass. Accessed the Prometheus URL and we see the above alert "VMCannotBeEvicted" VERIFIED with virt-operator/images/v4.9.0-35
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 Virtualization 4.9.0 Images security and bug fix 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-2021:4104