hadoop-yarn-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF GitHub Bot (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (YARN-5829) FS preemption should reserve a node before considering containers on it for preemption
Date Fri, 31 Mar 2017 01:17:42 GMT

    [ https://issues.apache.org/jira/browse/YARN-5829?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15950135#comment-15950135
] 

ASF GitHub Bot commented on YARN-5829:
--------------------------------------

Github user kambatla commented on a diff in the pull request:

    https://github.com/apache/hadoop/pull/201#discussion_r109071512
  
    --- Diff: hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-resourcemanager/src/main/java/org/apache/hadoop/yarn/server/resourcemanager/scheduler/fair/FSAppAttempt.java
---
    @@ -647,7 +647,12 @@ private boolean reserve(Resource perAllocationResource, FSSchedulerNode
node,
           Container reservedContainer, NodeType type,
           SchedulerRequestKey schedulerKey) {
     
    -    if (!reservationExceedsThreshold(node, type)) {
    +    RMContainer nodeReservedContainer = node.getReservedContainer();
    +    boolean reservableForThisApp = nodeReservedContainer == null ||
    +        nodeReservedContainer.getApplicationAttemptId()
    +            .equals(getApplicationAttemptId());
    +    if (!reservationExceedsThreshold(node, type) &&
    +        reservableForThisApp) {
    --- End diff --
    
    Let us flip the order here, because reservableForThisApp is cheaper to check. 


> FS preemption should reserve a node before considering containers on it for preemption
> --------------------------------------------------------------------------------------
>
>                 Key: YARN-5829
>                 URL: https://issues.apache.org/jira/browse/YARN-5829
>             Project: Hadoop YARN
>          Issue Type: Sub-task
>          Components: fairscheduler
>            Reporter: Karthik Kambatla
>            Assignee: Miklos Szegedi
>
> FS preemption evaluates nodes for preemption, and subsequently preempts identified containers.
If this node is not reserved for a specific application, any other application could be allocated
resources on this node. 
> Reserving the node for the starved application before preempting containers would help
avoid this.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

---------------------------------------------------------------------
To unsubscribe, e-mail: yarn-issues-unsubscribe@hadoop.apache.org
For additional commands, e-mail: yarn-issues-help@hadoop.apache.org


Mime
View raw message