Linux uses a hierarchical directory structure. Understanding the purpose of these core directories is fundamental to system administration. The diagram below illustrates a typical Linux directory tree:

Core System Directories
/bin
bin stands for Binary. This directory contains essential user commands required for system boot and single-user mode maintenance (e.g., ls, cp, bash). In most modern distributions, /bin is often a symbolic link to /usr/bin.
/boot
Contains core files needed for the boot process, such as the boot loader (e.g., GRUB), the Linux kernel image (vmlinuz-*), and the initial RAM disk image (initramfs-*).
/dev
dev stands for Device. This directory contains all device files (e.g., /dev/sda, /dev/tty, /dev/null), embodying the "everything is a file" philosophy. Applications interact with hardware by reading from and writing to these files.
/etc
The system-wide configuration directory. Global configuration files for almost all system services and applications reside here (e.g., /etc/passwd, /etc/fstab, /etc/nginx/nginx.conf).
/home
Personal home directories for regular users. Each user typically has a subdirectory named after their username (e.g., /home/alice) for personal files, configurations, and desktop environment settings.
/lib, /lib64
Contains essential system libraries (e.g., the C library libc.so.*) and kernel modules required to boot the system and run commands in /bin and /sbin. On 64-bit systems, 64-bit libraries are often placed separately in /lib64.
/root
The home directory for the system administrator (root user), not to be confused with the root (/) directory itself.
/sbin
s stands for System. Contains commands essential for system administration, repair, and booting (e.g., fdisk, ifconfig, init). Typically requires root privileges to execute.
/tmp
A directory for temporary files used by the system and applications. Files here may be cleared on system reboot (depending on the distribution's configuration).
/usr
Stands for Unix System Resources. One of the largest and most important directories, it contains the system's primary applications, libraries, documentation, and source code. It forms a relatively self-contained hierarchy.
- /usr/bin: The vast majority of user commands and non-essential system commands.
- /usr/sbin: Non-essential system administration commands.
- /usr/lib: Library files required by applications and system services.
- /usr/local: Locally installed software by the system administrator, not managed automatically by the system's package manager.
- /usr/share: Architecture-independent, read-only data such as documentation, icons, and fonts.
- /usr/src: Location for kernel source code (if installed).
- /usr/include: Standard header files for programming languages like C/C++.
/var
var stands for Variable. Stores data that changes frequently, such as logs, caches, spool files, and databases.
- /var/log: System and application logs.
- /var/cache: Application cache data.
- /var/spool: Data queued for processing, such as print jobs and mail queues.
- /var/www: The default web server (e.g., Apache) document root in some distributions.
Special Virtual Directories
/proc
A virtual filesystem that provides a real-time interface to kernel and process information. Its contents reside in memory, not on disk. For example, you can temporarily disable ICMP Echo responses (ping) by modifying /proc/sys/net/ipv4/icmp_echo_ignore_all:
echo 1 > /proc/sys/net/ipv4/icmp_echo_ignore_all
Note: This change is temporary and will be lost after a reboot. For a permanent change, use the /etc/sysctl.conf configuration file.
/sys
Another virtual filesystem (introduced with kernel 2.6) that exports kernel object (device, driver, module) information and configuration interfaces to user space in a more structured way, complementing /proc.
/mnt and /media
Generic mount points for temporarily mounting filesystems. /mnt is typically for manual mounts by the administrator (e.g., network storage), while /media is often for automatic mounting of removable media (e.g., USB drives, CDs).
/opt
Used for installing third-party or large add-on applications. Each application usually resides in its own subdirectory (e.g., /opt/google/chrome).
/lost+found
Each filesystem (partition) may have a lost+found directory at its root. When a filesystem error occurs (e.g., due to an improper shutdown) and is repaired by the fsck utility, recovered file fragments are placed here.
Summary and Best Practices
Understanding the Linux Filesystem Hierarchy Standard (FHS) aids efficient system administration and troubleshooting. Key points:
- /etc for configuration, /var for variable data, /usr for static programs.
- User data in /home, temporary files in /tmp, third-party software optionally in /opt or /usr/local.
- Avoid deleting files you don't understand, especially in
/lib,/bin, and/sbin. - In modern distributions,
/bin,/sbin, and/libmay be merged with their counterparts under/usrvia symbolic links, a trend known as "usr merge."