Chapter 11 Flashcards

(33 cards)

1
Q

Why does SSTF scheduling favor middle cylinders?

A

Middle cylinders are closer to more cylinders on average. Requests to middle cylinders have shorter average seek times than requests to edge cylinders. Creates bias toward center of disk.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Why is balancing file-system I/O important in multitasking?

A

Prevents bottlenecks on single disk/controller. Improves overall system throughput. Allows parallel I/O operations. Reduces waiting time for processes.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What are tradeoffs between rereading code pages vs using swap space?

A

Rereading from file: saves swap space but slower due to file system overhead. Swap space: faster access but consumes additional storage. Trade memory usage for speed.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Give two examples where RAID data loss occurs despite protection.

A

Power failure during write operation corrupting multiple disks. Controller failure affecting all disks in array. Multiple simultaneous disk failures exceeding RAID level protection.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

How to calculate effective transfer rate?

A

Effective rate = total bytes / (access latency + transfer time). Transfer time = bytes / streaming rate. Access latency reduces effective rate for small transfers.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What is device utilization formula?

A

Utilization = effective transfer rate / streaming transfer rate. Shows how much of theoretical bandwidth is actually achieved.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What transfer size gives 25% utilization for 15ms latency 5MB/s disk?

A

Access time = transfer time for 25% utilization. 15ms = (bytes / 5MB/s) * 0.75. Minimum transfer ≈ 60KB for acceptable utilization.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

When is disk considered random access vs sequential?

A

Random access: large transfers where access latency is small fraction of total time. Sequential: small transfers where access latency dominates.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Can RAID 1 achieve better read performance than RAID 0?

A

Yes - RAID 1 can read from either mirror choosing closer head position. RAID 0 must read from specific stripe location. Better seek optimization possible.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

What are three advantages of HDDs?

A

Large capacity at low cost. Mature technology with proven reliability. Good for sequential access workloads like backup and archival.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

What are three advantages of NVM devices?

A

No moving parts - more reliable. Much lower access latency. Better random access performance. Lower power consumption.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

Why are disk scheduling algorithms unfair except FCFS?

A

SSTF SCAN C-SCAN can indefinitely postpone requests to distant cylinders. Requests at edges may starve while middle requests are served.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

How to modify SCAN to ensure fairness?

A

Add maximum wait time limit. Use aging to boost priority of long-waiting requests. Implement deadline-based scheduling.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

Why is fairness important in multi-user systems?

A

Prevents user starvation. Ensures predictable response times. Maintains system responsiveness for all users. Critical for interactive applications.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

When should OS be unfair in serving I/O requests?

A

Real-time systems: critical deadlines take priority. System operations: metadata writes before data writes. Emergency: swap operations during memory pressure.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

How does FCFS disk scheduling work?

A

Serve requests in arrival order. Simple but can cause long seek times. No optimization but guarantees fairness and no starvation.

17
Q

How does SCAN disk scheduling work?

A

Move head in one direction serving all requests. When reach end reverse direction. Also called elevator algorithm. Reduces seek time vs FCFS.

18
Q

How does C-SCAN work?

A

Move head in one direction then jump to beginning. More uniform wait times than SCAN. Treats disk as circular queue.

19
Q

How many blocks accessed for RAID 5 single block write?

A

4 blocks total: read old data read old parity calculate new parity write new data write new parity.

20
Q

How many blocks for RAID 5 seven continuous block write?

A

If 7 blocks span multiple parity groups: multiple read-modify-write operations. More efficient than 7 separate single-block writes.

21
Q

Which files for RAID 1 vs RAID 5 placement?

A

RAID 1: frequently accessed files random I/O patterns critical data needing fast access. RAID 5: large sequential files archival data less critical applications.

22
Q

How to calculate MTBF for disk farm?

A

Individual MTBF / number of drives. 1000 drives with 750000 hour MTBF = 750 hours between failures ≈ once per month.

23
Q

What does 1 million hour MTBF mean for warranty?

A

MTBF ≈ 114 years suggests very reliable device. Warranty typically much shorter (3-5 years) than statistical lifetime.

24
Q

Why does OS need accurate disk block information?

A

Can optimize file placement for sequential access. Reduce seek times by placing related files nearby. Schedule I/O to minimize head movement.

25
How can OS improve performance with disk knowledge?
Cluster related files on same cylinders. Schedule writes to minimize seeks. Use disk-aware file allocation algorithms. Optimize for specific disk characteristics.
26
What is difference between streaming and effective transfer rate?
Streaming: theoretical maximum rate during data transfer. Effective: actual rate including access latency and overhead. Effective rate decreases with smaller transfers.
27
How does transfer size affect random vs sequential access classification?
Large transfers amortize access latency making device appear random access. Small transfers dominated by access latency making device appear sequential.
28
What is seek time in disk operation?
Time to move disk head to correct track/cylinder. Major component of access latency. Varies with distance traveled.
29
What is rotational latency?
Time waiting for desired sector to rotate under disk head. Average half rotation time. Independent of seek distance.
30
What is transfer time calculation?
Transfer time = data size / streaming transfer rate. Time actually moving data once positioned correctly.
31
How does RAID 0 work?
Stripes data across multiple disks without redundancy. Improves performance through parallelism. No fault tolerance - any disk failure loses all data.
32
How does RAID 1 work?
Mirrors data on two disks. Provides redundancy and can improve read performance. Doubles storage cost for redundancy.
33
How does RAID 5 work?
Distributes data and parity across multiple disks. Can survive single disk failure. Good balance of performance cost and reliability.