qemu-kvm fails with "Permission denied" when trying to open console.log

Bug #1337760 reported by Jaroslav Henner
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Invalid
Undecided
Unassigned

Bug Description

in the libvirt log:
qemu-kvm: -drive file=/var/lib/nova/instances/a2f907b5-6fe2-402a-86fe-81c44058a929/disk,if=none,id=drive-virtio-disk0,format=qcow2,cache=none: could not open disk image /var/lib/nova/instances/a2f907b5-6fe2-402a-86fe-81c44058a929/disk: Could not open file: Permission denied

The file is created with this permissions:
-rw-rw----. 1 nova nova 0 4. čec 04.58 /var/lib/nova/instances/a2f907b5-6fe2-402a-86fe-81c44058a929/console.log

# id qemu
uid=107(qemu) gid=107(qemu) groups=107(qemu),36(kvm)

openstack-nova-compute-2014.1-7.el7ost.noarch

Revision history for this message
Jaroslav Henner (jhenner) wrote :

There are lines like:

2014-07-04 04:41:03.685 5272 TRACE nova.compute.manager [instance: 1dbcc37a-828f-4285-843c-c3b3f51d6554] qemu-kvm: -chardev file,id=charserial0,path=/var/lib/nova/instances/1dbcc37a-828f-4285-843c-c3b3f51d6554/console.log: Could not open '/var/lib/nova/instances/1dbcc37a-828f-4285-843c-c3b3f51d6554/console.log': Permission denied

after I have manually added the permissions to the console.log `chmod a+rw ...`, there started to appear lines like:

2014-07-04 05:00:30.033 5272 TRACE nova.compute.manager [instance: a2f907b5-6fe2-402a-86fe-81c44058a929] qemu-kvm: -drive file=/var/lib/nova/instances/a2f907b5-6fe2-402a-86fe-81c44058a929/disk,if=none,id=drive-virtio-disk0,format=qcow2,cache=none: could not open disk image /var/lib/nova/instances/a2f907b5-6fe2-402a-86fe-81c44058a929/disk: Could not open file: Permission denied

Tracy Jones (tjones-i)
tags: added: libvirt
Revision history for this message
Thang Pham (thang-pham) wrote :

I believe it is the entire instance directory that may need to change permissions. What is the original permissions on /var/lib/nova/instances/? What happens when you try to create another instance?

Thang Pham (thang-pham)
Changed in nova:
status: New → Incomplete
Revision history for this message
Sean Dague (sdague) wrote :

I expect this is a downstream packaging issue on directory permisions

Changed in nova:
status: Incomplete → Invalid
Yang Luo (hsluoyz)
tags: added: migration
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Bug attachments

Remote bug watches

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