A Comprehensive Guide to Disks
A brief history
All computer disks store data in a series of 0s and 1s. The first computers didn't have any internal storage. Originally, programs had to be "written" into a computer by flipping switches on a control panel to represent 0 or 1, requiring a program to be written in binary, and entered one bit at a time. Punch cards allowed programs to be stored on pieces of paper, and rolls of tape allowed programs to be stored on reels, and eventually cassette tapes. Eventually someone had the idea to create a flat circle of metal covered with the same magnetic materials as video and audio tape, which the computer could read from and write to with a moveable read/write head, and the hard disk was born. Originally, hard drives were huge and were only used with the massive computers that came before microcomputers. When computers were miniaturized to the point that they could fit on a desk in the 1970s, they used much smaller drives with a removable, flexible, plastic disk and the floppy disk was born. The device that reads and writes to floppy disks is called a floppy drive.
Later on, hard drives were minitiarized enough to match the form factors of floppy drives. The sturdier nature of the glass or metal disks allowed manufacturers to shrink the area of each bit to increase capacity and, instead of being removable, these disks were sealed inside a metal case with the read/write head to protect them from humans and the environment, making the hard disk inseparable from the hard drive. In fact, multiple disks (known as platters) can be placed on top of each other within the drive. A hard drive usually contains a maximum of seven hard disks.
Half way between magnetic and optical disks are floptical disks. These were floppy drives that used a laser to track the position of the magnetic read/write head with high precision, which allowed much smaller tracks and sectors to be used. The most successful example was the LS-120 drive, which could read and write to 120 MB 3.5" floppy disks in addition to normal 1.44 MB disks. That capacity was later doubled on the LS-240 drive.
Instead of storing data magnetically, another option is to store data optically, using a laser to read tiny pits on a reflective surface to represent 0s and 1s. Originally Compact Discs (CDs) were read-only, and were manufactured by pressing indentations into a reflective metallic disc that was encased in plastic. If the laser hits an indentation, the light bounces around and not very much light returns, whereas the absence of an indentation causes the light to hit a flat surface, and most of the light bounces back. The strength of the light that bounces back tells the optical drive whether it found a 0 or a 1 at each location on the disc. Later, writeable discs were manufactured with a layer of reflective ink on the recording layer that normally bounces light back, but it can be burnt with a laser to prevent light from bouncing back. Since there is no way to un-burn the ink, these discs are writeable, but not rewriteable, and are known as CD-Rs. The DVD equivalents are DVD-R and DVD+R, and for Blu-Ray discs are BD-Rs. Later still, discs were created that contain a layer of metallic crystals that reflect light, but can be melted by a laser to stop reflecting light. However, the melted crystals can be made to recrystallize by exposing them to weaker laser for a longer period of time, allowing the disc to be rewritten. These are CD-RWs, their DVD equivalents are DVD-RW, DVD+RW and DVD-RAM, and their Blu-Ray equivalents are BD-REs.
Finally, the latest storage medium is called flash memory. Instead of winding a tape or spinning a disk, flash drives store data the same way that RAM and ROM chips do: in a grid of transistors with wires running to each one. RAM chips use tiny transistors to store (0) or not store (1) a charge, and they must be continually powered in order to hold that charge. Flash ROMs use a special material to hold a charge inside of the cell, which can continue to store data for years without a power source. That layer is damaged a bit each time the cell is emptied of charge to allow it to be rewritten, so Flash ROMs can only be written to a few hundred to a few thousand times per cell, but a good Solid State Drive (SSD) should have enough write cycles to last a typical user anywhere from decades to centuries.
Floppy disks
A floppy disk is a flat circle of plastic, coated with magnetic materials. A variety of physical dimensions have existed over the years, but only three have ever been popular: 8", 5.25", and 3.5".
Before formatting, a soft-sector disk technically has no inherent capacity (hard-sector disks have holes punched in them to mark the location of sectors). The floppy drive can divide the disk into as many tracks (cylinders) per side and sectors per cylinder as it wants, limited only by the quality of the disk and the precision of the mechanism that moves the read/write head. Allowing the user to set whatever capacity they wanted would pose a problem, because it would complicate compatibility. To ensure compatibility, IBM defined specific geometries that its drives could support. This allowed the drives to be installed in any computer with any operating system and have the disks be compatible, and it allowed competitors to make compatible drives.
Drive geometry
The circular disk is divided into tracks, and each track is divided into sectors (the smallest portion of the disk that will ever be written to or read from). All 5.25" and 3.5" floppy disks and hard disks use 512 byte sectors.
Almost every floppy disk format has used the same number of sectors on every track, meaning that the sectors on the outer tracks are much larger than the sectors on the inner tracks. The point of this was simplicity over capacity: floppy drives spin the disk at the same speed (in terms of RPM) at all times, so the drive reads or writes for the same amount of time regardless of what track it is on. For instance, on a hypothetical floppy drive that writes 60 sectors per track and spins at 1 RPM (one revolution per minute), each sector will spend exactly 1 second under the read/write head, regardless of its physical size. The data rate will also be constant (even though the outer tracks are spinning faster than the inner tracks), an important consideration in an age before buffering technology. In short, having the same number of sectors on every track simplified the design of floppy drives by making timing and data rate consistent across the disk. Some companies (notably Apple) increased the number of sectors on the larger tracks to boost capacity, which requires either a variable spin rate to maintain a consistent data rate, or a variable data rate if there's a constant spin rate.
While dozens of form factors and hundreds of disk geometries have been used by computers over the years, the tables below list all floppy disk formats that have been supported by the DOS and Windows operating systems. "Year" represents the year when a drive capable of supporting disks with this number of tracks and heads started to be manufactured, and not necessarily when this specific geometry started to be used.
8" Disk Formats | 5.25" Disk Formats | 3.5" Disk Formats | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
Category | Type | SSDD | DSDD | DSHD | SSDD | DSDD | SSDD | DSDD | DSHD | DSDD | DSHD | DSED |
Media | Coating | Fe | Fe | Fe | Fe | Fe | Fe | Fe | Co | Fe | Co | BaFe |
Coercivity (Oe) | 300 | 300 | 300 | 300 | 300 | 300 | 300 | 600 | 600 | 750 | 900 | |
TPI | 48 | 48 | 48 | 48 | 48 | 48 | 48 | 96 | 135 | 135 | 135 | |
Drive | Year | 1973 | 1976 | 1977 | 1978 | 1978 | 1978 | 1978 | 1982 | 1982 | 1986 | 1987 |
Heads | 1 | 2 | 2 | 1 | 2 | 1 | 2 | 2 | 2 | 2 | 2 | |
RPM | 360 | 360 | 360 | 300 | 300 | 300 | 300 | 360 | 300 | 300 | 300 | |
Controller | Bitrate (kbps) | 250 | 250 | 500 | 250 | 250 | 250 | 250 | 500 | 250 | 500 | 1000 |
Unformatted capacity | Track (b) | 41,666 | 41,666 | 83,333 | 50,000 | 50,000 | 50,000 | 50,000 | 83,333 | 50,000 | 100,000 | 200,000 |
Disk (B) | 401,042 | 802,083 | 1,604,167 | 250,000 | 500,000 | 250,000 | 500,000 | 1,666,667 | 1,000,000 | 2,000,000 | 4,000,000 | |
Geometry | Cylinders | 77 | 77 | 77 | 40 | 40 | 40 | 40 | 80 | 80 | 80 | 80 |
SPC | 26 | 26 | 8 | 8 | 8 | 9 | 9 | 15 | 9 | 18 | 36 | |
BPS | 128 | 128 | 1024 | 512 | 512 | 512 | 512 | 512 | 512 | 512 | 512 | |
Sectors | 2002 | 4004 | 1232 | 320 | 640 | 360 | 720 | 2400 | 1440 | 2880 | 5760 | |
Formatted capacity | 250.25 KB | 500.5 KB | 1232 KB | 160 KB | 320 KB | 180 KB | 360 KB | 1200 KB | 720 KB | 1440 KB | 2880 KB | |
Operating system | Media descriptor | FE | FD | FD | FE | FF | FC | FD | F9 | F9 | F9 | F0 |
DOS version | 1.00 | 2.00 | 2.00 | 1.00 | 1.10 | 2.00 | 2.00 | 3.00 | 3.20 | 3.30 | 5.00 |
Floppy disks on the PC
IBM introduced the first read-only floppy disk drive, the IBM 23FD, in 1971. It used 8" floppy disks that were formatted to a bizarre capacity of 81664 bytes. Read-write 8" floppy drives soon followed, and 8" disks were popular throughout the 1970s.
The first 5.25" floppy disks were introduced in 1976 and were adopted by the Apple II in 1978, and they quickly replaced 8" disks as the standard disk format. Seattle Computer Products created QDOS (later renamed 86-DOS) for customers who built their own 8086 computers from kits sold by SCP and others, and it supported only 8" floppy disks. Microsoft purchased the rights to 86-DOS and worked with IBM to make it suitable for their IBM PC, including adding support for 5.25" disks. The original PC (Model 5150) was released in 1981 with internal 5.25" floppy drives as a standard option, though it also had a DIN connector for cassette tape recorders for TRS-80 computers. IBM never included an 8" floppy drive option for any of their home PCs (such drives would have had to be external, as PC drive bays were only 5.25"), but DOS 1.0 supported SSDD 5.25" disks formatted to 160 KB (8 sectors) and 8" floppy disks formatted to 250 KB for the benefit of OEMs who sold computers with 8" floppy drives. Microsoft's contract with IBM allowed them to sell DOS to third-parties (under the name MS-DOS) while IBM sold it to PC customers under the name PC DOS. DOS 1.1 added support for double-sided 5.25" disks formatted to 320 KB (8 sectors).
DOS 2.0 was rewritten from scratch. It increased the number of sectors per track on 5.25" floppy disks from 8 to 9, increasing the formatted capacity to 180 KB single-sided and 360 KB double-sided. It also added support for double-sided 500 KB and double-sided, high-density 1.2 MB 8" floppy disks.
DOS 3.0 added support for 96 tpi 5.25" disks, and also doubled the data rate to 500 kbps. This would have allowed a doubling of sectors per track to 18 and a formatted capacity of 1.44 MB (the same as 3.5" DSHD floppy disks and a quadrupling of capacity of DSDD disks), except that IBM also increased the rotational speed to 360 rpm (as it had been on 8" floppy drives), which reduced the unformatted capacity to 1⅔️ MB. This only left room for 15 sectors, or 1.2 MB.
3.5" floppy disks started to appear in 1982 and were adopted by Apple. 3.5" disks were protected by a hard plastic casing, and the read/write hole was covered by a spring-loaded retractable metal shield, which made them less vulnerable to bending, dust, and physical contact with the recording media. Track density increased to 135 TPI, allowing the disks to hold (the same as 5.25" DSHD disks). They inititally had the same data rate (250 kbps) and sectors per track (9) as 5.25" DSDD disks, but doubled capacity to 720 KB due to having 80 tracks instead of 40. Support for this capacity was added to DOS 3.2. "High-density" (HD) disks doubled the data rate to 500 kbps and the sectors per track to 18 to allow 1.44 MB disks (supported in DOS 3.3), and support "Enhanced High-Density" (ED) drives that doubled the data rate to 1000 kbps data rate and 36 sectors per tracks were added to DOS 5.0. DSED drives were included with some IBM PS/2 models, but were probably never offered by other PC makers, so the standard never caught on.
The rate of floppy disk capacity increases didn't keep up with hard drives or the size of software. Windows 95 was initially sold on 13 floppy disks or one CD-ROM. Attempts were made to offer super-high capacity floppy disks, the most successful of which was LS-120, which used optical tracking to accurately read and write 1736 tracks! It also used zoned recording to put more sectors on the longer, outer tracks, like Macintosh GCR floppy disks. Combining optical tracking with magnetic recording is known as "floptical". Other floptical formats included Caleb UHD144, Sony HiFD (200 MB), and LS-240, all of which could read and write 720 KB and 1.44 MB disks. They competed with Zip drives, which came in 100, 250, and 750 MB capacities, but were not compatible with 3.5" floppy disks. What ultimately prevented any of them from catching on was competition from USB thumb drives and CD-R.
Hard drives
The first hard disks were absurdly huge. The IBM 350 used fifty-two 24" disks, using 100 heads and 100 tracks per surface to store 5 MB worth of 6-bit bytes (equivalent to 3.75 MB using 8-bit bytes). The technology miniaturized over the years until, in 1980, Shugart Technology (now known as Seagate) created the first 5.25" hard drive, the STS-506, which was 5 MB.
The original IBM PC (Model 5150) didn't come with a hard drive, and a hard drive couldn't be added without a special controller card and a separate power supply for the hard drive. The PC's successor, the PC XT (Model 5160), came with a 10 MB hard drive. It used the follow-up to the STS-506, the STS-412.
Like floppy disks, hard drives originally came in a 5.25" form factor, which was quickly overtaken by the 3.5" form factor. Like 5.25" and 3.5" floppy disks, hard drives originally used a 512 byte sector size, though hard drives for home computers with 4 KB sectors debuted in 2010. Support for hard drives with 4 KB sectors was only added to home versions of Windows as of Windows Vista, so early 4 KB hard drives used 512 byte sector translation for the benefit of Windows XP users.
Drive geometry
There were only a handful of drive geometries for floppy disks. This was necessary to ensure that a disk could be formatted and recorded on one computer and be read and modified by another. Hard disks, on the other hand, are permanently stored in the hard drive, so manufacturers are free to use whatever geometry they want, resulting in any capacity that they can reliably manufacture.
In the early days of hard drives, hard disks were recorded with the same MFM technique as floppy disks, using the same system of having the same number of sectors on each track. This made it possible to determine the capacity of a hard drive using the CHS system (Cylinders-heads-sectors). As with floppy disks, this meant that every sector on the hard drive had a unique CHS address. The first 5.25" hard drive had 4 heads (numbered 0 to 3), and each side of each platter had 153 cylinders (numbered 0 to 152), and each cylinder had 32 sectors (numbered 1 to 32), so the last sector on the drive could be identified as 152-3-32.
CHS information was stored in the Master Boot Record (MBR). Hard drives stopped recording data this way a long time ago, and now use a variable number of sectors per cylinder by dividing the disk into a number of "zones". All of the cylinders in each zone have the same number of sectors, but the outer zones have more sectors per cylinder than the inner zones. For many years, it was necessary to enter the hard drive's CHS geometry in the motherboard's CMOS Setup in order for the motherboard to use the drive, so hard drives continued to report a fake CHS value that equalled the drive's capacity for years after CHS ceased to be an accurate representation of a drive's geometry. CHS information was often written on the top of the hard drive to facilitate entering this information.
The Drive Geometry Calculator below can be used to calculate the capacity of both floppy disks and hard drives.
Capacity | |
---|---|
Bytes | |
KB | |
MB | |
GB |
Historical hard drives
The successor to CHS is LBA (Logical Block Addressing), used by most hard drives manufactured after 1996. That includes all Solid State Drives, for which CHS would be nonsensical (since they contain no discs). Instead of giving each sector an ID composed of three different numbers (C, H, and S), each sector is sequentially numbered, starting at 0. Determining the capacity of a hard drive is a simple matter of multiplying LBA by sector size. LBA information is usually printed on the hard drive.
Sector size | |
Capacity | |
---|---|
Bytes | |
KB | |
MB | |
GB | |
TB |
LBA could originally be a 22-bit number, and was increased to 28-bits in 1994. The 28-bit LBA led to the famous "137 GB limit", so called because 228 512 byte sectors results in a capacity of 137,438,953,472 bytes (hard drive manufacturers consider 137 billion bytes to be 137 GB). All hard drives larger than 137 GB must use a 48-bit LBA (introduced in 2003), which older motherboards don't support. This means that hard drives marketed as 120 GB are the largest hard drives that can safely be used in pre-2003 motherboards.
512 B | 4 KB | |
---|---|---|
22-bit | 2 GB | 16 GB |
28-bit | 128 GB | 1 TB |
48-bit | 128 PB | 1 EB |
Optical discs
All of the common optical discs have a 12 cm diameter, which conveniently allows optical drives to fit in a 5.25" drive bay. Audio CDs have been commercially available since 1982, but the "Yellow Book" standard that opened the door for CD-ROMs wasn't developed until 1985. CD-ROM drives were uncommon until the late 1980s and early 1990s, at which time multimedia-capable computers led to an explosion in popularity.
A standard CD contains 333,000 sectors of 2352 bytes per sector: 2048 bytes of data and 304 bytes for error detection and correction. DVDs use 2418 byte sectors and, again, only 2048 of those bytes store data.
Type | CD | DVD | HD DVD | BD |
---|---|---|---|---|
Wavelength | 780 nm | 650 nm | 405 nm | |
1× = | 150 KB/s | 1.35 MB/s | 4.5 MB/s | |
Capacity | 650 MB | 4.7 GB | 15 GB | 25 GB |