Linux Directory Structure
Basics of Linux Directory Structure
In Linux OS,
each file has its own importance. It means, every file is a part of a specific
concern a user can set. This nature of Linux provides the higher flexibility
for users like beginners, as well as provides more configurable options for
advanced system administration users. In this paper, we are going to discuss
shortly the directory structure of Linux. We will try to describe what a
directory is used for, by reading this article, we can decide and assess the
security fit falls according to different
directories.
directories.
The Root Directory
Every other
directory resides under the Root directory. You can call it the starting point
of Linux directory structure. Please note that there is a difference between
the System Root Directory and User Root Directory. The System
Root Directory is one, under which you see all the other essential directory
structure (simply speaking), and the User Root Directory is the one, which may
exist under the User Home, or the User Username (speaking generally). At this
point, it is enough to understand that the System Root Directory contains all the
other essential directories under it.
The Bin Directory
This
directory contains essential commands and utilities for all the users. The
commands and utilities available here may contain different shells and commands
like cp, ls, rm, cat, mv. For this reason, the placement of any executable
binary will be usable by most general and non general users, so be aware if you
want to place your private tool coded for the system, security matters.
The Boot Directory
This
directory contains the requirements used in Boot process. This directory saves
the data required for settings being applied before the kernel starts executing
user mode programs. Thus, the modification of this directory without having
proper knowledge of what you are doing, is dangerous and can sometimes results
in system booting errors.
The Dev Directory
This is the
directory contained files representing each device in your system. For example:
Each partition is represented by a single file here, similarly your devices
attached to the system has their separate files here. Interestingly, dealing
with the device files present here, you can control how to use or behave a
specific device.
The Etc Directory
This
directory contains mostly plain text files about various configurations. These
files control and configure different aspects of the system. This directory
must protect and look after carefully, so that no one may have access to the
text files (configurations).
The Home Directory
This is the
directory which identifies the Home of a user, as Linux is a multi users OS. A
user will have his prompt as: /home/username, under home directory, files
belonging to user are kept. The user Home directory is accessible by the User
himself and the System Administrator.
The Lib Directory
This
directory contains the Kernel Modules and other packaged related files, for
example the C Programming Library Files are present here. It is better to know
just that, this directory mostly contains the things related to System
Engineers (who know how to edit different system resources) and Programmers
(who use their library related files with the language they use).
The Lost+Found Directory
This
directory contains the data being recovered. It happens when the system
crashes, or when you have back up the device according to your choice. Just
remember at this position that, this directory contains the recovered data.
The Media Directory
This
directory is created for mounting purposes, for more information and know how
to use this directory, refer to your favorite article. At this point, mounting
is a process by which you can make a file system available to use in Linux.
The Opt Directory
This
directory is reserved for all the packages which are not present in your
default Linux installation. According to better rules, all third party packages
should be installed here.
The Proc Directory
This
directory reacts as a virtual space. For example: There may be no solid files
here, as this directory contains the on going processes regarding various
things. Like Hardware, Processes or any other tasks currently going on in the
system, like Printing.
The Root Directory
This is the
Home Directory of the System Administrator. As the System Administrator is the
king, so he has his Home named as Root.
The Sbin Directory
This
directory mostly contains the System Binaries.
The Usr Directory
This
directory contains the data belonging to users openly. For example you can use
this directory to share files, or the important tools used by all users may
found here.
The Var Directory
The
directory which contains Variable Data mostly. For example the data used and
important for all users (mostly some packages involved), like the Mail system
as /var/mail/ or the Logs as /var/logs/.
The Srv Directory
This
directory is used to keep files used for services of the system.
The Tmp Directory
This is the
directory keeping files on short memory basis. All the files kept here (whether
by system or user) are temporarily.
Finally, by
reading, you may have the general concept of each directory present in Linux
OS. By understanding these directories with their purpose properly, we can
assess how can we make our system profitable and usable for ourselves.
Comments
Post a Comment