Bug 1709775

Summary: [v2v][UI] Report better failing kubevirt-vmware deployment
Product: OpenShift Container Platform Reporter: Ilanit Stein <istein>
Component: Console Kubevirt PluginAssignee: Filip Krepinsky <fkrepins>
Status: CLOSED ERRATA QA Contact: Ilanit Stein <istein>
Severity: high Docs Contact:
Priority: high    
Version: unspecifiedCC: aos-bugs, cnv-qe-bugs, dagur, fkrepins, gouyang, mguetta, mlibra, ncredi, rawagner, sgordon, tjelinek
Target Milestone: ---Keywords: TestBlocker
Target Release: 4.6.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: 2.0.0-14.6 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-07-24 20:16:06 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:
Attachments:
Description Flags
web-ui.log
none
error_message.png
none
expected_error.png none

Description Ilanit Stein 2019-05-14 10:02:57 UTC
Description of problem:

In the Create VM wizard, provision type: 'Import', add a new VMware, and click 'Connect', does nothing in response. The VM list is not filled, as expected.

In addition a window is opened with an error (see attachment "error_message:).

mlibra:
"Behind the scene, there is a new Deployment for the kubevirt-vmware pod created within the desired (target) namespace (fired asynchornously while passing through the Create VM Wizard).
If it fails, i.e. on missing image or whatever, the flow goes on normally and the user has no info about the issue.
As a result, the "Check" action does not finish and so the dropdown is not populated.
Without knowledge of the backend, it's (probably) impossible to detect it by the user.

Please file a bug to better report failing deployment of the kubevirt-vmware pod (handling k8s <--> VMWare API communication).

How can this happen?
The `version` within kwebui CR is reused for composing tag for kubevirt-vmware, same as for later kubevirt-v2v-conversion pod (used for the conversion of VM disks).
I suggest to use "v2.0.0" as the version within kwebui CR consistently with the (future) flow in HCO.
It's based on rule that all our images will be shipped with v2.0, v2.0.0, v2.0.0-X.Y.Z tags.

To be sure you deploy the right images (web-ui, kubevirt-vmware or kubevirt-v2v-conversion) and not those from some of your previous tries, you can either
- "docker rmi" them in your registry
- or use "image_pull_policy: Always" in the kwebui CR


Work around trial:

Edited the kwebui and put version: v2.0.0:
$ oc edit kwebui -o yaml

But still the same "Connect" issue existed. 
The output of:
oc logs -f kubevirt-web-ui-operator-7bdddf9589-khmg8
is attached (web-ui.log)


Version-Release number of selected component (if applicable):
HCO_BUNDLE_REGISTRY_TAG: v2.0.0-11


How reproducible:
100%

Comment 1 Ilanit Stein 2019-05-14 10:03:59 UTC
Created attachment 1568354 [details]
web-ui.log

Comment 2 Ilanit Stein 2019-05-14 10:05:13 UTC
Created attachment 1568356 [details]
error_message.png

Comment 3 Marek Libra 2019-05-14 10:17:46 UTC
Since v2.0.0-12 the deployment should work. Can you please retry?

Comment 4 Marek Libra 2019-05-14 10:19:49 UTC
If it works, scope of this BZ should be changed to: Report better failing kubevirt-vmware deployment.

Recently, potential deployment failure is silently ignored causing the "Check" button not working.

Comment 5 Ilanit Stein 2019-05-15 09:21:28 UTC
Using v2.0.0-12, the kubevirt-web-ui is installed properly by the hco image.
ibragins check the VMware provider 'Connect', and it works fine:
the connection is successful, and the VMware VMs are listed.

As this verifies this "Connect" bug is resolved 
I shall change the bug, according to comment #4.

Comment 6 Ilanit Stein 2019-05-15 09:25:19 UTC
New Description of the Problem:
Recently, potential deployment failure is silently ignored causing the 
Create VM wizard: VMware provider "Check" button not working.

Version: 
HCO_BUNDLE_REGISTRY_TAG: v2.0.0-12

Comment 7 Ilanit Stein 2019-05-15 09:38:17 UTC
The attachments, added from the HCO_BUNDLE_REGISTRY_TAG: v2.0.0-11 system,
of the UI error message, and the web-ui logs are still relevant.

Comment 8 Filip Krepinsky 2019-05-31 00:07:53 UTC
https://github.com/kubevirt/web-ui-components/pull/486

Comment 9 Marek Libra 2019-06-03 08:05:32 UTC
patch merged

Comment 14 Maayan Hadasi 2019-06-18 09:28:10 UTC
Created attachment 1581616 [details]
expected_error.png

Comment 15 Maayan Hadasi 2019-06-18 09:32:21 UTC
Verified as fixed in version:
HCO_BUNDLE_REGISTRY_TAG: v2.0.0-29

The expected error message is received while trying import VM from VMware (see attached: expected_error.png)

Comment 17 errata-xmlrpc 2019-07-24 20:16:06 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, 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-2019:1850