Top Banner
Task Scheduling in Grid Computing Team Coda
37

Task Scheduling in Grid Computing.

Aug 17, 2015

Download

Engineering

Ramandeep Kaur
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: Task Scheduling in Grid Computing.

Task Scheduling in Grid Computing

Team Coda

Page 2: Task Scheduling in Grid Computing.

Hardik Navin Nagda

[email protected]

Divin Jagdish Visariya

[email protected]

Team Members

Page 3: Task Scheduling in Grid Computing.

Agenda

• Task Scheduling in Grid Computing • Min-Min Algorithm and Max-Min Algorithm • Hypothesis • Our Simulation Idea

• Design of our code

• Code structure explanation

• Demo

Page 4: Task Scheduling in Grid Computing.

Task Scheduling in Grid Computing

• Grid is globally distributed and consists of heterogeneous, loosely coupled data and resources

• Grid changes the resources quite frequently and the systems are heterogeneous in nature

• Task scheduling challenge is to find the best or optimal resources in order to minimize the tasks computation time

Page 5: Task Scheduling in Grid Computing.

Min-Min Algorithm

• Static Task Scheduling Algorithm • Tasks are scheduled based on minimum completion time

• Example : Expected Completion Time

M1 M2 M3

Task 1 3 6 7

Task 2 4 12 8

Task 3 6 20 18

Page 6: Task Scheduling in Grid Computing.

Min-Min Algorithm

M1 M2 M3

Task 1 3 6 7

Task 2 4 12 8

Task 3 6 20 18

Step 1 :

Page 7: Task Scheduling in Grid Computing.

Step 2 :

Min-Min Algorithm

M1 M2 M3

Task 2 4 + 3 12 8

Task 3 6 + 3 20 18

Page 8: Task Scheduling in Grid Computing.

Min-Min Algorithm

M1 M2 M3

Task 3 9 + 4 20 18

Step 3 :

Page 9: Task Scheduling in Grid Computing.

Min-Min algorithm

Image Taken from Paper : An Improved Scheduling Algorithm for Grid Tasks

Image Taken from Paper : An Improved Scheduling Algorithm for Grid Tasks

Page 10: Task Scheduling in Grid Computing.

Max-Min Algorithm

• Static Task Scheduling Algorithm • Two Phases

• First Phase : Set of all minimum expected completion time are found for every task and resource

• Second phase : Task with the maximum value within the above set is selected for execution

• Example : Expected Completion Time

M1 M2 M3

Task 1 3 6 7

Task 2 4 12 8

Task 3 6 20 18

Page 11: Task Scheduling in Grid Computing.

Max-Min Algorithm

M1 M2 M3

Task 1 3 6 7

Task 2 4 12 8

Task 3 6 20 18

Step 1 :

Page 12: Task Scheduling in Grid Computing.

Max-Min Algorithm

M1 M2 M3

Task 1 3 + 6 6 7

Task 2 4 + 6 12 8

Step 2 :

Page 13: Task Scheduling in Grid Computing.

Max-Min Algorithm

M1 M2 M3

Task 1 9 6 7

Task 2 10 12 8

Step 3 :

Page 14: Task Scheduling in Grid Computing.

Max-Min Algorithm

M1 M2 M3

Task 1 9 6 7 + 8

Step 4 :

Page 15: Task Scheduling in Grid Computing.

Max-Min Algorithm

Image Taken from Paper : An Improved Scheduling Algorithm for Grid Tasks

Page 16: Task Scheduling in Grid Computing.

Min-Min v/s Max-Min Algorithm

• If there are many lighter tasks, Max-Min algorithm is better than Min-Min in terms of makespan and resource utilization

• If there are many heavier tasks, Min-Min algorithm is better than Max-Min

Page 17: Task Scheduling in Grid Computing.

Hypothesis

• Grid scheduling using Min-Min algorithm gives lower makespan as compared to the Max-Min algorithm if there are more heavy computational jobs

• Likewise, Max-Min Algorithm gives lower makespan as compared to Min-Min Algorithm if there are more lighter jobs

• Makespan means the entire completion time for the fix number of jobs

Page 18: Task Scheduling in Grid Computing.

Simulation Idea

Page 19: Task Scheduling in Grid Computing.

Design of Min-Min Algorithm • T = {T1, T2 … Tm} : The Set of Tasks

• R = {R1, R2 … Rn} : The Set of Resources

• Expected Execution Time Table

• The m x n matrix which contains the time taken by the task to complete execution for given resource

• Expected Completion Time Table • The m x n matrix which contains the time taken by the

task to complete execution for given resource + waiting time of the task for obtaining the desired resource

• Running Time for Resources • The total time taken by resource to execute all task

assigned

Page 20: Task Scheduling in Grid Computing.

Design of Min-Min Algorithm

• Simulate Task • Task id is generated randomly and its added to the set • Arrival time of the task is recorded

• Scheduler Algorithm is invoked accordingly • Removes the task from the set after it is served

• Min-Min Scheduler

• Computes the Expected Execution Time : • Expected Execution Time = Size of task (MI) / CPU processing

power (MIPS)

• Computes the Expected Completion Time : • Expected Completion Time = Expected Execution Time

+ Resource Running Time - Task Arrival Time

Page 21: Task Scheduling in Grid Computing.

Design of Min-Min Algorithm (Cont..) • Min-Min Scheduler Continued

• Contacts Resource Monitor to check if any resource is idle • If yes, then finds the task with the minimum Expected

Completion Time and also the resource for that task

• Assigns the task to the resource and change the resource status to “Running”

• Adds the Execution Time of the resource to the resource Waiting Time and updates resource Running Time

• Also updates Expected Completion Time based on the resource Waiting Time

• After serving the task the resource again follows the same procedure until all task are served

Page 22: Task Scheduling in Grid Computing.

Design of Min-Min Algorithm (Cont..)

• Resource Monitor • Maintains the status of all the resources after every

task is being served or resource being idle

Page 23: Task Scheduling in Grid Computing.

T1

Set of Tasks

Resources

Page 24: Task Scheduling in Grid Computing.

T1

Set of Tasks

Resources

Page 25: Task Scheduling in Grid Computing.

T2

T1

Set of Tasks

Resources

Page 26: Task Scheduling in Grid Computing.

T1

T2

Set of Tasks

Resources

Page 27: Task Scheduling in Grid Computing.

T1

T2

T3

Set of Tasks

Resources

Page 28: Task Scheduling in Grid Computing.

T1

T2

T3 T4

Set of Tasks

Resources

Page 29: Task Scheduling in Grid Computing.

T1

T2

T3 T4 T5

Set of Tasks

Resources

Page 30: Task Scheduling in Grid Computing.

T4

T2

T5 T3

Set of Tasks

Resources

Page 31: Task Scheduling in Grid Computing.

Task

Page 32: Task Scheduling in Grid Computing.

Resource

Page 33: Task Scheduling in Grid Computing.

Simulate

Page 34: Task Scheduling in Grid Computing.

Demo

Page 35: Task Scheduling in Grid Computing.

MakeSpan Calculation

Page 36: Task Scheduling in Grid Computing.

Progress made so far

• Prepared the design of the system for simulation

• Written the code to simulate the Min-Min algorithm • To be Done:

• Implement Max-Min algorithm

• Perform experiments for different cases

• Evaluate the makespan calculation and check the results

• Prove or Disprove our hypothesis

Page 37: Task Scheduling in Grid Computing.

Questions ?

THANK YOU