[libvirt] [PATCH 1/3] Change VM cgroup suffix from '{lxc, qemu}.libvirt' to 'libvirt-{lxc, qemu}'

Eric Blake eblake at redhat.com
Fri Apr 26 11:12:58 UTC 2013


On 04/26/2013 04:45 AM, Daniel P. Berrange wrote:
> From: "Daniel P. Berrange" <berrange at redhat.com>
> 
> Recently we changed to create VM cgroups with the naming pattern
> $VMNAME.$DRIVER.libvirt. Following discussions with the systemd
> community it was decided that only having a single '.' in the
> names is preferrable. So this changes the naming scheme to be
> $VMNAME.libvirt-$DRIVER. eg for LXC 'mycontainer.libvirt-lxc' or
> for KVM 'myvm.libvirt-qemu'.

Well, $VMNAME could contain '.'; but your argument of having a single
suffix rather than a double suffix to determine who created the group
makes sense.

> 
> Signed-off-by: Daniel P. Berrange <berrange at redhat.com>
> ---
>  src/util/vircgroup.c  |  2 +-
>  tests/vircgrouptest.c | 14 +++++++-------
>  2 files changed, 8 insertions(+), 8 deletions(-)

ACK; worth going in 1.0.5.

> +++ b/tests/vircgrouptest.c
> @@ -362,13 +362,13 @@ static int testCgroupNewForPartitionDomain(const void *args ATTRIBUTE_UNUSED)
>      int ret = -1;
>      int rv;
>      const char *placement[VIR_CGROUP_CONTROLLER_LAST] = {
> -        [VIR_CGROUP_CONTROLLER_CPU] = "/production/foo.lxc.libvirt",
> -        [VIR_CGROUP_CONTROLLER_CPUACCT] = "/production/foo.lxc.libvirt",
> -        [VIR_CGROUP_CONTROLLER_CPUSET] = "/production/foo.lxc.libvirt",
> -        [VIR_CGROUP_CONTROLLER_MEMORY] = "/production/foo.lxc.libvirt",
> +        [VIR_CGROUP_CONTROLLER_CPU] = "/production/foo.libvirt-lxc",

So much easier to verify the series with this test in place :)

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 621 bytes
Desc: OpenPGP digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20130426/f800ab1f/attachment-0001.sig>


More information about the libvir-list mailing list