When using systemd, pass expected cgroupsPath and cli options to runc.

runc expects a systemd cgroupsPath to be in slice:scopePrefix:containerName
format and the "--systemd-cgroup" option to be set. Update docker accordingly.

Fixes 21475

Signed-off-by: Anusha Ragunathan <anusha@docker.com>
master
Anusha Ragunathan 2016-03-24 09:18:03 -07:00 committed by Tibor Vass
parent 327d937bf0
commit 31c32956ca
2 changed files with 7 additions and 5 deletions

View File

@ -491,12 +491,13 @@ with the `--exec-opt` flag. All the flag's options have the `native` prefix. A
single `native.cgroupdriver` option is available.
The `native.cgroupdriver` option specifies the management of the container's
cgroups. You can specify only specify `cgroupfs` at the moment. If you omit the
cgroups. You can specify only specify `cgroupfs` or `systemd`. If you specify
`systemd` and it is not available, the system errors out. If you omit the
`native.cgroupdriver` option,` cgroupfs` is used.
This example explicitely sets the `cgroupdriver` to `cgroupfs`:
This example sets the `cgroupdriver` to `systemd`:
$ sudo docker daemon --exec-opt native.cgroupdriver=cgroupfs
$ sudo docker daemon --exec-opt native.cgroupdriver=systemd
Setting this option applies to all containers the daemon launches.

View File

@ -230,8 +230,9 @@ Use the **--exec-opt** flags to specify options to the execution driver.
The following options are available:
#### native.cgroupdriver
Specifies the management of the container's `cgroups`. Only `cgroupfs` can be specified
`cgroupfs` at the moment.
Specifies the management of the container's `cgroups`. You can specify `cgroupfs`
or `systemd`. If you specify `systemd` and it is not available, the system errors
out.
#### Client
For specific client examples please see the man page for the specific Docker