1 Three layers
New to hex, little-endian numbers, sectors and clusters? Start with the Storage Foundations guide and its exercises; these pages assume them.
A storage device is one long array of bytes. Three layers of structure sit on top of it:
Every structure on these pages is found the same way: a number in one structure (a start sector, a cluster, a block, an inode number) tells you where the next one is. Learn the chain for each file system, and you can find any file by hand.
2 The pages
Every page has interactive hex views. Click a field to see its bytes, click a byte to see which field it belongs to, and follow the → rows to jump to the structure they point to.
3 Deep-dives
The same byte-level approach, applied to the files and devices you meet once the file system is understood.
4 At a glance
| FAT32 | ext4 | NTFS | |
|---|---|---|---|
| Starts with | Boot sector with BPB, "FAT32" text at 0x52 | Superblock at byte 1024, magic 53 EF at 0x438 | Boot sector, "NTFS" at offset 3 |
| File metadata | 32-byte directory entry | Inode (usually 256 bytes) in the inode table | MFT record (usually 1024 bytes) |
| Where the data is | First cluster in the entry, then the FAT chain | Extent tree in the inode | Resident in the record, or data runs |
| Names | 8.3 entry plus LFN entries | Directory entries (name → inode) | $FILE_NAME attribute and directory index |
| Timestamps | Local time, 2 s resolution, no time zone | UTC seconds (+ nanoseconds) | UTC FILETIME, 100 ns, two sets ($SI and $FN) |
| On deletion | First name byte → E5, FAT chain zeroed | Entry merged into its predecessor, inode gets dtime, extents wiped | Record flag "in use" cleared, record stays until reused |
5 Warm-up
Two quick checks before you start. Numbers can be typed in decimal or hex (0x…).
The start LBA of an MBR partition entry is a 4-byte little-endian number. On disk it reads 00 08 00 00. Which sector does the partition start at?
Little-endian: the first byte is the lowest. Reverse the bytes, then convert from hex.
Reversed: 00 00 08 00 = 0x00000800 = 8 × 256 = 2,048.
In bytes that is 2,048 × 512 = 1,048,576 = 0x100000 (1 MiB), the usual start of the first partition.
On which file system does deleting a file clear an "in use" flag and leave the file's metadata record in place, with name, times and data location, until it is reused?
See the row "On deletion" in the table above.
NTFS. The MFT record's flags at +0x16 go from 01 00 to 00 00; the attributes stay.
FAT32 overwrites the first name byte with E5 and zeroes the FAT chain, and ext4 wipes the extents in the inode.