Linux Directory

In this tutorial, we are going to learn about the Linux Directory and its structure. Through this tutorial, we will be covering about Linux main directory.

Linux Directory

Directories in Linux are just like the folders in Windows. We use Directories to manage our files efficiently.
Let us suppose we have 10 text files and we want to save them at a particular location and the requirement is the name of 10 files should be the same.

So, with the help of the directories concept, you can achieve this task. We will see this thing practically but first, let’s understand the directory structure in Linux.

Structure of Linux Directories

In the below structure we can see the ” / “ is the parent directory of all the directories and all the work is done under the ” / “ and it will be added or done inside this only.

Output:

Linux Directory
Structure of Linux Directory

Now, we have multiple directories inside the root directory. Each directory has its own use case. As we move forward and cover other topics in Linux we automatically get an idea about their use cases. Below, is a high-level idea about the use case of these directories.

Root(” / “)

This symbol is known as the root directory. Everything in Linux will be stored inside the root directory.

bin/

Here, bin means binary. So, As Name tells it contains binary executable files which can be accessible by any user. Basically, the commands in Linux are also program so those programs’ binary executable code is inside the bin directory that is why we are able to use the commands.

dev/

Just for simple understanding, It consists of files that represent all the devices attached to your local system. for example your local device camera, local device speaker, etc.

etc/

Mainly this file consists of all the configuration files. For example, you have to install the HTTPD(webserver) package in your Linux system. Now, the configuration file for your web server can be found inside /etc directory.

home/

This directory contains all the users present in your system. For example, if you create two users U1 and U2 now these users will be created inside the home directory. This thing will be more clear when we discuss the user’s concept in Linux.

Read:

What is Linux?

Working with “/” symbol

This symbol(‘ / ‘) is known as root directory. Everything in Linux will be stored inside the root directory.

For a better understanding have a look at the given path.

Syntax:

PATH1 --> /folder1/sub_folder/file1

So, Here first ( / ) denotes root directory and other ( / ) in PATH1 are called field separators which tells directory inside directory.

root directory and field separator
Root directory and field separator

So, in this tutorial, we discussed Linux Directory and we have also covered different examples related to its implementation. Here is the list of topics that we have covered.

  • Linux Directory
  • Structure of Linux Directories
  • Working with “/” symbol

Github Link

Check more projects in Repository from Github and you can also fork them.

Github User Name: PythonT-Point

1 thought on “Linux Directory”

  1. Вся информация, представленная на данном сайте, носит исключительно информационный характер и предназначена для ознакомления с деятельностью онлайн-казино. Сайт не являемся оператором игр и не предоставляем услуг по организации азартных игр. nijyrwviuz … https://images.google.as/url?q=https://t.me/s/kazino_casino_top

    Reply

Leave a Comment