SlideShare a Scribd company logo
Introduction to Linux-2
DevOps Essentials
2020
Linux Command Basics
 Linux commands are case-sensitive; ls is not the same as LS
 Linux commands may allow for arguments:
 $ ls /tmp
 You can run more than one command on the same line by separating
the commands with a semicolon (;)
 $ ls;date
 Most Linux commands have a manual page or help to describe how
they can be used in details.
 $ man ls
Top 50 commands
pwd Print current working directory
ls List the contents of a particular directory and files.
cd Short for Change Directory, the cd command is behind your movement from one directory to
another.
mkdir Lets you create folders anywhere you like in your Linux system.
rmdir Remove or delete directory or folder.
lsblk List the available block devices of your Linux system.
mount Mount existing filesystem which are not being used.
df Display essential information about the disk space on your filesystem.
ps Visualize processes currently running on your machine.
kill Kill a stuck process or in some cases used to stop application.
touch Creating a valid empty file.
cat Create new files, view file contents in the terminal, and redirect output to another command-
line tool or file.
head View the beginning of a file or piped data directly from the terminal.
cp Copy a file or directory from one folder to another.
mv Move files or directories, same as cut+paste.
comm Compare two files for common and distinct lines.
ln Commands for creating symbolic links to some specific file.
history Print out the bash history of your terminal session
wget Download files from the web right from the terminal.
curl Make request to a web URL. Used for querying web services.
find To search for files based on certain criteria such as file permissions, ownership, modification
date, size, etc.
which Search are executable files in the $PATH system environment variable.
echo Lets you output a specific text to the terminal console.
sort Sort out a file in an alphabetical or reverse manner.
Top 50 commands contd...
man Manual or documentation page of a command, when that command is passed as a parameter.
tar The tar command is used for archiving files and extracting them.
printenv Display shell variables.
sleep Pause command execution.
vi/vim Text editor.
wc Print number of lines, words or characters.
diff Compare files line by line.
less Scroll forward or back through a file.
netstat Check connections on server ports (LISTEN/WAIT/ACK/FIN)
chown Change ownership of a file/directory.
awk Allows manipulation of text.
tail View end of the file.
grep Searching for patterns inside large volumes of text files.
sed Commands to manipulate each line of a file or stream by replacing specified parts.
cut Extract a portion of a file using columns and delimiters.
whoami Displays username.
export Export environment variables.
free Check memory usage.
top Monitor CPU, Memory and I/O usage.
rm Delete files.
date Set/ get the system date.
nohup Send process to foreground..
uniq Filtering out the duplicate line in a file.
useradd Create/ add user.
usermod Modify user home directory, shell, groups and other properties.
Lab 1
1. Display your current directory.
2. Change to the /etc directory.
3. Now change to your home directory using only three key presses.
4. Change to the /boot/grub directory using only eleven key presses.
5. Go to the parent directory of the current directory.
6. Go to the root directory.
7. List the contents of the root directory.
8. List a long listing of the root directory.
9. Stay where you are, and list the contents of /etc.
10. Stay where you are, and list the contents of /bin and /sbin.
11. Stay where you are, and list the contents of ~.
12. List all the files (including hidden files) in your home directory.
13. List the files in /boot in a human readable format.
14. Create a directory testdir in your home directory.
15. Change to the /etc directory, stay here and create a directory newdir in your home
directory.
16. Create in one command the directories ~/dir1/dir2/dir3 (dir3 is a subdirectory
from dir2, and dir2 is a subdirectory from dir1 ).
17. Remove the directory testdir.
Ad

More Related Content

What's hot (20)

Linux commands
Linux commandsLinux commands
Linux commands
penetration Tester
 
Important Linux Commands
Important Linux CommandsImportant Linux Commands
Important Linux Commands
Arun Sharma
 
Basics of Linux
Basics of LinuxBasics of Linux
Basics of Linux
SaifUrRahman180
 
