Basic Linux Commands For Linux Terminal Beginners - PCsteps
Basic Linux Commands For Linux Terminal Beginners - PCsteps
Basic Linux Commands For Linux Terminal Beginners - PCsteps
com
Home Software Operating Systems Linux Basic Linux Commands for Linu
Search
68
Facebook Twitter
Print More
SHARES
If you run a Linux distribution, and you are only using the
GUI, you are missing out. The Linux terminal is an
extremely powerful tool that goes well beyond the GUI.
Writing commands might seem scary for a beginner, but
https://www.pcsteps.com/5010-basic-linux-commands-terminal/ 1/19
04/08/2017 Basic Linux Commands for Linux Terminal Beginners | PCsteps.com
you will soon get the hang of it. In this guide, you will find
the most important Linux commands, to use the terminal
like a pro.
S e a r cThe
h basic Linux commands, however, are universal, and
they should work on any past and future distribution.
They will even work with non-Linux operating systems
based on Unix, such as FreeBSD, or the macOS / OS X
terminal.
Important information
about the Linux terminal
There is not a single Linux distribution, as far as we know,
that doesn't have a terminal of some kind. On the
contrary, there are a few distributions that don't have a
GUI by default, and everything is done on the command
line.
environments.
Search
Using sudo will run any command with administrative
rights. Most Linux commands that have to deal with
system files and installation/uninstallation of programs
demand sudo.
Beware of spaces
Spacing is equally important. "chown-R" will only return
an error. If we want to create/access/delete a file or
https://www.pcsteps.com/5010-basic-linux-commands-terminal/ 3/19
04/08/2017 Basic Linux Commands for Linux Terminal Beginners | PCsteps.com
S e a r c...or
h "escape" the space using the backslash "\".
Search
If there are more than files that begin with the same
letters, e.g. "whydidIgivethisfilesuchalongname" and
https://www.pcsteps.com/5010-basic-linux-commands-terminal/ 5/19
04/08/2017 Basic Linux Commands for Linux Terminal Beginners | PCsteps.com
Search
Wildcards
While using Linux commands, the characters "?" and "*"
are wildcards.
https://www.pcsteps.com/5010-basic-linux-commands-terminal/ 6/19
04/08/2017 Basic Linux Commands for Linux Terminal Beginners | PCsteps.com
Search
"*" will replace any string of characters. "rm test*file" will
delete test1file, test12file, testBLABLABLAfile. It will also
delete any other filename that begins with "test-" and
ends in "-file", including testfile.
https://www.pcsteps.com/5010-basic-linux-commands-terminal/ 7/19
04/08/2017 Basic Linux Commands for Linux Terminal Beginners | PCsteps.com
Search
man [command] will show the command's manual, which
is an extended version of the --help output.
Basic navigation
https://www.pcsteps.com/5010-basic-linux-commands-terminal/ 8/19
04/08/2017 Basic Linux Commands for Linux Terminal Beginners | PCsteps.com
Search
https://www.pcsteps.com/5010-basic-linux-commands-terminal/ 9/19
04/08/2017 Basic Linux Commands for Linux Terminal Beginners | PCsteps.com
Search
".." represents the parent directory, i.e. the directory
that contains the one we currently are. If we are at
/home/test/public and type cd .. it will take us to
/home/test/
In this case, we can use a pipe with the vertical bar "|"
symbol (accessible with "Shift + \" ) and more or less.
https://www.pcsteps.com/5010-basic-linux-commands-terminal/ 10/19
04/08/2017 Basic Linux Commands for Linux Terminal Beginners | PCsteps.com
Search
With locate *.png | less we will still get the first page of
results, but navigate up and down with the arrow keys.
Again, we quit with "q".
https://www.pcsteps.com/5010-basic-linux-commands-terminal/ 11/19
04/08/2017 Basic Linux Commands for Linux Terminal Beginners | PCsteps.com
https://www.pcsteps.com/5010-basic-linux-commands-terminal/ 12/19
04/08/2017 Basic Linux Commands for Linux Terminal Beginners | PCsteps.com
https://www.pcsteps.com/5010-basic-linux-commands-terminal/ 13/19
04/08/2017 Basic Linux Commands for Linux Terminal Beginners | PCsteps.com
Search
File content
Creating and deleting files and directories is fine. But
what if we want to access the file content at the Linux
Terminal?
https://www.pcsteps.com/5010-basic-linux-commands-terminal/ 14/19
04/08/2017 Basic Linux Commands for Linux Terminal Beginners | PCsteps.com
https://www.pcsteps.com/5010-basic-linux-commands-terminal/ 15/19
04/08/2017 Basic Linux Commands for Linux Terminal Beginners | PCsteps.com
sort [text file] - will print the lines of text files sorted.
You can like our Facebook page, share this post with
your friends, and select our affiliate links for your
purchases on Amazon.com or Newegg.
68
Facebook Twitter
Print More
SHARES
https://www.pcsteps.com/5010-basic-linux-commands-terminal/ 16/19
04/08/2017 Basic Linux Commands for Linux Terminal Beginners | PCsteps.com
Category: Linux
Load Comments
Search
Custom Search
Search
https://www.pcsteps.com/5010-basic-linux-commands-terminal/ 18/19
04/08/2017 Basic Linux Commands for Linux Terminal Beginners | PCsteps.com
Search
Search
https://www.pcsteps.com/5010-basic-linux-commands-terminal/ 19/19