Bug 1902028

Summary: Validation stage with error messages added to the migration process
Product: Migration Toolkit for Virtualization Reporter: Ilanit Stein <istein>
Component: GeneralAssignee: Sam Lucidi <slucidi>
Status: CLOSED ERRATA QA Contact: Ilanit Stein <istein>
Severity: medium Docs Contact: Avital Pinnick <apinnick>
Priority: high    
Version: 2.0.0CC: fdupont, miguel, slucidi
Target Milestone: ---Keywords: Reopened
Target Release: 2.0.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Enhancement
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2021-06-10 17:11:26 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Ilanit Stein 2020-11-26 15:47:48 UTC
Description of problem:
On current VM migration, the only stages are Copy & Conversion.
This do not cover the cases where the Copy has not yet started from some reason.
For example, vddk-init-image is not available or the migration is pending a suitable storage to be found.
Adding such a stage will improve usability, since right now such cases look in UI as if image copy had started and is stuck from unknown reason.

Another option to address this can be to propagate the VM import "pre copy" conditions, like the ones mentioned above to reflect the user at what stage we are at, and why migration is not progressing to the "Copy" stage.

Version-Release number of selected component (if applicable):
MTV-2.0

Comment 1 Miguel Perez Colino 2021-03-25 12:46:54 UTC
One use case would be checking that VDDK is properly configured. If VDDK is not correctly configured for a VMware provider, warn the user on the steps required to continue.

Comment 2 Fabien Dupont 2021-04-07 07:21:06 UTC
Most of the conversation is in BZ 1902742. Marking this one as duplicate.

*** This bug has been marked as a duplicate of bug 1902742 ***

Comment 3 Fabien Dupont 2021-04-07 07:22:48 UTC
Oups. This one should remain. Reopening.

Comment 4 Sam Lucidi 2021-04-26 20:22:59 UTC
I've added a `reason` field to explain the current task's `phase`. If the DV is waiting for the PVC to bind, the disk transfer task's `phase` will indicate "Blocked", and the `reason` will indicate the reason why, such as waiting for the vddk-init-image to be configured.

https://github.com/konveyor/forklift-controller/pull/213

Comment 5 Fabien Dupont 2021-05-03 12:10:24 UTC
The fix should be part of build mtv-operator-bundle-container-2.0.0-4 / iib:72115.

Comment 6 Ilanit Stein 2021-05-25 16:40:19 UTC
Verified on CNV-2.6.3-25/MTV upstream latest May 24.

The fix is doing what's it's intended to - propagate DataVolume reported reason.

Those cases were ran, and plan CR status was checked:
1. No vddk-init-image case: reason not mentioned because CDI importer doesn't report it like before.
2. Running VM migration case: (VM import is running and it is not pending anything) reason: pod is running
3. Pending storage case: migrating a VM with 100GB disk, to nfs, when there are only PVs with smaller size on the OCP cluster - reason: Pending.

considering the above results, i'm afraid for MTV 2.0 GA we are actually not adding here any helpful info on the reason of what plan is pending for. 
This is because CDI (DataVolume) doesn't report it.

Comment 9 errata-xmlrpc 2021-06-10 17:11:26 UTC
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 (MTV 2.0.0 images), 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/RHEA-2021:2381