Explain the Linux directory structure (/etc, /var, /usr, /tmp, /home, /opt, /proc).
The Linux filesystem follows the Filesystem Hierarchy Standard (FHS). Key top-level directories DevOps engineers work with constantly:
/etc — system-wide configuration files (e.g.,
/etc/nginx/nginx.conf,/etc/ssh/sshd_config,/etc/hosts)./var — variable data: logs (
/var/log), package state, mail spool, databases (/var/lib/mysql)./usr — user-installed system software:
/usr/bin,/usr/lib,/usr/localfor locally-compiled apps./tmp — temporary files; typically cleared on reboot.
/home — user home directories (
/home/alice)./opt — optional / third-party software (often vendor-shipped apps).
/proc — virtual filesystem exposing kernel and per-process info (
/proc/cpuinfo,/proc/meminfo,/proc/<pid>)./sys — virtual filesystem for kernel/device info.
/dev — device files (disks, terminals).
/boot — kernel and bootloader.
# Common directories at a glance
/ # root of the filesystem
/etc # system-wide configuration files
/var/log # log files (syslog, app logs)
/var/lib # variable application state (DB files, etc.)
/usr/bin # user-installed system binaries
/usr/local # locally-compiled software
/tmp # temporary files (cleared on reboot)
/home/<user> # user home directories
/opt # optional / 3rd-party software
/proc # virtual FS exposing kernel/process info
/sys # virtual FS for kernel device info
/dev # device files (disks, terminals)
/boot # kernel + bootloader filesDon't list every directory — just the ones that matter for DevOps work: /etc (config), /var/log (logs), /proc (kernel info), /tmp, /home, /opt. Mention that /proc is a virtual filesystem — that detail signals real Linux experience.