BASIC COMMANDS OF LINUX
BASIC COMMANDS OF LINUXBASIC COMMANDS OF LINUX
BASIC COMMANDS OF LINUX
Mr.AKHILESH KUMAR {Computer Lab Technician}
 
Linux basic commands
Linux basic commandsLinux basic commands
Linux basic commands
MohanKumar Palanichamy
 
Lesson 1 Linux System Fundamentals
Lesson 1 Linux System Fundamentals  Lesson 1 Linux System Fundamentals
Lesson 1 Linux System Fundamentals
Sadia Bashir
 
Directory Commands - R.D.Sivakumar
Directory Commands - R.D.SivakumarDirectory Commands - R.D.Sivakumar
Directory Commands - R.D.Sivakumar
Sivakumar R D .
 
Unix slideshare
Unix slideshareUnix slideshare
Unix slideshare
Mohan Krishna Kona
 
Linux Getting Started
Linux Getting StartedLinux Getting Started
Linux Getting Started
Angus Li
 
Linux basic
Linux basicLinux basic
Linux basic
Pragyagupta37
 
Linux commands
Linux commandsLinux commands
Linux commands
Ajaigururaj R
 
Basic linux commands for bioinformatics
Basic linux commands for bioinformaticsBasic linux commands for bioinformatics
Basic linux commands for bioinformatics
Bonnie Ng
 
Common linux ubuntu commands overview
Common linux  ubuntu commands overviewCommon linux  ubuntu commands overview
Common linux ubuntu commands overview
Ameer Sameer
 
Lesson 3 Working with Files in Linux
Lesson 3 Working with Files in LinuxLesson 3 Working with Files in Linux
Lesson 3 Working with Files in Linux
Sadia Bashir
 
Basic linux commands
Basic linux commandsBasic linux commands
Basic linux commands
Harikrishnan Ramakrishnan
 
Anandha ganesh linux1.ppt
Anandha ganesh linux1.pptAnandha ganesh linux1.ppt
Anandha ganesh linux1.ppt
anandha ganesh
 
Basic commands
Basic commandsBasic commands
Basic commands
ambilivava
 
Linux day 2.ppt
Linux day  2.pptLinux day  2.ppt
Linux day 2.ppt
Kalkey
 
Basic 50 linus command
Basic 50 linus commandBasic 50 linus command
Basic 50 linus command
MAGNA COLLEGE OF ENGINEERING
 
Linux commands
Linux commands Linux commands
Linux commands
debashis rout
 

Similar to Introduction to linux day1 (20)

Applecmdlista zs
Applecmdlista zsApplecmdlista zs
Applecmdlista zs
Ben Pope
 
Kali Linux Commands PDF-converted.pdf
Kali Linux Commands PDF-converted.pdfKali Linux Commands PDF-converted.pdf
Kali Linux Commands PDF-converted.pdf
Casa Vista Properties
 
Kali linux commands
Kali linux commandsKali linux commands
Kali linux commands
Jubair Ahmed Junjun
 
linux-lecture4.ppt
linux-lecture4.pptlinux-lecture4.ppt
linux-lecture4.ppt
LuigysToro
 
linux-lecture4.pptuyhbjhbiibihbiuhbbihbi
linux-lecture4.pptuyhbjhbiibihbiuhbbihbilinux-lecture4.pptuyhbjhbiibihbiuhbbihbi
linux-lecture4.pptuyhbjhbiibihbiuhbbihbi
YajnadattaPattanayak
 
Nguyễn Vũ Hưng: Basic Linux Power Tools
Nguyễn Vũ Hưng: Basic Linux Power Tools Nguyễn Vũ Hưng: Basic Linux Power Tools
Nguyễn Vũ Hưng: Basic Linux Power Tools
Vu Hung Nguyen
 
Linux ppt
Linux pptLinux ppt
Linux ppt
Sanmuga Nathan
 
KALI-LINUX-COMMANDS.pdf.................
KALI-LINUX-COMMANDS.pdf.................KALI-LINUX-COMMANDS.pdf.................
KALI-LINUX-COMMANDS.pdf.................
salmannawaz6566504
 
