Understanding the Linux File System Hierarchy: /bin, /etc, /var, /home, /usr Explained

Linux RSH Network November 30, 2025 2 mins read

Explore the purpose and structure of essential Linux directories like /bin, /etc, /var, /home, and /usr β€” foundational knowledge for system management and troubleshooting.

πŸ“‚ What Is the Linux File System Hierarchy?

Linux follows the Filesystem Hierarchy Standard (FHS) — a guideline that defines how directories should be organized under the root directory /.
This structure keeps Linux systems consistent across distributions and ensures predictable locations for binaries, configs, logs, and user data.


πŸ—‚οΈ Key Directories and Their Roles

Directory Purpose
/ Root of the entire file system — everything starts here
/bin Essential user binaries (e.g., ls, cp, mv)
/etc System configuration files
/var Variable data like logs, mail, cache, spool files
/home User home directories (e.g., /home/rsh, /home/alice)
/usr Secondary hierarchy: user applications, libraries, documentation
/tmp Temporary files; often cleared on reboot
/opt Optional or third-party software packages
/dev Device files for hardware and virtual devices
/proc Virtual filesystem with runtime process and kernel data

🧠 Why It Matters

βœ” Troubleshooting

Knowing where logs (/var/log) and configs (/etc) reside makes diagnosing system issues faster.

βœ” Security

Misplacing files — especially configs or logs — can lead to data exposure.

βœ” Automation

Scripts and services rely on consistent directory paths. Understanding FHS ensures reliable automation.


🧰 Pro Tips

  • Check disk usage in variable directories:

     
    du -sh /var/*
  • Audit configuration changes with:

     
    ls -l /etc
  • Avoid putting custom binaries in / or /home — use:

    • /opt for optional packages

    • /usr/local/bin for custom executable scripts


πŸš€ What’s Next?

In Post #8, we’ll explore Linux Disk Management — using df, du, mount, and fdisk to inspect, mount, and manage storage devices.

Advertisement

R
RSH Network

39 posts published

Sign in to subscribe to blog updates