Top Banner
ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10
46

ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

Mar 29, 2015

Download

Documents

Kayleigh Badham
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

9. Computer Peripherals – Part I

Chapt. 10

Page 2: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Plan

• Storage (hierarchy and terminology)

• Magnetic disks

Page 3: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Storage

• Terminology• Medium

• The technology or product type that holds the data

• Access time• The time to get to the data

• Specified as an average in seconds (e.g., s, ms, µs, ns, etc.)

• Throughput• The rate of transfer for consecutive bytes of data

• Specified in bytes/s (e.g., Kbytes/s, Mbytes/s)

Page 4: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Offlinestorage

Secondarystorage

Primarystorage

Storage Hierarchy

MediumCPU registersCache memoryConventional memoryExpanded memoryHard diskFloppy diskCD-ROMTape

Access Time-15-30 ns50-100 ns75-500 ns10-50 ms95 ms100-600 ms0.5+ s

Throughput----600-6000 Kbytes/s100-200 Kbytes/s150-1000 Kbytes/s5-20 Kbytes/s (cartridge)200-3000 Kbytes/s (reel-to-reel)

Page 5: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Terminology

• Online storage• Memory that is accessible to programs without human

intervention• Primary storage and secondary storage are “online”

• Primary storage• Semiconductor technology (e.g., RAM)• Volatile (contents are loss when powered off)

• Secondary storage• Magnetic technology (e.g., disk drives)• Non-volatile (contents are retained in the absence of power)

Page 6: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Terminology

• Offline storage• Memory that requires human intervention in order for it to be

accessed by a program (e.g., loading a tape)• Sometimes called “archival storage”

• Direct Access Storage Device (DASD)• Pronounced “dazz-dee”• Term coinded by IBM• Distinguishes disks (disk head moves “directly” to the data) from

tapes (see below)

• Sequential access storage devices• Tape drives• Tape reel must wind forward or backward to the data

Page 7: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Plan

• Storage (hierarchy and terminology)

• Magnetic disks

Page 8: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Magnetic Disks

• A magnetic substance is coated on a round surface• The magnetic substance can be polarized in one of

two directions with an electromagnet (“writing data”)

• The electromagnet can also sense the direction of magnetic polarization (“reading data”)

• Similar to a read/write head on a tape recorder (except the information is digital rather than analogue)

Page 9: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Floppy Disks

• Also called “flexible disks” or “diskettes”• The platter is “floppy”, or flexible (e.g.,

mylar)• Most floppy disk drives can hold one

diskette (two surfaces)• The diskette is removable• Typical rpm: 300, 360• Capacities: 700 KB to 1.4 MB (& up to 100

MB “zip” disks)

Page 10: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Floppy Disk Example

Writeprotect tab

Spindle

ShutterAccess window

Cutawayshowing disk

Case

Page 11: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Hard Disks

• The platter is “hard” (e.g., aluminum)• Most hard disk drives contain more than one

platter• On most hard disk drives, the disks are “fixed”

(i.e., not removable)• On some hard disk drives, the disks are in a

removable pack (hence, “disk pack”)• Typical speed of rotation: 3600, 5400, 7200 rpm

(rpm = “revolutions per minute”)• Capacities: 500 MB to 1+ TB (terabyte = 240

bytes)

Page 12: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Hard Disk Example

Page 13: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Winchester Disks

• Invented by IBM• A type of hard disk drive• The disk is contained within a sealed unit• No dust particles• When powered off, the head is “parked” at the outer edge of

the platter and rests on the platter surface• When powered on, the aerodynamics of the head and enclosure

create a cushion of air between the head and the disk surface• The head floats above the surface (very close!) and does not

touch the surface• Thus, “head crash” (the head touches the surface, with damage

resulting)

Page 14: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Hard Disk Layout

Platter

Track

Cylinder

Drivemotor

Headmotor

Head, onmoving arm

Block

Sector

Track

Head

Head assembly

Page 15: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Terminology

• Platter• A round surface – the disk – containing a magnetic coating

• Track• A circle on the disk surface on which data are contained

• Head• A transducer attached to an arm for writing/reading data to/from the

disk surface

• Head assembly• A mechanical unit holding the heads and arms• All the head/arm units move together, via the head assembly

• Cylinder• A set of tracks simultaneously accessible from the heads on the head

assembly

Page 16: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Terminology

• Drive motor• The motor that rotates the platters• Typically a DC motor (DC = direct current)• The disk rotates at a fixed speed (e.g., 3600 rpm,

revolutions per minute)

