From 59cc0fe5aa00d472bdd19bfb40be219249cfd0c7 Mon Sep 17 00:00:00 2001 From: Jiri Denemark Date: Fri, 28 Jun 2013 16:58:03 +0200 Subject: [PATCH] qemu: Set RLIMIT_MEMLOCK when memoryBacking/locked is used If a domain is configured to have all its memory locked, we need to set RLIMIT_MEMLOCK so that QEMU is actually allowed to lock the memory. --- src/qemu/qemu_command.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c index a9aa6702f2..46db28a7a4 100644 --- a/src/qemu/qemu_command.c +++ b/src/qemu/qemu_command.c @@ -6795,6 +6795,7 @@ qemuBuildCommandLine(virConnectPtr conn, virCommandAddArgFormat(cmd, "mlock=%s", def->mem.locked ? "on" : "off"); } + mlock = def->mem.locked; virCommandAddArg(cmd, "-smp"); if (!(smp = qemuBuildSmpArgStr(def, qemuCaps))) -- 2.47.2