[virt-manager] [PATCH] domain: cpu: Clear 'migratable' when changing to custom cpu

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


Otherwise going host-passthrough -> custom can cause libvirt validation
error due to libvirt fills the default value(migratable='on') for the
host-passthrough in domain XML.

Signed-off-by: Lin Ma <lma@xxxxxxxx>
 virtinst/domain/cpu.py | 1 +
 1 file changed, 1 insertion(+)

diff --git a/virtinst/domain/cpu.py b/virtinst/domain/cpu.py
index e40c5307..5de42b4e 100644
--- a/virtinst/domain/cpu.py
+++ b/virtinst/domain/cpu.py
@@ -358,6 +358,7 @@ class DomainCpu(XMLBuilder):
     def set_model(self, guest, val):
         log.debug("setting cpu model %s", val)
+        self.migratable = None
         if val:
             self.mode = "custom"
             if not self.match:

[Index of Archives]     [Linux Virtualization]     [KVM Development]     [CentOS Virtualization]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite Forum]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]     [Video 4 Linux]

  Powered by Linux