Important Linux commands and what they do

The terminal…
An infinite realm of possibilities, knowledge, data and…confusion.

Since you are reading this article I am assuming you too are a beginner in the world of Linux based operating systems.
I as well when I was a newborn didn’t know what the heck was going on when people talked about administrative rights and the difference between nano and leafpad.
And that’s why I’m here to explain some of the in my opinion most important and frequently used terminal commands for Linux based operating systems.
So sit back and enjoy…


To get the most important note first: sudo is a command you should ALWAYS use.
Its basic purpose is to make use of your admin rights, which some if not most commands require you to do.
That way a command using sudo could look like this:

This is a basic command, which will make your Raspberry search for updates.


This command is actually a variation of the apt command.
apt is used to manage packages and files and in command with -get it is used to download packages as shown in the example above, where it is used to download updates.
But it can not only used to get updates but also to download any kind of program or application.

To download programs just add install and the name of the program you want to download.


As you have probably noticed, these are multiple commands that I put in a group together, since they are very similar.
The first few (shutdown/reboot/halt) are used to do what they say – to shutdown or reboot your Pi.
halt is the one that is the least self-explanatory, but it’s basically shutting down your Pi if it doesn’t react anymore.
In a sense, it is the direct power-off button and your last resort before pulling the plug.

start/stop/restart also do exactly what they’re called with the difference that they are used with programs and/or applications.
Just add the path of the application (per default it’s in /etc/init.d/ )


This command is used to edit files and you might remember it from my introduction and ask yourself now: “Well, what is the difference between nano and leafpad now?”
And I’d say: “Good question!”
Because the difference when it comes to funktionality isn’t really great.
Both enable you to edit files, nano is just terminal based, while leafpad makes use of a graphical interface.

I’d reccomend using nano, since it is usable via ssh as shown above and therefore is way more practical than leafpad, which can only be used directly on the Pi.


Okay, this is probably the most confusing of them all just from looking at it, but in reality, it is the MOST basic one of them.
So let me tell you what it does: it displays external devices and where they are connected.
It’s that simple.

You will need these information when using mount.


When you connect external storage devices to your Pi it can automatically mount them, which means that it makes them accessible.
But by default it mounts them to /media/, which might not be perfect for whatever project you are currently working on or it doesn’t automount it and you have to do it manually.

In this example, I mounted an external SSD which was connected at /dev/sda2 to the folder /media/server.

But to tell the truth I more frequently use the opposite command umount to unmount devices.
In this case, you just need the connection path /dev/sda2


Now you’re probably wondering: “How did he create that folder via the terminal?”
And that as well is really simple.

Using mkdir you only have to give the new path and BOOM – its’ done.

Now, this is the end of my little tour through the most important Linux commands.
Have there been any you missed or wanted to know about?
Don’t shy away from the comment box!

And if you need some more advice, I have a post on how to easily start up with Raspberry Pi.

Good luck!


Leave a Reply

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

This site uses Akismet to reduce spam. Learn how your comment data is processed.

By continuing to use the site, you agree to the use of cookies. more information

The cookie settings on this website are set to "allow cookies" to give you the best browsing experience possible. If you continue to use this website without changing your cookie settings or you click "Accept" below then you are consenting to this.