You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@mesos.apache.org by "Iulian Dragos (JIRA)" <ji...@apache.org> on 2015/08/18 16:56:45 UTC

[jira] [Issue Comment Deleted] (MESOS-1688) No offers if no memory is allocatable

     [ https://issues.apache.org/jira/browse/MESOS-1688?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Iulian Dragos updated MESOS-1688:
---------------------------------
    Comment: was deleted

(was: This commit does not appear in master, nor in any other tags than 0.21. Is that expected?

{code}
$ git tag --contains ab8fa65
0.21.0
0.21.0-rc3
0.21.1
0.21.1-rc1
0.21.1-rc2
$ git branch --contains ab8fa65
$ 
{code})

> No offers if no memory is allocatable
> -------------------------------------
>
>                 Key: MESOS-1688
>                 URL: https://issues.apache.org/jira/browse/MESOS-1688
>             Project: Mesos
>          Issue Type: Bug
>          Components: master
>    Affects Versions: 0.18.1, 0.18.2, 0.19.0, 0.19.1
>            Reporter: Martin Weindel
>            Assignee: Martin Weindel
>            Priority: Critical
>             Fix For: 0.21.0
>
>
> The [Spark scheduler|https://github.com/apache/spark/blob/master/core/src/main/scala/org/apache/spark/scheduler/cluster/mesos/MesosSchedulerBackend.scala] allocates memory only for the executor and cpu only for its tasks.
> So it can happen that all memory is nearly completely allocated by Spark executors, but all cpu resources are idle.
> In this case Mesos does not offer resources anymore, as less than MIN_MEM (=32MB) memory is allocatable.
> This effectively causes a dead lock in the Spark job, as it is not offered cpu resources needed for launching new tasks.
> see {{HierarchicalAllocatorProcess::allocatable(const Resources&)}} called in {{HierarchicalAllocatorProcess::allocate(const hashset<SlaveID>&)}}
> {code}
> template <class RoleSorter, class FrameworkSorter>
> bool
> HierarchicalAllocatorProcess<RoleSorter, FrameworkSorter>::allocatable(
>     const Resources& resources)
> {
> ...
>   Option<double> cpus = resources.cpus();
>   Option<Bytes> mem = resources.mem();
>   if (cpus.isSome() && mem.isSome()) {
>     return cpus.get() >= MIN_CPUS && mem.get() > MIN_MEM;
>   }
>   return false;
> }
> {code}
> A possible solution may to completely drop the condition on allocatable memory.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)