Issue
I've created a VM with wirt-manager, installed Win10 with a iso on start up. Couple of reboots, Installed software. All fine. creating an overlay, starting from the overlay. all fine. Creating second overlay on top. "Permission denied" on the base-image (W_64_10_v1.img). Other machines with less overlays and same rights are working fine.
Why can't I start the machine? / Which process is missing it's rights?
The images and backingchain might be correct, because I can start the images with sudo qemu-system ...
.
virsh # start W_64_10_v1
error: Failed to start domain W_64_10_v1
error: internal error: process exited while connecting to monitor:
2018-06-06T12:55:42.062395Z qemu-system-x86_64:
-drive file=/media/img/SharedImages/qemu18/W_64_10_v1_daemon.ovl,
format=qcow2,if=none,id=drive-ide0-1-0:
Could not open backing file: Could not open backing file:
Could not open '/media/img/SharedImages/qemu18/W_64_10_v1.img':
Permission denied
virsh version
Compiled against library: libvirt 4.0.0
Using library: libvirt 4.0.0
Using API: QEMU 4.0.0
Running hypervisor: QEMU 2.11.1
/etc/libvirt/qemu.conf (extract)
dynamic_ownership = 1
user = "root"
group = "root"
Filepermissiones: (addding every right to file... not working)
-rwxrwxrwx 1 root root 193K Jun 6 14:41 W_64_10_v1_daemon.ovl
-rwxrwxrwx 1 root root 193K Jun 6 14:41 W_64_10_v1_daemon.ovl.backup
-rwxrwxrwx 1 root root 135M Jun 6 14:41 W_64_10_v1_F.ovl
-rwxrwxrwx 1 root root 51G Jun 6 14:41 W_64_10_v1.img
Solution
Reason: wrongly created backingfile/overlay. during creation i haven't used the -F switch.
Base.img (ok - Win 10 Installation starting)
FirstFloor.ovl (ok - Win 10 Installation starting)
SecondFloor.ovl (permission denied -> Base.img) => assumed Bug
Roof.ovl (permission denied -> Base.img) => assumed Bug
create like (How to create the error)
qemu-img create -f qcow2 Base.img 50G
qemu-img create -f qcow2 -b Base.img FirstFloor.ovl
qemu-img create -f qcow2 -b FirstFloor.ovl SecondFloor.ovl
qemu-img create -f qcow2 -b SecondFloor.ovl Roof.ovl
This works because RAW is assumed, which leads to the error.
How YOU are supposed to do it:
qemu-img create -f qcow2 Base.img 50G
qemu-img create -f qcow2 -F qcow2 -b Base.img FirstFloor.ovl
qemu-img create -f qcow2 -F qcow2 -b FirstFloor.ovl SecondFloor.ovl
qemu-img create -f qcow2 -F qcow2 -b SecondFloor.ovl Roof.ovl
How you resolve already existing problems
qemu-img rebase -f qcow2 -b Base.img -F qcow2 FirstFloor.ovl
qemu-img rebase -f qcow2 -b FirstFloor.ovl -F qcow2 SecondFloor.ovl
qemu-img rebase -f qcow2 -b SecondFloor.ovl -F qcow2 Roof.ovl
thx for support: Peter Krempa (redhat) related bugrequest: https://bugzilla.redhat.com/show_bug.cgi?id=1588373
Answered By - Cutton Eye
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.