Linux File System: Operating Systems CSC322
Linux File System: Operating Systems CSC322
/bin This is where the executable files are located. These files are available to all users.
The /bin directory contains the essential user binaries (programs) that must be present when
the system is mounted in single-user mode. Applications such as Firefox are stored in /usr/bin,
while important system programs and utilities such as the bash shell are located in /bin.
/boot The /boot directory contains the files needed to boot the system – for example, the GRUB boot
loader’s files and your Linux kernels are stored here. The boot loader’s configuration files aren’t
located here, though – they’re in /etc with the other configuration files.
/etc The /etc directory contains configuration files, which can generally be edited by hand in a text
editor. Note that the /etc/ directory contains system-wide configuration files – user-specific
configuration files are located in each user’s home directory.
/home The /home directory contains a home folder for each user. For example, if your user name is
bob, you have a home folder located at /home/bob. This home folder contains the user’s data
files and user-specific configuration files. Each user only has write access to their own home
folder and must obtain elevated permissions (become the root user) to modify other files on the
system.
/lib The /lib directory contains libraries needed by the essential binaries in the /bin and /sbin folder.
Libraries needed by the binaries in the /usr/bin folder are located in /usr/lib.
/lost+found Each Linux file system has a lost+found directory. If the file system crashes, a file system check
will be performed at next boot. Any corrupted files found will be placed in the lost+found
directory, so you can attempt to recover as much data as possible.
/media The /media directory contains subdirectories where removable media devices inserted into the
computer are mounted. For example, when you insert a CD into your Linux system, a directory
will automatically be created inside the /media directory. You can access the contents of the
CD inside this directory.
/mnt Used to mount other temporary file systems, such as cdrom and floppy for the CD-ROM drive
and floppy diskette drive, respectively
/opt he /opt directory contains subdirectories for optional software packages. It’s commonly used by
proprietary software that doesn’t obey the standard file system hierarchy – for example, a
proprietary program might dump its files in /opt/application when you install it.
/proc The /proc directory similar to the /dev directory because it doesn’t contain standard files. It
contains special files that represent system and process information.
/usr Used for miscellaneous purposes, and can be used by many users. Includes administrative
commands, shared files, library files, and others
/var Typically contains variable-length files such as log and print files and any other type of file
that may contain a variable amount of data
/sbin Contains binary (executable) files, usually for system administration. For example, fdisk and
ifconfig utlities