• Head motion• A mechanism is required to move the head assembly in/out• Two possibilities:

• A stepper motor (digital, head moves in steps, no feedback)• A servo motor (analogue, very precision positioning, but requires

feedback)

Page 17: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Terminology

• Sector• That portion of a track falling along a predefined pie-shaped

portion of the disk surface• The number of bytes stored in a sector is the same, regardless

of where the sector is located; thus, the density of bits is greater for sectors near the centre of the disk

• The rotational speed is constant; i.e., constant angular velocity• Thus, the transfer rate is the same for inner sectors and outer

sectors

• Block• The smallest unit of data that can be written or read to/from

the disk (typically 512 bytes)

Page 18: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Locating a Block of Data

Seek Time Latency Time Transfer Rate

Desiredtrack

Seek

Head

TransferLatency

Note: Access time = seek time + latency

Page 19: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Terminology

• Seek time• The time for the head to move to the correct track• Specified as an average for all tracks on the disk surface

• Latency time• The time for the correct block to arrive at the head once the head

is positioned at the correct track• Specified as an average, in other words, ½ the period of rotation• Also called “rotational delay”

• Access time is the time “to get to” the data (remember!)• Access time = seek time + latency

• Transfer rate• Same as throughput

Page 20: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Latency Example

• A hard disk rotates at 3600 rpm

• What is the average latency?

Period of rotation = (1 / 3600) minutes= (1 / 3600) 60 seconds= 0.01667 s= 16.67 ms

Average latency = 16.67 / 2 ms= 8.33 ms

Page 21: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Factors Determining Transfer Rate

• Transfer rate can be determined, given…• Rotational speed of the disk platters • Number of sectors per track• Number of bytes per sector

Page 22: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Transfer Rate Example

• Q: Determine the transfer rate, in Mbytes/s, for a hard disk drive, given• Rotational speed = 7200 rpm• Sectors per track = 30• Data per sector = 512 bytes = 0.5 Kbytes

• A: Transfer rate = 7200 x 30 = 216,000 sectors/min

= 216,000 x 0.5 = 108,000 Kbytes/min= 108,000 / 60 = 1,800 Kbytes/s= 1,800 / 210 = 1.76 Mbytes/s

Page 23: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Exercise - Transfer Rate

• Q: Determine the transfer rate, in Mbytes/s, for a hard disk drive, given

• Rotational speed = 7000 rpm• Sectors per track = 32• Data per sector = 1024 bytes

Skip answer Answer

Page 24: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Exercise - Transfer Rate

• Q: Determine the transfer rate, in Mbytes/s, for a hard disk drive, given

• Rotational speed = 7000 rpm• Sectors per track = 32• Data per sector = 1024 bytes

A: Transfer rate = 7000 x 32 = 224,000 sectors/min

= 224,000 x 1 = 224,000 Kbytes/min= 224,000 / 60 = 3,733 Kbytes/s= 3,733 / 210

= 3.65 Mbytes/s

Answer

Page 25: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Typical Spec’s

Specification 3 ½” Floppy 2 GB Hard Disk

Platters/heads 1 / 2 5 / 9

Cylinders 80 4160

Sectors/track 18 Varies

Block size 512 512

Capacity 1.44 MB 2.1 GB

Rotation speed 360 rpm 7200 rpm

Avg. seek time 95 ms 8.5 ms

Latency 83 ms 4.2 ms

Transfer rate 54 Kbyte/s 10 Mbyte/s

Page 26: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Track Format

• Format of each track:

dataheadergap gapCRC

SectorPrevious sector Next sector

Inter-blockgap

Inter-blockgap

Note:

CRC stands for “cyclic redundancy code”. It’s the “footer” at the end of each sector. CRC is a sophisticated form of parity for checking that the data read are accurate.

Page 27: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Disk Formatting

• The track positions, blocks, headers, and gaps must be established before a disk can be used

• The process for doing this is called “formatting”

• The header, at the beginning of each sector, uniquely identifies the sector, e.g., by track number and sector number

Page 28: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Disk Controller

• Interface between the disk drive and the system is known as a “disk controller”

• A primary function is to ensure data read/write operations are from/to the correct sector

• Since data rate to/from the disk is different than data rate to/from system memory, “buffering” is needed

Page 29: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Buffering

System Diskcontroller

DiskRAM Buffer

(RAM)

1. Read data from disk into a buffer in the disk controller

