Partitioning is the first real decision the installer asks you to make, before you've even seen a desktop. One big partition, or several smaller ones? Swap partition or swap file? How much space for root versus home? This page answers all of it — including when the right answer is "just use one partition."
Section 01
A partition is a defined region of a storage device. The disk doesn't know or care what's in each region — partitioning is just the act of drawing lines on the disk and assigning each region a filesystem and a purpose.
On Linux, each partition can be mounted at a path in the filesystem
tree. Mount /dev/sda2 at /home and everything written to
/home goes to that partition — physically separate from /
even though it looks like one unified directory tree.
Before you can create partitions, the disk needs a partition table — a small data structure at the very beginning of the disk that describes where the partitions are. Two formats matter:
MBR (Master Boot Record) — the old format. Supports disks up to 2TB. Maximum 4 primary partitions (workaround: extended/logical partitions). Required for legacy BIOS boot on very old hardware. If you're installing on a machine from the last decade, you almost certainly don't need this.
GPT (GUID Partition Table) — the modern format. Supports disks up to 9.4 ZB. Up to 128 partitions. Required for UEFI boot. Stores partition data redundantly (at start and end of disk). If you're on any remotely modern machine (post-2012ish), use GPT. The Debian installer defaults to it when it detects UEFI firmware.
ext4 — the default for most Linux installs. Mature, stable, fast, well-understood. If nothing else in this list means anything to you, use ext4 and move on. It handles everything a desktop user needs.
btrfs — a copy-on-write filesystem with built-in snapshot and subvolume support. Fedora defaults to it. Useful if you want rollback capability (snapshot before an update, roll back if it breaks). More complex than ext4; recovery when it goes wrong is harder.
xfs — high-performance filesystem, excellent for large files
and high-throughput workloads. Common on servers and NAS. Cannot shrink in place
(you can grow it, but not shrink). Good choice for /var or
data partitions on servers.
FAT32 — required for the EFI system partition. Not a choice, a requirement. The UEFI firmware itself reads the ESP and it only understands FAT32.
Section 02
The argument for splitting your disk into many partitions sounds compelling until you realize the most common result is that one partition fills up while another sits mostly empty. Disk space is fungible. Partitions are not.
Swap in this scheme is a file inside / — not a partition.
See Section 04. This is now the preferred approach on modern systems.
This scheme is completely valid for a single-user desktop or laptop where you're the only person who uses the machine, you're not running services that generate significant log volume, and you don't need to reinstall the OS while preserving your data. The EFI partition is mandatory on UEFI systems — that's not a choice. Everything else can live in root.
The trade-off is recovery friction: if you want to reinstall the OS, your
home directory and OS files are on the same partition, so you'd need to back
up /home externally before wiping. If you do this often enough,
a separate /home partition pays for itself immediately.
Section 03
Adding a separate /home partition is the single most useful
thing you can do beyond the minimal scheme. It is also the only partition
split that most desktop users will ever actually benefit from.
Why separate /home?
Your home directory contains your config files (dotfiles), documents, downloads,
music, and everything personal. The OS in / is replaceable.
When you separate them onto different partitions, you can wipe and reinstall
/ — even switch distros — without touching /home at all.
Just tell the new installer to mount the existing partition at /home
without formatting it.
In / (root)
In /home
/boot holds your kernel images, initramfs, and bootloader
configuration. In most modern setups with UEFI and GPT, a separate
/boot partition is not needed — the kernel
lives in /boot inside root, and the EFI partition handles
the bootloader separately.
You need a separate /boot partition in two specific cases:
/boot (512 MB–1 GB) holds the kernel in the clear, and the
encrypted root partition mounts after you enter your passphrase at boot.
/boot outside LVM solves it.
Standard desktop install with no encryption or LVM: leave /boot
inside root. The Debian installer handles this correctly by default.
If you're building a server, two more separations become meaningful. On a desktop, these almost never matter.
Why /var on a server?
/var is where logs grow, package caches accumulate,
databases write their files, and mail spools. On a server running services,
an uncontrolled log flood or a large database dump can fill
/var to 100%. If /var shares root, a full
/var crashes the OS — you can't log in, can't write anything,
system is dead. Separate /var means that runaway log growth
fills the /var partition while the OS continues running.
You get an alert, you fix it, nothing else breaks.
Section 04
Swap is overflow space on disk for when RAM fills up. The kernel can move memory pages that haven't been accessed recently from RAM to swap, freeing up RAM for active processes. It also stores a complete RAM snapshot to disk when the system hibernates.
Swap used to always be a dedicated partition. Modern Linux supports swap files — regular files inside an existing filesystem that behave identically. The question is whether there's any real reason to prefer one over the other.
fallocate, format, add to /etc/fstab. No repartitioning.resume=UUID and resume_offset kernel parameters. Not impossible, just more steps.resume=UUID pointing at the partition. One parameter, no offset calculation.Recommendation: use a swap file. The flexibility wins on a desktop. You can resize it without touching the partition table, disable it if you find you don't need it, and the performance difference on an SSD is genuinely zero. If you need hibernation, the extra kernel parameters are a one-time setup. The only reason to prefer a swap partition is if you're on spinning disk hardware and want to squeeze every millisecond of swap performance, or if you're running btrfs and want to avoid the CoW configuration step.
The old rule was "2× your RAM." That came from an era when RAM was measured in megabytes and the kernel's memory management was less sophisticated. It's not a useful rule on modern hardware.
What actually matters:
zRAM creates a compressed block device entirely in RAM and uses it as swap. When memory pressure is high, the kernel compresses less-used pages and moves them to the zRAM device — freeing real RAM, without writing to disk at all. Access time is RAM speed, not disk speed.
Fedora, Chrome OS, and Android all default to zRAM. On a modern desktop with plenty of RAM (16 GB+), zRAM often eliminates the need for any disk swap. The trade-off: zRAM can't save state for hibernation, so you still need disk swap if you hibernate.
The vm.swappiness kernel parameter (0–200) controls how
eagerly the kernel moves memory pages to swap. Default is 60.
Lower values make the kernel prefer keeping things in RAM;
higher values make it swap more freely.
For a desktop with an SSD and plenty of RAM, a lower value (10–30) often feels snappier because programs don't get paged out while you're actively using them. For a server, the default or higher values are usually better — the kernel is smarter than you about what's hot and cold.
SSDs have a finite write endurance, measured in TBW — terabytes written. Every NAND flash cell can only be programmed and erased a limited number of times before it stops reliably holding data. Consumer SSDs are rated anywhere from 75 TBW (cheap 256 GB drive) to 600+ TBW (high-endurance 1 TB drive). Writes to swap count toward that total.
The concern: a high swappiness value on a system that regularly hits memory pressure means the kernel is constantly writing memory pages to the SSD and reading them back. Each cycle burns write endurance. On a spinning hard disk this doesn't matter — mechanical platters don't wear out from writes. On flash storage, they do.
How serious is the risk? For most desktop users: real but overstated. A typical desktop that never runs out of RAM will barely touch swap regardless of swappiness setting, writing a few gigabytes to swap per year at most. A 300 TBW drive at that rate lasts decades. The concern becomes real if your machine regularly exhausts physical RAM — a laptop with 8 GB running a browser, Electron apps, and a VM simultaneously, for example. In that scenario, high swappiness with swap on SSD is genuinely eating drive life every session.
The write amplification problem
SSDs don't overwrite individual bytes — they erase and rewrite entire blocks (typically 128 KB–4 MB). If the kernel writes one 4 KB memory page to swap, the SSD controller may need to erase and rewrite a full 128 KB block to accommodate it. This amplification means actual flash writes are larger than the data writes you initiated. Modern SSDs have wear-leveling controllers that distribute writes across cells to even out the wear, but amplification is always a factor.
You can see how much your drive has actually written versus what the OS
requested with smartctl:
The practical mitigations, in order of impact:
The setup to avoid: High swappiness (60+) + swap on a budget SSD (low TBW) + regular memory pressure (system frequently near RAM limit). That combination genuinely shortens drive life. Any one of the three factors alone is manageable. All three together is the problem.
Section 05
This is the full reference. Most of these you will never need to separate on a desktop. Read the "who needs this separate" column honestly.
/boot inside root is completely fine — the Debian installer
puts it there by default.
/var/log can grow without bound from service logs,
/var/lib holds database files, and /var/cache/apt
accumulates package downloads. A separate partition means runaway growth
here can't take down the OS. On a desktop, log growth is minimal and
this separation usually just wastes space.
du -sh /var/* on a running system before deciding./tmp as tmpfs
by default — a RAM-backed filesystem that exists only in memory and
disappears on reboot. This is faster than disk and requires no partition.
A separate disk partition for /tmp is only useful if you
need to limit the size of temporary files (e.g., a build server where
compilations generate multi-GB temp files).
findmnt /tmp — if it says tmpfs, no disk partition is needed./usr holds everything in /usr/bin,
/usr/lib, and /usr/share — essentially
all installed software. Separating it made sense decades ago when
/usr might live on a network share. Today, the kernel
and initramfs expect /usr to be available immediately
at boot; a separate partition adds complexity with no practical benefit
on modern systems. Leave it inside root.
/opt to stay self-contained and avoid conflicts with
the distro's package manager. On a desktop, almost nothing uses
/opt except maybe a few Flatpaks or snap-equivalent tools.
Separating it is rarely worth the partition slot.
Section 06
These are practical recommendations, not rules. Your actual usage will vary —
the right move after installing is to monitor with df -h and
adjust future installs based on what you actually consumed.
| Mount point | Recommended size | Filesystem | Notes |
|---|---|---|---|
| /boot/efi | 512 MB | FAT32 (required) | First partition. Non-negotiable on UEFI. |
| / | 40–60 GB | ext4 | OS + all installed software. 40 GB is safe; 60 GB if you install a lot. |
| /home | remainder | ext4 | Give it everything that's left. Don't try to predict how much you'll need. |
| swap | 8–16 GB (file) | swapfile inside / | RAM size if you hibernate; 8 GB otherwise. Created after install, not during. |
| Mount point | Recommended size | Filesystem | Notes |
|---|---|---|---|
| /boot/efi | 512 MB | FAT32 | Same as desktop. |
| /boot | 1 GB | ext4 | Outside LUKS if encrypted. Holds kernel and initramfs only. |
| / | 20–30 GB | ext4 | Smaller than desktop — no desktop apps, no media. Just OS and system software. |
| /var | 20–100 GB | ext4 or xfs | Size based on services. Monitor du -sh /var/* after a week of operation. |
| /home | remainder | ext4 | Or a dedicated data volume depending on workload. |
| swap | RAM size | partition or file | Servers may need hibernation during maintenance windows. Partition is simpler here. |
Checking your usage after install
The most useful tool for understanding partition usage over time:
Root is too small:
You'll see warnings when packages can't install.
Solutions: move large directories (/var/cache, /opt)
to a different mount; use ncdu to find and purge large files;
resize the partition with gparted from a live USB (extend root,
shrink home). ext4 supports live resizing in some directions.
Home is too small: Move it. On a separate partition: back up, resize, restore. If /home is inside root and root has room: nothing to do. If /home is on its own partition and is full: external drive + resize from live USB.
Swap is too small:
If you used a swapfile, disable it (sudo swapoff /swapfile),
delete it, create a larger one, re-enable. Five minutes. If you used a
partition, you need a live environment and a partition editor.
This is the main practical reason to use a swapfile.