CENG334 Introduction to Operating Systems Erol Sahin Dept of Computer Eng. Middle East Technical University Ankara, TURKEY URL:

Slides:



Advertisements
Similar presentations
IT253: Computer Organization
Advertisements

Overview of Mass Storage Structure
Hard Disk Drives Chapter 7.
Operating Systems ECE344 Ashvin Goel ECE University of Toronto Disks and RAID.
CS4432: Database Systems II Data Storage - Lecture 2 (Sections 13.1 – 13.3) Elke A. Rundensteiner.
Operating Systems Input/Output Devices (Ch , 12.7; , 13.7)
Disk Drivers May 10, 2000 Instructor: Gary Kimura.
Prof. John Nestor ECE Department Lafayette College Easton, Pennsylvania ECE Computer Organization Lecture 22 - Input/Output.
Disks.
IT Systems In and Out EN230-1 Justin Champion C208 –
Silberschatz, Galvin and Gagne ©2009 Operating System Concepts – 8 th Edition Mass-Storage Systems Revised Tao Yang.
1 CS222: Principles of Database Management Fall 2010 Professor Chen Li Department of Computer Science University of California, Irvine Notes 01.
Operating Systems Input/Output Devices (Ch 5: )
Secondary Storage Management Hank Levy. 8/7/20152 Secondary Storage • Secondary Storage is usually: –anything outside of “primary memory” –storage that.
Introduction to Database Systems 1 The Storage Hierarchy and Magnetic Disks Storage Technology: Topic 1.
Silberschatz, Galvin and Gagne ©2009 Operating System Concepts – 8 th Edition, Chapter 12: Mass-Storage Systems.
Silberschatz, Galvin and Gagne ©2009 Operating System Concepts – 8 th Edition, Chapter 12: Mass-Storage Systems.
Mass Storage System EMELIZA R. YABUT MSIT. Overview of Mass Storage Structure Traditional magnetic disks structure ◦Platter- composed of one or more.
By: Akram Ali. What Are Hard Drive Disks?  Hard Drives are the main storage device for all the data on your computer  It is where you store all your.
Copyright © 2007 Heathkit Company, Inc. All Rights Reserved PC Fundamentals Presentation 20 – The Hard Drive Interface.
CS4432: Database Systems II Data Storage (Better Block Organization) 1.
Device Management. So far… We have covered CPU and memory management Computing is not interesting without I/Os Device management: the OS component that.
1 I/O and Filesystems Based on slides by Matt Welsh, Harvard.
Silberschatz, Galvin and Gagne ©2013 Operating System Concepts – 9 th Edition Chapter 10: Mass-Storage Systems.
Physical Storage and File Organization COMSATS INSTITUTE OF INFORMATION TECHNOLOGY, VEHARI.
Topic: Disks – file system devices. Rotational Media Sector Track Cylinder Head Platter Arm Access time = seek time + rotational delay + transfer time.
Copyright ©: Nahrstedt, Angrave, Abdelzaher, Caccamo1 Disk & disk scheduling.
Silberschatz, Galvin and Gagne ©2009 Operating System Concepts – 8 th Edition, Chapter 12: Mass-Storage Systems.
Lecture No 11 Storage Devices
Chapter 12: Mass-Storage Systems Silberschatz, Galvin and Gagne ©2005 Operating System Concepts – 7 th Edition, Jan 1, 2005 Chapter 12: Mass-Storage.
Computer Architecture
15-410, S’ Disks Mar. 24, 2004 Dave Eckhardt & Bruce Maggs Brian Railing & Steve Muckle Contributions from Eno Thereska “How Stuff Works”
Lecture 3 Page 1 CS 111 Online Disk Drives An especially important and complex form of I/O device Still the primary method of providing stable storage.
1 CENG334 Introduction to Operating Systems Erol Sahin Dept of Computer Eng. Middle East Technical University Ankara, TURKEY URL:
Computer Architecture CST 250
CENG334 Introduction to Operating Systems Erol Sahin Dept of Computer Eng. Middle East Technical University Ankara, TURKEY URL:
Operating Systems (CS 340 D) Princess Nora University Faculty of Computer & Information Systems Computer science Department.
1 CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 13 Mass-Storage Systems Slide 1 Chapter 13 Mass-Storage Systems.
1 COMPUTER ARCHITECTURE (for Erasmus students) Assoc.Prof. Stasys Maciulevičius Computer Dept.
Device Management Mark Stanovich Operating Systems COP 4610.
Disk Average Seek Time. Multi-platter Disk platter Disk read/write arm read/write head.
Disk Scheduling The operating system is responsible for using hardware efficiently — for the disk drives, this means having a fast access time and disk.
CPSC 231 Secondary storage (D.H.)1 Learning Objectives Understanding disk organization. Sectors, clusters and extents. Fragmentation. Disk access time.
1 Reminders Project 3 due tomorrow in lecture turnin + report Today’s office hours in 006 changed to 5:30-6:30 Project 4 out soon, due last day of classes.
Device Management Andy Wang Operating Systems COP 4610 / CGS 5765.
Chapter Six Hard Drive Dr. Mohammad AlAhmad
Chapter 10: Mass-Storage Systems
Sarah Diesburg Operating Systems CS 3430
Computer Hard Drive.
Introduction to Computing
Hard Drive Technologies
Disks and Files DBMS stores information on (“hard”) disks.
Department of Health Science Education University of Florida
CSE 153 Design of Operating Systems Winter 2018
Input-output I/O is very much architecture/system dependent
CSE 451: Operating Systems Autumn 2003 Lecture 12 Secondary Storage
Persistence: hard disk drive
Mass-Storage Systems.
CSE 451: Operating Systems Secondary Storage
CSE 451: Operating Systems Winter 2003 Lecture 12 Secondary Storage
Disks and Disk Scheduling
Secondary Storage Management Hank Levy
CSE451 File System Introduction and Disk Drivers Autumn 2002
CSE 451: Operating Systems Autumn 2004 Secondary Storage
Chapter 11: Mass-Storage Systems
Lecture 10: Magnetic Disks
Operating Systems 2019 Spring by Euiseong Seo
Mass-Storage Systems (Disk Scheduling)
Andy Wang Operating Systems COP 4610 / CGS 5765
Introduction to Operating Systems
Presentation transcript:

CENG334 Introduction to Operating Systems Erol Sahin Dept of Computer Eng. Middle East Technical University Ankara, TURKEY URL: Disks Topics:

2 Today: Disks Physical operation of modern disk drives Operating system access to raw disk and disk I/O scheduling Adapted from Matt Welsh’s (Harvard University) slides.

3 A Disk Primer Disks consist of one or more platters divided into tracks Each platter may have one or two heads that perform read/write operations Each track consists of multiple sectors The set of sectors across all platters is a cylinder Aperture Platter Heads Track Sector Adapted from Matt Welsh’s (Harvard University) slides.

4 Hard Disk Evolution IBM 305 RAMAC (1956) First commercially produced hard drive 5 Mbyte capacity, 50 platters each 24” in diameter! Adapted from Matt Welsh’s (Harvard University) slides.

5 Hard Disk Evolution Adapted from Matt Welsh’s (Harvard University) slides.

6 Disk access time-1 Command overhead: Time to issue I/O, get the HDD to start responding, select appropriate head Seek time: Time to move disk arm to the appropriate track Depends on how fast you can physically move the disk arm These times are not improving rapidly Settle time: Time for head position to stabilize on the selected track Adapted from Matt Welsh’s (Harvard University) slides.

7 Disk access time-2 Rotational latency: Time for the appropriate sector to move under the disk arm Depends on the rotation speed of the disk (e.g., 7200 RPM) Transfer time Time to transfer a sector to/from the disk controller Depends on density of bits on disk and RPM of disk rotation Faster for tracks near the outer edge of the disk – why? Modern drives have more sectors on the outer tracks! Adapted from Matt Welsh’s (Harvard University) slides.

8 Example disk characteristics Seagate Barracuda GB Hard Drive Capacity (GB): 320 Interface: Serial ATA-300 Spindle Speed (RPM): 7200 Buffer Memory: 16MB Average Latency (msec): 4.16 Maximum External Transfer Rate (Mbits/sec): 300 Data Transfer Rate on Serial ATA: Up to 3000 Mb/sec Logical Cylinders/Heads/Sectors per Track: 16,383/16/63 Bytes Per Sector: 512 form factor: 3.5” Disk interface speeds SCSI: From 5 MB/sec to 320 MB/sec ATA: from 33 MB/sec to 100 MB/sec Serial ATA (single wire): Starting at 150 MB/sec Firewire: 50 MB/sec Adapted from Matt Welsh’s (Harvard University) slides.

9 Disk I/O Scheduling Given multiple outstanding I/O requests, what order to issue them? Why does it matter? Major goals of disk scheduling: Adapted from Matt Welsh’s (Harvard University) slides.

10 Disk I/O Scheduling Given multiple outstanding I/O requests, what order to issue them? Why does it matter? Major goals of disk scheduling: 1) Minimize latency for small transfers Primarily: Avoid long seeks by ordering accesses according to disk head locality 2) Maximize throughput for large transfers Large databases and scientific workloads often involve enormous files and datasets Note that disk block layout also has a large impact on performance Where we place file blocks, directories, file system metadata, etc. Adapted from Matt Welsh’s (Harvard University) slides.

11 Disk I/O Scheduling Given multiple outstanding I/O requests, what order to issue them? FIFO: Just schedule each I/O in the order it arrives What's wrong with this? Adapted from Matt Welsh’s (Harvard University) slides.

12 Disk I/O Scheduling Given multiple outstanding I/O requests, what order to issue them? FIFO: Just schedule each I/O in the order it arrives What's wrong with this? Potentially lots of seek time! SSTF: Shortest seek time first Issue I/O with the nearest cylinder to the current one Why might this not work so well??? Adapted from Matt Welsh’s (Harvard University) slides.

13 Disk I/O Scheduling Given multiple outstanding I/O requests, what order to issue them? FIFO: Just schedule each I/O in the order it arrives What's wrong with this? Potentially lots of seek time! SSTF: Shortest seek time first Issue I/O with the nearest cylinder to the current one Favors middle tracks: Head rarely moves to edges of disk SCAN (or Elevator) Algorithm: Head has a current direction and current cylinder Sort I/Os according to the track # in the current direction of the head If no more I/Os in the current direction, reverse direction CSCAN Algorithm: Always move in one direction, “wrap around” to beginning of disk when moving off the end Idea: Reduce variance in seek times, avoid discriminating against the highest and lowest tracks Adapted from Matt Welsh’s (Harvard University) slides.

14 SCAN example Current track Direction Adapted from Matt Welsh’s (Harvard University) slides.

15 SCAN example Current track Direction Adapted from Matt Welsh’s (Harvard University) slides.

16 SCAN example Direction Current track Adapted from Matt Welsh’s (Harvard University) slides.

17 SCAN example Direction Current track Adapted from Matt Welsh’s (Harvard University) slides.

18 SCAN example Direction Current track Adapted from Matt Welsh’s (Harvard University) slides.

19 SCAN example Direction Current track Adapted from Matt Welsh’s (Harvard University) slides.

20 SCAN example Direction Current track Adapted from Matt Welsh’s (Harvard University) slides.

21 SCAN example Direction Current track Adapted from Matt Welsh’s (Harvard University) slides.

22 SCAN example Direction Current track Adapted from Matt Welsh’s (Harvard University) slides.

23 SCAN example Direction Current track Adapted from Matt Welsh’s (Harvard University) slides.

24 SCAN example Direction Current track Adapted from Matt Welsh’s (Harvard University) slides.

25 SCAN example Direction Current track What is the overhead of the SCAN algorithm? Count the total amount of seek time to service all I/O requests In this case, 12 tracks in --> direction 15 tracks for long seek back 5 tracks in <-- direction Total: = 32 tracks Adapted from Matt Welsh’s (Harvard University) slides.

26 ATA and IDE Interfaces IDE stands for Integrated (or “Intelligent”) Drive Electronics Same as “ATA” (Advanced Technology Attachment) Standard interface to hard drives that integrate a drive controller in the drive itself 1 or 2 drives on a chain Enhanced IDE (EIDE) and ATA-2 Faster version of ATA/IDE that supports Direct Memory Access (DMA) transfers Ultra ATA: Speed enhancements to ATA standard Versions running at 33, 66, and 100 Mbytes/sec Serial ATA: Emerging standard using a serial (not parallel) interface Speeds starting at 150 Mbyte/sec Can drive longer cables at much higher clock speeds than parallel cable Serial ATA Rounded parallel ATA Parallel ATA

27 SCSI Interface Standard hardware interface to wide range of I/O devices Disks, CDs, DVDs, tapes, etc. Bus-based design: single shared set of I/O lines that all devices connect to Access model using logical blocks on disk On-disk controller maps logical block # to sector/track/head combination SCSI-1: 8-bit bus, 5 Mhz = 5 Mbytes/sec max speed Supported up to 8 devices on a single bus Lots of problems with termination: required physical connector on end of cable to avoid signal refraction! SCSI-2: The next generation Fast SCSI: 10 Mhz clock speed Wide SCSI: 16 bit bus width Fast wide SCSI: 10 Mhz + 16 bit bus = 20 MB/sec throughput SCSI-3: Ramping up on speed and bus width Highest speed now is “Ultra320 SCSI”: 160 Mhz x 16 bits = 320 MB/sec max speed

28 Relative Interconnect Speeds (from macspeedzone.com) USB 3.0 standard established in 2007 supports speeds upto 5GBps