Bug 1031526
Summary: | Can not commit snapshot when disk is using glusterfs:native backend | ||
---|---|---|---|
Product: | Red Hat Enterprise Linux 7 | Reporter: | Qian Guo <qiguo> |
Component: | qemu-kvm | Assignee: | Jeff Cody <jcody> |
Status: | CLOSED CURRENTRELEASE | QA Contact: | Virtualization Bugs <virt-bugs> |
Severity: | high | Docs Contact: | |
Priority: | medium | ||
Version: | 7.0 | CC: | acathrow, dyuan, hhuang, huding, juzhang, mazhang, michen, shyu, virt-maint |
Target Milestone: | rc | ||
Target Release: | --- | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | qemu-kvm-1.5.3-53.el7 | Doc Type: | Bug Fix |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2014-06-13 13:17:08 UTC | Type: | Bug |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: |
Description
Qian Guo
2013-11-18 08:15:56 UTC
The glusterfs image driver needs a reopen implementation for block commit to work correctly. Currently, there is no reopen implementation. Without that, if the backing file is a glusterfs image, it cannot be changed to r/w from r/o. Fix included in qemu-kvm-1.5.3-53.el7 Reproduce this bug using the following version: qemu-kvm-rhev-1.5.3-19.el7.x86_64 kernel-3.10.0-99.el7.x86_64 Steps to Reproduce 1. boot a guest, the storage backend is native glusterfs /usr/libexec/qemu-kvm -name test -S -M pc -cpu Nehalem -m 4G -realtime mlock=off -smp 2,sockets=2,cores=1,threads=1 -nodefaults -rtc base=utc -boot menu=on,strict=on -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 -device virtio-serial-pci,id=virtio-serial0,bus=pci.0 -drive file=gluster://10.66.8.178/chayang_test/rhel7-64.qcow2,if=none,id=drive-scsi0-disk0,format=qcow2,cache=writethrough -device virtio-scsi-pci,id=scsi0,addr=0x4 -device scsi-hd,scsi-id=0,lun=0,bus=scsi0.0,drive=drive-scsi0-disk0,id=virtio-disk0,bootindex=1 -netdev tap,id=hostnet0,vhost=on,queues=4 -device virtio-net-pci,vectors=9,netdev=hostnet0,id=net0,mac=52:54:00:18:85:20,bus=pci.0 -device usb-tablet,id=input0 -spice port=5900,disable-ticketing,seamless-migration=on -vga qxl -global qxl-vga.ram_size=67108864 -global qxl-vga.vram_size=67108864 -device intel-hda,id=sound0,bus=pci.0 -device hda-duplex,id=sound0-codec0,bus=sound0.0,cad=0 -device virtio-balloon-pci,id=balloon0,bus=pci.0 -monitor stdio -qmp tcp:0:4455,server,nowait 2.Under qmp. create 1 snapshots with the glusterfs:native mode { "execute": "blockdev-snapshot-sync", "arguments": { "device": "drive-scsi0-disk0","snapshot-file":"gluster://10.66.8.178/chayang_test/sp1.qcow2","format":"qcow2"}} 3.Shutdown guest, then try to commit sn2: # qemu-img commit -f qcow2 gluster://10.66.8.178/chayang_test/sp1.qcow2 qemu-img: Image is read-only 4.Boot guest with this snapshot, inside guest, can read/write to this snapshot image. 5.Do live snapshot under hmp: (qemu) commit drive-virtio-disk1 'commit' error for 'drive-virtio-disk1': Permission denied Verify this bug using the following version: qemu-kvm-rhev-1.5.3-53.el7.x86_64 kernel-3.10.0-99.el7.x86_64 Steps to Verification: 1. boot a guest, the storage backend is native glusterfs /usr/libexec/qemu-kvm -name test -S -M pc -cpu Nehalem -m 4G -realtime mlock=off -smp 2,sockets=2,cores=1,threads=1 -nodefaults -rtc base=utc -boot menu=on,strict=on -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 -device virtio-serial-pci,id=virtio-serial0,bus=pci.0 -drive file=gluster://10.66.8.178/chayang_test/rhel7-64.qcow2,if=none,id=drive-scsi0-disk0,format=qcow2,cache=writethrough -device virtio-scsi-pci,id=scsi0,addr=0x4 -device scsi-hd,scsi-id=0,lun=0,bus=scsi0.0,drive=drive-scsi0-disk0,id=virtio-disk0,bootindex=1 -netdev tap,id=hostnet0,vhost=on,queues=4 -device virtio-net-pci,vectors=9,netdev=hostnet0,id=net0,mac=52:54:00:18:85:20,bus=pci.0 -device usb-tablet,id=input0 -spice port=5900,disable-ticketing,seamless-migration=on -vga qxl -global qxl-vga.ram_size=67108864 -global qxl-vga.vram_size=67108864 -device intel-hda,id=sound0,bus=pci.0 -device hda-duplex,id=sound0-codec0,bus=sound0.0,cad=0 -device virtio-balloon-pci,id=balloon0,bus=pci.0 -monitor stdio -qmp tcp:0:4455,server,nowait 2.Under qmp. create 1 snapshots with the glusterfs:native mode { "execute": "blockdev-snapshot-sync", "arguments": { "device": "drive-scsi0-disk0","snapshot-file":"gluster://10.66.8.178/chayang_test/sp1.qcow2","format":"qcow2"}} 3.Shutdown guest, then try to commit sn2: # qemu-img commit -f qcow2 gluster://10.66.8.178/chayang_test/sp1.qcow2 Image committed. 4.Boot guest with this snapshot, inside guest, can read/write to this snapshot image. 5.Do live snapshot under hmp: (qemu) commit drive-virtio-disk1 (qemu) Atual results: after step3 and step5, the snapshot can be committed to the base image. Based on the above result, I think this bug has been fixed. This request was resolved in Red Hat Enterprise Linux 7.0. Contact your manager or support representative in case you have further questions about the request. |