Partitioning requirements: what partitions do I need?
A reliable partition scheme balances operational isolation, performance, snapshotting, and available storage. You need to decide which directories to separate, whether to use fixed partitions or Btrfs/ZFS subvolumes, and how to align partitions to the underlying storage media.
Directory isolation & sizing matrix
| Directory | Recommended Size | Implementation | Rationale |
|---|---|---|---|
/boot/efi (ESP) | 512 MB to 1 GB | Dedicated VFAT Partition | Mandatory for UEFI boot firmware. Sizing at 1GB provides capacity for multiple kernels, initramfs images, and Unified Kernel Images (UKIs). |
/ (Root) | 50 GB to 100 GB | Ext4 / XFS or Btrfs Subvolume | Houses system binaries, shared libraries, system configurations, and application runtimes. |
/home | Remaining Storage | Dedicated Partition or Subvolume | Isolates personal user files and dotfiles. Prevents user downloads from consuming root storage and stopping system services. |
/var & /var/log | 20 GB to 50 GB+ | Dedicated Partition or Subvolume | Contains systemd journal logs, database files, and container storage. Segregation prevents log surges from exhausting disk space. |
/tmp | Dynamic (RAM) | tmpfs in Memory | Mounted automatically as tmpfs in RAM for fast I/O and zero disk wear. |
[SWAP] | 4 GB to 16 GB or zram | zram (RAM) + Swapfile | In-memory compressed swap handles active memory pressure; optional disk swapfile accommodates hibernation. |
Fixed partitions vs. subvolume architectures
@root, @home, and @snapshots expand and contract dynamically without rigid partition boundaries.Whichever layout you choose, filesystem labels and UUIDs keep your /etc/fstab entries stable across reboots and hardware changes.
Storage media alignment
- NVMe SSDs: High-throughput block devices. Sector alignment on 1MiB (2048 sector) boundaries is required to align with internal NAND Flash page/erase blocks and prevent write amplification.
- SATA SSDs: Standard solid-state drives requiring 1MiB alignment and periodic discard maintenance via
fstrim.timer. - Rotational HDDs: Mechanical storage suitable for sequential archival data and backup repositories.
Sources & references
- UEFI System Partition Size Requirements — Microsoft official documentation specifying minimum ESP size requirements: 200 MB for 512-byte sectors, 300 MB for 4K native
- fdisk(8) — Linux manual page — documents fdisk's automatic alignment to 4K-sector size and optimal alignment based on device topology
- parted(8) — Linux manual page — official GNU Parted documentation for partition manipulation, including optimal alignment options
- tmpfs(5) — Linux manual page — documents tmpfs as a virtual memory filesystem, supporting the recommendation to mount /tmp as tmpfs
- tmpfs — Linux Kernel Documentation — official kernel documentation explaining tmpfs behavior, including dynamic memory allocation and swap usage
Frequently asked questions
What size should the EFI System Partition be?
The ESP should be 512 MB to 1 GB, formatted as VFAT (FAT32). Sizing at 1 GB provides capacity for multiple kernels, initramfs images, and Unified Kernel Images (UKIs).
How big should the root partition be?
The root partition (/) should be 50 GB to 100 GB, housing system binaries, shared libraries, system configurations, and application runtimes. It can be Ext4, XFS, or a Btrfs subvolume.
Should I use fixed partitions or Btrfs subvolumes?
Fixed partitions provide strict physical space guarantees but require unmounting to resize. Btrfs/ZFS subvolumes share a unified storage pool and expand or contract dynamically without rigid partition boundaries.
How much swap space do I need?
Allocate 4 GB to 16 GB of swap, or use zram for in-memory compressed swap. zram handles active memory pressure; an optional disk swapfile accommodates hibernation.
Why should I separate /var into its own partition?
/var contains systemd journal logs, database files, and container storage. Separating it prevents log surges from exhausting disk space and stopping system services.
What sector alignment do NVMe SSDs require?
NVMe SSDs require 1 MiB (2048 sector) alignment to match internal NAND Flash page and erase blocks, which prevents write amplification. SATA SSDs also require 1 MiB alignment and periodic discard via fstrim.timer.