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

Hemanth Yamijala updated MAPREDUCE-771:
---------------------------------------

    Attachment: MAPREDUCE-771.patch

Attached patch fixes the issue in scheduling of setup and cleanup tasks. The 
fix is to use TaskTrackerStatus.countOccupied{Map|Reduce}Slots to get the right 
number of slots to account to.

In order to test this in unit test style, I've marked the method 
JobTracker.getSetupAndCleanupTasks as package private. Introduced a new test 
class TestSetupTaskScheduling to test these conditions. Verified without the 
code fix the corresponding tests fail.

Arun and I felt that changing the usage in other schedulers from using slots to 
tasks is probably best left to a different jira as the impact needs to be more 
carefully studied, and this is a simple bug that only affects setup and cleanup 
tasks in the case of capacity scheduler right now.

I plan to run a real cluster test tomorrow manually to ensure things work fine 
still. But I would appreciate a review in the meantime.

> Setup and cleanup tasks remain in UNASSIGNED state for a long time on 
> tasktrackers with long running high RAM tasks
> -------------------------------------------------------------------------------------------------------------------
>
>                 Key: MAPREDUCE-771
>                 URL: https://issues.apache.org/jira/browse/MAPREDUCE-771
>             Project: Hadoop Map/Reduce
>          Issue Type: Bug
>          Components: jobtracker
>    Affects Versions: 0.21.0
>            Reporter: Hemanth Yamijala
>             Fix For: 0.21.0
>
>         Attachments: MAPREDUCE-771.patch
>
>
> When a high RAM job's task is scheduled on a tasktracker, the number of slots 
> it occupies will be more than one. If enough such tasks are scheduled, there 
> can come a situation when there are no more slots free on the node but the 
> number of tasks running is less than the number of slots. The jobtracker 
> currently schedules a setup or cleanup task based on how many tasks are 
> running on the system, rather than slots. As a result of this, it can 
> schedule a setup or cleanup task on a tasktracker without any free slots. If 
> the high RAM job's tasks are long running, this will significantly delay the 
> running of the setup or cleanup task, and thus the entire job.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to