Shell_Scripting.ppt
Shell_Scripting.pptShell_Scripting.ppt
Shell_Scripting.ppt
KiranMantri
 
TERMINAL COMMANDS IN LINUX TERMINAL USED TO INTERACT WITH SYSTEM
TERMINAL COMMANDS IN LINUX TERMINAL USED TO INTERACT WITH SYSTEMTERMINAL COMMANDS IN LINUX TERMINAL USED TO INTERACT WITH SYSTEM
TERMINAL COMMANDS IN LINUX TERMINAL USED TO INTERACT WITH SYSTEM
pssafvan97
 
linux-file-system01.ppt
linux-file-system01.pptlinux-file-system01.ppt
linux-file-system01.ppt
MeesanRaza
 
Quick guide of the most common linux commands
Quick guide of the most common linux commandsQuick guide of the most common linux commands
Quick guide of the most common linux commands
Carlos Enrique
 
Red hat linux essentials
Red hat linux essentialsRed hat linux essentials
Red hat linux essentials
Haitham Raik
 
Linux Introduction (Commands)
Linux Introduction (Commands)Linux Introduction (Commands)
Linux Introduction (Commands)
anandvaidya
 
Linux introduction-commands2338
Linux introduction-commands2338Linux introduction-commands2338
Linux introduction-commands2338
Cam YP Co., Ltd
 
Linux introduction-commands2338
Linux introduction-commands2338Linux introduction-commands2338
Linux introduction-commands2338
Cam YP Co., Ltd
 
An a z index of the bash commands
An a z index of the bash commandsAn a z index of the bash commands
An a z index of the bash commands
Ben Pope
 
managing-the-linux-file-system_suse_.ppt
managing-the-linux-file-system_suse_.pptmanaging-the-linux-file-system_suse_.ppt
managing-the-linux-file-system_suse_.ppt
submarinoaguadulce1
 
managing-the-linux-file-system________________________
managing-the-linux-file-system________________________managing-the-linux-file-system________________________
managing-the-linux-file-system________________________
saurabhbquest
 
Comenzi unix
Comenzi unixComenzi unix
Comenzi unix
Valentin Valentin
 
Applecmdlista zs
Applecmdlista zsApplecmdlista zs
Applecmdlista zs
Ben Pope
 
Kali Linux Commands PDF-converted.pdf
Kali Linux Commands PDF-converted.pdfKali Linux Commands PDF-converted.pdf
Kali Linux Commands PDF-converted.pdf
Casa Vista Properties
 
linux-lecture4.ppt
linux-lecture4.pptlinux-lecture4.ppt
linux-lecture4.ppt
LuigysToro
 
linux-lecture4.pptuyhbjhbiibihbiuhbbihbi
linux-lecture4.pptuyhbjhbiibihbiuhbbihbilinux-lecture4.pptuyhbjhbiibihbiuhbbihbi
linux-lecture4.pptuyhbjhbiibihbiuhbbihbi
YajnadattaPattanayak
 
Nguyễn Vũ Hưng: Basic Linux Power Tools
Nguyễn Vũ Hưng: Basic Linux Power Tools Nguyễn Vũ Hưng: Basic Linux Power Tools
Nguyễn Vũ Hưng: Basic Linux Power Tools
Vu Hung Nguyen
 
KALI-LINUX-COMMANDS.pdf.................
KALI-LINUX-COMMANDS.pdf.................KALI-LINUX-COMMANDS.pdf.................
KALI-LINUX-COMMANDS.pdf.................
salmannawaz6566504
 
Shell_Scripting.ppt
Shell_Scripting.pptShell_Scripting.ppt
Shell_Scripting.ppt
KiranMantri
 
TERMINAL COMMANDS IN LINUX TERMINAL USED TO INTERACT WITH SYSTEM
TERMINAL COMMANDS IN LINUX TERMINAL USED TO INTERACT WITH SYSTEMTERMINAL COMMANDS IN LINUX TERMINAL USED TO INTERACT WITH SYSTEM
TERMINAL COMMANDS IN LINUX TERMINAL USED TO INTERACT WITH SYSTEM
pssafvan97
 
