Apparmor doesn't allow volume to attach in 13.10 Ubuntu

Bug #1259860 reported by Rushi Agrawal
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
libvirt (Ubuntu)
Expired
High
Unassigned

Bug Description

Host machine: Ubuntu desktop 13.10
Setup: devstack

When I try to attach a volume to an instance via the CLI, the volume doesn't get attached. It's status still shows 'available'. While the logs tell that 'device /dev/vdx is busy'. Here are the logs from screen http://paste.openstack.org/show/54808/

I looked into /var/log/libvirt/libvirtd.log and found this:
http://paste.openstack.org/show/54809/

As per this guy's question at ask.openstack.org,
https://ask.openstack.org/en/question/7128/deviceisbusy-the-supplied-device-vdx-is-busy/
I uninstalled apparmor, and restarted and tried again. EVERYTHING went smooth! Looks like some issue with apparmor conflicting with libvirt.

Chuck Short (zulcss)
affects: nova → ubuntu
affects: ubuntu → libvirt (Ubuntu)
Changed in libvirt (Ubuntu):
status: New → Triaged
importance: Undecided → High
Revision history for this message
Serge Hallyn (serge-hallyn) wrote :

When I simply create a vm, an extra disk and some xml like

<disk type='block'>
   <driver name='qemu'/>
   <source dev='/tmp/x.img'/>
   <target dev='vdc' bus='virtio'/>
 </disk>

and do

virsh attach-device saucy /tmp/x.xml --live

then the vm definition gets the /tmp/x.img definition, and
/etc/apparmor.d/libvirt/libvirt-$uuid.files has /tmp/x.img rw.

Can someone with a saucy or trusty nova setup please set
log_level = 1
in /etc/libvirt/libvirtd.conf, (then do
stop libvirt-bin; rm /var/log/libvirt/libvirtd.log; start libvirt-bin)
and reproduce this and attach /var/log/libvirt/libvirtd.log to
this bug? I'd like to see which path this takes through libvirt
when done by nova.

Changed in libvirt (Ubuntu):
status: Triaged → Incomplete
Revision history for this message
Launchpad Janitor (janitor) wrote :

[Expired for libvirt (Ubuntu) because there has been no activity for 60 days.]

Changed in libvirt (Ubuntu):
status: Incomplete → Expired
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.