II.  Generalities


II.1  Geometry of a hard disk drive

Basics

The generic term used to refer to the way the disk structures its data into platters, tracks and sectors, is its geometry. In the early days this was a relatively simple concept: the disk had a certain number of heads, tracks per surface, and sectors per track. These were entered into the BIOS set up so the PC knew how to access the drive.

With newer drives the situation is more complicated. The simplistic limits placed in the older BIOS's have persisted to this day, but the disks themselves have moved on to more complicated ways of storing data, and much larger capacities. The result is that tricks must be employed to ensure compatibility between old BIOS standards and newer hard disks.


Note: These issues are related to IDE/ATA hard disks, not SCSI, which use a different addressing methodology.


Physical geometry

The physical geometry of a hard disk is the actual physical number of head, cylinder, and sector used by the disk. On older disks this is the only type of geometry that is ever used. The original setup parameters in the system BIOS are designed to support the geometries of these older drives, in particular the fact that every track has the same number of sectors.

All newer drives that use zoned bit recording must hide the internal physical geometry from the rest of the system, because the BIOS can only handle one number for sectors per track. These drives use logical geometry figures, with the physical geometry hidden behind routines inside the drive controller.

Logical geometry

Drive parameters obtained by its auto-detection in the system BIOS setup, additional software such as ATAID, or those printed in a hard disk's setup manual are the logical geometry parameters that the hard disk manufacturer has specified for the drive. Since newer drives use zoned bit recording and hence have ten or more values for sectors per track depending on which region of the disk is being examined, it is not possible to set up the disk in the BIOS using the physical geometry. Also, the BIOS has a limit of 63 sectors per track, and all newer hard disks average more than 100 sectors per track, so even without zoned bit recording, there would be a problem.

To get around this issue, the BIOS is given bogus parameters that give the approximate capacity of the disk, and the hard disk controller is given intelligence so that it can do automatic translation between the logical and physical geometry. Virtually all modern disks use a logical geometry with 16 heads and 63 sectors, since these are the largest values allowed by the BIOS. The actual physical geometry is totally different, but the BIOS (and the system) knows nothing about this. As far as the system is concerned, the disk has 16 heads and 63 sectors on every track, and the hard disk itself takes care of all the "dirty work". The physical geometry is totally hidden from view.

Here is an example showing the difference between the physical and logical geometry for a sample drive, a 3.8 GB Quantum Fireball TM (from [Quantum]):


Table II.1.1: Physical and logical geometry of 3.8 GB Quantum Fireball TM.
Specification Physical Geometry Logical Geometry
Read/Write Heads 6 16
Cylinders (tracks per Surface) 6,810 7,480
Sectors Per track 122 to 232 63
Total Sectors 7,539,840 7,539,840

The fact that both geometries equate to the same number of total sectors is not a coincidence. The purpose of the logical geometry is to enable access to the entire disk using terms that the BIOS can handle. The logical geometry could theoretically end up with a smaller number of sectors than the physical, but this would mean wasted space on the disk. It can never specify more sectors than physically exist, of course.

The translation between logical and physical geometry is the lowest level of translation that occurs when using a modern hard disk. It is different from BIOS geometry translation, which occurs at a higher level, to overcome hard disk capacity limitations (cf. [Kozierok]).