Basic To – Know commands In Linux

by Dan

 Linux is one of the favorite OS of many and particularly if you are or wanna become a core programmer and test your every single piece of code then these Linux OS’s offer a great platform.

And one more thing that i personally feel i can use any software any compiler and a sense of freedom and liberty, which i hope Windows or Mac do not offer.

If you want to show off!!! Than just Open a terminal and type a command for Update , it seems like that you are doing some really great task!(Just kidding)

Using a Linux system is easy if you have some basic knowledge about the UNIX command.

Here is the list of command that i find it worth learning of using OS with comfort.

If you are new to using the terminal i prefer you start with the “man” command, Ex

man man : will bring up the manual entry for the man command, where man is manual.

su : Super User rights from within the terminal

sudo : Super user run this command

ls : List directory contents

cd : Change directory.

cd /dirname : Jump change to directory or folder.

apt-get install : Gets app from web and installs

apt-get update : Updates the database from the repositories.

reboot : Reboots system

halt : Turn off the system.

exit : Exits from terminal or moves back a user level

cp oldfilename newfilename : Copies a file from oldfile to newfile.

mv oldfile newfile : Will overwrite the oldfile with the newfile

rm filename : Is used to delete files.

rm -R filename :To remove a directory, you must use the -R option

lsb_release -a: The lsb_release command with the -a option prints version information for the Linux release you’re running

date : Prints the date and time of the system.

cal : Prints the calender.

Pwd : Prints the current working directory.

If you are planning to go a step ahead. Then you might consider learning shell scripting.

Open a text file and write the script that you want to run and make it executable so that when ever you execute that command you will the whole process written in the text file executes.

In UBUNTU for example consider you want to open a terminal from one terminal through terminal from the written script. Then in a text file write the following code



echo “new terminal has been opened”

Once you have done save it with a extension (.sh) and now you will have to make it executable type this command in a terminal

chmod +x


Run it using


Screenshot at 2012-12-23 22:11:00

This is a most simple scripting . Try and learn to become a pro in Linux.

Related Posts