Explorar el Código

use empty string as cgroup path to grab first find

Signed-off-by: Andrew Hsu <andrewhsu@docker.com>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
(cherry picked from commit 78045a5419718ba8884ed5afc0b41a3a80afc3b4)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Andrew Hsu hace 6 años
padre
commit
b66c7ad62e
Se han modificado 2 ficheros con 2 adiciones y 2 borrados
  1. 1 1
      daemon/daemon_unix.go
  2. 1 1
      pkg/sysinfo/sysinfo_linux.go

+ 1 - 1
daemon/daemon_unix.go

@@ -1480,7 +1480,7 @@ func (daemon *Daemon) initCgroupsPath(path string) error {
 	// for the period and runtime as this limits what the children can be set to.
 	daemon.initCgroupsPath(filepath.Dir(path))
 
-	mnt, root, err := cgroups.FindCgroupMountpointAndRoot("cpu")
+	mnt, root, err := cgroups.FindCgroupMountpointAndRoot("", "cpu")
 	if err != nil {
 		return err
 	}

+ 1 - 1
pkg/sysinfo/sysinfo_linux.go

@@ -227,7 +227,7 @@ func checkCgroupCpusetInfo(cgMounts map[string]string, quiet bool) cgroupCpusetI
 
 // checkCgroupPids reads the pids information from the pids cgroup mount point.
 func checkCgroupPids(quiet bool) cgroupPids {
-	_, err := cgroups.FindCgroupMountpoint("pids")
+	_, err := cgroups.FindCgroupMountpoint("", "pids")
 	if err != nil {
 		if !quiet {
 			logrus.Warn(err)