Linux- An In-Depth world

What Is Linux?

Linux is an operating system. It is distributed under an open-source license. UNIX is called the mother of operating systems which laid out the foundation for Linux. Unix is used mainly for mainframes. While Linux is fast becoming a household name for computer users, developers, and server environments. But, the commands using on UNIX and Linux are usually the same. Linux and UNIX are almost similar.

Linux characteristics:

    • Security

    • Stable

    • Command Line Interface

As Linux is the open-source operating system you could download the kernel, a desktop environment, and various other utilities and applications, and install them all yourself useful for the system.

 Some of the better-known Linux distributions are:                                                                                                  

    • LINUX MINT

    • MANJARO

    • DEBIAN

    • UBUNTU

    • ANTERGOS

    • SOLUS

    • FEDORA

    • ELEMENTARY OS

    • OPENSUSE

BASIC COMMANDS:

1)pwd – Present Working Directory

This command is used to know the user’s working directory.

2)ls – short of list

This command is used to know the list of files and child directories in a directory.

Similar:

ls -a : This command is used to show the hidden files named as dotfiles in the directory.

ls -l : This command is used to show the long format information of each folder in a directory like file permissions, owner, time.., etc.

ls -R : This command is used to show all the sub-directories inside a directory.

ls -S : This command is used to show the list of all files sorted by their file size.

3)Cd – Change Directory

This command is used to change the directory. We can go into a directory and can back from that directory using this command.

Similar:

cd ..   : The current working directory is represented with a single dot (.).If two dots (..), one after the other, are representing the previous directory or in other words the directory immediately before the current one.

cd .  : This command will do nothing it will redirect into the same working directory.

You can also navigate to the same directory by using its absolute path:

eg:  cd /home/shivar/Desktop/

If path starts with slash( / ) then it is considering as an absolute path.

Slash (/) is the root directory of all the directories.

4)mv – move (rename) files:

 mv – This command is used to move and rename the files into another file location.

eg: mv [source path] [destination path]

5)touch command:

This command is used to create an empty file.

We can create multiple directories and files with this command.

Eg: touch linux{1..4}.txt

6)mkdir – make a directory

This command is used to create a directory which is an empty folder.

7)Man Command:

This command is used to display the user manual of any command that we can run on the terminal. It is considered as the manual pager.

8)rm command:

This command is used to remove a file or folder .we can also specify the path in this.

Similar:

rm -i : This command is used to remove a file by verifying or confirming it.

rmdir : This command is used to remove an empty directory.

rm -rf : This command is used to delete a directory with the content in it forcibly without asking confirmation.

9)cp command:

This command is used to copy a file from source to destination.

eg : cp [source file] [destination file]

10)history command:

This command is used to see the previous commands run on that machine

Similar:

history -c : This is used to clear the history of executed commands to run on that machine.

11)Chmod – Change mode

This command is used to change modes or change permissions of a file or directory.

eg: Chmod 777 [Filename]

12)chown – Change Owner

This command is used to change the owner of a given file or directory

13)adduser :

This command is used to add a standard user.

eg : #adduser linux

14)deluser:

This command is used to delete the user.

Eg: #deluser linux

15)cat:

This command is used to create a file and add some data to it.

eg : #cat > linux

    ctrl + D

#cat linux [To read file linux]

#cat >> linux[Without overwriting we can add some new data]

#cat > .linux [To create hidden file]

#cat .linux [To read that hidden file]

16)groupadd:

This command is used create a secondary group.

eg: #groupadd linux

17)date command:

    This command is used to show the current date (showing the day of the week, month, time, time zone, year).

 18)Password:

    This command is used to set a password for a User.

        Eg: Password user – Username

  19)Shut Down:

     This command is used to shut down the system.

 20)Reboot:

     This command is used to restart the machine.

21)Ps Aux:

      This Command is used to show running applications on your system.

22)Free-M :

       This command is used to show the Quantity of memory.

23)Sudo Command :

      This command is used to run the command with root.

24)Whoami :

      This command is used to show your login account.

25)Isb_release-a :

This command is used to show information about the distribution.

26)Clear:

This command is used to clear the terminal.

27)Cal:

This command is used to show the calendar.

28)df:

This command is used to show the Disk usage.

29)PowerOff:

This command is used to shut down the system.

Similar:

Poweroff  – -halt : This command is used to halt the machine.

Poweroff  – -reboot : This command is used to reboot the machine.

30)Ifconfig:

This Command is used to show the network interface.

Leave a Reply

Your email address will not be published. Required fields are marked *