OCR H446, section 1.1.3 (b)
Secondary storage keeps programs and data permanently, even when the power is off (it is non-volatile). It holds far more than RAM, and is cheaper per gigabyte, but is slower. There are three technologies.
Magnetic storage
Data is stored as tiny regions of magnetism on a surface, with the direction of magnetisation representing 1 or 0.
Hard disk drive (HDD)
- One or more platters coated with a magnetic material spin at high speed (such as 5400 or 7200 revolutions per minute).
- A read/write head on a moving arm floats just above the surface. To write, it changes the magnetisation of a tiny area. To read, it senses the magnetisation as the surface passes underneath.
- The surface is divided into tracks and sectors. To reach data, the arm seeks to the right track, and the disk rotates until the sector arrives, which causes delay (latency).
| Characteristic | HDD |
|---|---|
| Capacity | Very high (several terabytes) |
| Cost per GB | Low |
| Speed | Slower, because of the moving parts |
| Durability | Fragile: moving parts can be damaged by knocks |
| Power and noise | Uses more power, makes some noise |
Uses: bulk storage in desktops and servers, backup, and large media libraries, where capacity and cost matter more than speed.
Magnetic tape
Data is stored on a long strip of magnetic tape on a reel or cartridge, and must be read sequentially (to reach data in the middle, the tape must wind to it).
- Very cheap per gigabyte, and very large capacity.
- Slow to find data, because it is not random access.
- Suited to backup and long-term archive, where data is written in bulk and rarely read.
Flash storage
Data is stored in flash memory, using NAND chips made of floating gate transistors. Each one traps an electric charge, and whether the charge is present represents a 1 or 0. The charge stays when the power is off. There are no moving parts.
Examples: the solid-state drive (SSD), USB flash drives, SD and other memory cards, and the storage in phones and tablets.
| Characteristic | Flash |
|---|---|
| Capacity | Medium to high, and increasing |
| Cost per GB | Higher than a hard disk |
| Speed | Very fast read and write, with low latency |
| Durability | Robust: no moving parts, so it survives knocks |
| Power and noise | Low power, silent |
| Lifespan | Each cell can only be rewritten a limited number of times, although this is long in normal use |
Uses: the main drive in laptops and phones (fast start-up and good battery life), portable storage, cameras, and devices that are moved around.
Optical storage
Data is stored as a pattern on the surface of a disc, read with a laser.
- A spiral track has tiny pits (dents) and lands (flat areas).
- A laser shines on the track. Lands reflect most of the light, and pits scatter it. A sensor detects the changes in reflected light, which are read as 1s and 0s.
- Read-only discs (CD-ROM, DVD-ROM) are pressed in a factory. Recordable discs (CD-R, DVD-R) have a dye that the laser marks once. Rewritable discs (CD-RW, DVD-RW) use a material that can be changed back and forth.
| Disc | Typical capacity | Laser |
|---|---|---|
| CD | 700 MB | Infrared |
| DVD | 4.7 GB (one layer) | Red |
| Blu-ray | 25 GB (one layer) | Blue-violet (shorter wavelength, so smaller pits and more data) |
| Characteristic | Optical |
|---|---|
| Capacity | Low compared with the others |
| Cost | Cheap per disc, and cheap to produce in bulk |
| Speed | Slowest |
| Durability | Can be scratched or damaged |
| Portability | Light and easy to post |
Uses: distributing software, music, films and games, and small backups. Less common now that downloads and flash drives are widely used.
Comparison
| Magnetic (HDD) | Flash (SSD) | Optical | |
|---|---|---|---|
| Technology | Magnetised areas on spinning platters | Charge in floating gate transistors | Pits and lands read by a laser |
| Capacity | Very high | High | Low |
| Speed | Medium | Fastest | Slowest |
| Cost per GB | Low | Higher | Low (per disc) |
| Moving parts | Yes | No | Yes (spinning disc) |
| Durability | Fragile | Robust | Scratches easily |
| Typical use | Bulk storage, backup | Laptops, phones, portable storage | Distributing media |
Worked example
Task: recommend storage for (a) a company's 200 TB archive of old records, (b) a phone, (c) a software company posting a game to customers.
- (a) Magnetic tape or hard disks: the lowest cost per gigabyte and the highest capacity, and speed isn't critical for an archive. Tape is best if the data is rarely accessed.
- (b) Flash memory: fast, robust, light and low-power, with no moving parts, which a phone needs.
- (c) An optical disc (a DVD or Blu-ray): cheap to produce in bulk, light and easy to post, and read-only, which protects the contents.
Exam tip: compare on capacity, speed, cost, durability and portability, and give a typical use with a reason. For flash, mention floating gate transistors and no moving parts. For optical, mention pits and lands and the laser.
Check yourself
How does a hard disk store data?
As magnetised regions on spinning platters. A read/write head changes the magnetisation to write data and senses it to read data.
Why is flash storage more robust than a hard disk?
It has no moving parts, so knocks and vibration don't damage it in the same way.
How is data read from an optical disc?
A laser shines on the track, and a sensor detects the difference in reflected light between pits and lands.
Why is magnetic tape used for backups but not for everyday files?
It is very cheap and has huge capacity, but it is read sequentially, so finding a particular file is slow.