From ad7f8b0fac579087a069c689a86c960496de6d94 Mon Sep 17 00:00:00 2001 From: Qiu Jian Date: Thu, 14 Oct 2021 23:22:49 +0800 Subject: [PATCH] fix: set qemu cpu sockets to 2 for x86 cpu --- pkg/hostman/guestman/qemu-kvmhelper.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/hostman/guestman/qemu-kvmhelper.go b/pkg/hostman/guestman/qemu-kvmhelper.go index cd32bbf562..7c527f3370 100644 --- a/pkg/hostman/guestman/qemu-kvmhelper.go +++ b/pkg/hostman/guestman/qemu-kvmhelper.go @@ -513,7 +513,7 @@ function nic_mtu() { cmd += fmt.Sprintf(" -machine %s,accel=%s", s.getMachine(), accel) cmd += " -k en-us" // #cmd += " -g 800x600" - cmd += fmt.Sprintf(" -smp %d,maxcpus=255", cpu) + cmd += fmt.Sprintf(" -smp cpus=%d,sockets=2,cores=64,maxcpus=128", cpu) cmd += fmt.Sprintf(" -name %s", name) // #cmd += fmt.Sprintf(" -uuid %s", self.desc["uuid"]) cmd += fmt.Sprintf(" -m %dM,slots=4,maxmem=524288M", mem)