|
|
c313de |
From 5abd9049c8bdea6170dc455033e37811ba875db8 Mon Sep 17 00:00:00 2001
|
|
|
c313de |
Message-Id: <5abd9049c8bdea6170dc455033e37811ba875db8@dist-git>
|
|
|
c313de |
From: Pavel Hrdina <phrdina@redhat.com>
|
|
|
c313de |
Date: Mon, 1 Jul 2019 17:06:13 +0200
|
|
|
c313de |
Subject: [PATCH] vircgroup: fix bug in virCgroupEnableMissingControllers
|
|
|
c313de |
MIME-Version: 1.0
|
|
|
c313de |
Content-Type: text/plain; charset=UTF-8
|
|
|
c313de |
Content-Transfer-Encoding: 8bit
|
|
|
c313de |
|
|
|
c313de |
If we are on host with systemd we need to build cgroup hierarchy
|
|
|
c313de |
ourselves for controllers that are not managed by systemd.
|
|
|
c313de |
|
|
|
c313de |
As a starting parent we need to force root group because
|
|
|
c313de |
virCgroupMakeGroup() takes that parent in order to inherit values
|
|
|
c313de |
for cpuset controller.
|
|
|
c313de |
|
|
|
c313de |
By default cpuset controller is managed by systemd so we will never
|
|
|
c313de |
hit the issue but for v2 cgroups we need to use parent cgroup every
|
|
|
c313de |
time.
|
|
|
c313de |
|
|
|
c313de |
Reviewed-by: Fabiano Fidêncio <fidencio@redhat.com>
|
|
|
c313de |
Reviewed-by: Ján Tomko <jtomko@redhat.com>
|
|
|
c313de |
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
|
|
|
c313de |
(cherry picked from commit 63b4ed0dd3e1555b4c9d82ef0ca0648493f75af2)
|
|
|
c313de |
|
|
|
c313de |
Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1689297
|
|
|
c313de |
|
|
|
c313de |
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
|
|
|
c313de |
Message-Id: <ae150854a6a02300cd3329c538373b770320f504.1561993099.git.phrdina@redhat.com>
|
|
|
c313de |
Reviewed-by: Ján Tomko <jtomko@redhat.com>
|
|
|
c313de |
---
|
|
|
c313de |
src/util/vircgroup.c | 2 +-
|
|
|
c313de |
1 file changed, 1 insertion(+), 1 deletion(-)
|
|
|
c313de |
|
|
|
c313de |
diff --git a/src/util/vircgroup.c b/src/util/vircgroup.c
|
|
|
c313de |
index 6aa30a82be..2328957818 100644
|
|
|
c313de |
--- a/src/util/vircgroup.c
|
|
|
c313de |
+++ b/src/util/vircgroup.c
|
|
|
c313de |
@@ -1495,7 +1495,7 @@ virCgroupEnableMissingControllers(char *path,
|
|
|
c313de |
int ret = -1;
|
|
|
c313de |
|
|
|
c313de |
if (virCgroupNew(pidleader,
|
|
|
c313de |
- "",
|
|
|
c313de |
+ "/",
|
|
|
c313de |
NULL,
|
|
|
c313de |
controllers,
|
|
|
c313de |
&parent) < 0)
|
|
|
c313de |
--
|
|
|
c313de |
2.22.0
|
|
|
c313de |
|