Difference between SCAN and C-SCAN Disk Scheduling AlgorithmIn this article, you will learn about the difference between the SCAN and C-SCAN Disk Scheduling Algorithm. But before discussing the differences, you have to know about the SCAN and C-SCAN Disk Scheduling Algorithm. What is SCAN Disk Scheduling Algorithm?It is also known as the Elevator algorithm. In this algorithm, the head may move in both directions, i.e., the disk arm begins to move from one end of the disk to the other end and servicing all requests until it reaches the other end of the disk. After reaching the other end, the head position direction is changed and further continues servicing the requests till the end of the disk. Example: Let's take a disk with 180 tracks (0-179) and the disk queue having input/output requests in the following order: 75, 90, 40, 135, 50, 170, 65, 10. The initial head position of the Read/Write head is 45 and will move on the left-hand side. Find the total number of track movements of the Read/Write head using the SCAN algorithm. Solution: Total head movements, Initial head point is 45, = (45-40) + (40-10) + (10-0) + (50-0) + (65-50) + (75-65) + (90-75) + (135-90) + (170-135) = 5 + 30 +10 +50 +15 + 10 +15 + 45 + 35 = 215 Advantages and Disadvantages of SCAN Disk Scheduling AlgorithmThere are various advantages and disadvantages of SCAN disk scheduling algorithm. These advantages and disadvantages are as follows: Advantages
Disadvantages
What is C-SCAN Disk Scheduling Algorithm?It is also known as the Circular Elevator algorithm. It is an improved version of the SCAN disk scheduling algorithm. In this algorithm, the head works for requests in a single direction, i.e., it scans all the way to the end of a direction and then jumps to another end and services the requests in the same direction. Example: Let's take a disk with 180 tracks (0-179) and the disk queue having input/output requests in the following order: 75, 90, 40, 135, 50, 170, 65, 10. The initial head position of the Read/Write head is 45 and will move on the right-hand side. Find the total number of track movements of the Read/Write head using the C-SCAN algorithm. Solution: Total head movements, The initial head point is 45, = (50-45) + (65-50) + (75-65) + (90-75) + (135-90) + (170-135) + (179-170) + (179-0) + (10-0) + (40-10) = 5 + 15 + 10 +15 + 45 + 35 + 9 +179 + 10 + 30 = 353 Advantages and Disadvantages of C-SCAN Disk Scheduling AlgorithmThere are various advantages and disadvantages of the C-SCAN disk scheduling algorithm. These advantages and disadvantages are as follows: Advantages
Disadvantages
Main Differences between the SCAN and C-SCAN Disk Scheduling AlgorithmHere, you will learn the main differences between the SCAN and C-SCAN Disk Scheduling Algorithm. Various differences between the SCAN and C-SCAN Disk Scheduling Algorithm are as follows:
Head-to-head Comparison between the SCAN and C-SCAN Disk Scheduling AlgorithmHere, you will learn the head-to-head comparison between the SCAN and C-SCAN Disk Scheduling Algorithm. The main differences between the SCAN and C-SCAN Disk Scheduling Algorithm are as follows:
Next TopicSCAN vs FCFS Disk Scheduling Algorithm
|