Bug 1177062
Summary: | The error messages are not accurate enough when do blockcommit passing target[index] to base and top | ||
---|---|---|---|
Product: | Red Hat Enterprise Linux 7 | Reporter: | Yang Yang <yanyang> |
Component: | libvirt | Assignee: | Peter Krempa <pkrempa> |
Status: | CLOSED ERRATA | QA Contact: | Virtualization Bugs <virt-bugs> |
Severity: | low | Docs Contact: | |
Priority: | low | ||
Version: | 7.1 | CC: | dyuan, eblake, mzhan, pkrempa, rbalakri, shyu, xuzhang |
Target Milestone: | rc | ||
Target Release: | --- | ||
Hardware: | x86_64 | ||
OS: | Linux | ||
Whiteboard: | |||
Fixed In Version: | libvirt-1.2.15-1.el7 | Doc Type: | Bug Fix |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2015-11-19 06:05:44 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
Yang Yang
2014-12-24 02:20:41 UTC
Following upstream commit improves the error message: commit dff92b3f2fe63da63391f929134b06d3be992a40 Author: Peter Krempa <pkrempa> Date: Tue Apr 21 17:38:08 2015 +0200 util: storage: Improve error message when requesting image above 'start' When a user would specify a backing chain index that is above the start point libvirt would report a rather unhelpful error: invalid argument: could not find backing store 1 in chain for 'sub/link2' This patch adds an explicit check that the index is below start point in the backing store and reports the following error if not: invalid argument: requested backing store index 1 is above 'sub/../qcow2' in chain for 'sub/link2' v1.2.14-260-gdff92b3 Hi Peter I found a tiny issue that error message is not accurate when passing an invalid path to base when using gluster as storage backend # virsh blockcommit vm3 vda --top vda[2] --base xx --wait --verbose error: invalid argument: top '/rhel7.qcow2' in chain for 'vda' has no backing file # virsh blockcommit vm3 vda --top vda[2] --base vda[] --wait --verbose --bandwidth 1 error: invalid argument: top '/rhel7.qcow2' in chain for 'vda' has no backing file ============================================== The following test scenarios have passed. Tested with libvirt-1.2.15-2.el7.x86_64 Steps <disk type='network' device='disk'> <driver name='qemu' type='qcow2'/> <source protocol='gluster' name='gluster-vol1/rhel7.s3'> <host name='10.66.4.164' port='24007'/> </source> <backingStore type='network' index='1'> <format type='qcow2'/> <source protocol='gluster' name='gluster-vol1/rhel7.s2'> <host name='10.66.4.164'/> </source> <backingStore type='network' index='2'> <format type='qcow2'/> <source protocol='gluster' name='gluster-vol1/rhel7.s1'> <host name='10.66.4.164'/> </source> <backingStore type='network' index='3'> <format type='qcow2'/> <source protocol='gluster' name='gluster-vol1/rhel7.qcow2'> <host name='10.66.4.164'/> </source> <backingStore/> </backingStore> </backingStore> </backingStore> <target dev='vda' bus='virtio'/> <alias name='virtio-disk0'/> <address type='pci' domain='0x0000' bus='0x00' slot='0x08' function='0x0'/> </disk> # virsh blockcommit vm3 vda --top vda[2] --base vda[1] --wait --verbose error: invalid argument: requested backing store index 1 is above '/rhel7.s1' in chain for '/rhel7.s3' # virsh blockcommit vm3 vda --top vda[2] --base vda[2] --wait --verbose error: invalid argument: requested backing store index 2 is above '/rhel7.s1' in chain for '/rhel7.s3' # virsh blockcommit vm3 vda --top xx --base vda[1] --wait --verbose --bandwidth 1 error: invalid argument: could not find image 'xx' in chain for '/rhel7.s3' Yes that's a known issue. Network disk strings in error messages need to be fixed at some time. Here as long as it works for local files it's good enough. Thanks Peter. Also verified it with local file libvirt-1.2.15-2.el7.x86_64 Steps as following # virsh blockcommit simple vda --top vda[2] --base xx --wait --verbose error: invalid argument: could not find image 'xx' beneath '/tmp/simple.s2' in chain for '/tmp/simple.s4' # virsh blockcommit simple vda --top vda[2] --base vda[] --wait --verbose error: invalid argument: could not find image 'vda[]' beneath '/tmp/simple.s2' in chain for '/tmp/simple.s4' # virsh blockcommit simple vda --top vda[] --base vda[] --wait --verbose error: invalid argument: could not find image 'vda[]' in chain for '/tmp/simple.s4' # virsh blockcommit simple vda --top vda[2] --base vda[1] --wait --verbose error: invalid argument: requested backing store index 1 is above '/tmp/simple.s2' in chain for '/tmp/simple.s4' # virsh blockcommit simple vda --top vda[2] --base vda[2] --wait --verbose error: invalid argument: requested backing store index 2 is above '/tmp/simple.s2' in chain for '/tmp/simple.s4' Per comment #2 and comment #4, move it to verified status. Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://rhn.redhat.com/errata/RHBA-2015-2202.html |