Bug 537688

Summary: attach-interface: function is not supported by the hypervisor device type 'interface' cannot be attached
Product: [Fedora] Fedora Reporter: Gerry Reno <greno>
Component: libvirtAssignee: Daniel Veillard <veillard>
Status: CLOSED WONTFIX QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: urgent Docs Contact:
Priority: low    
Version: 11CC: berrange, clalance, crobinso, ian.woodstock, itamar, jforbes, veillard, virt-maint
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2009-11-16 06:27:48 EST Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:

Description Gerry Reno 2009-11-15 13:56:22 EST
Description of problem:
virsh attach-interface ... fails

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

How reproducible:
always

Steps to Reproduce:

I'm using libvirt 0.6.2 on F11 x86_64 and CPU supports hw virtualization.  When I try to do 'virsh attach-interface ...' I get an error that the function is not supported by the hypervisor device type 'interface' cannot be attached.  Is this command not supported?  Or is there something special I need to do?  I found it in the man page.


I have a private network declared.

And here is how I am trying to attach an interface:

# cat PRIVBR0.xml
 <network>
   <name>PRIVBR0</name>
   <bridge name='privbr0'/>
   <ip address='172.19.0.1' netmask='255.255.0.0'>
   </ip>
 </network>

# virsh net-list --all
Name                 State      Autostart
-----------------------------------------
PRIVBR0              active     yes
default              active     no

# virsh attach-interface CC  bridge privbr0
error: this function is not supported by the hypervisor: device type 'interface' cannot be attached

# grep emulator  CC.xml
   <emulator>/usr/bin/qemu-kvm</emulator>


I tried the 'attach-interface' both while the domain is running and while shutdown.  Neither works.




Actual results:
interface is not attached

Expected results:
interface is attached

Additional info:
Comment 1 Gerry Reno 2009-11-15 14:22:38 EST
I have also tried this as 'attach-device' with the same result:

# cat INTERFACE_PRIVBR0.xml 
    <interface type='bridge'>
      <mac address='00:0c:01:41:50:01'/>
      <source bridge='privbr0'/>
    </interface>

# virsh attach-device CC INTERFACE_PRIVBR0.xml 
error: Failed to attach device from INTERFACE_PRIVBR0.xml
error: this function is not supported by the hypervisor: device type 'interface' cannot be attached
Comment 2 Ian Woodstock 2009-11-15 19:34:27 EST
NIC hotplug was added in libvirt 0.70 http://libvirt.org/news.html

It's available in F12/rawhide now or you can look at virt-previews
http://fedoraproject.org/wiki/Virtualization_Preview_Repository
Comment 3 Daniel Berrange 2009-11-16 06:27:48 EST
As comment #2 says, NIC hotplug was not available in 0.6.2 libvirt, and it is not practical to backport this functionality. It is currently available in Fedora 12