Bug 1390553

Summary: Re-assign MACs that are already in use in the destination DC isn't working
Product: [oVirt] ovirt-engine Reporter: Michael Burman <mburman>
Component: BLL.NetworkAssignee: Yevgeny Zaspitsky <yzaspits>
Status: CLOSED CURRENTRELEASE QA Contact: Meni Yakove <myakove>
Severity: high Docs Contact:
Priority: high    
Version: 4.1.0CC: bugs, danken
Target Milestone: ovirt-4.1.0-betaFlags: rule-engine: ovirt-4.1+
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-02-15 14:52:02 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: Network RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Bug Depends On:    
Bug Blocks: 1226206    
Attachments:
Description Flags
engine log none

Description Michael Burman 2016-11-01 11:47:39 UTC
Description of problem:
Re-assign MACs that are already in use in the destination DC isn't working.

2016-11-01 13:25:34,657 - Dummy-1 - storagedomains - DEBUG - Action request content is --  url:/ovirt-engine/api/storagedomains/009a842a-ed19-44b3-a130-b5b89f0593e4/vms/9222428c-557d-47c7-8b
f5-8a4fae844176/register body:<action>
   <async>false</async>
   <cluster>
       <name>golden_env_mixed_1</name>
   </cluster>
   <grace_period>
       <expiry>10</expiry>
   </grace_period>
   <reassign_bad_macs>true</reassign_bad_macs>
</action> 

2016-11-01 13:25:34,659 - Dummy-1 - storagedomains - INFO - Using Correlation-Id: storagedomains_syncAction_8d5d048d-4ace-4fb4
2016-11-01 13:25:35,162 - Dummy-1 - core_api - DEBUG - Request POST response time: 0.259
2016-11-01 13:25:35,164 - Dummy-1 - storagedomains - DEBUG - Cleaning Correlation-Id: storagedomains_syncAction_8d5d048d-4ace-4fb4
2016-11-01 13:25:35,165 - Dummy-1 - api_utils - ERROR - Failed to syncAction element NOT as expected:
       Status: 409
       Reason: Conflict
       Detail: [MAC Address is already in use.]

Version-Release number of selected component (if applicable):
4.1.0-0.0.master.20161031231324.git5d8702e.el7.centos.noarch + Yevgeny rpms

How reproducible:
100% 

Steps to Reproduce:
1. Import vm from data domain with macs that already in use in the destination DC and re-assign macs(send true)

Actual results:
Failed. 

Expected results:
Re-assign macs should work for duplicated macs.

Additional info:
We are testing Yevgeny rpms on latest master.

Comment 1 Michael Burman 2016-11-01 12:23:24 UTC
Created attachment 1216092 [details]
engine log

Comment 2 Dan Kenigsberg 2016-11-01 12:26:24 UTC
Thanks for reporting the issue and supplying the logs, even though "Yevgeny rpms" is not a very specific definition of the tested code. In my opinion it's a bit to early for bugzilla.

Comment 3 Michael Burman 2016-11-01 15:19:27 UTC
This is the code we testing - https://gerrit.ovirt.org/#/c/65278/

Comment 4 Michael Burman 2016-12-05 10:07:14 UTC
Verified on - 4.1.0-0.2.master.20161204231323.gite9669ad.el7.centos