2. Transfer data from buffer to system RAM (Note: this is a DMA operation)

Example: Reading data from a disk

Page 30: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Multi-block Transfers (1 of 2)

• The smallest transfer is one block (e.g., 512 bytes)• However, often multi-block transfers are required• The inter-block gap provides “time” for the controller

electronics to adjust from the end of one sector to the beginning of the next

• “time” may be needed for a few reasons:• Compute and/or verify the CRC bytes• Switch circuits from read mode to write mode

• During a write operation the header is “read” but the data are “written”• (Remember, the header is only “written” during formatting.)

• Perform a DMA operation

Page 31: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Multi-block Transfers (2 of 2)

• Sometimes, sectors simply cannot be read or written consecutively

• There is not enough time (see preceding slide)

• The result is lost performance because the disk must undergo a full revolution to read the next sector

• The solution: interleaving

Page 32: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Interleaving

• Rather than numbering blocks consecutively, the system skips one or more blocks in its numbering

• This allows multi-block transfers to occur as fast as possible

• Interleaving minimizes lost time due to latency• Interleaving “factor” (see next slide) is established

when the disk is formatted• Can have a major impact on system performance

Page 33: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Interleaving Examples

21 3 54 6 87 9

1 2 3 4 5

1 2 3

1:1 etc.

etc.

etc.

2:1

3:1

Factor

Page 34: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

2:1 Interleaving

1

2 6

7

3

84

9

5

Page 35: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

File System Considerations

• There is no direct relationship between the size and physical layout of blocks on a disk drive and the size and organization of files on a system

• File system• Determines the organization of information on a computer• Performs logical-to-physical mapping of information• A file system is part of each and every operating system

• Logical mapping• The way information is perceived to be stored

• Physical mapping• The way information is actually stored

Page 36: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Disks Capacity in Windows

• To determine the capacity of the C: hard disk on Windows• From the Desktop, double click on My

Computer• Right click on C: and select Properties

Next slide

Page 37: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Note:Varies on different systems Demo

Page 38: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Alternative Technologies (1 of 3)

• Removable hard disks• Also called “disk packs”• A stack of hard disks enclosed in a metal or plastic removable cartridge• Advantages

• High capacity and fast, like hard disk drives• Portable, like floppy disks

• Disadvantage• Expensive

Page 39: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Alternative Technologies (2 of 3)

• Fixed heads• Fewer tracks but eliminates seek time

Disk Spindle Moving head

Fixed heads

Page 40: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Alternative Technologies (3 of 3)

• R.A.I.D. = Redundant array of inexpensive disks• A category of disk drive that employs two or

more drives in combination for fault tolerance and performance

• Frequently used on servers, but not generally used on PCs

• There are a number of different R.A.I.D. “levels” (next slide)

Page 41: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

R.A.I.D. Levels (1 of 2)

• Level 0• Provides “data striping” (spreading out blocks of each file

across multiple disks)• No redundancy• Improves performance, but does not deliver “fault tolerance”

• Level 1• Provides “data mirroring”• Data are written to two duplicate disks simultaneously• If one drive fails, the system can switch to the other without

loss of data or service• Delivers fault tolerance

Page 42: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

R.A.I.D. Levels (2 of 2)

• Level 3• Same as level 0, but also reserves one dedicated

disk for error correction data• Good performance, and some level of fault

tolerance

• Level 5• Data striping at the byte level and stripe error

correction information• Excellent performance, good fault tolerance

Page 43: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Terminology

• Fault tolerance• The ability of a computer system to respond gracefully

to unexpected hardware or software failure

• Many levels of fault tolerance• E.g., the ability to continue operating in the event of a power

failure

• Some systems “mirror” all operations• Every operation is performed on two or more duplicate

systems, so if one fails, another can take over

Page 44: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Terminology

• Data mirroring• A technique in which data are written to two

duplicate disks simultaneously• If one disk fails, the system can instantly switch

to the other disk without loss of data or service• Used commonly in on-line database systems

where it is critical that data are accessible at all times

Page 45: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Terminology

• Data striping• A technique for spreading data over multiple

disks• Speeds operations that retrieve data from disk

storage• Data are broken into units (blocks) and these

are spread across the available disks• Implementations allow selection of data units

size, or stripe width

Page 46: ITEC 1011 Introduction to Information Technologies 9. Computer Peripherals – Part I Chapt. 10.

ITEC 1011 Introduction to Information Technologies

Thank you