What is the maximum file size supported by the original Macintosh Hierarchical…
2023
What is the maximum file size supported by the original Macintosh Hierarchical File System (HFS)?
- A.
2 GB
- B.
4 GB
- C.
8 GB
- D.
16 GB
- E.
32 GB
Attempted by 17 students.
Show answer & explanation
Correct answer: A
Concept
In any file system the largest possible size of a single file is set by the width of the field used to store that file's length. A file's length is kept as a fixed-width integer, and the biggest value that integer can represent is the hard ceiling on file size. This ceiling is separate from, and usually much smaller than, the total capacity of the disk or volume.
Application to HFS
The original Macintosh Hierarchical File System (HFS), introduced in 1985, stores the logical length (end-of-file) of a file's data fork as a 32-bit signed byte count. Working through what that width allows:
The data-fork length is stored as a signed 32-bit integer, so the largest byte count it can represent is 231 − 1 ≈ 2,147,483,647 bytes.
Since 231 bytes = 2 × 1024 × 1024 × 1024 bytes = 2 GB, the limit is two gigabytes (precisely, one byte short of 2 GB).
Therefore no single file on an original HFS volume can exceed about 2 GB, no matter how large the volume itself is.
Cross-check and contrast
Do not confuse the 2 GB file-size limit with the volume-size limit, or with the later HFS+ (HFS Plus, 1998), which widened the length field to 64 bits and pushed the maximum file size far beyond the gigabyte range.
The values 4 GB, 8 GB, 16 GB and 32 GB would each need a wider length field than the 32-bit signed byte count HFS actually uses, so none of them is reachable on the original HFS.