APM (Apple Partition Map)

The Apple Partition Map was the partition scheme of 68k and PowerPC Macs (1986 until the Intel switch in 2006). It is found on classic Mac hard disks, CD-ROMs, and old media and images.

Overview

APM begins with a driver descriptor block (ER) at block 0 describing the block size and device drivers. Partition map entries (PM) follow from block 1; the first entry describes the map itself. Each entry records start block, block count, name, type string (such as Apple_HFS) and flags. All values are big-endian.

History

  • Introduced in the late 1980s for Macintosh SCSI disks.
  • Replaced by GPT on Intel-based Macs from 2006.

Structures

Offsets are in bytes from the start of the structure named in each heading. Field names are descriptive and are not an official specification. Fixed-width integers are shown as u/i (unsigned/signed) followed by bit width and byte order.

Detect Block Size

OffsetSizeTypeFieldNotes
0x02u16 BE–
0x22u16 BEDeclared

Detect Block Size

OffsetSizeTypeFieldNotes
0x44u32 BEAp Count
0x3032bytesType

Read Volumes

OffsetSizeTypeFieldNotes
0x84u32 BEStart
0xC4u32 BECount
0x1032bytesName
0x3032bytesType

Other fields read

Read inOffsetSizeTypeFieldNotes
Read Entry0x02u16 BE–
Read Volumes0x44u32 BEAp Count

Constants

Apm Module

NameValueTypeNotes
DriverDescriptorSignature0x4552ushort“ER”
PartitionSignature0x504Dushort“PM”

Implementation limits

ClassNameValueNotes
Apm ModuleMaxEntries256
Structures and constants were extracted from the implementation. Prose sections are a summary from public sources; verify details before relying on them.