[PATCH v2 5/6] qemu: Allow setting per-disk snapshot name for RBD disks

ORO@il.ibm.com oro at oro.sl.cloud9.ibm.com
Sun Jan 29 11:15:58 UTC 2023


From: Or Ozeri <oro at il.ibm.com>

This commit adds the option for setting per-disk snapshot name for
RBD disks. All other disk types are still disallowed to use the
snapshotName attribute.

Signed-off-by: Or Ozeri <oro at il.ibm.com>
---
 src/qemu/qemu_snapshot.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/qemu/qemu_snapshot.c b/src/qemu/qemu_snapshot.c
index a10bdf7bf2..c72bdb4723 100644
--- a/src/qemu/qemu_snapshot.c
+++ b/src/qemu/qemu_snapshot.c
@@ -664,7 +664,7 @@ qemuSnapshotPrepare(virDomainObj *vm,
                 return -1;
             }
 
-            if (disk->snapshot_name) {
+            if (disk->snapshot_name && !is_raw_rbd) {
                 virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
                                _("snapshot name setting for disk %s unsupported "
                                  "for storage type %s"),
-- 
2.25.1



More information about the libvir-list mailing list