1. Introduction to Disk Scheduling
In operating systems, multiple processes continuously request disk access.
Examples:
Reading files
Writing data
Accessing databases
Loading applications
Since the disk head can serve only one request at a time, the operating system must decide:
Which disk request should be served first?
This decision-making process is called:
Disk Scheduling
The main goal of disk scheduling is:
Reduce seek time
Reduce head movement
Improve throughput
Increase disk efficiency
2. Why C-LOOK Was Introduced
Before understanding C-LOOK, let us briefly understand earlier algorithms.
FCFS
Serves requests in arrival order
Simple but inefficient
SSTF
Serves nearest request first
Improves performance
May cause starvation
SCAN
Moves head in one direction
Reverses at disk end
Better fairness
LOOK
Similar to SCAN
Stops at last request instead of disk end
C-SCAN
Moves in one direction only
After reaching disk end:
Jumps back to beginning
Starts scanning again
However, C-SCAN still wastes movement by unnecessarily traveling to the physical ends of the disk.
This leads to:
C-LOOK
3. What is C-LOOK?
C-LOOK stands for:
Circular LOOK
It is an improved version of:
LOOK
C-SCAN
Definition
C-LOOK moves the disk head in one direction, services all requests until the last request in that direction, then jumps directly to the first request on the other side without going to the disk end.
4. Core Idea of C-LOOK
The key idea is:
Serve requests in one direction only
+
Avoid unnecessary travel to disk ends
This improves efficiency while maintaining fairness.
5. How C-LOOK Works
Suppose the disk head is moving toward higher track numbers.
The algorithm performs these steps:
Serve all requests in increasing order
Stop at the last request
Jump directly to the smallest pending request
Continue servicing again in same direction
The head never reverses direction.
6. Important Difference from LOOK
In LOOK:
Head reverses direction
In C-LOOK:
Head jumps back circularly
Continues in same direction only
This creates more uniform waiting time.
7. Step-by-Step Numerical Example
Given
Request Queue:
98, 183, 37, 122, 14, 124, 65, 67
Initial Head Position = 53
Direction = Right
8. Step 1 — Divide Requests
Requests greater than 53:
65, 67, 98, 122, 124, 183
Requests smaller than 53:
14, 37
9. Step 2 — Sort Requests
Ascending order:
14, 37, 65, 67, 98, 122, 124, 183
10. Step 3 — Service Requests
Since direction is right:
First service:
65 → 67 → 98 → 122 → 124 → 183
After reaching 183:
Head jumps to 14
Continues again
Then:
14 → 37
11. Final Head Movement Sequence
53 → 65 → 67 → 98 → 122 → 124 → 183 → 14 → 37
12. Head Movement Calculation
Now calculate total movement.
Step-by-Step
53 → 65 = 12
65 → 67 = 2
67 → 98 = 31
98 → 122 = 24
122 → 124 = 2
124 → 183 = 59
183 → 14 = 169
14 → 37 = 23
13. Total Head Movement
12 + 2 + 31 + 24 + 2 + 59 + 169 + 23
= 322 cylinders
14. Visualization of C-LOOK
15. Why C-LOOK Is Efficient
Unlike C-SCAN:
It does NOT go to disk ends
Avoids unnecessary movement
Reduces seek time
This improves overall efficiency.
16. Why C-LOOK Provides Better Fairness
Since the head always moves in one direction:
Requests are serviced uniformly
Waiting time becomes more predictable
No request gets unfair priority repeatedly.
17. Advantages of C-LOOK
17.1 Reduced Head Movement
No unnecessary travel to disk boundaries.
17.2 Better Throughput
Reduced seek time improves disk performance.
17.3 More Uniform Waiting Time
Compared to LOOK and SSTF.
17.4 Avoids Starvation
Every request eventually gets serviced.
18. Disadvantages of C-LOOK
18.1 Jump Overhead
Large jumps may still occur.
Example:
183 → 14
18.2 More Complex Than FCFS
Requires sorting and direction management.
18.3 Direction Dependency
Performance depends on current direction.
19. Comparison with Other Algorithms
| Algorithm | Direction | Goes to Disk End | Fairness | Efficiency |
|---|---|---|---|---|
| FCFS | Random | No | High | Poor |
| SSTF | Nearest | No | Poor | High |
| SCAN | Both ways | Yes | Good | Good |
| LOOK | Both ways | No | Good | Better |
| C-SCAN | One way | Yes | Very Good | Medium |
| C-LOOK | One way | No | Very Good | High |
20. Real-World Analogy
Imagine a circular bus route.
The bus:
Travels only clockwise
Stops only where passengers exist
Does not travel unnecessarily to empty roads
After last stop:
Jumps to first stop
Continues again
This is exactly how C-LOOK works.
21. Important Insight
The most important concept is:
C-LOOK combines the fairness of C-SCAN with the efficiency of LOOK.
That is why it is considered one of the best practical disk scheduling algorithms.