Cylinder-head-sector (CHS) is an early method for giving addresses to each physical block of data on a hard disk drive.
CHS addresses were exposed, instead of simple linear addresses (going from 0 to the total block count on disk - 1), because early hard drives didn't come with an embedded disk controller, that would hide the physical layout.
As the geometry became more complicated (for example, with the introduction of zone bit recording) and drive sizes grew over time, the CHS addressing method became restrictive.
Since the late 1980s, hard drives began shipping with an embedded disk controller[1] that had good knowledge of the physical geometry; they would however report a false geometry to the computer, e.g., a larger number of heads than actually present, to gain more addressable space.
[2] In the early 2010s, the disk size limitations imposed by MBR became problematic and the GUID Partition Table (GPT) was designed as a replacement; modern computers using UEFI firmware without MBR support no longer use any notions from CHS addressing.
The terms are explained bottom up, for disk addressing the sector is the smallest unit.
Disk controllers can introduce address translations to map logical to physical positions, e.g., zone bit recording stores fewer sectors in shorter (inner) tracks, physical disk formats are not necessarily cylindrical, and sector numbers in a track can be skewed.
A device called a head reads and writes data in a hard drive by manipulating the magnetic medium that composes the surface of an associated disk platter.
However, a bug in all versions of Microsoft DOS/IBM PC DOS up to and including 7.10 will cause these operating systems to crash on boot when encountering volumes with 256 heads[2].
This historical oddity can affect the maximum disk size in old BIOS INT 13h code as well as old PC DOS or similar operating systems: (512 bytes/sector)×(63 sectors/track)×(255 heads (tracks/cylinder))×(1024 cylinders)=8032.5 MiB, but actually 512×63×256×1024=8064 MiB yields what is known as 8 GB limit.
[7] In this context relevant definition of 8 GiB = 8192 MiB is another incorrect limit, because it would require CHS 512×64×256 with 64 sectors per track.
[7] The 28=16+4+8 bits in the ATA-2 specification are also covered by Ralf Brown's Interrupt List, and an old working draft of this now expired standard was published.
For example, the Linux fdisk utility, before version 2.25,[12] displayed partition sizes using 1024-byte blocks.
Clusters are not directly affected by the physical or virtual geometry of the disk, i.e., a cluster can begin at a sector near the end of a given CH track, and end in a sector on the physically or logically next CH track.
Examples: To help visualize the sequencing of sectors into a linear LBA model, note that: Cylinder Head Record format has been used by Count Key Data (CKD) hard disks on IBM mainframes since at least the 1960s.
Thus, the CHS addressing scheme cannot correspond directly with the physical geometry of such drives, due to the varying number of sectors per track for different regions on a platter.
[citation needed] For operating systems such as Microsoft DOS or older version of Windows, each partition must start and end at a cylinder boundary.
[citation needed] Only some of the relatively modern operating systems (Windows XP included) may disregard this rule, but doing so can still cause some compatibility issues, especially if the user wants to perform dual booting on the same drive.
Microsoft does not follow this rule with internal disk partition tools since Windows Vista.