Bug 1809027

Summary: [RFE] CloudForms should check that the VM doesn't exist in destination during migration preflight check
Product: Red Hat CloudForms Management Engine Reporter: Fabien Dupont <fdupont>
Component: V2VAssignee: Fabien Dupont <fdupont>
Status: CLOSED ERRATA QA Contact: Nandini Chandra <nachandr>
Severity: high Docs Contact: Red Hat CloudForms Documentation <cloudforms-docs>
Priority: high    
Version: 5.11.0CC: bthurber, simaishi, sshveta
Target Milestone: GAKeywords: ZStream
Target Release: 5.11.5Flags: pm-rhel: cfme-5.11.z+
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: 5.11.5.0 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-05-05 13:43:32 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: V2V Target Upstream Version:
Embargoed:
Bug Depends On: 1809580    
Bug Blocks:    

Description Fabien Dupont 2020-03-02 09:47:31 UTC
Description of problem:

One failure condition for migration is that a virtual machine with the same name already exists in the destination provider. This will cause virt-v2v to fail and is already checked by virt-v2v-wrapper. It would be great to add a check in migration pre-flight check, in order to not alter the source VM when we know it will fail.

Comment 2 Fabien Dupont 2020-03-02 17:25:16 UTC
https://github.com/ManageIQ/manageiq/pull/19911

Comment 3 CFME Bot 2020-03-20 17:30:26 UTC
New commit detected on ManageIQ/manageiq/ivanchuk:

https://github.com/ManageIQ/manageiq/commit/457a029edd80336c83d2bbf7599858065491da02
commit 457a029edd80336c83d2bbf7599858065491da02
Author:     Adam Grare <agrare>
AuthorDate: Tue Mar  3 16:34:45 2020 +0000
Commit:     Adam Grare <agrare>
CommitDate: Tue Mar  3 16:34:45 2020 +0000

    Merge pull request #19911 from fdupont-redhat/v2v_bz_1809027

    [V2V] Preflight check: verify if a VM with same name already exists in destination

    (cherry picked from commit 6de1130e5d9a307bc9db6c3ec5c73207fd48c316)

    https://bugzilla.redhat.com/show_bug.cgi?id=1809027

 app/models/service_template_transformation_plan_task.rb | 17 +
 spec/models/service_template_transformation_plan_task_spec.rb | 10 +
 2 files changed, 27 insertions(+)

Comment 4 Nandini Chandra 2020-04-03 14:42:57 UTC
Verified in master.20200401002122_8bd930cd58

Comment 5 Nandini Chandra 2020-04-16 13:40:05 UTC
See https://bugzilla.redhat.com/show_bug.cgi?id=1821842  V2V: Message logged for preflight check failure should be more specific when VM already exists on target provider

Comment 6 Nandini Chandra 2020-04-16 18:12:43 UTC
Verified that preflight check fails if VM already exists on target provider.

Verified in 5.11.5

Comment 8 CFME Bot 2020-05-01 23:35:21 UTC
New commit detected on ManageIQ/manageiq/jansa:

https://github.com/ManageIQ/manageiq/commit/3ac964408a2e7bf7927db8406712072e2581e374
commit 3ac964408a2e7bf7927db8406712072e2581e374
Author:     Adam Grare <agrare>
AuthorDate: Tue Mar  3 16:34:45 2020 +0000
Commit:     Adam Grare <agrare>
CommitDate: Tue Mar  3 16:34:45 2020 +0000

    Merge pull request #19911 from fdupont-redhat/v2v_bz_1809027

    [V2V] Preflight check: verify if a VM with same name already exists in destination

    (cherry picked from commit 6de1130e5d9a307bc9db6c3ec5c73207fd48c316)

    https://bugzilla.redhat.com/show_bug.cgi?id=1809027

 app/models/service_template_transformation_plan_task.rb | 17 +
 spec/models/service_template_transformation_plan_task_spec.rb | 10 +
 2 files changed, 27 insertions(+)

Comment 10 errata-xmlrpc 2020-05-05 13:43:32 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/RHBA-2020:2020