Which I/O scheduling algorithm is designed to reduce the average seek time by servicing requests in the order of their position on the disk, moving the disk arm in one direction only until it reaches the end?
Think of an elevator moving up and down, servicing requests in one direction before reversing.
The SCAN algorithm moves the disk arm in one direction, servicing all requests until it reaches the end, then reverses direction. This reduces seek time compared to FCFS by avoiding unnecessary back-and-forth movement, though SSTF may have lower average seek time but can cause starvation.
What is the primary purpose of buffering in I/O operations?
Consider why data might need a temporary holding place when moving between fast and slow devices.
Buffering temporarily holds data to accommodate differences in speed between the CPU and I/O devices, preventing data loss or CPU waiting.
Consider a system using double buffering for I/O. What is the main advantage of double buffering compared to single buffering?
Think about how two buffers can be used to overlap operations.
Double buffering uses two buffers so one can be filled while the other is being emptied, allowing reading and writing to happen at the same time and reducing waiting.
Which of the following statements correctly compares SSTF and C-SCAN scheduling algorithms?
Consider how each algorithm moves the disk arm and how that affects wait times.
SSTF selects the closest request next, which can cause starvation for far requests. C-SCAN moves the arm in one direction only, servicing requests in order and then jumping back, providing more uniform wait times.
A system uses buffering for I/O operations. If the buffer size is increased significantly, which of the following is the most likely effect?
Think about the trade-off between throughput and delay when changing buffer size.
Larger buffers can hold more data, improving throughput by reducing I/O wait times. However, very large buffers can cause delays before data is processed, increasing latency.