You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mesos.apache.org by ji...@apache.org on 2018/08/21 20:33:07 UTC

[mesos] branch 1.7.x updated (d83f5f9 -> 59b3d2e)

This is an automated email from the ASF dual-hosted git repository.

jieyu pushed a change to branch 1.7.x
in repository https://gitbox.apache.org/repos/asf/mesos.git.


    from d83f5f9  Removed MESOS-4509 from the 1.7.0 CHANGELOG.
     new 821494e  Skip the container if there's no container network.
     new 59b3d2e  Added MESOS-9171 to 1.7.0 CHANGELOG.

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 CHANGELOG                                                   |  1 +
 src/slave/containerizer/mesos/isolators/network/cni/cni.cpp | 10 ++++++++++
 2 files changed, 11 insertions(+)


[mesos] 01/02: Skip the container if there's no container network.

Posted by ji...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

jieyu pushed a commit to branch 1.7.x
in repository https://gitbox.apache.org/repos/asf/mesos.git

commit 821494e785cc215d605d3f4a0771e3a24fac59ec
Author: Sergey Urbanovich <se...@gmail.com>
AuthorDate: Tue Aug 21 13:23:08 2018 -0700

    Skip the container if there's no container network.
    
    If the container wants to join host network it won't have container
    networks. In that case `rootDir` could be not configured and
    `rootDir.get()` in `usage()` will cause mesos agent crash.
    
    Review: https://reviews.apache.org/r/68448/
    (cherry picked from commit e6828b778ca3bcac0f1400049440661702668cc5)
---
 src/slave/containerizer/mesos/isolators/network/cni/cni.cpp | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/src/slave/containerizer/mesos/isolators/network/cni/cni.cpp b/src/slave/containerizer/mesos/isolators/network/cni/cni.cpp
index 6df52a5..ed47046 100644
--- a/src/slave/containerizer/mesos/isolators/network/cni/cni.cpp
+++ b/src/slave/containerizer/mesos/isolators/network/cni/cni.cpp
@@ -1513,6 +1513,16 @@ Future<ResourceStatistics> NetworkCniIsolatorProcess::usage(
     return ResourceStatistics();
   }
 
+  // Skip the container if there's no container network, e.g.
+  // container joins host network.
+  if (infos[containerId]->containerNetworks.empty()) {
+    return ResourceStatistics();
+  }
+
+  // If the `network/cni` isolator is providing network isolation to
+  // the container its `rootDir` should always be set.
+  CHECK_SOME(rootDir);
+
   const string netns = paths::getNamespacePath(rootDir.get(), containerId);
 
   // We collect networking statistics only for known interfaces.


[mesos] 02/02: Added MESOS-9171 to 1.7.0 CHANGELOG.

Posted by ji...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

jieyu pushed a commit to branch 1.7.x
in repository https://gitbox.apache.org/repos/asf/mesos.git

commit 59b3d2ef9bd2a3d167c58bc5dd80257f06254e5a
Author: Jie Yu <yu...@gmail.com>
AuthorDate: Tue Aug 21 13:32:32 2018 -0700

    Added MESOS-9171 to 1.7.0 CHANGELOG.
    
    (cherry picked from commit 7f5ddf05c32468fa6be865a80503e295be50460c)
---
 CHANGELOG | 1 +
 1 file changed, 1 insertion(+)

diff --git a/CHANGELOG b/CHANGELOG
index 9acef39..0f130b6 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -140,6 +140,7 @@ All Resolved Issues:
   * [MESOS-9160] - Failed to compile gRPC when the build path contains symlinks.
   * [MESOS-9163] - `UriDiskProfileAdaptor` should not update profiles when a poll returns a non-OK HTTP status.
   * [MESOS-9170] - Zookeeper doesn't compile with newer gcc due to format error.
+  * [MESOS-9171] - Mesos agent crashes in CNI isolator when usage is queried.
 
 ** Documentation
   * [MESOS-8740] - Update description of a Containerizer interface.