From 6bfc0ecd576f8f346ff7a965917d43e78a0da4de Mon Sep 17 00:00:00 2001 From: Brian Goff Date: Wed, 11 Oct 2017 13:27:08 -0400 Subject: [PATCH] Don't abort when setting may_detach_mounts 83c2152de503012195bd26069fd8fbd2dea4b32f sets the kernel param for fs.may_detach_mounts, but this is not neccessary for the daemon to operate. Instead of erroring out (and thus aborting startup) just log the error. Signed-off-by: Brian Goff Upstream-commit: c6a2044497e0e1ff61350859c8572a2c31c17ced Component: engine --- components/engine/daemon/daemon_unix.go | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/components/engine/daemon/daemon_unix.go b/components/engine/daemon/daemon_unix.go index 31f8bc036b..2b0e206629 100644 --- a/components/engine/daemon/daemon_unix.go +++ b/components/engine/daemon/daemon_unix.go @@ -1300,7 +1300,10 @@ func setupDaemonProcess(config *config.Config) error { if err := setupOOMScoreAdj(config.OOMScoreAdjust); err != nil { return err } - return setMayDetachMounts() + if err := setMayDetachMounts(); err != nil { + logrus.WithError(err).Warn("Could not set may_detach_mounts kernel parameter") + } + return nil } // This is used to allow removal of mountpoints that may be mounted in other