linux-file-system01.ppt
linux-file-system01.pptlinux-file-system01.ppt
linux-file-system01.ppt
MeesanRaza
 
Quick guide of the most common linux commands
Quick guide of the most common linux commandsQuick guide of the most common linux commands
Quick guide of the most common linux commands
Carlos Enrique
 
Red hat linux essentials
Red hat linux essentialsRed hat linux essentials
Red hat linux essentials
Haitham Raik
 
Linux Introduction (Commands)
Linux Introduction (Commands)Linux Introduction (Commands)
Linux Introduction (Commands)
anandvaidya
 
Linux introduction-commands2338
Linux introduction-commands2338Linux introduction-commands2338
Linux introduction-commands2338
Cam YP Co., Ltd
 
Linux introduction-commands2338
Linux introduction-commands2338Linux introduction-commands2338
Linux introduction-commands2338
Cam YP Co., Ltd
 
An a z index of the bash commands
An a z index of the bash commandsAn a z index of the bash commands
An a z index of the bash commands
Ben Pope
 
managing-the-linux-file-system_suse_.ppt
managing-the-linux-file-system_suse_.pptmanaging-the-linux-file-system_suse_.ppt
managing-the-linux-file-system_suse_.ppt
submarinoaguadulce1
 
managing-the-linux-file-system________________________
managing-the-linux-file-system________________________managing-the-linux-file-system________________________
managing-the-linux-file-system________________________
saurabhbquest
 
Ad

Recently uploaded (20)

Structural Response of Reinforced Self-Compacting Concrete Deep Beam Using Fi...
Structural Response of Reinforced Self-Compacting Concrete Deep Beam Using Fi...Structural Response of Reinforced Self-Compacting Concrete Deep Beam Using Fi...
Structural Response of Reinforced Self-Compacting Concrete Deep Beam Using Fi...
Journal of Soft Computing in Civil Engineering
 
QA/QC Manager (Quality management Expert)
QA/QC Manager (Quality management Expert)QA/QC Manager (Quality management Expert)
QA/QC Manager (Quality management Expert)
rccbatchplant
 
"Boiler Feed Pump (BFP): Working, Applications, Advantages, and Limitations E...
"Boiler Feed Pump (BFP): Working, Applications, Advantages, and Limitations E..."Boiler Feed Pump (BFP): Working, Applications, Advantages, and Limitations E...
"Boiler Feed Pump (BFP): Working, Applications, Advantages, and Limitations E...
Infopitaara
 
some basics electrical and electronics knowledge
some basics electrical and electronics knowledgesome basics electrical and electronics knowledge
some basics electrical and electronics knowledge
nguyentrungdo88
 
Mathematical foundation machine learning.pdf
Mathematical foundation machine learning.pdfMathematical foundation machine learning.pdf
Mathematical foundation machine learning.pdf
TalhaShahid49
 
Raish Khanji GTU 8th sem Internship Report.pdf
Raish Khanji GTU 8th sem Internship Report.pdfRaish Khanji GTU 8th sem Internship Report.pdf
Raish Khanji GTU 8th sem Internship Report.pdf
RaishKhanji
 
new ppt artificial intelligence historyyy
new ppt artificial intelligence historyyynew ppt artificial intelligence historyyy
new ppt artificial intelligence historyyy
PianoPianist
 
Compiler Design Unit1 PPT Phases of Compiler.pptx
Compiler Design Unit1 PPT Phases of Compiler.pptxCompiler Design Unit1 PPT Phases of Compiler.pptx
Compiler Design Unit1 PPT Phases of Compiler.pptx
RushaliDeshmukh2
 
DATA-DRIVEN SHOULDER INVERSE KINEMATICS YoungBeom Kim1 , Byung-Ha Park1 , Kwa...
DATA-DRIVEN SHOULDER INVERSE KINEMATICS YoungBeom Kim1 , Byung-Ha Park1 , Kwa...DATA-DRIVEN SHOULDER INVERSE KINEMATICS YoungBeom Kim1 , Byung-Ha Park1 , Kwa...
DATA-DRIVEN SHOULDER INVERSE KINEMATICS YoungBeom Kim1 , Byung-Ha Park1 , Kwa...
charlesdick1345
 
Introduction to Zoomlion Earthmoving.pptx
Introduction to Zoomlion Earthmoving.pptxIntroduction to Zoomlion Earthmoving.pptx
Introduction to Zoomlion Earthmoving.pptx
AS1920
 
Process Parameter Optimization for Minimizing Springback in Cold Drawing Proc...
Process Parameter Optimization for Minimizing Springback in Cold Drawing Proc...Process Parameter Optimization for Minimizing Springback in Cold Drawing Proc...
Process Parameter Optimization for Minimizing Springback in Cold Drawing Proc...
Journal of Soft Computing in Civil Engineering
 
Oil-gas_Unconventional oil and gass_reseviours.pdf
Oil-gas_Unconventional oil and gass_reseviours.pdfOil-gas_Unconventional oil and gass_reseviours.pdf
Oil-gas_Unconventional oil and gass_reseviours.pdf
M7md3li2
 
211421893-M-Tech-CIVIL-Structural-Engineering-pdf.pdf
211421893-M-Tech-CIVIL-Structural-Engineering-pdf.pdf211421893-M-Tech-CIVIL-Structural-Engineering-pdf.pdf
211421893-M-Tech-CIVIL-Structural-Engineering-pdf.pdf
inmishra17121973
 
ELectronics Boards & Product Testing_Shiju.pdf
ELectronics Boards & Product Testing_Shiju.pdfELectronics Boards & Product Testing_Shiju.pdf
ELectronics Boards & Product Testing_Shiju.pdf
Shiju Jacob
 
AI-assisted Software Testing (3-hours tutorial)
AI-assisted Software Testing (3-hours tutorial)AI-assisted Software Testing (3-hours tutorial)
AI-assisted Software Testing (3-hours tutorial)
Vəhid Gəruslu
 
Introduction to FLUID MECHANICS & KINEMATICS
Introduction to FLUID MECHANICS &  KINEMATICSIntroduction to FLUID MECHANICS &  KINEMATICS
Introduction to FLUID MECHANICS & KINEMATICS
narayanaswamygdas
 
theory-slides-for react for beginners.pptx
theory-slides-for react for beginners.pptxtheory-slides-for react for beginners.pptx
theory-slides-for react for beginners.pptx
sanchezvanessa7896
 
RICS Membership-(The Royal Institution of Chartered Surveyors).pdf
RICS Membership-(The Royal Institution of Chartered Surveyors).pdfRICS Membership-(The Royal Institution of Chartered Surveyors).pdf
RICS Membership-(The Royal Institution of Chartered Surveyors).pdf
MohamedAbdelkader115
 
π0.5: a Vision-Language-Action Model with Open-World Generalization
π0.5: a Vision-Language-Action Model with Open-World Generalizationπ0.5: a Vision-Language-Action Model with Open-World Generalization
π0.5: a Vision-Language-Action Model with Open-World Generalization
NABLAS株式会社
 
Smart Storage Solutions.pptx for production engineering
Smart Storage Solutions.pptx for production engineeringSmart Storage Solutions.pptx for production engineering
Smart Storage Solutions.pptx for production engineering
rushikeshnavghare94
 
QA/QC Manager (Quality management Expert)
QA/QC Manager (Quality management Expert)QA/QC Manager (Quality management Expert)
QA/QC Manager (Quality management Expert)
rccbatchplant
 
"Boiler Feed Pump (BFP): Working, Applications, Advantages, and Limitations E...
"Boiler Feed Pump (BFP): Working, Applications, Advantages, and Limitations E..."Boiler Feed Pump (BFP): Working, Applications, Advantages, and Limitations E...
"Boiler Feed Pump (BFP): Working, Applications, Advantages, and Limitations E...
Infopitaara
 
some basics electrical and electronics knowledge
some basics electrical and electronics knowledgesome basics electrical and electronics knowledge
some basics electrical and electronics knowledge
nguyentrungdo88
 
Mathematical foundation machine learning.pdf
Mathematical foundation machine learning.pdfMathematical foundation machine learning.pdf
Mathematical foundation machine learning.pdf
TalhaShahid49
 
Raish Khanji GTU 8th sem Internship Report.pdf
Raish Khanji GTU 8th sem Internship Report.pdfRaish Khanji GTU 8th sem Internship Report.pdf
Raish Khanji GTU 8th sem Internship Report.pdf
RaishKhanji
 
new ppt artificial intelligence historyyy
new ppt artificial intelligence historyyynew ppt artificial intelligence historyyy
new ppt artificial intelligence historyyy
PianoPianist
 
Compiler Design Unit1 PPT Phases of Compiler.pptx
Compiler Design Unit1 PPT Phases of Compiler.pptxCompiler Design Unit1 PPT Phases of Compiler.pptx
Compiler Design Unit1 PPT Phases of Compiler.pptx
RushaliDeshmukh2
 
DATA-DRIVEN SHOULDER INVERSE KINEMATICS YoungBeom Kim1 , Byung-Ha Park1 , Kwa...
DATA-DRIVEN SHOULDER INVERSE KINEMATICS YoungBeom Kim1 , Byung-Ha Park1 , Kwa...DATA-DRIVEN SHOULDER INVERSE KINEMATICS YoungBeom Kim1 , Byung-Ha Park1 , Kwa...
DATA-DRIVEN SHOULDER INVERSE KINEMATICS YoungBeom Kim1 , Byung-Ha Park1 , Kwa...
charlesdick1345
 
Introduction to Zoomlion Earthmoving.pptx
Introduction to Zoomlion Earthmoving.pptxIntroduction to Zoomlion Earthmoving.pptx
Introduction to Zoomlion Earthmoving.pptx
AS1920
 
Oil-gas_Unconventional oil and gass_reseviours.pdf
Oil-gas_Unconventional oil and gass_reseviours.pdfOil-gas_Unconventional oil and gass_reseviours.pdf
Oil-gas_Unconventional oil and gass_reseviours.pdf
M7md3li2
 
211421893-M-Tech-CIVIL-Structural-Engineering-pdf.pdf
211421893-M-Tech-CIVIL-Structural-Engineering-pdf.pdf211421893-M-Tech-CIVIL-Structural-Engineering-pdf.pdf
211421893-M-Tech-CIVIL-Structural-Engineering-pdf.pdf
inmishra17121973
 
ELectronics Boards & Product Testing_Shiju.pdf
ELectronics Boards & Product Testing_Shiju.pdfELectronics Boards & Product Testing_Shiju.pdf
ELectronics Boards & Product Testing_Shiju.pdf
Shiju Jacob
 
AI-assisted Software Testing (3-hours tutorial)
AI-assisted Software Testing (3-hours tutorial)AI-assisted Software Testing (3-hours tutorial)
AI-assisted Software Testing (3-hours tutorial)
Vəhid Gəruslu
 
Introduction to FLUID MECHANICS & KINEMATICS
Introduction to FLUID MECHANICS &  KINEMATICSIntroduction to FLUID MECHANICS &  KINEMATICS
Introduction to FLUID MECHANICS & KINEMATICS
narayanaswamygdas
 
theory-slides-for react for beginners.pptx
theory-slides-for react for beginners.pptxtheory-slides-for react for beginners.pptx
theory-slides-for react for beginners.pptx
sanchezvanessa7896
 
RICS Membership-(The Royal Institution of Chartered Surveyors).pdf
RICS Membership-(The Royal Institution of Chartered Surveyors).pdfRICS Membership-(The Royal Institution of Chartered Surveyors).pdf
RICS Membership-(The Royal Institution of Chartered Surveyors).pdf
MohamedAbdelkader115
 
