]> xenbits.xensource.com Git - libvirt.git/commitdiff
Change default resource partition to /machine
authorDaniel P. Berrange <berrange@redhat.com>
Thu, 18 Apr 2013 10:07:17 +0000 (11:07 +0100)
committerDaniel P. Berrange <berrange@redhat.com>
Mon, 22 Apr 2013 11:10:12 +0000 (12:10 +0100)
After discussions with systemd developers it was decided that
a better default policy for resource partitions is to have
3 default partitions at the top level

   /system   - system services
   /machine - virtual machines / containers
   /user    - user login session

This ensures that the default policy isolates guest from
user login sessions & system services, so a mis-behaving
guest can't consume 100% of CPU usage if other things are
contending for it.

Thus we change the default partition from /system to
/machine

Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
src/lxc/lxc_cgroup.c
src/qemu/qemu_cgroup.c

index 0a43b61e7d615dfc63e62b283b542df5fb4276d1..7311489d1d4346b8a20e1962f59d17e9eaa42692 100644 (file)
@@ -537,7 +537,7 @@ virCgroupPtr virLXCCgroupCreate(virDomainDefPtr def, bool startup)
             goto cleanup;
         }
 
-        if (!(res->partition = strdup("/system"))) {
+        if (!(res->partition = strdup("/machine"))) {
             virReportOOMError();
             VIR_FREE(res);
             goto cleanup;
index 9a7bffbe2fe4067b334efdc3e934622695241da0..3a58f24e03db5295a6bf2fa0675253d04f07c663 100644 (file)
@@ -236,7 +236,7 @@ int qemuInitCgroup(virQEMUDriverPtr driver,
             goto cleanup;
         }
 
-        if (!(res->partition = strdup("/system"))) {
+        if (!(res->partition = strdup("/machine"))) {
             virReportOOMError();
             VIR_FREE(res);
             goto cleanup;