Bug 548401 - Ownership of LVM backing store not updated on domain creation
Ownership of LVM backing store not updated on domain creation
Status: CLOSED DUPLICATE of bug 579067
Product: Fedora
Classification: Fedora
Component: libvirt (Show other bugs)
13
All Linux
low Severity medium
: ---
: ---
Assigned To: Daniel Veillard
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2009-12-17 06:04 EST by Matthew Booth
Modified: 2010-05-26 14:06 EDT (History)
8 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2010-05-26 14:06:07 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Matthew Booth 2009-12-17 06:04:59 EST
Description of problem:
In F12, qemu runs as user qemu rather than root. While it normally automatically changes the ownership of storage when a domain is created, it does not do this for an LVM backing store. This may also be the case for other types of backing store, but I have not tested anything other than LVM. This means that domain creation will fail, reporting permission denied on the snapshot volume.

Version-Release number of selected component (if applicable):
libvirt-0.7.4-1.fc12.x86_64 (Rawhide recompiled for F12)

How reproducible:
Always

Steps to Reproduce:
1. qemu-img create -b /dev/vg_foo/lv_guest -f qcow2 snapshot.qcow2
2. Add snapshot.qcow2 to guest
3. Start guest
  
Actual results:
Permission denied

Expected results:
Both snapshot.qcow2 and /dev/vg_foo/lv_guest have ownership changed.
Comment 1 Christoph Höger 2009-12-17 10:28:11 EST
The same (on a simple image file) for me.

Even after setting the qemu user to root in /etc/libvirt/qemu.conf and the image to mode 777 I still got "permission denied" (no avc denial).

I am not sure from stracing what libvirtd tries to do here, but what it does is:

1. chown the image file to root:root (<- total crap)
2. start qemu with some very strange security restrictions.
Comment 2 Bug Zapper 2010-03-15 09:36:04 EDT
This bug appears to have been reported against 'rawhide' during the Fedora 13 development cycle.
Changing version to '13'.

More information and reason for this action is here:
http://fedoraproject.org/wiki/BugZappers/HouseKeeping
Comment 3 Cole Robinson 2010-05-26 14:06:07 EDT

*** This bug has been marked as a duplicate of bug 579067 ***

Note You need to log in before you can comment on or make changes to this bug.