You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mesos.apache.org by tn...@apache.org on 2016/01/21 04:47:47 UTC
mesos git commit: Fixed unmount order in linux filesystem isolator
cleanup.
Repository: mesos
Updated Branches:
refs/heads/master 4d4d71664 -> 10f8052c7
Fixed unmount order in linux filesystem isolator cleanup.
Review: https://reviews.apache.org/r/42389/
Project: http://git-wip-us.apache.org/repos/asf/mesos/repo
Commit: http://git-wip-us.apache.org/repos/asf/mesos/commit/10f8052c
Tree: http://git-wip-us.apache.org/repos/asf/mesos/tree/10f8052c
Diff: http://git-wip-us.apache.org/repos/asf/mesos/diff/10f8052c
Branch: refs/heads/master
Commit: 10f8052c763fcb1fe796e66f985271808f903ffe
Parents: 4d4d716
Author: Timothy Chen <tn...@apache.org>
Authored: Wed Jan 20 19:23:05 2016 -0800
Committer: Timothy Chen <tn...@apache.org>
Committed: Wed Jan 20 19:23:05 2016 -0800
----------------------------------------------------------------------
src/slave/containerizer/mesos/isolators/filesystem/linux.cpp | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/mesos/blob/10f8052c/src/slave/containerizer/mesos/isolators/filesystem/linux.cpp
----------------------------------------------------------------------
diff --git a/src/slave/containerizer/mesos/isolators/filesystem/linux.cpp b/src/slave/containerizer/mesos/isolators/filesystem/linux.cpp
index ace9e30..96c37ed 100644
--- a/src/slave/containerizer/mesos/isolators/filesystem/linux.cpp
+++ b/src/slave/containerizer/mesos/isolators/filesystem/linux.cpp
@@ -24,6 +24,7 @@
#include <process/metrics/metrics.hpp>
+#include <stout/adaptor.hpp>
#include <stout/error.hpp>
#include <stout/foreach.hpp>
#include <stout/os.hpp>
@@ -738,7 +739,9 @@ Future<Nothing> LinuxFilesystemIsolatorProcess::cleanup(
bool sandboxMountExists = false;
- foreach (const fs::MountInfoTable::Entry& entry, table.get().entries) {
+ // Reverse unmount order to handle nested mount points.
+ foreach (const fs::MountInfoTable::Entry& entry,
+ adaptor::reverse(table.get().entries)) {
// NOTE: All persistent volumes are mounted at targets under the
// container's work directory. We unmount all the persistent
// volumes before unmounting the sandbox/work directory mount.