From 417a32631df93ee02a55ed6743eae1d59f377a17 Mon Sep 17 00:00:00 2001 From: Luyao Huang Date: Mon, 20 Apr 2015 15:33:31 +0200 Subject: [PATCH] lxc: fix starting a domain with non-strict numa memory mode MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit # virsh -c lxc:/// start helloworld error: Failed to start domain helloworld error: internal error: guest failed to start: Unknown failure in libvirt_lxc startup Return success when there are no cpuset.mems to be set, instead of failing without setting an error. Signed-off-by: Ján Tomko (cherry picked from commit 930e8697a5b66989fbf56a5e38cfaf1378a1c59e) --- src/lxc/lxc_cgroup.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/lxc/lxc_cgroup.c b/src/lxc/lxc_cgroup.c index b13fede81d..ba64b69601 100644 --- a/src/lxc/lxc_cgroup.c +++ b/src/lxc/lxc_cgroup.c @@ -82,8 +82,10 @@ static int virLXCCgroupSetupCpusetTune(virDomainDefPtr def, } if (virDomainNumatuneGetMode(def->numa, -1) != - VIR_DOMAIN_NUMATUNE_MEM_STRICT) + VIR_DOMAIN_NUMATUNE_MEM_STRICT) { + ret = 0; goto cleanup; + } if (virDomainNumatuneMaybeFormatNodeset(def->numa, nodemask, &mask, -1) < 0)