Chapter 12: Mass-Storage Systems Operating System Concepts with Java – 7th Edition, Nov 15, 2006 Silberschatz, Galvin and Gagne ©2007 Chapter 12: Mass-Storage Systems Overview of Mass Storage Structure Disk Structure Disk Formatting Disk Scheduling Disk Management RAID Stable Storage Swap-Space Management Disk Attachment Tertiary Storage Devices Operating System Issues Performance Issues Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.2 Silberschatz, Galvin and Gagne ©2007 Objectives Describe the physical structure of secondary and tertiary storage devices and the resulting effects on the uses of the devices Explain the performance characteristics of massstorage devices Discuss operating-system services provided for mass storage, including RAID and HSM Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.3 Silberschatz, Galvin and Gagne ©2007 Overview of Mass Storage Structure Magnetic disks provide bulk of secondary storage of modern computers Drives rotate at 60 to 200 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 Drive attached to computer via I/O bus Busses vary, including EIDE, ATA, SATA, USB, SCSI Host controller in computer uses bus to talk to disk controller built into drive or storage array Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.4 Silberschatz, Galvin and Gagne ©2007 Overview of Mass Storage (Cont.) Magnetic tape Was early secondary-storage medium Relatively permanent and holds large quantities of data Access time slow Random access ~1000 times slower than disk Mainly used for backup, storage of infrequently-used data, transfer medium between systems Kept in spool and wound or rewound past read-write head Once data under head, transfer rates comparable to disk 20-200GB typical storage Common technologies are 4mm, 8mm, 19mm, LTO-2 and SDLT Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.5 Silberschatz, Galvin and Gagne ©2007 What Does The Disk Look Like? Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.6 Silberschatz, Galvin and Gagne ©2007 Some Parameters 2-30 heads (platters * 2) diameter 14’’ to 2.5’’ 700-20480 tracks per surface 16-1600 sectors per track Sector size: 64-8k bytes 512 for most PCs Note: inter-sector gaps Capacity: 20M-300G Main adjectives: BIG, slow Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.7 Silberschatz, Galvin and Gagne ©2007 Disk Overheads To read from disk, we must specify: cylinder #, surface #, sector #, transfer size, memory address Latency includes: Seek time: to get to the track Latency time: to get to the sector (rotation delay) Transfer time: get bits off the disk Track Sector Rotation Delay Seek Time Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.8 Silberschatz, Galvin and Gagne ©2007 Modern Disks Barracuda 180 Cheetah X15 36LP Capacity 181GB 36.7GB Disk/Heads 12/24 4/8 Cylinders 24,247 18,479 Sectors/track ~609 ~485 Speed 7200 RPM 15000 RPM Rotational latency (ms) 4.17 2.0 Avg seek (ms) 7.4 3.6 Track-2-track(ms) 0.8 0.3 Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.9 Silberschatz, Galvin and Gagne ©2007 50 Years Ago… On 13th September 1956, IBM 305 RAMAC computer system first to use disk storage 80000 times more data on the 8GB 1-inch drive in his right hand than on the 24-inch RAMAC one in his left… Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.10 Silberschatz, Galvin and Gagne ©2007 Disks vs. Memory Smallest write: sector Atomic write = sector Random access: 5ms not on a good curve Sequential access: 200MB/s Cost $.002MB Crash: doesn’t matter (“non-volatile”) Operating System Concepts with Java – 7th Edition, Nov 15, 2006 (usually) bytes byte, word 50 ns faster all the time 200-1000MB/s $.10MB contents gone (“volatile”) 12.11 Silberschatz, Galvin and Gagne ©2007 Disk Structure Disk drives addressed as 1-dim arrays of logical blocks the logical block is the smallest unit of transfer Logical block addressing This array mapped sequentially onto disk sectors Address 0 is 1st sector of 1st track of the outermost cylinder Addresses incremented within track, then within tracks of the cylinder, then across cylinders, from innermost to outermost Translation is theoretically possible, but usually difficult Some sectors might be defective Number of sectors per track is not a constant Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.12 Silberschatz, Galvin and Gagne ©2007 Non-Uniform # Sectors / Track Maintain same data rate with Constant Linear Velocity Approaches: Reduce bit density per track for outer layers Have more sectors per track on the outer layers (virtual geometry) Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.13 Silberschatz, Galvin and Gagne ©2007 How is the Disk Formatted? After manufacturing disk has no information Is stack of platters coated with magnetizable metal oxide Before use, each platter receives low-level format Format has series of concentric tracks Each track contains some sectors There is a short gap between sectors Preamble allows h/w to recognize start of sector Also contains cylinder and sector numbers Data is usually 512 bytes ECC field used to detect and recover from read errors Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.14 Silberschatz, Galvin and Gagne ©2007 Cylinder Skew Why cylinder skew? How much skew? Example, if 10000 rpm Drive rotates in 6 ms Track has 300 sectors New sector every 20 µs If track seek time 800 µs 40 sectors pass on seek Cylinder skew: 40 sectors Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.15 Silberschatz, Galvin and Gagne ©2007 Formatting and Performance If 10K rpm, 300 sectors of 512 bytes per track 153,600 bytes every 6 ms 24.4 MB/sec transfer If disk controller buffer can store only one sector For 2 consecutive reads, 2nd sector flies past during memory transfer of 1st track Idea: Use single/double interleaving Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.16 Silberschatz, Galvin and Gagne ©2007 Disk Partitioning Each partition is like a separate disk Sector 0 is Master Boot Record (MBR) Contains boot code + partition table (starting sector and size) High-level formatting Done for each partition Specifies boot block, free list, root directory, empty file system What happens on boot? BIOS loads MBR, boot program checks to see active partition Reads boot sector from that partition that then boots OS kernel, Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.17 Silberschatz, Galvin and Gagne ©2007 Handling Errors A disk track with a bad sector Solutions: Substitute a spare for the bad sector (sector sparing) Shift all sectors to bypass bad one (sector forwarding) Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.18 Silberschatz, Galvin and Gagne ©2007 Disk Scheduling The operating system tries to use hardware efficiently for disk drives having fast access time, disk bandwidth Access time has two major components Seek time is time to move the heads to the cylinder containing the desired sector Rotational latency is additional time waiting to rotate the desired sector to the disk head. Want to minimize seek time Seek time seek distance Disk bandwidth is total number of bytes transferred, divided by the total time between the first request for service and the completion of the last transfer. Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.19 Silberschatz, Galvin and Gagne ©2007 Disk Scheduling (Cont.) Several algorithms exist to schedule the servicing of disk I/O requests. We illustrate them with a request queue (0-199). 98, 183, 37, 122, 14, 124, 65, 67 Head pointer starts at 53 Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.20 Silberschatz, Galvin and Gagne ©2007 FCFS (First-Come First Serve) Illustration shows total head movement of 640 cylinders. Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.21 Silberschatz, Galvin and Gagne ©2007 SSTF (Shortest Seek Time First) Selects request with minimum seek time from current head position SSTF scheduling is a form of SJF scheduling may cause starvation of some requests. Illustration shows total head movement of 236 cylinders. Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.22 Silberschatz, Galvin and Gagne ©2007 SSTF (Cont.) Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.23 Silberschatz, Galvin and Gagne ©2007 SCAN The disk arm starts at one end of the disk, moves toward the other end, servicing requests head movement is reversed when it gets to the other end of disk servicing continues. Sometimes called the elevator algorithm. Illustration shows total head movement of 208 cylinders. Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.24 Silberschatz, Galvin and Gagne ©2007 SCAN (Cont.) Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.25 Silberschatz, Galvin and Gagne ©2007 C-SCAN Provides a more uniform wait time than SCAN. The head moves from one end of the disk to the other. servicing requests as it goes. When it reaches the other end it immediately returns to beginning of the disk No requests serviced on the return trip. Treats the cylinders as a circular list that wraps around from the last cylinder to the first one. Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.26 Silberschatz, Galvin and Gagne ©2007 C-SCAN (Cont.) Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.27 Silberschatz, Galvin and Gagne ©2007 C-LOOK Version of C-SCAN Arm only goes as far as last request in each direction, then reverses direction immediately, without first going all the way to the end of the disk. Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.28 Silberschatz, Galvin and Gagne ©2007 C-LOOK (Cont.) Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.29 Silberschatz, Galvin and Gagne ©2007 Selecting a Good Algorithm SSTF is common and has a natural appeal SCAN and C-SCAN perform better under heavy load Performance depends on number and types of requests Requests for disk service can be influenced by the fileallocation method. Disk-scheduling algo should be a separate OS module allowing it to be replaced with a different algorithm if necessary. Either SSTF or C-LOOK is a reasonable default algo Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.30 Silberschatz, Galvin and Gagne ©2007 RAID Motivation Disks are improving, but not as fast as CPUs 1970s seek time: 50-100 ms. 2000s seek time: <5 ms. Factor of 20 improvement in 3 decades Use multiple disks to improve performance By striping files across multiple disks (placing parts of each file on a different disk), parallel I/O can improve access time Problem: striping reduces reliability 100 disks have 1/100th the reliability of one disk MTBF: mean time between failures So, we need striping for performance, but we need something to help with reliability / availability To improve reliability, we can add redundant data to the disks, in addition to striping Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.31 Silberschatz, Galvin and Gagne ©2007 RAID RAID: Redundant Array of Inexpensive Disks In industry, “I” is for “Independent” Alternative: SLED, single large expensive disk Disks are small and cheap, so it’s easy to put lots of disks (10s to 100s) in one box for increased storage, performance, and availability The RAID box with a RAID controller looks just like a SLED to the computer Data plus some redundant information is striped across the disks in some way How that striping is done is key to performance and reliability. Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.32 Silberschatz, Galvin and Gagne ©2007 RAID Level 0 Level 0 is nonredundant disk array Files are striped across disks, no redundant info Stripe is 1-N sectors, sometimes also called a block High read throughput Best write throughput (no redundant info to write) Any disk failure results in data loss Reliability worse than SLED Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.33 Silberschatz, Galvin and Gagne ©2007 RAID Level 1 Mirrored Disks Data is written to two places On failure, just use surviving disk On read, choose fastest disk to read Write performance is same as single drive, read performance is 2x better Expensive Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.34 Silberschatz, Galvin and Gagne ©2007 Parity and Hamming Code What do you need to do in order to detect and correct a one-bit error ? Suppose you have a binary number, represented as a collection of bits: <b3, b2, b1, b0>, e.g. 0110 Detection is easy Parity: Count the number of bits that are on, see if it’s odd or even EVEN parity is 0 if the number of 1 bits is even Parity(<b3, b2, b1, b0 >) = P0 = b0 b1 b2 b3 Parity(<b3, b2, b1, b0, p0>) = 0 if all bits are intact Parity(0110) = 0, Parity(01100) = 0 Parity(11100) = 1 => ERROR! Parity can detect a single error, but can’t tell you which of the bits got flipped Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.35 Silberschatz, Galvin and Gagne ©2007 Parity and Hamming Code Detection and correction require more work Hamming codes can detect double bit errors and detect & correct single bit errors 7/4 Hamming Code h0 = b0 b1 b3 h1 = b0 b2 b3 h2 = b1 b2 b3 H0(<1101>) = 0 H1(<1101>) = 1 H2(<1101>) = 0 Hamming(<1101>) = <b3, b2, b1, h2, b0, h1, h0> = <1100110> If a bit is flipped, e.g. <1110110> Hamming(<1111>) = <h2, h1, h0> = <111> compared to <010>, <101> are in error. Error occurred in bit 5. Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.36 Silberschatz, Galvin and Gagne ©2007 RAID Level 2 Bit-level Striping with Hamming (ECC) codes for error correction All 7 disk arms are synchronized and move in unison Complicated controller Single access at a time Tolerates only one error, but with no performance degradation Bit 0 Bit 1 Bit 2 Bit 3 Bit 4 data disks Operating System Concepts with Java – 7th Edition, Nov 15, 2006 Bit 5 Bit 6 ECC disks 12.37 Silberschatz, Galvin and Gagne ©2007 RAID Level 3 Single parity disk can be used to detect and correct errors after crash Simplified version of RAID level 2; drives again synchronized Uses a parity disk Each bit on the parity disk is a parity function of the corresponding bits on all the other disks A read accesses all the data disks A write accesses all data disks plus the parity disk On disk failure, read remaining disks plus parity disk to compute the missing data Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.38 Silberschatz, Galvin and Gagne ©2007 RAID Level 4 Combines level 0 and 3 – block-level parity with stripes Parity stripe is XOR of all other stripes A read accesses all the data disks A write accesses all data disks plus the parity disk Heavy load on the parity disk Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.39 Silberschatz, Galvin and Gagne ©2007 RAID Level 5 Block Interleaved Distributed Parity Like parity scheme, but distribute the parity info over all disks (as well as data over all disks) Better read performance, large write performance Reads can outperform SLEDs and RAID-0 Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.40 Silberschatz, Galvin and Gagne ©2007 RAID Level 6 Level 5 with an extra parity bit Can tolerate two failures What are the odds of having two concurrent failures ? May outperform Level-5 on reads, slower on writes Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.41 Silberschatz, Galvin and Gagne ©2007 Nested RAID: RAID 0 + 1 RAID 0 + 1: Set of disks are striped, stripe is mirrored to 2nd array Performance of RAID 0, reliability of RAID 1 Expensive If First RAID 0 A2 fails, fall back to 2nd RAID 0 disk Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.42 Silberschatz, Galvin and Gagne ©2007 Nested RAID: RAID 1 + 0 RAID 1 + 0: Disks are mirrored first, then striped If disk fails, mirror is still available Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.43 Silberschatz, Galvin and Gagne ©2007 Stable Storage Handling disk write errors: Write lays down bad data Crash during a write corrupts original data What we want to achieve? Stable Storage When a write is issued, the disk either correctly writes data, or it does nothing, leaving existing data intact Model: An incorrect disk write can be detected by looking at the ECC It is very rare that same sector goes bad on multiple disks CPU is fail-stop Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.44 Silberschatz, Galvin and Gagne ©2007 Stable Storage: Approach Use 2 identical disks corresponding blocks on both drives are the same 3 operations: Stable write: retry on 1st until successful, then try 2nd disk Stable read: read from 1st. If ECC error, then try 2nd Crash recovery: scan corresponding blocks on both disks If one block is bad, replace with good one If both are good, replace block in 2nd with the one in 1st Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.45 Silberschatz, Galvin and Gagne ©2007 Network-Attached Storage Network-attached storage (NAS) is storage made available over a network rather than over a local connection (such as a bus) NFS and CIFS are common protocols Implemented via remote procedure calls (RPCs) between host and storage New iSCSI protocol uses IP network to carry the SCSI protocol Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.46 Silberschatz, Galvin and Gagne ©2007 Storage Area Network Common in large storage environments (and becoming more common) Multiple hosts attached to multiple storage arrays flexible Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.47 Silberschatz, Galvin and Gagne ©2007 Swap-Space Management Swap-space — Virtual memory uses disk space as an extension of main memory. Swap-space can be carved out of the normal file system,or, more commonly, it can be in a separate disk partition. Swap-space management 4.3BSD allocates swap space when process starts; holds text segment (the program) and data segment. Kernel uses swap maps to track swap-space use. Solaris 2 allocates swap space only when a page is forced out of physical memory, not when the virtual memory page is first created. Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.48 Silberschatz, Galvin and Gagne ©2007 Swapping on Linux Linux uses 4K page slots Swap can be in dedicated swap partition or swap file on FS Numbers above indicate ref count; e.g., 3 means 3 processes sharing Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.49 Silberschatz, Galvin and Gagne ©2007 Tertiary Storage Devices Low cost is the defining characteristic of tertiary storage. Generally, tertiary storage is built using removable media Common examples of removable media are floppy disks and CD-ROMs; other types are available. Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.50 Silberschatz, Galvin and Gagne ©2007 Removable Disks Floppy disk — thin flexible disk coated with magnetic material, enclosed in a protective plastic case. Most floppies hold about 1 MB; similar technology is used for removable disks that hold more than 1 GB. Removable magnetic disks can be nearly as fast as hard disks, but they are at a greater risk of damage from exposure. Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.51 Silberschatz, Galvin and Gagne ©2007 Removable Disks (Cont.) A magneto-optic disk records data on a rigid platter coated with magnetic material. Laser heat is used to amplify a large, weak magnetic field to record a bit. Laser light is also used to read data (Kerr effect). The magneto-optic head flies much farther from the disk surface than a magnetic disk head, and the magnetic material is covered with a protective layer of plastic or glass; resistant to head crashes. Optical disks do not use magnetism; they employ special materials that are altered by laser light. Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.52 Silberschatz, Galvin and Gagne ©2007 WORM Disks The data on read-write disks can be modified over and over. WORM (“Write Once, Read Many Times”) disks can be written only once. Thin aluminum film sandwiched between two glass or plastic platters. To write a bit, the drive uses a laser light to burn a small hole through the aluminum; information can be destroyed by not altered. Very durable and reliable. Read Only disks, such ad CD-ROM and DVD, come from the factory with the data pre-recorded. Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.53 Silberschatz, Galvin and Gagne ©2007 Tapes Compared to a disk, a tape is less expensive and holds more data, but random access is much slower. Tape is an economical medium for purposes that do not require fast random access, e.g., backup copies of disk data, holding huge volumes of data. Large tape installations typically use robotic tape changers that move tapes between tape drives and storage slots in a tape library. stacker – library that holds a few tapes silo – library that holds thousands of tapes A disk-resident file can be archived to tape for low cost storage; the computer can stage it back into disk storage for active use. Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.54 Silberschatz, Galvin and Gagne ©2007 Application Interface Most OSs handle removable disks almost exactly like fixed disks — a new cartridge is formatted and an empty file system is generated on the disk. Tapes are presented as a raw storage medium, i.e., and application does not not open a file on the tape, it opens the whole tape drive as a raw device. Usually the tape drive is reserved for the exclusive use of that application. Since the OS does not provide file system services, the application must decide how to use the array of blocks. Since every application makes up its own rules for how to organize a tape, a tape full of data can generally only be used by the program that created it. Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.55 Silberschatz, Galvin and Gagne ©2007 Tape Drives The basic operations for a tape drive differ from those of a disk drive. locate positions the tape to a specific logical block, not an entire track (corresponds to seek). The read position operation returns the logical block number where the tape head is. The space operation enables relative motion. Tape drives are “append-only” devices; updating a block in the middle of the tape also effectively erases everything beyond that block. An EOT mark is placed after a block that is written. Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.56 Silberschatz, Galvin and Gagne ©2007 Naming on Removable Media The issue of naming files on removable media is especially difficult when we want to write data on a removable cartridge on one computer, and then use the cartridge in another computer. Contemporary OSs generally leave the name space problem unsolved for removable media, and depend on applications and users to figure out how to access and interpret the data. Some kinds of removable media (e.g., CDs) are so well standardized that all computers use them the same way. Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.57 Silberschatz, Galvin and Gagne ©2007 Hierarchical Storage Management A hierarchical storage system extends the storage hierarchy beyond primary memory and secondary storage to incorporate tertiary storage — usually implemented as a jukebox of tapes or removable disks. Usually incorporate tertiary storage by extending the file system. Small and frequently used files remain on disk. Large, old, inactive files are archived to the jukebox. HSM is usually found in supercomputing centers and other large installations that have enormous volumes of data. Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.58 Silberschatz, Galvin and Gagne ©2007 Speed in Tertiary Storage Two aspects of speed in tertiary storage are bandwidth and latency. Bandwidth is measured in bytes per second. Sustained bandwidth – average data rate during a large transfer; # of bytes/transfer time. Data rate when the data stream is actually flowing. Effective bandwidth – average over the entire I/O time, including seek or locate, and cartridge switching. Drive’s overall data rate. Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.59 Silberschatz, Galvin and Gagne ©2007 Speed in Tertiary Storage (Cont.) Access latency – amount of time needed to locate data. Access time for a disk – move the arm to the selected cylinder and wait for the rotational latency; < 35 milliseconds. Access on tape requires winding the tape reels until the selected block reaches the tape head; tens or hundreds of seconds. Generally say that random access within a tape cartridge is about a thousand times slower than random access on disk. The low cost of tertiary storage is a result of having many cheap cartridges share a few expensive drives. A removable library is best devoted to the storage of infrequently used data, because the library can only satisfy a relatively small number of I/O requests per hour. Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.60 Silberschatz, Galvin and Gagne ©2007 Reliability A fixed disk drive is likely to be more reliable than a removable disk or tape drive. An optical cartridge is likely to be more reliable than a magnetic disk or tape. A head crash in a fixed hard disk generally destroys the data, whereas the failure of a tape drive or optical disk drive often leaves the data cartridge unharmed. Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.61 Silberschatz, Galvin and Gagne ©2007 Disk Attachment Host-attached storage accessed through I/O ports talking to I/O busses SCSI itself is a bus, up to 16 devices on one cable, SCSI initiator requests operation and SCSI targets perform tasks Each target can have up to 8 logical units (disks attached to device controller Fiber Channel is high-speed serial architecture Can be switched fabric with 24-bit address space – the basis of storage area networks (SANs) in which many hosts attach to many storage units Can be arbitrated loop (FC-AL) of 126 devices Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.62 Silberschatz, Galvin and Gagne ©2007 Cost Main memory is much more expensive than disk storage The cost per megabyte of hard disk storage is competitive with magnetic tape if only one tape is used per drive. The cheapest tape drives and the cheapest disk drives have had about the same storage capacity over the years. Tertiary storage gives a cost savings only when the number of cartridges is considerably larger than the number of drives. Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.63 Silberschatz, Galvin and Gagne ©2007 DRAM Price per MB, 1981 to 2004 Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.64 Silberschatz, Galvin and Gagne ©2007 Hard Disk Price per MB, 1981 to 2004 Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.65 Silberschatz, Galvin and Gagne ©2007 Tape Price per MB, 1984-2004 Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.66 Silberschatz, Galvin and Gagne ©2007 End of Chapter 12 Operating System Concepts with Java – 7th Edition, Nov 15, 2006 Silberschatz, Galvin and Gagne ©2007 CD-ROMs (1) Spiral makes 22,188 revolutions around disk (approx 600/mm). Will be 5.6 km long. Rotation rate: 530 rpm to 200 rpm Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.68 Silberschatz, Galvin and Gagne ©2007 CD-ROMs (2) Logical data layout on a CD-ROM. Picture from Tanenbaum, Modern Operating Systems 3 e, (c) 2008 Prentice-Hall, Inc. All rights reserved. 0-13-6006639 Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.69 Silberschatz, Galvin and Gagne ©2007 CD-Recordables Cross section of a CD-R disk and laser. A silver CD-ROM has similar structure, except without dye layer and with pitted aluminum layer instead of gold layer. Picture from Tanenbaum, Modern Operating Systems 3 e, (c) 2008 Prentice-Hall, Inc. All rights reserved. 0-13-6006639 Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.70 Silberschatz, Galvin and Gagne ©2007 DVD (1) DVD Improvements on CDs 1. 2. 3. Smaller pits (0.4 microns versus 0.8 microns for CDs). A tighter spiral (0.74 microns between tracks versus 1.6 microns for CDs). A red laser (at 0.65 microns versus 0.78 microns for CDs). Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.71 Silberschatz, Galvin and Gagne ©2007 DVD (2) DVD Formats 1. 2. 3. 4. Single-sided, single-layer (4.7 GB). Single-sided, dual-layer (8.5 GB). Double-sided, single-layer (9.4 GB). Double-sided, dual-layer (17 GB). Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.72 Silberschatz, Galvin and Gagne ©2007 DVD (3) A double-sided, dual-layer DVD disk. Picture from Tanenbaum, Modern Operating Systems 3 e, (c) 2008 Prentice-Hall, Inc. All rights reserved. 0-13-6006639 Operating System Concepts with Java – 7th Edition, Nov 15, 2006 12.73 Silberschatz, Galvin and Gagne ©2007