[PATCH 1/1] conf: remove domain name change check on CheckABI

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



virDomainDefCheckABIStabilityFlags() is called to validate two domains
during migration. In addition to validating ABI, it also ensures the
domain names have not changed. Such a check prevents cloning a saved VM
because clones require a new name.

This removes the check, allowing the use case described above.

Signed-off-by: Felipe Franciosi <felipe@xxxxxxxxxxx>
---
 src/conf/domain_conf.c | 11 -----------
 1 file changed, 11 deletions(-)

diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c
index e658b68c48..0030e2b4b4 100644
--- a/src/conf/domain_conf.c
+++ b/src/conf/domain_conf.c
@@ -21786,17 +21786,6 @@ virDomainDefCheckABIStabilityFlags(virDomainDef *src,
         goto error;
     }
 
-    /* Not strictly ABI related, but we want to make sure domains
-     * don't get silently re-named through the backdoor when passing
-     * custom XML into various APIs, since this would create havoc
-     */
-    if (STRNEQ_NULLABLE(src->name, dst->name)) {
-        virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
-                       _("Target domain name '%1$s' does not match source '%2$s'"),
-                       dst->name, src->name);
-        goto error;
-    }
-
     if (!virDomainMemtuneCheckABIStability(src, dst, flags))
         goto error;
 
-- 
2.39.5



[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux