This chapter follows Scheduling tasks with cron and systemd timers.
On Linux, almost every resource—disks, processes, kernel tunables—surfaces through the Virtual File System (VFS) as paths you can open, list, or mount. Debian stable defaults to ext4 on many installs; servers may use XFS or Btrfs. Understanding inodes, mount tables, and pseudo filesystems explains disk-full errors, permission denials on /proc, and why containers see different roots.
The Filesystem Hierarchy Standard
The FHS describes conventional locations on a Unix-like system. Debian follows it closely:
| Path | Typical role |
|---|---|
/ |
Root of the tree; boot often under /boot |
/etc |
Host-specific configuration |
/home |
User home directories |
/var |
Variable data: logs, caches, spool |
/usr |
User programs and libraries (read-only in many images) |
/tmp |
Temporary files (often tmpfs) |
Distributions may use merged /usr layouts (binaries only under /usr/bin with symlinks from /bin). Container and cloud images sometimes make /usr read-only for immutability—policy, not kernel magic.
Inodes, directories, and links
Every file name points at an inode storing metadata (mode, owner, timestamps, block pointers). Directories map names to inode numbers. df -i reports inode exhaustion—a full disk with free space but no inodes left.
Hard links share one inode; you cannot hard-link across filesystems. Symbolic links are separate files whose content is another path; they can cross mounts and dangle if the target disappears.
ls -li /etc/hostsreadlink -f /etc/localtimestat /var/logOn-disk filesystems
Common choices on Linux:
| Filesystem | Notes |
|---|---|
| ext4 | Default on many Debian installs; mature journaling |
| XFS | Strong on large files and parallel I/O |
| Btrfs | Snapshots, subvolumes; optional on Debian |
| ZFS | Advanced features; often via DKMS or third-party repos |
Creation and check tools (mkfs.ext4, xfs_repair, btrfs subvolume) operate on block devices exposed in /dev—see Hardware and devices in Linux.
Mount attaches a filesystem to a mount point:
findmntmount | column -t/etc/fstab and persistent mounts
/etc/fstab lists filesystems to mount at boot. Fields include device or UUID, mount point, type, options, dump, and fsck order:
UUID=abc... / ext4 defaults 0 1UUID=def... /home ext4 defaults 0 2Use UUID= or LABEL= so disks keep working when /dev/sd* names shuffle. After editing fstab, run findmnt --verify or boot a rescue shell if unsure.
systemd also generates .mount units from fstab entries; ordering interacts with services that need /var or network mounts.
Virtual filesystems and swap
Not everything under / lives on spinning rust:
/proc— process and kernel information (/proc/self,/proc/cpuinfo)./sys— sysfs view of devices and drivers.devtmpfson/dev— device nodes created by the kernel and udev.- tmpfs — RAM-backed
/tmpor/run.
Swap extends memory with disk or zram. Swappiness (/proc/sys/vm/swappiness) influences how aggressively the kernel reclaims anonymous pages. Containers and databases often tune swap policy explicitly.
Capacity and maintenance
Routine checks:
df -hTdu -sh /var/log/*tune2fs -l /dev/sda1Snapshots (Btrfs, LVM thin, ZFS) and backups sit above this layer; the filesystem chapter’s job is to show how the tree you cd through maps to block storage and kernel exports.
Next: Hardware and devices in Linux connects /dev, udev, and drivers to the disks you mount here.
The next chapter is Hardware and devices in Linux.
Check your understanding
Question 1 of 6
0 of 6 checked