Uploaded image for project: 'Mesos'
  1. Mesos
  2. MESOS-9081

cgroups::verify is expensive and is done implicitly during cgroups operations.

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • None
    • 1.7.0
    • containerization

    Description

      See MESOS-8418 for how this initially came up.

      Currently, many of the cgroup helper functions perform an internal verify:
      https://github.com/apache/mesos/blob/1.6.0/src/linux/cgroups.cpp#L922

      This reads /procs/mounts to see which cgroups subsystems are mounted, and /proc/mounts can get rather large and expensive to read.

      The steady state case (polling /containers and /monitor/snapshot to retrieve container resource usage statistics) was addressed with a short term patch in MESOS-8418. However, we should consider some longer-term fixes that address performance of other events that incur cgroup operations (e.g. updating resources of a container, launching a container, etc):

      1. Consider moving the verify function to public and have the isolators use it where appropriate.
      2. Complementary to 1, optimize verify (e.g. read /proc/self/mountstats as suggested in MESOS-8418).

      Attachments

        Issue Links

          Activity

            People

              jieyu Jie Yu
              bmahler Benjamin Mahler
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: