Emery Berger - PowerPoint PPT Presentation

About This Presentation
Title:

Emery Berger

Description:

Operating Systems CMPSCI 377 Lecture 18: Storage Systems Emery Berger University of Massachusetts, Amherst Last Time: Improving I/O Performance Approaches: Caching ... – PowerPoint PPT presentation

Number of Views:109
Avg rating:3.0/5.0
Slides: 20
Provided by: uma105
Category:
Tags: berger | elevator | emery | high | speed

less

Transcript and Presenter's Notes

Title: Emery Berger


1
Operating SystemsCMPSCI 377Lecture 18 Storage
Systems
  • Emery Berger
  • University of Massachusetts, Amherst

2
Last TimeImproving I/O Performance
  • Approaches
  • Caching reduces data transfer
  • Large data transfers
  • DMA

3
Today
  • Improving performance of storage systems (i.e.,
    the disk)
  • Scheduling
  • Interleaving
  • Read-ahead
  • Tertiary storage

4
Disk Operations
  • Disks are SLOW!
  • 1 disk seek 40,000,000 cycles
  • Latency
  • Seek position head over track/cylinder
  • Rotational delay time for sector to rotate
    underneath head
  • Bandwidth
  • Transfer time move bytes from disk to memory

5
Calculating Disk Operations Time
  • Read/write n bytes
  • Cant reduce transfer time
  • Can we reduce latency?

I/O time seek rotational delay transfer(n)
6
Reducing Latency
  • Minimize seek time rotational latency
  • Smaller disks
  • Faster disks
  • Sector size tradeoff
  • Scheduling
  • Layout

7
Disk Head Scheduling
  • Change order of disk accesses
  • Reduce length number of seeks
  • Algorithms
  • FCFS
  • SSTF
  • SCAN, C-SCAN
  • LOOK, C-LOOK

8
FCFS
I/O time seek rotational delay transfer(n)
  • First-come, first-serve
  • Example disk tracks (65, 40, 18, 78)
  • assume head at track 50
  • Total seek time?
  • 15252260 122

65
18
78
40
disk
9
SSTF
I/O time seek rotational delay transfer(n)
  • Shortest-seek-time first (like SJF)
  • Example disk tracks (65, 40, 18, 78)
  • assume head at track 50
  • Total seek time?
  • 10224713 92
  • Is this optimal?

65
18
78
40
disk
10
SCAN
I/O time seek rotational delay transfer(n)
  • Always move back and forth across diska.k.a.
    elevator
  • Example disk tracks (65, 40, 18, 78)
  • assume head at track 50, moving forwards
  • Total seek time?
  • 1513226022132
  • When is this good?

65
18
78
40
disk
11
C-SCAN
I/O time seek rotational delay transfer(n)
  • Circular SCANGo back to start of disk after
    reaching end
  • Example disk tracks (65, 40, 18, 78)
  • assume head at track 50, moving forwards
  • Total seek time?
  • 1513221001840208
  • Can be expensive, but more fair

65
18
78
40
disk
12
LOOK variants
  • Instead of going to end of disk,go to last
    request in each direction
  • SCAN, C-SCAN ) LOOK, C-LOOK

13
Exercises
  • 5000 cylinders, currently at 143, moving
    forwards(86, 1470, 913, 1774, 948, 1509, 1022,
    1750, 130 )
  • FCFS
  • SSTF
  • SCAN
  • LOOK
  • C-SCAN
  • C-LOOK
  • Find sequence total seek time
  • First 0, last 4999

14
Solutions
  • FCFS
  • 143, 86, 1470, 913, 1774, 948, 1509, 1022, 1750,
    130 distance 7,081  
  • SSTF
  • 143, 130, 86, 913, 948, 1022, 1470, 1509, 1750,
    1774 distance 1,745 
  • SCAN
  • 143, 913, 948, 1022, 1470, 1509, 1750, 1774,
    4999, 130, 86 distance 9,769 
  • LOOK
  • 143, 913, 948, 1022, 1470, 1509, 1750, 1774, 130,
    86 distance 3,319 
  • C-SCAN
  • 143, 913, 948, 1022, 1470, 1509, 1750, 1774,
    4999, 0, 86, 130 distance 9,813
  • C-LOOK
  • 143, 913, 948, 1022, 1470, 1509, 1750, 1774, 86,
    130 distance 3,363

15
Today
  • Improving performance of storage systems (i.e.,
    the disk)
  • Scheduling
  • Interleaving
  • Read-ahead
  • Tertiary storage

16
Disk Interleaving
  • Contiguous allocation
  • Requires OS response before disk spins past next
    block
  • Instead of physically contiguous
    allocation,interleave blocks
  • Relative to OS speed, rotational speed

17
Read-Ahead
  • Reduce seeks by reading blocks from disk ahead of
    users request
  • Place in buffer on disk controller
  • Similar to pre-paging
  • Easier to predict future accesses on disk?

18
Tertiary Storage
  • a.k.a. long-term storage
  • disks secondary storage
  • used for archival data or backups
  • Examples
  • tape drives
  • CD-R, DVD-R/W
  • Performance still somewhat important
  • not much OS can do

19
Summary
  • OS can improve storage system performance
  • Scheduling
  • Interleaving
  • Read-ahead
Write a Comment
User Comments (0)
About PowerShow.com