Bug 1685989 - Add facility to use block jobs with backing images without write permission
Summary: Add facility to use block jobs with backing images without write permission
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: qemu-kvm-rhev
Version: 7.5
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: rc
: ---
Assignee: Kevin Wolf
QA Contact: aihua liang
URL:
Whiteboard:
Depends On: 1671798
Blocks: 1717168
TreeView+ depends on / blocked
 
Reported: 2019-03-06 13:40 UTC by Peter Krempa
Modified: 2019-08-22 09:20 UTC (History)
9 users (show)

Fixed In Version: qemu-kvm-rhev-2.12.0-27.el7
Doc Type: If docs needed, set a value
Doc Text:
Clone Of: 1671798
: 1717168 (view as bug list)
Environment:
Last Closed: 2019-08-22 09:20:23 UTC
Target Upstream Version:


Attachments (Terms of Use)


Links
System ID Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2019:2553 None None None 2019-08-22 09:20:42 UTC

Description Peter Krempa 2019-03-06 13:40:12 UTC
+++ This bug was initially created as a clone of Bug #1671798 +++

Description of problem:
When discussing the use of 'auto-read-only' property for use with -blockdev so that libvirt is able to use block jobs I forgot that sVirt labelling of the backing chain images actually forbids the write permission. [1]

This means that the 'auto-read-only' property works as expected and opens the images as read-only in this case. This unfortunately means that when libvirt attempts a block-commit which needs to write into the backing chain we relabel the image to allow write, but qemu will not reopen it any more.

This means that we unfortunately still need a way to control reopening of the images of the backing chain:
1) automatically by block-commit doing the right thing
2) manually by providing an interface to achieve that

Libvirt is relabeling the files anyways so 2) is also acceptable.

[1] Unfortunately it's very unpleasant to run a development git image of libvirt under full enforcing selinux, thus I neglected todo when testing 'auto-read-only'. I'm sorry for that.

Comment 2 Miroslav Rezanina 2019-04-25 03:52:26 UTC
Fix included in qemu-kvm-rhev-2.12.0-27.el7

Comment 6 aihua liang 2019-05-24 12:48:41 UTC
-blockdev and sVirt not support RHEL7.7, so just do some regression test to make sure no breaks.

A regression test has been run on block_commit with backend:gluster and basic block commit test with kinds of backend(nfs, nbd, iscsi), bugs found as bellow:
  New bugs:
    Bug 1713647 - Block format 'nbd' does not support reopening files when do block commit
    Bug 1713650 - [upstream]Failed to do block commit to NBD device with BLOCK_JOB_ERROR, error: "Invalid argument"
  
  Existed bugs:
    Bug 1711643 - qemu aborts in blockCommit: qemu-kvm: block.c:3486: bdrv_replace_node: Assertion `!({ _Static_assert(!(sizeof(*&from->in_flight) > 8), "not expecting: " "sizeof(*&from->in_flight) > ATOMIC_REG_SIZE"); __atomic_load_n(&from->in_flight, 0); })' failed.
    Bug 1614623 - qemu and guest hang when guest poweroff after live commit with data-plane
    Bug 1667307 - qemu and guest hang when hotunplug a device with block commit running on it (data-plane enable)
    Bug 1683937 - [data plane] Qemu core dump for 'virtio_scsi_ctx_check: Assertion `blk_get_aio_context(d->conf.blk) == s->ctx' failed' when create a snapshot with blockdev-create
    Bug 1553234 - RFE: synchronous mirror to prevent a long-running block-job-complete (qemu)


RBD Sever is broken, will add the result later if have any bugs.

So set this bug's status to "Verified" and track the left issue by the new/existed bugs.

Comment 8 errata-xmlrpc 2019-08-22 09:20:23 UTC
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://access.redhat.com/errata/RHSA-2019:2553


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