The Basics of Linux Commands

The most important command of them all is wget.

Wget downloads the specified file from the URL.

An example would be:


If you wanted to make a directory, you would use mkdir.


mkdir cows

This will create a directory from the current directory you are in.

If you are in /var/ it would make /var/cows/.

If you want to go into a different directory, you would use cd.


cd cows

The cool thing about directories in Linux, is that you can go back a directory by typing:

cd ../

If you wanted to go back another directory and so forth, you would just add another “../”.

To move a directory, you would use mv.


mv cows ../ (This moves cows into the directory before this.)

To remove a directory, you would use rm.

Example rm -rf (rf forcefully removes it) cows

To add a user, you would use useradd.


useradd me

To change the password, you would use passwd.


me passwd

However, Linux does not show passwords as you are typing them in.

To login as root, you would do sudo root or any other user if you are root already.

To install a package that is in the repository on Ubuntu, you would use apt-get install package name.

To install a package on CentOS, you would use yum install package name.

If you are getting errorson Ubuntu try typing in sudo -i apt-get install.

Or you could just type in sudo -i before that as a standalone command and then use apt-get install.

That’;s about all for the basics of Linux.

I will publish some more tutorials later on…

Thanks for reading!

Related posts:

  • About Author

    Thomas Neal

    Thomas Neal was born and raised in the Bronx, New York. He was a bookseller before shifting to publishing where he worked at a literary development company, a creative writing website for millennials, and as a book reviewer of adult and young adult novels. He lives in New York City and is obviously a voracious reader. He has just released his debut novel and working on his second already!

  • Advertising

  • Advertising