Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.

Bug 638570

Summary: [RHEL6 Beta:] 'virsh attach-interface' succeeds even if an already attached target device is specified.
Product: Red Hat Enterprise Linux 6 Reporter: Sadique Puthen <sputhenp>
Component: libvirtAssignee: Laine Stump <laine>
Status: CLOSED NOTABUG QA Contact: Virtualization Bugs <virt-bugs>
Severity: medium Docs Contact:
Priority: low    
Version: 6.0CC: dallan, dyuan, eblake, gsun, jwest, whuang, xen-maint, ydu
Target Milestone: rc   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2011-06-17 18:04:20 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 658636    

Description Sadique Puthen 2010-09-29 11:43:44 UTC
Description of problem:

Description of Problem:
"virsh attach-interface" succeeds with the following message even if an already attached target device is specified.

# virsh attach-interface <domain-name> bridge br0 --target vnet0

Interface attached successfully

vnet0 is just an already attached target device. It should report an error
message like "vnet0 already attached" then. We believe that this is a bug of
"virsh attach-interface". Could you please fix "virsh attach-interface" so
that it reports an error message in the above case?

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

Red Hat Enterprise Linux Version Number: 6
Release Number: snapshot13
Architecture: x86_64
Kernel Version: kernel-2.6.32-70.el6.x86_64
Related Package Version: libvirt-client-0.8.1-27.el6.x86_64 
How reproducible:


Steps to Reproduce:

1 - # virsh dumpxml rhel6
....
....
 <interface type='bridge'>
      <mac address='52:54:00:73:00:0e'/>
      <source bridge='br0'/>
      <target dev='vnet0'/>
      <model type='virtio'/>
      <alias name='net0'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x05' function='0x0'/>
    </interface>
....
....

# virsh attach-interface rhel6 bridge br0 --target vnet0
Interface attached successfully

It should say the interface is already attached.
 
Actual results:

Hotplugging and already attached network interface is successful.

Expected results:

Hot plugging an already attahced network interface should fail with an error message "interface already attached"

Additional info: