Answers - HTML: Basic Linux Commands
Answers - HTML: Basic Linux Commands
Answers - HTML: Basic Linux Commands
com/linux-interview-questions-
answers.html
Networking command
Command Description
SSH username@ip-address or
hostname login into a remote Linux machine using SSH
Process command
Command Description
bg To send a process to the background
fg To run a stopped process in the foreground
top Details on all Active Processes
ps Give the status of processes running for a user
ps PID Gives the status of a particular process
pidof Gives the Process ID (PID) of a process
kill PID Kills a process
nice Starts a process with a given priority
renice Changes priority of an already running process
df Gives free hard disk space on your system
free Gives free RAM on your system
VI Editing Commands
Command Description
i Insert at cursor (goes into insert mode)
Command Description
a Write after cursor (goes into insert mode)
A Write at the end of line (goes into insert mode)
ESC Terminate insert mode
u Undo last change
U Undo all changes to the entire line
o Open a new line (goes into insert mode)
dd Delete line
3dd Delete 3 lines
D Delete contents of line after the cursor
C Delete contents of a line after the cursor and
insert new text. Press ESC key to end insertion.
dw Delete word
4dw Delete 4 words
cw Change word
x Delete character at the cursor
r Replace character
R Overwrite characters from cursor onward
s Substitute one character under cursor continue to
insert
S Substitute entire line and begin to insert at the
beginning of the line
~ Change case of individual character
Hope this Linux reference guide helps you!