operating-systems file-management

Definition

File System Layout

The file system layout describes the physical organisation of data on a disk partition, enabling the OS to locate the root directory and manage allocated vs. free blocks.

Master Boot Record

MBR

Located in Sector 0 of the disk. Contains:

  • Boot Code: Executed by BIOS during startup
  • Partition Table: Start/end addresses of all partitions; identifies the active partition

Partition Layout

Boot Block

Loads the OS kernel from this partition.

Super Block

Critical metadata: file system size, block count, magic number, pointers to other structures.

Free Space Management

Tracks unallocated blocks (e.g., bit table).

i-node Table

Array of i-nodes, one per potential file.

Root Directory

Top of the file hierarchy.

Data Blocks

Actual user data.