The Linux File Hierarchy Structure or the Filesystem Hierarchy Standard (FHS) defines the directory structure and directory contents in Unix-like operating systems.It is maintained by the Linux Foundation
/ (root directory)
/ (root directory) :
Primary hierarchy root and root directory of the entire file system hierarchy.
Every single file and directory starts from the root directory
The only root user has the right to write under this directory
/root is the root user’s home directory, which is not the same as /
This is the directory that has all the binary files of some important programs on the operating system. This directory holds the data about the most used commands related to making(mkdir), moving(mv), copying(cp), listing(ls), and removing(rm) a directory or file. According to the Linux Filesystem Standards, this directory cannot have subdirectories.
Boot loader files, e.g., kernels, initrd.
Kernel initrd, vmlinux, grub files are located under /boot
This directory holds the files of the devices like a USB Device or a Hard Drive. Most of the files are either created on the boot time or when a device is attached.
This directory is for those types of configuration files and folders
Users’ home directories, containing saved files, personal settings, etc
Home directories for all users to store their personal files
example: /home/kishlay, /home/kv
These are the folders where libraries are stored. Libraries are some files that are needed by any application to perform several tasks or functions. For example, these libraries may be needed by the binary files in the /bin directory.
This is the directory where all the external connected storage devices are mounted automatically. We do not need to do anything in this directory because it is managed by the Operating System itself, but if we want to mount storage devices manually, we have the /mnt directory for that purpose.
Temporarily mounted filesystems.
This is the optional folder. It is the directory where manually installed software by vendors is placed.
Essential system binaries, e.g., fsck, init, route
This is a temporary directory and holds the temporary files of the applications running on the system.
This directory contains the applications installed and used by the user. It is also known as the “UNIX System Resources”. It also has its own /bin, /sbin, and /lib directory, which is different from the superuser’s /bin, /sbin, and /lib directories.
This is the directory with the pseudo files. The pseudo files contain information about the processes.