0% found this document useful (0 votes)
34 views61 pages

Chapter4 DeviceManagement v1

This document discusses device management and input/output systems. It covers topics like dedicated, shared and virtual devices, direct access storage devices, optical discs, flash memory storage, components of the I/O subsystem, and communication among devices.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
34 views61 pages

Chapter4 DeviceManagement v1

This document discusses device management and input/output systems. It covers topics like dedicated, shared and virtual devices, direct access storage devices, optical discs, flash memory storage, components of the I/O subsystem, and communication among devices.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 61

Chapter 4

Device Management
Learning Objectives

After completing this chapter, you should be able to


describe:
• Features of dedicated, shared, and virtual devices
• Differences between sequential and direct access media
• Concepts of blocking and buffering and how they
improve I/O performance
• Roles of seek time, search time, and transfer time in
calculating access time
Learning Objectives (cont'd.)

• Differences in access times in several types of devices


• Critical components of the input/output subsystem,
and how they interact
• Strengths and weaknesses of common seek strategies,
including FCFS, SSTF, SCAN/LOOK, C-SCAN/C-
LOOK, and how they compare
• Different levels of RAID and what sets each apart
from the others
Types of Devices

• Dedicated Devices
• Device assigned to one job at a time
• For entire time job is active (or until released)
• Example: tape drives, printers, and plotters
• Disadvantage
• Inefficient if device is not used 100%
• Allocated for duration of job’s execution
Types of Devices (cont'd.)

• Shared Devices
• Device assigned to several processes
• Example: direct access storage device (DASD)
• Processes share DASD simultaneously
• Requests interleaved
• Device manager supervision
• Controls interleaving
• Predetermined policies determine conflict resolution
Types of Devices (cont'd.)

• Virtual Devices
• Dedicated and shared device combination
• Dedicated devices transformed into shared devices
• Example: printer
• Converted by spooling program
• Spooling
• Speeds up slow dedicated I/O devices
• Example: universal serial bus (USB) controller
• Interface between operating system, device drivers, applications,
and devices attached via USB host
Types of Devices (cont'd.)

• Storage media
• Two groups
• Sequential access media
• Records stored sequentially
• Direct access storage devices (DASD)
• Records stored sequentially
• Records stored using direct access files
• Vast differences
• Speed and sharability
Direct Access Storage Devices
• Directly read or write to specific disk area
• Random access storage devices
• Four categories
• Magnetic disks
• Optical discs
• Flash memory
• Magneto-optical disks
• Access time variance
• Not as wide as magnetic tape
• Record location directly affects access time
Fixed-Head Magnetic Disk
Storage
• Looks like a large CD or DVD
• Covered with magnetic film
• Formatted
• Both sides (usually) in concentric circles called tracks
• Data recorded serially on each track
• Fixed read/write head positioned over data
• Advantages
• Fast (more so than movable head)
• Disadvantages
• High cost and reduced storage
Fixed-Head Magnetic Disk
Storage (cont'd.)
Movable-Head Magnetic Disk
• Storage
One read/write head floats over disk surface
• Example: computer hard drive
• Disks
• Single platter
• Part of disk pack (stack of platters)
• Disk pack platter
• Two recording surfaces
• Exception: top and bottom platters
• Surface formatted with concentric tracks
• Track number varies
• 1000+ (high-capacity disk)
Movable-Head Magnetic Disk
Storage (cont'd.)
• Disk pack platter (cont'd.)
• Track surface number
• Track zero: outermost concentric circle on each surface
• Center: contains highest-numbered track
• Arm moves over all heads in unison
• Slower: fill disk pack surface-by-surface
• Faster: fill disk pack track-by-track
• Virtual cylinder: fill track zero
• Record access system requirements
• Cylinder number, surface number, record number
Movable-Head Magnetic Disk
Storage (cont'd.)
Optical Disc Storage
• Design difference
• Magnetic disk
• Concentric tracks of sectors
• Spins at constant angular
velocity (CAV)
• Wastes storage space but
fast data retrieval
Optical Disc Storage (cont'd.)
• Design features
• Optical disc
• Single spiralling track of
same-sized sectors running
from center to disc rim
• Spins at constant linear
velocity (CLV)
• More sectors and more disc
data
Optical Disc Storage (cont'd.)
• Two important performance measures
• Sustained data-transfer rate
• Speed to read massive data amounts from disc
• Measured in megabytes per second (Mbps)
• Crucial for applications requiring sequential access
• Average access time
• Average time to move head to specific disc location
• Expressed in milliseconds (ms)

• Third feature
• Cache size (hardware)
• Buffer to transfer data blocks from disc
CD and DVD Technology

• CD
• Data recorded as zeros and ones
• Pits: indentations
• Lands: flat areas
• Reads with low-power laser
• Light strikes land and reflects to photodetector
• Pit is scattered and absorbed
• Photodetector converts light intensity into digital signal
CD and DVD Technology
(cont'd.)
• CD-Recordable technology (CD-R)
• Requires expensive disk controller
• Records data using write-once technique
• Data cannot be erased or modified
• Disk
• Contains several layers
• Gold reflective layer and dye layer
• Records with high-power laser
• Permanent marks on dye layer
• CD cannot be erased after data recorded
• Data read on standard CD drive (low-power beam)
CD and DVD Technology
(cont'd.)
• CD-Rewritable technology (CD-RW)
• Data written, changed, erased
• Uses phase change technology
• Amorphous and crystalline phase states
• Record data: beam heats up disc
• State changes from crystalline to amorphous
• Erase data: low-energy beam to heat up pits
• Loosens alloy to return to original crystalline state
• Drives read standard CD-ROM, CD-R, CD-RW discs
• Drives store large quantities of data, sound, graphics, multimedia
CD and DVD Technology
(cont'd.)
• DVD technology (Digital Versatile Disc)
• CD-ROM comparison
• Similar in design, shape, size
• Differs in data capacity
• Dual-layer, single-sided DVD holds 13 CDs
• Single-layer, single-sided DVD holds 8.6 GB (MPEG video compression)
• Differs in laser wavelength
• Uses red laser (smaller pits, tighter spiral)
• DVDs cannot be read by CD or CD-ROM drives
• DVD-R and DVD-RW provide rewritable flexibility
Blu-Ray Disc Technology

• Same physical size as DVD/CD


• Smaller pits
• More tightly wound tracks
• Use of blue-violet laser allows multiple layers
• 50GB-500GB
• 432 Mbps
• Formats: BD-ROM, BD-R, BD-RE
Flash Memory Storage
• Electronically erasable programmable read-only memory (EEP)
• Nonvolatile and removable
• Emulates random access
• Difference: data stored securely (even if removed)
• Data stored on microchip card or “key”
• Compact flash, smart cards, memory sticks
• Often connected through USB port
• Write data: electric charge sent through floating gate
• Erase data: strong electrical field (flash) applied
Components of the I/O
• I/O Channel
• Programmable units
Subsystem
• Positioned between CPU and control unit
• Synchronizes device speeds
• CPU (fast) with I/O device (slow)
• Manages concurrent processing
• CPU and I/O device requests
• Allows overlap
• CPU and I/O operations
• Channels: expensive because so often shared
Components of the I/O
Subsystem (cont'd.)
• I/O channel programs
• Specifies action performed by devices
• Controls data transmission
• Between main memory and control units
• I/O control unit: receives and interprets signal
• Disk controller (disk drive interface)
• Links disk drive and system bus
• Entire path must be available when I/O command initiated
• I/O subsystem configuration
• Multiple paths increase flexibility and reliability
Components of the I/O
Subsystem (cont'd.)
Components of the I/O
Subsystem (cont'd.)
Communication Among
Devices
• Problems to resolve
• Know which components are busy/free
• Solved by structuring interaction between units
• Accommodate requests during heavy I/O traffic
• Handled by buffering records and queuing requests
• Accommodate speed disparity between CPU and I/O
devices
• Handled by buffering records and queuing requests
Communication Among
Devices (cont'd.)
• I/O subsystem units finish independently of others
• CPU processes data while I/O performed
• Success requires device completion knowledge
• Hardware flag tested by CPU
• Channel status word (CSW) contains flag
• Three bits in flag represent I/O system component (channel, control
unit, device)
• Changes zero to one (free to busy)
• Flag tested using polling and interrupts
• Interrupts are more efficient way to test flag
Communication Among
Devices (cont'd.)
• Direct memory access (DMA)
• Allows control unit main memory access directly
• Transfers data without the intervention of CPU
• Used for high-speed devices (disk)
• Buffers
• Temporary storage areas in main memory, channels, control units
• Improves data movement synchronization
• Between relatively slow I/O devices and very fast CPU
• Double buffering: processing of record by CPU while another is
read or written by channel
Communication Among
Devices (cont'd.)
Management of I/O Requests

• I/O traffic controller


• Watches status of devices, control units, channels
• Three main tasks
• Determine if path available
• If more than one path available, determine which one to
select
• If paths all busy, determine when one is available
• Maintain database containing unit status and connections
Management of I/O Requests
(cont'd.)
• I/O scheduler
• Same job as process scheduler (Chapter 4)
• Allocates devices, control units, channels
• If requests greater than available paths
• Decides which request to satisfy first: based on different criteria
• In many systems
• I/O requests not preempted
• For some systems
• Allow preemption with I/O request subdivided
• Allow preferential treatment for high-priority requests
Management of I/O Requests
(cont'd.)
• I/O device handler
• Performs actual data transfer
• Processes device interrupts
• Handles error conditions
• Provides detailed scheduling algorithms
• Device dependent
• Each I/O device type has device handler algorithm
Device Handler Seek Strategies
• Predetermined device handler
• Determines device processing order
• Goal: minimize seek time
• Types
• First-come, first-served (FCFS), shortest seek time first (SSTF),
SCAN (including LOOK, N-Step SCAN, C-SCAN, and C-LOOK)
• Scheduling algorithm goals
• Minimize arm movement
• Minimize mean response time
• Minimize variance in response time
First Come First Serve (FCFS)
 We illustrate scheduling algorithms with a request queue (0-
199)

98, 183, 37, 122, 14, 124, 65, 67

Head pointer 53

Illustration shows total head movement of 640 cylinders


Device Handler Seek Strategies
• FCFS (cont'd.)
• On average: does not meet three seek strategy goals
• Disadvantage: extreme arm movement
Shortest Seek Time First (SSTF)
• Shortest Seek Time First selects the request with the minimum seek time
from the current head position

 We illustrate scheduling algorithms with a request


queue (0-199)
98, 183, 37, 122, 14, 124, 65, 67
Head pointer 53

Illustration shows total head movement of 236 cylinders


Device Handler Seek Strategies
(cont'd.)
• Shortest Seek Time First (SSTF)
• Request with track closest to one being served
• Minimizes overall seek time
• Postpones traveling to out of way tracks
SCAN
• SCAN
• Directional bit
• Indicates if arm moving toward/away from disk center
• Algorithm moves arm methodically
• From outer to inner track, services every request in its path
• If reaches innermost track, reverses direction and moves toward outer tracks
• Services every request in its path

• The disk arm starts at one end of the disk, and moves toward the other
end, servicing requests until it gets to the other end of the disk, where
the head movement is reversed and servicing continues.
• SCAN algorithm Sometimes called the elevator algorithm
Device Handler Seek Strategies (cont'd.)
 We illustrate scheduling algorithms with a request queue (0-
199). Assume arm move to the beginning of the queue
98, 183, 37, 122, 14, 124, 65, 67
Head pointer 53

Illustration shows total head movement of 208 cylinders


Device Handler Seek Strategies
• LOOK
(cont'd.)
• Arm does not go to either edge
• Unless requests exist
• Eliminates indefinite postponement
Circular SCAN

• C-SCAN (Circular SCAN)


• The head moves from one end of the disk to the other,
servicing requests as it goes
• When it reaches the other end, however, it immediately
returns to the beginning of the disk, without servicing
any requests on the return trip
• Provides more uniform wait time
Device Handler Seek Strategies
(cont'd.)
 We illustrate scheduling algorithms with a request queue
(0-199). Assume arm move to the end of the disk
98, 183, 37, 122, 14, 124, 65, 67
Head pointer 53

Illustration shows total head movement of 382 cylinders


Circular LOOK

• C-LOOK
• LOOK a version of SCAN, C-LOOK a version of C-
SCAN
• Arm only goes as far as the last request in each direction,
then reverses direction immediately, without first going
all the way to the end of the disk
Device Handler Seek Strategies
 (cont'd.)
We illustrate scheduling algorithms with a request queue (0-
199).Assume arm move towards the end of the disk
98, 183, 37, 122, 14, 124, 65, 67
Head pointer 53

Illustration shows total head movement of 338


cylinders
Device Handler Seek Strategies
(cont'd.)
• Best strategy
• FCFS best with light loads
• Service time unacceptably long under high loads
• SSTF best with moderate loads
• Localization problem under heavy loads
• SCAN best with light to moderate loads
• Eliminates indefinite postponement
• Throughput and mean service times SSTF similarities
• C-SCAN best with moderate to heavy loads
• Very small service time variances
RAID
• Physical disk drive set viewed as single logical unit
• Preferable over few large-capacity disk drives
• Improved I/O performance
• Improved data recovery
• Disk failure event
• Introduces redundancy
• Helps with hardware failure recovery
• Significant factors in RAID level selection
• Cost, speed, system’s applications
• Increases hardware costs
RAID (cont'd.)
RAID (cont'd.)
Level Zero
• Uses data striping (not considered true RAID)
• No parity and error corrections
• No error correction/redundancy/recovery
• Benefits
• Devices appear as one logical unit
• Best for large data quantity non-critical data
Level One
• Uses data striping (considered true RAID)
• Mirrored configuration (backup)
• Duplicate set of all data (expensive)
• Provides redundancy and improved reliability
Level Two
• Uses small stripes (considered true RAID)
• Hamming code: error detection and correction
• Expensive and complex
• Size of strip determines number of array disks
Level Three
• Modification of Level 2
• Requires one disk for redundancy
• One parity bit for each strip
Level Four
• Same strip scheme as Levels 0 and 1
• Computes parity for each strip
• Stores parities in corresponding strip
• Has designated parity disk
Level Five
• Modification of Level 4
• Distributes parity strips across disks
• Avoids Level 4 bottleneck
• Disadvantage
• Complicated to regenerate data from failed device
Level Six
• Provides extra degree of error protection/correction
• Two different parity calculations (double parity)
• Same as level four/five and independent algorithm
• Parities stored on separate disk across array
• Stored in corresponding data strip
• Advantage: data restoration even if two disks fail
Nested RAID Levels
• Combines multiple RAID levels (complex)
Nested RAID Levels (cont'd.)
Summary
• Device Manager
• Manages every system device effectively as possible
• Devices
• Vary in speed and sharability degrees
• Direct access and sequential access
• Magnetic media: one or many read/write heads
• Heads in a fixed position (optimum speed)
• Move across surface (optimum storage space)
• Optical media: disk speed adjusted
• Data recorded/retrieved correctly
Summary (cont'd.)
• Flash memory: device manager tracks USB devices
• Assures data sent/received correctly
• I/O subsystem success dependence
• Communication linking channels, control units, devices
• SCAN: eliminates indefinite postponement problem
• Best for light to moderate loads
• C-SCAN: very small service time variance
• Best for moderate to heavy loads
• RAID: redundancy helps hardware failure recover
• Consider cost, speed, applications
Summary (cont'd.)

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy