17
http://raj-os.blogspot.in/ 1 FCFS Scheduling The First Come First Serve Scheduling Advantages Simplest form of disk scheduling algorithm Easy to program Intrinsically fair

Fcfs scheduling

Embed Size (px)

DESCRIPTION

 

Citation preview

Page 1: Fcfs scheduling

http://raj-os.blogspot.in/ 1

FCFS Scheduling

• The First Come First Serve Scheduling

Advantages

– Simplest form of disk scheduling algorithm

– Easy to program

– Intrinsically fair

Page 2: Fcfs scheduling

http://raj-os.blogspot.in/ 2

FCFS Scheduling

• Consider for example an ordered disk queue with

requests involving

– Tracks 98, 183, 37, 122, 14, 124, 65, 67

– “Head pointer” 53

• The request queue (0-199)

Page 3: Fcfs scheduling

http://raj-os.blogspot.in/ 3

FCFS Scheduling

• If the disk head is initially at cylinder 53,

– it will first move from 53 to 98,

– then to 183, 37, 122, 14, 124, 65 and 67 as shown in the next slides

• The total head movement of 640 tracks

Page 4: Fcfs scheduling

http://raj-os.blogspot.in/ 4

FCFS Scheduling

Initial Position

Page 5: Fcfs scheduling

http://raj-os.blogspot.in/ 5

FCFS Scheduling

Head is at 98th track

Page 6: Fcfs scheduling

http://raj-os.blogspot.in/ 6

FCFS Scheduling

Head is at 183rd track

Page 7: Fcfs scheduling

http://raj-os.blogspot.in/ 7

FCFS Scheduling

Head movement from 183 to 37th track

Page 8: Fcfs scheduling

http://raj-os.blogspot.in/ 8

FCFS Scheduling

Head movement from 37 to 122

Page 9: Fcfs scheduling

http://raj-os.blogspot.in/ 9

FCFS Scheduling

Head movement from 122 to 14th track

Page 10: Fcfs scheduling

http://raj-os.blogspot.in/ 10

FCFS Scheduling

Head movement from 14th to 124th track

Page 11: Fcfs scheduling

http://raj-os.blogspot.in/ 11

FCFS Scheduling

Head movement from 124 to 65

Page 12: Fcfs scheduling

http://raj-os.blogspot.in/ 12

FCFS Scheduling

Head movement from 65 to 67th track

Page 13: Fcfs scheduling

http://raj-os.blogspot.in/ 13

Page 14: Fcfs scheduling

http://raj-os.blogspot.in/ 14

FCFS Scheduling

Disadvantages:

• It does not provide best service

• Wild swing from 122 to 14 and then back to 124

• If the requests for tracks 37 and 124 could be serviced together

Page 15: Fcfs scheduling

http://raj-os.blogspot.in/ 15

FCFS Scheduling

• Before or after the requests at 122 and 124

• The average head movement would decrease total head movement &

• Thus Improving disk throughput

Page 16: Fcfs scheduling

http://raj-os.blogspot.in/ 16

Summary

In this class , you have learnt Disk scheduling-Need FCFS disk scheduling algorithm

Page 17: Fcfs scheduling

http://raj-os.blogspot.in/ 17

Frequently asked questions

1. Define seek time and latency time

2.Explain the need for disk scheduling

3.List different disk scheduling algorithms

4.List the advantages and disadvantages of FCFS disk scheduling algorithm

5.List the advantages and disadvantages of FCFS algorithm