root@ubuntu:~# root@ubuntu:~# virsh define testguest.xml Domain testguest defined from testguest.xml
root@ubuntu:~# virsh start testguest Domain testguest started root@ubuntu:~# cat <<EOF >usb.xml > <hostdev mode='subsystem' type='usb' managed='yes'> > <source> > <vendor id='0x046d'/> > <product id='0x0825'/> > </source> > </hostdev> > EOF root@ubuntu:~# virsh attach-device testguest usb.xml error: Failed to attach device from usb.xml error: internal error: unable to execute QEMU command 'device_add': failed to find host usb device 2:10 Denies while USB was initialized the first time: [ 1046.984694] audit: type=1400 audit(1508926280.712:48): apparmor="STATUS" operation="profile_replace" profile="unconfined" name="libvirt-deadbeef-dead-beef-dead-beefdeadbeef" pid=6668 comm="apparmor_parser" [ 1046.987757] audit: type=1400 audit(1508926280.715:49): apparmor="DENIED" operation="open" profile="libvirt-deadbeef-dead-beef-dead-beefdeadbeef" name="/run/udev/data/c189:133" pid=6638 comm="qemu-system-x86" requested_mask="r" denied_mask="r" fsuid=64055 ouid=0 [ 1046.987831] audit: type=1400 audit(1508926280.715:50): apparmor="DENIED" operation="open" profile="libvirt-deadbeef-dead-beef-dead-beefdeadbeef" name="/run/udev/data/c189:256" pid=6638 comm="qemu-system-x86" requested_mask="r" denied_mask="r" fsuid=64055 ouid=0 [ 1046.988143] audit: type=1400 audit(1508926280.715:55): apparmor="DENIED" operation="open" profile="libvirt-deadbeef-dead-beef-dead-beefdeadbeef" name="/run/udev/data/c189:129" pid=6638 comm="qemu-system-x86" requested_mask="r" denied_mask="r" fsuid=64055 ouid=0 [ 1046.988263] audit: type=1400 audit(1508926280.715:57): apparmor="DENIED" operation="open" profile="libvirt-deadbeef-dead-beef-dead-beefdeadbeef" name="/run/udev/data/c189:0" pid=6638 comm="qemu-system-x86" requested_mask="r" denied_mask="r" fsuid=64055 ouid=0 Due to the design of qemu (no rescan later) we need to restart the qemu process after the upgrade. # Upgrade to Proposed (in other window) # then start guest again and then attach the device (now working) virsh attach-device testguest usb.xml => Verified Note: since you likely came here for having issues with USB passthrough. While working on this I found related issues, please check the following bugs to be sure you not just have to add a config or so: - bug 1727311 - bug 1727313 ** Tags removed: verification-needed verification-needed-artful ** Tags added: verification-done verification-done-artful -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1552241 Title: libvirt-bin apparmor settings for usb host device To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/libvirt/+bug/1552241/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs