Day 2 : Linux Fundamentals

How To: Build A Read-Only Linux System

# What is Linux?

Linux is a free and open-source operating system based on the family of kernels. Linux distribution is the Linux kernel and a collection of software that together, create an os.

Ex: Debian, Ubuntu, Fedora, CentOS, Kali Linux, Arch Linux etc.

#Linux OS Architecture :-

The Linux OS architecture mainly contains the following components: kernel, system library, hardware layer, system, and shell utility.

Linux Operating System : Types, Working, Differences & Its ...

#Linux File System Hierarchy :-

In Linux everything is represented as a file including a hardware program, the files are stored in a directory, and every directory contains a file with a tree structure. that is called file system hierarchy.

Linux File System Hierarchy – nepalisupport

# Basic Linux Commands :-

Listing commands :-

ls option_flag arguments --> List the sub-directories and files available in the present directory.]

Examples:

  • ls -l--> list the files and directories in long list format with extra information

  • ls -a --> list all including hidden files and directory

  • ls *.sh --> list all the files having .sh extension.

  • ls -i --> list the files and directories with index numbers inodes.

  • ls -d */ --> list only directories.(we can also specify a pattern).

  • Directory commands :-

    • pwd --> print work directory. Gives the present working directory.

    • cd path_to_directory --> change directory to the provided path

    • cd ~ or just cd --> change directory to the home directory

    • cd - --> Go to the last working directory.

    • cd .. --> change directory to one step back.

    • cd ../.. --> Change directory to 2 levels back.

    • mkdir directoryName --> to make a directory in a specific location

  • pwd --> print work directory. Gives the present working directory.

  • cd path_to_directory --> change directory to the provided path

  • cd ~ or just cd --> change directory to the home directory

  • cd - --> Go to the last working directory.

  • cd .. --> change directory to one step back.

  • cd ../.. --> Change directory to 2 levels back.

  • mkdir directoryName --> to make a directory in a specific location

  • Day 2 Task :**-**

    1. Check your present working directory.

    2. List all the files or directories, including hidden files.

    1. Create a nested directory A/B/C/D

      command : mkdir -p A/B/C/D

      1. Make multiple directories at the same time

        command : mkdir A B C D

      2. List all the nested directory

_ Thank you for reading💚

_Komal 🌻✨