Uploaded image for project: 'Spark'
  1. Spark
  2. SPARK-1882

Support dynamic memory sharing in Mesos

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Major
    • Resolution: Won't Fix
    • 1.0.0
    • None
    • Mesos
    • None

    Description

      Fine grained mode Mesos currently supports sharing CPUs very well, but requires that memory be pre-partitioned according to the executor memory parameter. Mesos supports dynamic memory allocation in addition to dynamic CPU allocation, so we should utilize this feature in Spark.

      See below where when the Mesos backend accepts a resource offer it only checks that there's enough memory to cover sc.executorMemory, and doesn't ever take a fraction of the memory available. The memory offer is accepted all or nothing from a pre-defined parameter.

      Coarse mode:
      https://github.com/apache/spark/blob/3ce526b168050c572a1feee8e0121e1426f7d9ee/core/src/main/scala/org/apache/spark/scheduler/cluster/mesos/CoarseMesosSchedulerBackend.scala#L208

      Fine mode:
      https://github.com/apache/spark/blob/a5150d199ca97ab2992bc2bb221a3ebf3d3450ba/core/src/main/scala/org/apache/spark/scheduler/cluster/mesos/MesosSchedulerBackend.scala#L114

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              aash Andrew Ash
              Votes:
              1 Vote for this issue
              Watchers:
              11 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: