Platter. Track. Index Mark. Disk Storage. PHY 406F - Microprocessor Interfacing Techniques



Similar documents
Price/performance Modern Memory Hierarchy

CPS104 Computer Organization and Programming Lecture 18: Input-Output. Robert Wagner

Record Storage and Primary File Organization

Mass Storage Structure

Solid State Drive Architecture

William Stallings Computer Organization and Architecture 7 th Edition. Chapter 6 External Memory

1 Storage Devices Summary

Chapter 9: Peripheral Devices: Magnetic Disks

Chapter 2: Computer-System Structures. Computer System Operation Storage Structure Storage Hierarchy Hardware Protection General System Architecture

CSCA0201 FUNDAMENTALS OF COMPUTING. Chapter 5 Storage Devices

CS 464/564 Introduction to Database Management System Instructor: Abdullah Mueen

Introduction to I/O and Disk Management

With respect to the way of data access we can classify memories as:

Q & A From Hitachi Data Systems WebTech Presentation:

Main Memory & Backing Store. Main memory backing storage devices

University of Dublin Trinity College. Storage Hardware.

Communicating with devices

1 File Management. 1.1 Naming. COMP 242 Class Notes Section 6: File Management

INTRODUCTION The collection of data that makes up a computerized database must be stored physically on some computer storage medium.

William Stallings Computer Organization and Architecture 8 th Edition. External Memory

Data Storage - I: Memory Hierarchies & Disks

Types Of Storage Device

File System & Device Drive. Overview of Mass Storage Structure. Moving head Disk Mechanism. HDD Pictures 11/13/2014. CS341: Operating System

HARD DRIVE CHARACTERISTICS REFRESHER

Sistemas Operativos: Input/Output Disks

Lecture 16: Storage Devices

Two main categories of storage technology used today are magnetic storage and optical storage.

Introduction Disks RAID Tertiary storage. Mass Storage. CMSC 412, University of Maryland. Guest lecturer: David Hovemeyer.

Input / Ouput devices. I/O Chapter 8. Goals & Constraints. Measures of Performance. Anatomy of a Disk Drive. Introduction - 8.1

Data Storage - II: Efficient Usage & Errors

Random-Access Memory (RAM) The Memory Hierarchy. SRAM vs DRAM Summary. Conventional DRAM Organization. Page 1

& Data Processing 2. Exercise 2: File Systems. Dipl.-Ing. Bogdan Marin. Universität Duisburg-Essen

How To Store Data On A Computer (For A Computer)

COMPUTER SCIENCE AND ENGINEERING - Microprocessor Systems - Mitchell Aaron Thornton

File Systems Management and Examples

Windows Server Performance Monitoring

Storage in Database Systems. CMPSCI 445 Fall 2010

Virtuoso and Database Scalability

Lesson Plan. Preparation

COS 318: Operating Systems. Storage Devices. Kai Li Computer Science Department Princeton University. (

Writing Assignment #2 due Today (5:00pm) - Post on your CSC101 webpage - Ask if you have questions! Lab #2 Today. Quiz #1 Tomorrow (Lectures 1-7)

Chapter 3: Computer Hardware Components: CPU, Memory, and I/O

Chapter 8 Memory Units

CS 153 Design of Operating Systems Spring 2015

Primary Memory. Input Units CPU (Central Processing Unit)

Outline. CS 245: Database System Principles. Notes 02: Hardware. Hardware DBMS Data Storage

Data recovery from a drive with physical defects within the firmware Service Area, unrecoverable using

Understanding Flash SSD Performance

CSCA0102 IT & Business Applications. Foundation in Business Information Technology School of Engineering & Computing Sciences FTMS College Global

Outline. Principles of Database Management Systems. Memory Hierarchy: Capacities and access times. CPU vs. Disk Speed

Linux Driver Devices. Why, When, Which, How?

COMPUTER HARDWARE. Input- Output and Communication Memory Systems

Enterprise-class versus Desktopclass

Taking Linux File and Storage Systems into the Future. Ric Wheeler Director Kernel File and Storage Team Red Hat, Incorporated

Review. Lecture 21: Reliable, High Performance Storage. Overview. Basic Disk & File System properties CSC 468 / CSC /23/2006

Chapter 10: Mass-Storage Systems

Devices and Device Controllers

Benchmarking Hadoop & HBase on Violin

File System Management

Secondary Storage. Any modern computer system will incorporate (at least) two levels of storage: magnetic disk/optical devices/tape systems

Computer Performance. Topic 3. Contents. Prerequisite knowledge Before studying this topic you should be able to:

Here are my slides from lecture, along with my notes about each slide.

Chapter 1 Computer System Overview

NCTE Advice Sheet Storage and Backup Advice Sheet 7

Tech Application Chapter 3 STUDY GUIDE

Enterprise-class versus Desktop-class Hard Drives

Intel RAID Controllers

Storage Technologies for Video Surveillance

System Architecture. CS143: Disks and Files. Magnetic disk vs SSD. Structure of a Platter CPU. Disk Controller...

Operating System Concepts. Operating System 資 訊 工 程 學 系 袁 賢 銘 老 師

Storing Data: Disks and Files

Chapter 11 I/O Management and Disk Scheduling

Introduction. What is RAID? The Array and RAID Controller Concept. Click here to print this article. Re-Printed From SLCentral

WHITE PAPER FUJITSU PRIMERGY SERVER BASICS OF DISK I/O PERFORMANCE

Project Group High- performance Flexible File System 2010 / 2011

Distribution One Server Requirements

I/O Management. General Computer Architecture. Goals for I/O. Levels of I/O. Naming. I/O Management. COMP755 Advanced Operating Systems 1

Difference between Enterprise SATA HDDs and Desktop HDDs. Difference between Enterprise Class HDD & Desktop HDD

Practical issues in DIY RAID Recovery

Disk Geometry: How Data is Organized on a Hard Disk Drive

Chapter 12: Mass-Storage Systems

The Quest for Speed - Memory. Cache Memory. A Solution: Memory Hierarchy. Memory Hierarchy

5 Reasons Your Business Needs Network Monitoring

Physical Data Organization

Chapter Introduction. Storage and Other I/O Topics. p. 570( 頁 585) Fig I/O devices can be characterized by. I/O bus connections

HP Smart Array Controllers and basic RAID performance factors

Disk Storage & Dependability

Chapter 8. Secondary Storage. McGraw-Hill/Irwin. Copyright 2008 by The McGraw-Hill Companies, Inc. All rights reserved.

Storing Data: Disks and Files. Disks and Files. Why Not Store Everything in Main Memory? Chapter 7

Outline. Failure Types

Optimizing LTO Backup Performance

Five Reasons Your Business Needs Network Monitoring

Discovering Computers Chapter 7 Storage

COMPUTER BASICS. Seema Sirpal Delhi University Computer Centre

CS 6290 I/O and Storage. Milos Prvulovic

Data Storage Solutions

A Computer Glossary. For the New York Farm Viability Institute Computer Training Courses

Chapter 12: Secondary-Storage Structure

The IntelliMagic White Paper: Green Storage: Reduce Power not Performance. December 2010

Transcription:

Platter PHY 406F - icroprocessor Interfacing Techniques Disk Storage The major "permanent" storage medium for computers is, at present, generally magnetic media in the form of either magnetic tape or disks. For microcomputers, tape storage is somewhat inconvenient as it is a serial access medium with very little parallelism and therefore disk storage is to be preferred in many, but not all applications. Track Index ark Disk agnetic Structure magnetic disk consists simply of a disk coated with a similar material to that used in recording tape. s the disk spins, a head or heads moves over the surface of the disk on a radial arm in a stepwise fashion. t every step position the head scans a "track" of the disk, a track being a circle on the medium. Electrical currents in the head are used to record information on the track, or the magnetic variations induce currents in the head which are amplified to play back the recording. The tracks themselves are very narrow since the narrowness of the track determines the number of tracks which will fit on a side. The floppy disk drives, for instance, record at 135 tpi (tracks per inch) and fit 80 tracks onto a disk in less than one inch of space. Therefore disks are actually quite precise devices and should be treated as such - no dust, dirt, smoke etc. Do not drip coffee on them either. Sides, Tracks, Cylinders and Sectors Disks have two sides and one or both may be used. Larger disks have more sides by stacking "platters" (single disks) into larger assemblies. Each side requires a read/write head and therefore the James R. Drummond - September 1997 6

cost goes up, but the degree of parallelism also goes up giving faster access to a random piece of data, or the same access time to a larger amount of data. On multi-platter disks the "tracks" accessible at a given head position are often referred to collectively as "cylinders". Platter Track Cylinder ulti-platter Disk Structure track needs a "start" and "end" point and this is supplied by a mechanical marker which in the case of a floppy disk is an index hole on the inside edge which indicates the start of the track to the recording system. track is too large a segment of information to split the disk into. Even allowing for two sides of these small floppy disks, there are only 160 tracks on a disk and if the recording unit is a track that means that only 160 separate units of information may be stored. Furthermore if you only want to store a small amount of information you still need to take a whole track. So tracks are divided into "sectors" of information. The sectors are either delineated by more hardware markers (hard sectoring) or by software markers actually recorded on the disk (soft sectoring). The floppy disks use soft-sectoring. James R. Drummond - September 1997 7

soft-sectored disk has a track structure of alternating sector markers and data areas. Each sector marker contains the number of the next sector and each data area is a sector of information. To read the disk we check the sector markers - called address marks - until we find the right one and then read the next data area after it. To write, we read the markers again and then record in the next data area. Of course we must be sure that recording is finished before the next sector marker or that will be corrupted, so there are buffer zones between the sectors sufficiently long to ensure that under all normal conditions data areas do not overlap address marks. We can therefore indicate the track structure linearly as: Time/Direction of rotation D T E C D T Sector Sector Sector E C Reference ark = ddress ark EC = Error Correction (CRC) = Buffer Zone Track Structure In Linear Format The structure of ddress arks containing the sector numbers is laid down when a disk is "formatted", but for normal read/write operations only the data areas are changed. ccess Times The time it takes to access the data depends upon how close we are to the data when the request is made and is composed of two elements: a) The time taken to get the head to the right track b) The time taken for the data to get under the head. The worst case for a) is (number of tracks)*(time to step 1 track) and for b) time for 1 disk revolution. For small floppy disks the step time is about 5mS and the rotation rate 300 rpm - giving a worst-case access time of 80*5/1000 + 1/5 secs = 0.6 secs. Contrast this with the corresponding James R. Drummond - September 1997 8

