DISK MANAGEMENT SYSTEMS
DISK MANAGEMENT SYSTEMS
Mass-Storage Systems
Overview of Mass Storage Structure
HDD Scheduling
NVM Scheduling
Error Detection and Correction
Storage Device Management
Swap-Space Management
Storage Attachment
RAID Structure
Objectives
Describe the physical structure of secondary storage
devices and the effect of a device’s structure on its uses
Explain the performance characteristics of mass-storage
devices
Evaluate I/O scheduling algorithms
Discuss operating-system services provided for mass
storage, including RAID
Overview of Mass Storage Structure
Bulk of secondary storage for modern computers is hard
disk drives (HDDs) and nonvolatile memory (NVM)
devices
HDDs spin platters of magnetically-coated material under
moving read-write heads
Drives rotate at 60 to 250 times per second
Transfer rate is rate at which data flow between drive and
computer
Positioning time (random-access time) is time to move disk
arm to desired cylinder (seek time) and time for desired sector
to rotate under the disk head (rotational latency)
Head crash results from disk head making contact with the disk
surface -- That’s bad
Disks can be removable
Moving-head Disk Mechanism
Hard Disk Drives
Platters range from .85” to 14”
(historically)
Commonly 3.5”, 2.5”, and 1.8”
Range from 30GB to 3TB per drive
Performance
Transfer Rate – theoretical – 6
Gb/sec
Effective Transfer Rate – real –
1Gb/sec
Seek time from 3ms to 12ms –
9ms common for desktop drives
Average seek time measured or
calculated based on 1/3 of tracks
Latency based on spindle speed
1 / (RPM / 60) = 60 / RPM
Average latency = ½ latency
Hard Disk Performance
Access Latency = Average access time = average seek
time + average latency
For fastest disk 3ms + 2ms = 5ms
For slow disk 9ms + 5.56ms = 14.56ms
Average I/O time = average access time + (amount to
transfer / transfer rate) + controller overhead
For example to transfer a 4KB block on a 7200 RPM disk with
a 5ms average seek time, 1Gb/sec transfer rate with a .1ms
controller overhead =
5ms + 4.17ms + 0.1ms + transfer time =
Transfer time = 4KB / 1Gb/s * 8Gb / GB * 1GB / 1024 2KB = 32 /
(10242) = 0.031 ms
Average I/O time for 4KB block = 9.27ms + .031ms = 9.301ms
The First Commercial Disk Drive
1956
IBM RAMDAC computer
included the IBM Model 350
disk storage system
5M (7 bit) characters
50 x 24” platters
Access time = < 1 second
Nonvolatile Memory Devices
If disk-drive like, then called solid-state disks (SSDs)
Other forms include USB drives (thumb drive, flash drive),
DRAM disk replacements, surface-mounted on motherboards,
and main storage in devices like smartphones
Can be more reliable than HDDs
More expensive per MB
Maybe have shorter life span – need careful management
Less capacity
But much faster
Busses can be too slow -> connect directly to PCI for example
No moving parts, so no seek time or rotational latency
Nonvolatile Memory Devices
Have characteristics that present
challenges
Read and written in “page”
increments (think sector) but
can’t overwrite in place
Must first be erased, and erases
happen in larger ”block”
increments
Can only be erased a limited
number of times before worn out –
~ 100,000
Life span measured in drive
writes per day (DWPD)
A 1TB NAND drive with rating of
5DWPD is expected to have 5TB
per day written within warrantee
period without failing
NAND Flash Controller Algorithms
With no overwrite, pages end up with mix of valid and invalid
data
To track which logical blocks are valid, controller maintains
flash translation layer (FTL) table
Also implements garbage collection to free invalid page
space
Allocates overprovisioning to provide working space for GC
Each cell has lifespan, so wear leveling needed to write
equally to all cells