]> Git Repo - qemu.git/commitdiff
migration: forbid bitmap migration by generated node-name
authorVladimir Sementsov-Ogievskiy <[email protected]>
Thu, 21 May 2020 22:06:48 +0000 (01:06 +0300)
committerEric Blake <[email protected]>
Thu, 28 May 2020 18:15:22 +0000 (13:15 -0500)
It actually never worked with libvirt, as auto-generated names are
different on source and destination.

It's unsafe and useless to migrate by auto-generated node-names, so
let's forbid it.

Signed-off-by: Vladimir Sementsov-Ogievskiy <[email protected]>
Reviewed-by: Andrey Shinkevich <[email protected]>
Reviewed-by: Eric Blake <[email protected]>
Message-Id: <20200521220648[email protected]>
[eblake: shorter subject line]
Signed-off-by: Eric Blake <[email protected]>
migration/block-dirty-bitmap.c

index 7be1644b330aa9819508ce6ce85c5267506dc57c..47bc0f650c1efad1fda1651c1b8fd0ce556cf348 100644 (file)
@@ -285,6 +285,13 @@ static int add_bitmaps_to_list(BlockDriverState *bs, const char *bs_name)
         return -1;
     }
 
+    if (bs_name[0] == '#') {
+        error_report("Bitmap '%s' in a node with auto-generated "
+                     "name '%s' can't be migrated",
+                     bdrv_dirty_bitmap_name(bitmap), bs_name);
+        return -1;
+    }
+
     FOR_EACH_DIRTY_BITMAP(bs, bitmap) {
         if (!bdrv_dirty_bitmap_name(bitmap)) {
             continue;
This page took 0.033644 seconds and 4 git commands to generate.