Hard Drive

The hard drive stores the computer’s operating system and individual applications internally, so that they do not have to be loaded from discs each time the computer is started. These applications are accessed from the drive and pulled to RAM when needed. Saved files are also stored here, or on external drives for mobility. Hard drive storage is slower, but cheaper, than RAM.

Desktop Hard Drive
Laptop Hard Drive

Hard Drive Performance

To measure the performance of a drive, we use two key characteristics: data rate and seek time.

Key Characteristics for Performance

  1. Data Rate: The bytes per second that the drive can deliver to the CPU.
  2. Seek Time: The time it takes for the hard drive to start sending the first byte of data following the initial request from the CPU.

Hard drives contain two important pieces of equipment that allow them to function efficiently as primary data storage. This first piece is a magnetic recording medium layered on a high-precision glass or aluminum disk, called the “platter.” The second piece is called a “head,” and is used to read and write information on the platter. There are two heads per platter, one on each side, and most hard drives have multiple platters. An internal motor spins the platters, allowing the heads to read the magnetically stored data.

Hard drives also have a component called the cache. If data stored in the cache is requested, it can be read directly from the cache rather than searching and reading information from the disk itself.

An image of a hard drive displaying a "head" and "platter"

Storing the Data

Data is stored on the surface of the platter using organizational elements known as sectors and tracks. 

Data Storage

  • Tracks: Concentric circles that surround the entire platter.
  • Sectors: Wedges that, when grouped together, form a track. Each sector contains a fixed number of bytes (usually 256 or 512) and is grouped into clusters.
Visualization of tracks on a hard drive

Red: Track; Blue: Sector 

Formatting

Before a drive can be used, it must be properly formatted. A low-level format is performed that. After the low-level formatting, a high-level format is performed.

  • Low-Level Format: Establishes the tracks and sectors on the platter to prepare the disk to hold blocks of bytes
  • High-Level Format: Prepares the disk to hold files and writes important structures for the operating system to the disk.

Hard Drive Interfaces

Historical Interfaces

  • Integrated Drive Electronics (IDE): Also known as ATA or PATA, was used in PCs for about 20 years. It has two channels and a shared bus, allowing only one drive to talk at a time. Limited to 4 drives without an expansion card and is internal to the computer.
  • Small Computer System Interface (SCSI): Developed in 1986, it uses an intelligent controller to manage the bus, supporting up to 15 devices. SCSI can connect devices directly to each other and to the controller, requiring an add-in card for use. Using SCSI will typically require an add-in card. Tape drives, scanners, and the first CD-ROM drives were designed for SCSI. Like IDE, only one device can talk on a SCSI bus at a time, but devices can talk directly to each other as well as to the controller.

Modern Interface

  • Serial ATA (SATA): The evolution of IDE. SATA uses a direct serial connection between the motherboard and each drive, which gives smaller/narrower connectors and cables and faster speeds than IDE.

Hard Drive Configuration

Redundant Array of Independent Disks (RAID: Configuration)
RAID refers to a scheme, not an interface, of using multiple hard drives to create one or more logical units to gain fault tolerance or increased capacity. Historically, RAID was used exclusively in expensive server hardware, but is now affordable enough for personal desktops. There is hardware and software RAID, and they may be used with IDE, SCSI, or SATA hard drives.

Solid State Drives (SSD)

Solid-state drives (SSDs) use solid-state memory that emulates a hard disk drive interface to store data. SSDs have no moving parts, making them more durable and quieter than hard disk drives.

Arshane88 / CC BY-SA 4.0 / Wikimedia Commons

SSDs are drives made from certain types of flash memory (like a USB). There are a few different kinds; the image below shows NAND-based non-volatile memory.

If you have a newer laptop computer, you likely have an SSD, not a spinning hard drive.

SSD vs. HDD: Key Differences

  1. Speed: SSDs are significantly faster than HDDs due to the lack of moving parts. They offer quicker boot times, file transfers, and overall performance.
  2. Durability: SSDs are more durable and shock-resistant since they don’t have moving parts.
  3. Capacity: HDDs typically offer larger storage capacities at a lower cost compared to SSDs.
  4. Power Consumption: SSDs use less power, which can extend battery life in laptops.
  5. Noise: HDDs can be noisy due to spinning disks, while SSDs are silent.

For more details, you can check the article here.