[libvirt] Can't Pass Through USB Device To Ubuntu 9.05 Guest OS

Robert L Cochran cochranb at speakeasy.net
Sun Jun 7 01:29:43 UTC 2009


Greetings!

I created Bug 504444 
<https://bugzilla.redhat.com/show_bug.cgi?id=504444> which is partially 
quoted in this post:

----------------------------------------------------------------

Coding this xml:

<hostdev mode='subsystem' type='usb'>
        <source>
           <vendor id='0x0403'/>
    <product id='0x6001'/>
        </source>
</hostdev>

should let my Ubuntu 9.04 guest have access to the device, which in this case
is a USB-to-Serial UART (based on an FTDI FT232RL chip.) However the guest does
not "see" the device or recognize it in any way. It does not show up in the
guest's /var/log/messages or in the output of lsusb. I would like the guest to
have access to this device.

This is what virsh seems to be seeing:

# virsh dumpxml Ubuntu9
<domain type='kvm'>
   <name>Ubuntu9</name>
   <uuid>cb8c3d15-fe92-1bf2-5676-03370743e815</uuid>
   <memory>1572864</memory>
   <currentMemory>1572864</currentMemory>
   <vcpu>1</vcpu>
   <os>
     <type arch='x86_64' machine='pc'>hvm</type>
     <boot dev='hd'/>
   </os>
   <features>
     <acpi/>
     <apic/>
     <pae/>
   </features>
   <clock offset='utc'/>
   <on_poweroff>destroy</on_poweroff>
   <on_reboot>restart</on_reboot>
   <on_crash>restart</on_crash>
   <devices>
     <emulator>/usr/bin/qemu-kvm</emulator>
     <disk type='file' device='cdrom'>
       <target dev='hdc' bus='ide'/>
       <readonly/>
     </disk>
     <disk type='file' device='disk'>
       <source file='/var/lib/libvirt/images/Ubuntu9.img'/>
       <target dev='vda' bus='virtio'/>
     </disk>
     <interface type='network'>
       <mac address='54:52:00:74:32:2f'/>
       <source network='default'/>
       <model type='virtio'/>
     </interface>
     <serial type='pty'>
       <target port='0'/>
     </serial>
     <console type='pty'>
       <target port='0'/>
     </console>
     <input type='mouse' bus='ps2'/>
     <graphics type='vnc' port='-1' autoport='yes'/>
     <sound model='es1370'/>
     <hostdev mode='subsystem' type='usb' managed='no'>
       <source>
         <vendor id='0x0403'/>
         <product id='0x6001'/>
       </source>
     </hostdev>
   </devices>
</domain>


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

libvirt-0.6.2-11.fc11.x86_64


----------------------------------

Any suggestions for fixing this problem? Is there a clear procedure for 
getting a Fedora virtualization guest to recognize a USB device?

Thanks for your help!

Bob Cochran






More information about the libvir-list mailing list