number for a 5Gbyte hard disk - 21mS (full stroke) and a rotation rate of 5400 rpm (specs for a axtor 851208 disk) - and we get 32mS over a much larger dataset. The average access time - which everybody likes to quote - is obviously less than the worst case. Note incidentally that a large computer, such as our "server" system, gets on with something else while the disk is doing a "seek" whereas ours hangs around until it's done. Total Capacity The number of sectors on a track depends upon the size of the sectors, the frequency of recording and the method of recording since some methods are inherently more dense than others. standard 3.5" floppy disk squeezes 18 sectors of 512 bytes onto each track. There are two ways to increase this: either use more linear density of bits/m along the track or use more tracks per inch. Both refinements produce issues of alignment, for example the track density of a 3.5" floppy disk is 270 tpi - already about 0.004"/track!!! By simple calculation small floppy disks hold 80*2*18*512 bytes or 1440k of information. If you have been paying attention you will realise that because of the "gaps" and other marks which are required in the formatting process, the amount of data which you can actually store on a disk is less than the amount that you would get by multiplying the "bits/inch" figure by the total length of the tracks. This explains why an "HD" 3.5" floppy disk for example is listed as "2b" capacity on the label but only formats to 1,474,560bytes of information at best - and there is still some to be lost in the directory structure. Caching Since disks are slower than the main CPU and memory is getting cheaper all the time, many operating systems and some disk controllers cache data as it is transferred to and from the disk. When reading a disk it is often the case that we can predict the next piece of information required - it is just the next piece of information from the file. Thus we can read that information and store it locally even if the user hasn t asked for it yet. Then, when it is requested, the access time is apparently blindingly fast. The success of a caching scheme depends upon: < Being able to accurately predict what is going to be required next. < Large reads being much more efficient than short ones < Having a lot of memory < Spending less time finding out if the data is in the cache than it would take to get it from the disk. The maximum size of a cache is a matter of some experiment. t some point the cache starts to lose efficiency because it is violating one of the points above - maybe reading too far ahead and James R. Drummond - September 1997 9

reading a lot of useless data - and the apparent speed drops. Systems are often tuned by actually looking at the rate of processing as a function of the cache size. When writing a disk, caching can also be used to improve the efficiency of the process. Writing large blocks is more efficient than writing small blocks. It might also be that the data is required to be read back again quickly. The same general arguments apply to size as were discussed above. There is a hidden problem in disk-caching - it inherently slows down the rate at which you can read or write to the disk! This can be seen in its simplest form in the following situation. If you want to read the entire disk in one go from end to end. Is it easier just to read the next piece of data, or spend time trying to figure out whether it is in the cache? It must be faster just to read the data because we all know it won t be in the cache. The correct strategy would be to read the disk in as large a unit as possible - preferably a cylinder at a time - in sequence to minimise head movement time. You will find that some video systems actually require you to turn off any caching systems in your operating system for this very reason. There is one additional point about write caching - if the computer crashes while there is data pending in the write cache, the state of the disk is uncertain. What this means is that there is a finite chance that the computer will be unable to make sense of the disk structure when it comes back up and at a minimum recent data will be lost. t worst, the entire disk could be unreadable! To prevent this, disk write caches should be flushed (ie emptied) before turning the computer off. This implies that all computers with caches need to be shut down rather than simply turned off. This is the case with your machines - please observe the rule to shut down rather than turn off. s an additional measure, disk caches often flush if there has been no system activity for a few seconds - this helps to keep the real disk and the apparent disk synchronised in the case of a power outage or other problem. Why go On about It? For our purposes the main problem with disks is knowing reliably how fast you can read or write to them. This limits the rate at which we can take data through the system without a compression step first. With modern processors the limiting feature is often the disk storage rate which can be as high as 6bytes/sec and as low as 10kbytes/sec and anything in between. Limitations may come from any part of the disk and operating system as we shall see. James R. Drummond - September 1997 10