LOOK Disk Scheduling
LOOK Disk Scheduling
🔷 What is LOOK?
LOOK is an improved version of SCAN.
👉 Key idea:
-
The disk head does NOT go to the end of the disk
-
It only goes as far as the last request in that direction, then reverses
1. How LOOK Works
🔷 Steps
-
Start at current head position
-
Move in a chosen direction
-
Service all requests in that direction
-
Stop at the last request (not disk end)
-
Reverse direction
-
Continue servicing remaining requests
2. Example
🔹 Given:
-
Request queue:
-
Initial head position:
-
Direction:
👉 Moving toward 0 (same as SCAN example)
🔷 Step-by-Step Execution
Step 1: Move Left (toward 0)
Requests less than 53:
Service in descending order:
👉 Stop at 14 (last request in this direction)
❌ Do NOT go to 0
Step 2: Reverse Direction
Now move right and service remaining requests:
🔷 Final Order of Service
3. Total Head Movement
👉 Total = 208 cylinders
4. Advantages
✅ 1. Less Movement than SCAN
-
Avoids unnecessary travel to disk ends
✅ 2. Better Performance
-
Reduces seek time
✅ 3. Fairness
-
No starvation (like SCAN)
5. Disadvantages
🔴 1. Slight Waiting Issues
-
Requests just behind head may wait longer
6. Key Insight
👉 Difference from SCAN:
-
SCAN → goes to disk end (0 or max)
-
LOOK → stops at last request
👉 Result:
-
Saves time
-
Improves efficiency
7. Comparison Snapshot
| Algorithm | Total Movement |
|---|---|
| FCFS | 640 |
| SSTF | 236 |
| SCAN | (higher than LOOK) |
| LOOK | 208 |
8. Simple Analogy
-
SCAN → Elevator goes to top floor even if no one is there
-
LOOK → Elevator stops at highest requested floor and turns back
9. Key Takeaways
-
LOOK = optimized SCAN
-
Avoids unnecessary movement
-
Improves efficiency
-
Widely used in practice
Comments
Post a Comment