10 Linux commands to get started (Part 2)

10 Linux commands to get started (Part 2)

·

3 min read

In the last blog, we talked about 10 Linux commands that are essential for a new Linux user. We are going to continue that list in this blog too.

locate

The locate command is used to find the location of a file in our system's database.

It is used like this locate filename

All the locations in my system which have a filename folder1 have been shown.

clear

Now is a good time to introduce the clear command as my screen is filled. This command is used to clear the screen to give some breathing space for the user.

Don't worry, our logs are still available at a simple scroll-up but are not visible at the current cursor.

I have scrolled up to show the previous logs.

ln

This command is used to create a link between two files. There are two types of links in Linux: hard links and soft links. The ln command is also very extensive but here we will just be introduced to it.

ps

The ps command is used to view the active processes in the terminal.

man

If someone is a forgetful person like I am then this command is very useful. It helps us get a manual about the command we want to use. It is used as man commandname and it will give the entire manual about the usage of the command.

To get just a simple use of the command and not the entire manual, we can add -f to the command as done above.

apropos

The man command helps us in knowing more about a particular command. But what if we know what we want to do and not the command we should use for that? apropos helps in that situation.

Here, I wanted to know how to add comments so I searched for it using apropos command and it showed me the appropriate commands.

grep

This command is used to find specific strings in a text file. It is used as grep command followed by the string. And it shows where that string is mentioned in the current file.

We can use it with cat command to view a file and see how many times it has a particular string.

echo

The echo command is very simple. It is used to print something in the terminal.

whoami

The "who am I" command shows the username of the current user. It helps in situations when we want to switch users or see which users have admin privileges etc.

cal

This command helps you remember the date. No, literally. It shows the current month's calendar.

In the next blog, we will talk about fun linux commands. Hope you come back and read again! :)