[OS]I/O System and Disk Management
I/O Mechanisms
- Processor controlled memory access
- Polling (Programmed I/O)
- Interrupt
- Direct Memory Access (DMA)
Pooling(Programmed I/O)
- The processor periodically checks the status of the I/O devices
Interrupt
- After I/O devices completes the task, communicate its status to the processor
- lower overhead than pooling
- Interrupt handling overhead
I/O Servies of OS
- I/O Scheduling
- E.g., Disk I/O scheduling
- Error handling
- E.g., disk access fail, network communication error
- I/O device information managements
- Buffering
- Caching
- Spooling
Disk Scheduling
- Optimizing seek time
- FCFS (First Come First SErvice)
- SSTF (Shortest Seek Time First)
- Scan
- C-Scan (Circular Scan)
- Look
- Optimizing rotational delay
- Sector queueing (SLTF, Shortest Latency Time First)
- SPTF (Shortest Positioning Time First)
FCFS
- Advantage
- Problem
- Does not consider optimization
SSTF
- Advantage
- High throughput
- Low average response time
- Problem
- Low predictability
- Starvation
Scan Scheduling
- Advantage
- Fix starvation issue in SSTF
- Excellent throughput and average response time
- Problem
- High response time on the other side of the process
C-Scan Scheduling
- Similar to Scan Scheduling
- Advantage
- Equal opportunity than Scan
Look Scheduling
- Elevator algorithm
- Advantage
- Remove unnecessary head movement of Scan
SLTF
- Use Fixde head disk system
- Sector queuing algorithm
SPTF
- Positioning time = Seek time + rotational delay
- Advantage
- High throughput
- Low average response time
- Problem
- Starvation occurs for innermost and outer cylinder requests
RAID Architecture
- Redundant Array of Inexpensive Disks(RAID)
- OS support, RAID controller
- Use to improve disk system performance
- Performance (access speed)
- Reliability
Reference
I/O System and Disk Management