Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.

Bug 1091714

Summary: [Network labels] Network label rename should be blocked while label is configured on hosts
Product: Red Hat Enterprise Virtualization Manager Reporter: GenadiC <gcheresh>
Component: ovirt-engine-webadmin-portalAssignee: Moti Asayag <masayag>
Status: CLOSED CURRENTRELEASE QA Contact: Michael Burman <mburman>
Severity: high Docs Contact:
Priority: high    
Version: 3.4.0CC: danken, ecohen, gklein, iheim, lvernia, masayag, myakove, nyechiel, rbalakri, Rhev-m-bugs, yeylon
Target Milestone: ---   
Target Release: 3.5.0   
Hardware: x86_64   
OS: Linux   
Whiteboard: network
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-02-17 17:08:57 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:
Embargoed:
Bug Depends On:    
Bug Blocks: 1142923, 1156165    

Description GenadiC 2014-04-27 14:02:43 UTC
Description of problem:
If after attaching network to Host NIC with Network label feature, you change the Network label on the Network to non-existent label, the network doesn't get removed from the Host NIC and it should

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


How reproducible:
Always

Steps to Reproduce:
1. Create label lb_1 on Host NIC
2. Create label lb_1 on new network
3. Check the network is attached to the Host NIC with the same label
4. Change network label on the network to lb_2 (new label)

Actual results:
Network is still attached to the Host NIC

Expected results:
Network should be removed from Host NIC as there is no label lb_2 on Host NIC

Additional info:

Comment 1 Moti Asayag 2014-04-27 14:22:50 UTC
This action should be blocked by UpdateNetworkCommand.canDoAction() and specifically the bug resides in:

UpdateNetworkValidator.notRenamingLabel(String oldLabel):

1. the parameter name should be newLabel
2. the check inside the loop should be changed to:
   if (NetworkUtils.isLabeled(nic) && nic.getLabels().contains(network.getLabel()))

Comment 4 Michael Burman 2014-07-16 13:51:18 UTC
Verified on-  oVirt Engine Version: 3.5.0-0.0.master.20140715172116.git4687dc1.el6 

The action will be blocked with the next error:
"Error while executing action: Cannot edit Network. Renaming a network label while configured on hosts interfaces is not supported. Please unlabel the network first and later specify the new one."

Comment 6 Eyal Edri 2015-02-17 17:08:57 UTC
rhev 3.5.0 was released. closing.