[systemd-devel] [PATCH v2] cgroup-util: fix is_valid check to pass for unified cgroup hierchy.

Lennart Poettering lennart at poettering.net
Fri May 29 08:19:16 PDT 2015

On Fri, 29.05.15 17:09, Martin Pitt (martin.pitt at ubuntu.com) wrote:

> Lennart Poettering [2015-05-29 17:02 +0200]:
> > I'd really just introduce a new kernel cmdline option:
> > systemd.debug-unified-cgroup=1 or so. A simple boolean that gets you
> > either one or the other behaviour. Maybe make the default for this
> > setting configurable with a configure script switch. And I'd include
> > the "debug" in the name, to indicate that this is just for testing for
> > now, and is an option that will go away eventually.
> How does that play with containers? Is it just that you can't switch
> on the unified hierarchy as long as you still have containers with
> older systemd versions which don't support that yet? That would be
> a bit ugly, but bearable, I guess, and it'll sort itself out over
> time.

IIUC a container manager could actually support old userspace in
containers on a system that otherwise uses the unified hierarchy. THis
is because even with the unified hierarchy in place you can still set
up additional, named hierarchies. You'd hence mount an otherwise empty
name=systemd hierarchied in your container manager and pass that to
the container, and not mount anything else (especially no controller
hierarchies). For the container everything should be as usual.

Unfortunately this requires configuration though: you have to tell
your container manager how to set things up, this cannot be set up in
a way so that that old userspace magically gets the right classic
cgroup setup, while new userspace magically gets the new cgroup


Lennart Poettering, Red Hat

More information about the systemd-devel mailing list