[PATCH 0/6] qemu: refactor disk migration safety check and add corner case exemption for Kubevirt's usage

Peter Krempa via Devel posted 6 patches 3 weeks, 3 days ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/libvirt tags/patchew/cover.1757512552.git.pkrempa@redhat.com
src/qemu/qemu_migration.c                     | 188 ++++++++++++------
src/qemu/qemu_monitor.h                       |   3 +
src/qemu/qemu_monitor_json.c                  |   3 +
tests/qemublocktest.c                         |   2 +
tests/qemublocktestdata/bitmap/synthetic.json |   1 +
tests/qemublocktestdata/bitmap/synthetic.out  |   1 +
6 files changed, 133 insertions(+), 65 deletions(-)
[PATCH 0/6] qemu: refactor disk migration safety check and add corner case exemption for Kubevirt's usage
Posted by Peter Krempa via Devel 3 weeks, 3 days ago
Patches 1-3 are refactors that simplify the code and prepare it.
Patch 4 fixed bug where 'data_file' is not checked
Patches 5 and 6 add a workaround for Kubevirt's corner case migration
approach.

Peter Krempa (6):
  qemuMigrationSrcIsSafe: Drop 'DEBUG' message about qemu supporting
    cache dropping
  qemuMigrationSrcIsSafe: Extract code for checking safe migrability of
    one disk
  qemuMigrationSrcIsSafeDisk: Extract safe migration checks for one
    storage source
  qemuMigrationSrcIsSafeDisk: Check also data file propertiues for
    migrability
  qemuBlockGetNamedNodeData: Extract 'data_file_raw' flag
  qemuMigrationSrcIsSafeDisk: Allow non-shared qcow2's with raw data
    file

 src/qemu/qemu_migration.c                     | 188 ++++++++++++------
 src/qemu/qemu_monitor.h                       |   3 +
 src/qemu/qemu_monitor_json.c                  |   3 +
 tests/qemublocktest.c                         |   2 +
 tests/qemublocktestdata/bitmap/synthetic.json |   1 +
 tests/qemublocktestdata/bitmap/synthetic.out  |   1 +
 6 files changed, 133 insertions(+), 65 deletions(-)

-- 
2.51.0
Re: [PATCH 0/6] qemu: refactor disk migration safety check and add corner case exemption for Kubevirt's usage
Posted by Ján Tomko via Devel 3 weeks, 3 days ago
On a Wednesday in 2025, Peter Krempa via Devel wrote:
>Patches 1-3 are refactors that simplify the code and prepare it.
>Patch 4 fixed bug where 'data_file' is not checked
>Patches 5 and 6 add a workaround for Kubevirt's corner case migration
>approach.
>
>Peter Krempa (6):
>  qemuMigrationSrcIsSafe: Drop 'DEBUG' message about qemu supporting
>    cache dropping
>  qemuMigrationSrcIsSafe: Extract code for checking safe migrability of
>    one disk
>  qemuMigrationSrcIsSafeDisk: Extract safe migration checks for one
>    storage source
>  qemuMigrationSrcIsSafeDisk: Check also data file propertiues for
>    migrability
>  qemuBlockGetNamedNodeData: Extract 'data_file_raw' flag
>  qemuMigrationSrcIsSafeDisk: Allow non-shared qcow2's with raw data
>    file
>
> src/qemu/qemu_migration.c                     | 188 ++++++++++++------
> src/qemu/qemu_monitor.h                       |   3 +
> src/qemu/qemu_monitor_json.c                  |   3 +
> tests/qemublocktest.c                         |   2 +
> tests/qemublocktestdata/bitmap/synthetic.json |   1 +
> tests/qemublocktestdata/bitmap/synthetic.out  |   1 +
> 6 files changed, 133 insertions(+), 65 deletions(-)
>

Reviewed-by: Ján Tomko <jtomko@redhat.com>

Jano