Linux filesystem structure is not imposed by the system. filesystem structure in linux Can vary from one system to the other, even between two GNU/Linux installations!
| Directory | Explanation |
|---|---|
| / | Root directory |
| /bin/ | Basic, essential system commands |
| /boot/ | Kernel images, initrd and configuration files |
| /dev/ | Files representing devices. /dev/hda: first IDE hard disk |
| /etc/ | System configuration files |
| /home/ | User directories |
| /lib/ | Basic system shared libraries |
| /lost+found | Corrupt files the system tried to recover |
| /media |
Mount points for removable media:
$ /media/usbdisk $ /media/cdrom |
| /mnt/ | Mount points for temporarily mounted filesystems |
| /opt/ | Specific tools installed by the sysadmin. /usr/local/often used instead |
| /proc/ |
Access to system information.
$ /proc/cpuinfo $ /proc/version $ ... |
| /root/ | root user home directory |
| /sbin/ | Administrator-only commands |
| /sys/ | System and device controls (cpu frequency, device power, etc.) |
| /tmp/ | Temporary files |
| /usr/ |
Regular user tools (not essential to the system)
$ /usr/bin/ $ /usr/lib/ $ /usr/sbin $ ... |
| /usr/local/ | Specific software installed by the sysadmin (often preferred to /opt/) |
| /var/ |
Data used by the system or system servers
$ /var/log/ $ /var/spool/mail(incoming mail) $ /var/spool/lpd(print jobs)... |
The Unix filesystem structure is defined by the Filesystem Hierarchy Standard (FHS)