An executor is terminated by Mesos if it misbehaves (e.g. sends TASK_STAGING updates or uses too much memory), killed by an oversubscription QoSController, a framework shuts down, or a scheduler sends a scheduler::Call::Shutdown request to Mesos. Note that an executor may also fail or decide to commit suicide.
On Tue, Jun 30, 2015 at 12:38 PM, Hans van den Bogert <[email protected]> wrote: > Exactly what I needed to know, one follow-up question though: > > An executor is terminated by Mesos if it has no running tasks > > Does this mean there is some timeout? Or does the “parent” framework > actively have to give a command to shutdown the executor? Because using > Spark in fine-grained mode for example, I don’t see the executors getting > shutdown, even though they might not have tasks for a while. (I am glad > they don’t get killed without consent of Spark, because we would lose our > in memory data). > > On 30 Jun 2015, at 12:32, Alex Rukletsov <[email protected]> wrote: > > There are two types of tasks: (1) those that specify an executor and (2) > those, that specify a command. > > When a task of ttype (1) arrives to a slave, the slave checks whether an > executor with the same executorID already exists on this slave. If yes, the > task is redirected to the executor; if not, then an executor instance is > created. An executor is terminated by Mesos if it has no running tasks and > all status updated for terminated tasks have been delivered. > > For tasks of type (2) a special executor (called MesosExecutor) is created > for each task. When such task terminates or is killed, the corresponding > executor shuts down as well. > > On Tue, Jun 30, 2015 at 12:08 PM, Hans van den Bogert < > [email protected]> wrote: > >> I have difficulty understanding Mesos’ model. >> >> A framework can, for every accepted resource offer, mention an executor >> besides the tasks descriptions it submits to Mesos. However does every use >> of offered resources, start a new executor? Thus for instance if the >> scenario occurs that two resource offers are used (shortly after each >> other), which happen to be of the same slave, then are two executors >> started at one point? Or is the second batch of tasks given to the first >> started executor? >> >> I hope my question is clear, if not, let me know, >> >> Hans van den Bogert > > > >

