[PATCH 4/6] qemuMigrationSrcIsSafeDisk: Check also data file propertiues for migrability

Peter Krempa via Devel posted 6 patches 3 weeks, 3 days ago
[PATCH 4/6] qemuMigrationSrcIsSafeDisk: Check also data file propertiues for migrability
Posted by Peter Krempa via Devel 3 weeks, 3 days ago
From: Peter Krempa <pkrempa@redhat.com>

If the qcow2 data file feature (which separates the data into a separate
file from the metadata) is in use the migration safety check ought co
consider both the metadata and the data file for safe migration.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
---
 src/qemu/qemu_migration.c | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/src/qemu/qemu_migration.c b/src/qemu/qemu_migration.c
index ae26f74f8c..2e52e73f48 100644
--- a/src/qemu/qemu_migration.c
+++ b/src/qemu/qemu_migration.c
@@ -1795,6 +1795,12 @@ qemuMigrationSrcIsSafeDisk(virDomainDiskDef *disk,
                                                  &requires_safe_cache) < 0)
         return false;

+    if (disk->src->dataFileStore &&
+        qemuMigrationSrcCheckStorageSourceSafety(disk->src->dataFileStore,
+                                                 cfg, &unsafe_storage,
+                                                 &requires_safe_cache) < 0)
+        return false;
+
     if (unsafe_storage) {
         virReportError(VIR_ERR_MIGRATE_UNSAFE, "%s",
                        _("Migration without shared storage is unsafe"));
-- 
2.51.0
Re: [PATCH 4/6] qemuMigrationSrcIsSafeDisk: Check also data file propertiues for migrability
Posted by Ján Tomko via Devel 3 weeks, 3 days ago
In the commit summary:

*properties

On a Wednesday in 2025, Peter Krempa via Devel wrote:
>From: Peter Krempa <pkrempa@redhat.com>
>
>If the qcow2 data file feature (which separates the data into a separate
>file from the metadata) is in use the migration safety check ought co

ought to

Jano

>consider both the metadata and the data file for safe migration.
>
>Signed-off-by: Peter Krempa <pkrempa@redhat.com>
>---
> src/qemu/qemu_migration.c | 6 ++++++
> 1 file changed, 6 insertions(+)
>