π0.5: a Vision-Language-Action Model with Open-World Generalization
π0.5: a Vision-Language-Action Model with Open-World Generalizationπ0.5: a Vision-Language-Action Model with Open-World Generalization
π0.5: a Vision-Language-Action Model with Open-World Generalization
NABLAS株式会社
 
Smart Storage Solutions.pptx for production engineering
Smart Storage Solutions.pptx for production engineeringSmart Storage Solutions.pptx for production engineering
Smart Storage Solutions.pptx for production engineering
rushikeshnavghare94
 
Ad

Introduction to linux day1

  • 2. Linux Command Basics  Linux commands are case-sensitive; ls is not the same as LS  Linux commands may allow for arguments:  $ ls /tmp  You can run more than one command on the same line by separating the commands with a semicolon (;)  $ ls;date  Most Linux commands have a manual page or help to describe how they can be used in details.  $ man ls
  • 3. Top 50 commands pwd Print current working directory ls List the contents of a particular directory and files. cd Short for Change Directory, the cd command is behind your movement from one directory to another. mkdir Lets you create folders anywhere you like in your Linux system. rmdir Remove or delete directory or folder. lsblk List the available block devices of your Linux system. mount Mount existing filesystem which are not being used. df Display essential information about the disk space on your filesystem. ps Visualize processes currently running on your machine. kill Kill a stuck process or in some cases used to stop application. touch Creating a valid empty file. cat Create new files, view file contents in the terminal, and redirect output to another command- line tool or file. head View the beginning of a file or piped data directly from the terminal. cp Copy a file or directory from one folder to another. mv Move files or directories, same as cut+paste. comm Compare two files for common and distinct lines. ln Commands for creating symbolic links to some specific file. history Print out the bash history of your terminal session wget Download files from the web right from the terminal. curl Make request to a web URL. Used for querying web services. find To search for files based on certain criteria such as file permissions, ownership, modification date, size, etc. which Search are executable files in the $PATH system environment variable. echo Lets you output a specific text to the terminal console. sort Sort out a file in an alphabetical or reverse manner.
  • 4. Top 50 commands contd... man Manual or documentation page of a command, when that command is passed as a parameter. tar The tar command is used for archiving files and extracting them. printenv Display shell variables. sleep Pause command execution. vi/vim Text editor. wc Print number of lines, words or characters. diff Compare files line by line. less Scroll forward or back through a file. netstat Check connections on server ports (LISTEN/WAIT/ACK/FIN) chown Change ownership of a file/directory. awk Allows manipulation of text. tail View end of the file. grep Searching for patterns inside large volumes of text files. sed Commands to manipulate each line of a file or stream by replacing specified parts. cut Extract a portion of a file using columns and delimiters. whoami Displays username. export Export environment variables. free Check memory usage. top Monitor CPU, Memory and I/O usage. rm Delete files. date Set/ get the system date. nohup Send process to foreground.. uniq Filtering out the duplicate line in a file. useradd Create/ add user. usermod Modify user home directory, shell, groups and other properties.
  • 5. Lab 1 1. Display your current directory. 2. Change to the /etc directory. 3. Now change to your home directory using only three key presses. 4. Change to the /boot/grub directory using only eleven key presses. 5. Go to the parent directory of the current directory. 6. Go to the root directory. 7. List the contents of the root directory. 8. List a long listing of the root directory. 9. Stay where you are, and list the contents of /etc. 10. Stay where you are, and list the contents of /bin and /sbin. 11. Stay where you are, and list the contents of ~. 12. List all the files (including hidden files) in your home directory. 13. List the files in /boot in a human readable format. 14. Create a directory testdir in your home directory. 15. Change to the /etc directory, stay here and create a directory newdir in your home directory. 16. Create in one command the directories ~/dir1/dir2/dir3 (dir3 is a subdirectory from dir2, and dir2 is a subdirectory from dir1 ). 17. Remove the directory testdir.