SlideShare a Scribd company logo
2
3. kill pid Kill the process with given pid
4. killall proc Kill all the process named proc
5. pkill pattern Will kill all processes matching the pattern
6. bg List stopped or background jobs,resume a stopped
job in the background
7. fg Brings the most recent job to foreground
8. fg n Brings job n to the foreground
File permission
1. chmod octal file Change the permission of file to octal,which can
be found separately for user,group,world by
adding,
• 4-read(r)
• 2-write(w)
• 1-execute(x)
Searching
1. grep pattern file Search for pattern in file
2. grep -r pattern dir Search recursively for pattern in dir
3. command | grep
pattern
Search pattern in the output of a command
4. locate file Find all instances of file
5. find . -name filename Searches in the current directory (represented by
a period) and below it, for files and directories with
names starting with filename
6. pgrep pattern Searches for all the named processes , that
matches with the pattern and, by default, returns
their ID
System Info
1. date Show the current date and time
2. cal Show this month's calender
3. uptime Show current uptime
4. w Display who is on line
5. whoami Who you are logged in as
Unix/Linux Command Reference
Most read
3
6. finger user Display information about user
7. uname -a Show kernel information
8. cat /proc/cpuinfo Cpu information
9. cat proc/meminfo Memory information
10. man command Show the manual for command
11. df Show the disk usage
12. du Show directory space usage
13. free Show memory and swap usage
14. whereis app Show possible locations of app
15. which app Show which applications will be run by default
Compression
1. tar cf file.tar file Create tar named file.tar containing file
2. tar xf file.tar Extract the files from file.tar
3. tar czf file.tar.gz files Create a tar with Gzip compression
4. tar xzf file.tar.gz Extract a tar using Gzip
5. tar cjf file.tar.bz2 Create tar with Bzip2 compression
6. tar xjf file.tar.bz2 Extract a tar using Bzip2
7. gzip file Compresses file and renames it to file.gz
8. gzip -d file.gz Decompresses file.gz back to file
Network
1. ping host Ping host and output results
2. whois domain Get whois information for domains
3. dig domain Get DNS information for domain
4. dig -x host Reverse lookup host
5. wget file Download file
6. wget -c file Continue a stopped download
Unix/Linux Command Reference
Most read
4
Shortcuts
1. ctrl+c Halts the current command
2. ctrl+z Stops the current command, resume with fg in the
foreground or bg in the background
3. ctrl+d Logout the current session, similar to exit
4. ctrl+w Erases one word in the current line
5. ctrl+u Erases the whole line
6. ctrl+r Type to bring up a recent command
7. !! Repeats the last command
8. exit Logout the current session
Unix/Linux Command Reference
Most read
Unix/Linux Command Reference
File Commands
1. ls Directory listing
2. ls -al Formatted listing with hidden files
3. ls -lt Sorting the Formatted listing by time modification
4. cd dir Change directory to dir
5. cd Change to home directory
6. pwd Show current working directory
7. mkdir dir Creating a directory dir
8. cat >file Places the standard input into the file
9. more file Output the contents of the file
10. head file Output the first 10 lines of the file
11. tail file Output the last 10 lines of the file
12. tail -f file Output the contents of file as it grows,starting with
the last 10 lines
13. touch file Create or update file
14. rm file Deleting the file
15. rm -r dir Deleting the directory
16. rm -f file Force to remove the file
17. rm -rf dir Force to remove the directory dir
18. cp file1 file2 Copy the contents of file1 to file2
19. cp -r dir1 dir2 Copy dir1 to dir2;create dir2 if not present
20. mv file1 file2 Rename or move file1 to file2,if file2 is an existing
directory
21. ln -s file link Create symbolic link link to file
Process management
1. ps To display the currently working processes
2. top Display all running process
Unix/Linux Command Reference
3. kill pid Kill the process with given pid
4. killall proc Kill all the process named proc
5. pkill pattern Will kill all processes matching the pattern
6. bg List stopped or background jobs,resume a stopped
job in the background
7. fg Brings the most recent job to foreground
8. fg n Brings job n to the foreground
File permission
1. chmod octal file Change the permission of file to octal,which can
be found separately for user,group,world by
adding,
• 4-read(r)
• 2-write(w)
• 1-execute(x)
Searching
1. grep pattern file Search for pattern in file
2. grep -r pattern dir Search recursively for pattern in dir
3. command | grep
pattern
Search pattern in the output of a command
4. locate file Find all instances of file
5. find . -name filename Searches in the current directory (represented by
a period) and below it, for files and directories with
names starting with filename
6. pgrep pattern Searches for all the named processes , that
matches with the pattern and, by default, returns
their ID
System Info
1. date Show the current date and time
2. cal Show this month's calender
3. uptime Show current uptime
4. w Display who is on line
5. whoami Who you are logged in as
Unix/Linux Command Reference
6. finger user Display information about user
7. uname -a Show kernel information
8. cat /proc/cpuinfo Cpu information
9. cat proc/meminfo Memory information
10. man command Show the manual for command
11. df Show the disk usage
12. du Show directory space usage
13. free Show memory and swap usage
14. whereis app Show possible locations of app
15. which app Show which applications will be run by default
Compression
1. tar cf file.tar file Create tar named file.tar containing file
2. tar xf file.tar Extract the files from file.tar
3. tar czf file.tar.gz files Create a tar with Gzip compression
4. tar xzf file.tar.gz Extract a tar using Gzip
5. tar cjf file.tar.bz2 Create tar with Bzip2 compression
6. tar xjf file.tar.bz2 Extract a tar using Bzip2
7. gzip file Compresses file and renames it to file.gz
8. gzip -d file.gz Decompresses file.gz back to file
Network
1. ping host Ping host and output results
2. whois domain Get whois information for domains
3. dig domain Get DNS information for domain
4. dig -x host Reverse lookup host
5. wget file Download file
6. wget -c file Continue a stopped download
Unix/Linux Command Reference
Shortcuts
1. ctrl+c Halts the current command
2. ctrl+z Stops the current command, resume with fg in the
foreground or bg in the background
3. ctrl+d Logout the current session, similar to exit
4. ctrl+w Erases one word in the current line
5. ctrl+u Erases the whole line
6. ctrl+r Type to bring up a recent command
7. !! Repeats the last command
8. exit Logout the current session
Unix/Linux Command Reference

More Related Content

Similar to Unix/Linux Command Reference - File Commands and Shortcuts (20)

Linux commands
Linux commandsLinux commands
Linux commands
Shiva Bhardwaj
 
The Linux Command Cheat Sheet
The Linux Command Cheat SheetThe Linux Command Cheat Sheet
The Linux Command Cheat Sheet
Tola LENG
 
Information about linux operating system
Information about linux operating systemInformation about linux operating system
Information about linux operating system
PriyankaMate4
 
Linux commands and file structure
Linux commands and file structureLinux commands and file structure
Linux commands and file structure
Sreenatha Reddy K R
 
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
 
linux-lecture4.ppt
linux-lecture4.pptlinux-lecture4.ppt
linux-lecture4.ppt
LuigysToro
 
Linux presentation
Linux presentationLinux presentation
Linux presentation
Nikhil Jain
 
Basic unix commands_1
Basic unix commands_1Basic unix commands_1
Basic unix commands_1
thakor bharati
 
Unix reference sheet
Unix reference sheetUnix reference sheet
Unix reference sheet
apajadeh
 
Unix Trainning Doc.pptx
Unix Trainning Doc.pptxUnix Trainning Doc.pptx
Unix Trainning Doc.pptx
KalpeshRaut7
 
14.Linux Command
14.Linux Command14.Linux Command
14.Linux Command
Export Promotion Bureau
 
Linux
LinuxLinux
Linux
Rathan Raj
 
BITS: Introduction to Linux - Text manipulation tools for bioinformatics
BITS: Introduction to Linux - Text manipulation tools for bioinformaticsBITS: Introduction to Linux - Text manipulation tools for bioinformatics
BITS: Introduction to Linux - Text manipulation tools for bioinformatics
BITS
 
Commands
CommandsCommands
Commands
damlepramod
 
Linux Commands all presentation file .pptx
Linux Commands all  presentation  file .pptxLinux Commands all  presentation  file .pptx
Linux Commands all presentation file .pptx
AshutoshPrajapati30
 
Linux ppt
Linux pptLinux ppt
Linux ppt
Sanmuga Nathan
 
linux-lecture4.pptuyhbjhbiibihbiuhbbihbi
linux-lecture4.pptuyhbjhbiibihbiuhbbihbilinux-lecture4.pptuyhbjhbiibihbiuhbbihbi
linux-lecture4.pptuyhbjhbiibihbiuhbbihbi
YajnadattaPattanayak
 
Introduction to linux day1
Introduction to linux day1Introduction to linux day1
Introduction to linux day1
UtpalenduChakrobortt1
 
40 important command for linux
40 important command for linux40 important command for linux
40 important command for linux
Md Abdullah Al Mamun
 
Linux Presentation
Linux PresentationLinux Presentation
Linux Presentation
nishantsri
 
The Linux Command Cheat Sheet
The Linux Command Cheat SheetThe Linux Command Cheat Sheet
The Linux Command Cheat Sheet
Tola LENG
 
Information about linux operating system
Information about linux operating systemInformation about linux operating system
Information about linux operating system
PriyankaMate4
 
Linux commands and file structure
Linux commands and file structureLinux commands and file structure
Linux commands and file structure
Sreenatha Reddy K R
 
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
 
linux-lecture4.ppt
linux-lecture4.pptlinux-lecture4.ppt
linux-lecture4.ppt
LuigysToro
 
Linux presentation
Linux presentationLinux presentation
Linux presentation
Nikhil Jain
 
Unix reference sheet
Unix reference sheetUnix reference sheet
Unix reference sheet
apajadeh
 
Unix Trainning Doc.pptx
Unix Trainning Doc.pptxUnix Trainning Doc.pptx
Unix Trainning Doc.pptx
KalpeshRaut7
 
BITS: Introduction to Linux - Text manipulation tools for bioinformatics
BITS: Introduction to Linux - Text manipulation tools for bioinformaticsBITS: Introduction to Linux - Text manipulation tools for bioinformatics
BITS: Introduction to Linux - Text manipulation tools for bioinformatics
BITS
 
Linux Commands all presentation file .pptx
Linux Commands all  presentation  file .pptxLinux Commands all  presentation  file .pptx
Linux Commands all presentation file .pptx
AshutoshPrajapati30
 
linux-lecture4.pptuyhbjhbiibihbiuhbbihbi
linux-lecture4.pptuyhbjhbiibihbiuhbbihbilinux-lecture4.pptuyhbjhbiibihbiuhbbihbi
linux-lecture4.pptuyhbjhbiibihbiuhbbihbi
YajnadattaPattanayak
 
Linux Presentation
Linux PresentationLinux Presentation
Linux Presentation
nishantsri
 

More from Jason J Pulikkottil (20)

Introduction to PERL Programming - Complete Notes
Introduction to PERL Programming - Complete NotesIntroduction to PERL Programming - Complete Notes
Introduction to PERL Programming - Complete Notes
Jason J Pulikkottil
 
VLSI System Verilog Notes with Coding Examples
VLSI System Verilog Notes with Coding ExamplesVLSI System Verilog Notes with Coding Examples
VLSI System Verilog Notes with Coding Examples
Jason J Pulikkottil
 
VLSI Physical Design Physical Design Concepts
VLSI Physical Design Physical Design ConceptsVLSI Physical Design Physical Design Concepts
VLSI Physical Design Physical Design Concepts
Jason J Pulikkottil
 
Verilog Coding examples of Digital Circuits
Verilog Coding examples of Digital CircuitsVerilog Coding examples of Digital Circuits
Verilog Coding examples of Digital Circuits
Jason J Pulikkottil
 
Floor Plan, Placement Questions and Answers
Floor Plan, Placement Questions and AnswersFloor Plan, Placement Questions and Answers
Floor Plan, Placement Questions and Answers
Jason J Pulikkottil
 
Physical Design, ASIC Design, Standard Cells
Physical Design, ASIC Design, Standard CellsPhysical Design, ASIC Design, Standard Cells
Physical Design, ASIC Design, Standard Cells
Jason J Pulikkottil
 
Basic Electronics, Digital Electronics, Static Timing Analysis Notes
Basic Electronics, Digital Electronics, Static Timing Analysis NotesBasic Electronics, Digital Electronics, Static Timing Analysis Notes
Basic Electronics, Digital Electronics, Static Timing Analysis Notes
Jason J Pulikkottil
 
Floorplan, Powerplan and Data Setup, Stages
Floorplan, Powerplan and Data Setup, StagesFloorplan, Powerplan and Data Setup, Stages
Floorplan, Powerplan and Data Setup, Stages
Jason J Pulikkottil
 
Floorplanning Power Planning and Placement
Floorplanning Power Planning and PlacementFloorplanning Power Planning and Placement
Floorplanning Power Planning and Placement
Jason J Pulikkottil
 
Digital Electronics Questions and Answers
Digital Electronics Questions and AnswersDigital Electronics Questions and Answers
Digital Electronics Questions and Answers
Jason J Pulikkottil
 
Different Types Of Cells, Types of Standard Cells
Different Types Of Cells, Types of Standard CellsDifferent Types Of Cells, Types of Standard Cells
Different Types Of Cells, Types of Standard Cells
Jason J Pulikkottil
 
DFT Rules, set of rules with illustration
DFT Rules, set of rules with illustrationDFT Rules, set of rules with illustration
DFT Rules, set of rules with illustration
Jason J Pulikkottil
 
Clock Definitions Static Timing Analysis for VLSI Engineers
Clock Definitions Static Timing Analysis for VLSI EngineersClock Definitions Static Timing Analysis for VLSI Engineers
Clock Definitions Static Timing Analysis for VLSI Engineers
Jason J Pulikkottil
 
Basic Synthesis Flow and Commands, Logic Synthesis
Basic Synthesis Flow and Commands, Logic SynthesisBasic Synthesis Flow and Commands, Logic Synthesis
Basic Synthesis Flow and Commands, Logic Synthesis
Jason J Pulikkottil
 
ASIC Design Types, Logical Libraries, Optimization
ASIC Design Types, Logical Libraries, OptimizationASIC Design Types, Logical Libraries, Optimization
ASIC Design Types, Logical Libraries, Optimization
Jason J Pulikkottil
 
Floorplanning and Powerplanning - Definitions and Notes
Floorplanning and Powerplanning - Definitions and NotesFloorplanning and Powerplanning - Definitions and Notes
Floorplanning and Powerplanning - Definitions and Notes
Jason J Pulikkottil
 
Physical Design Flow - Standard Cells and Special Cells
Physical Design Flow - Standard Cells and Special CellsPhysical Design Flow - Standard Cells and Special Cells
Physical Design Flow - Standard Cells and Special Cells
Jason J Pulikkottil
 
Physical Design - Import Design Flow Floorplan
Physical Design - Import Design Flow FloorplanPhysical Design - Import Design Flow Floorplan
Physical Design - Import Design Flow Floorplan
Jason J Pulikkottil
 
Physical Design-Floor Planning Goals And Placement
Physical Design-Floor Planning Goals And PlacementPhysical Design-Floor Planning Goals And Placement
Physical Design-Floor Planning Goals And Placement
Jason J Pulikkottil
 
Short Notes on Verilog and SystemVerilog
Short Notes on Verilog and SystemVerilogShort Notes on Verilog and SystemVerilog
Short Notes on Verilog and SystemVerilog
Jason J Pulikkottil
 
Introduction to PERL Programming - Complete Notes
Introduction to PERL Programming - Complete NotesIntroduction to PERL Programming - Complete Notes
Introduction to PERL Programming - Complete Notes
Jason J Pulikkottil
 
VLSI System Verilog Notes with Coding Examples
VLSI System Verilog Notes with Coding ExamplesVLSI System Verilog Notes with Coding Examples
VLSI System Verilog Notes with Coding Examples
Jason J Pulikkottil
 
VLSI Physical Design Physical Design Concepts
VLSI Physical Design Physical Design ConceptsVLSI Physical Design Physical Design Concepts
VLSI Physical Design Physical Design Concepts
Jason J Pulikkottil
 
Verilog Coding examples of Digital Circuits
Verilog Coding examples of Digital CircuitsVerilog Coding examples of Digital Circuits
Verilog Coding examples of Digital Circuits
Jason J Pulikkottil
 
Floor Plan, Placement Questions and Answers
Floor Plan, Placement Questions and AnswersFloor Plan, Placement Questions and Answers
Floor Plan, Placement Questions and Answers
Jason J Pulikkottil
 
Physical Design, ASIC Design, Standard Cells
Physical Design, ASIC Design, Standard CellsPhysical Design, ASIC Design, Standard Cells
Physical Design, ASIC Design, Standard Cells
Jason J Pulikkottil
 
Basic Electronics, Digital Electronics, Static Timing Analysis Notes
Basic Electronics, Digital Electronics, Static Timing Analysis NotesBasic Electronics, Digital Electronics, Static Timing Analysis Notes
Basic Electronics, Digital Electronics, Static Timing Analysis Notes
Jason J Pulikkottil
 
Floorplan, Powerplan and Data Setup, Stages
Floorplan, Powerplan and Data Setup, StagesFloorplan, Powerplan and Data Setup, Stages
Floorplan, Powerplan and Data Setup, Stages
Jason J Pulikkottil
 
Floorplanning Power Planning and Placement
Floorplanning Power Planning and PlacementFloorplanning Power Planning and Placement
Floorplanning Power Planning and Placement
Jason J Pulikkottil
 
Digital Electronics Questions and Answers
Digital Electronics Questions and AnswersDigital Electronics Questions and Answers
Digital Electronics Questions and Answers
Jason J Pulikkottil
 
Different Types Of Cells, Types of Standard Cells
Different Types Of Cells, Types of Standard CellsDifferent Types Of Cells, Types of Standard Cells
Different Types Of Cells, Types of Standard Cells
Jason J Pulikkottil
 
DFT Rules, set of rules with illustration
DFT Rules, set of rules with illustrationDFT Rules, set of rules with illustration
DFT Rules, set of rules with illustration
Jason J Pulikkottil
 
Clock Definitions Static Timing Analysis for VLSI Engineers
Clock Definitions Static Timing Analysis for VLSI EngineersClock Definitions Static Timing Analysis for VLSI Engineers
Clock Definitions Static Timing Analysis for VLSI Engineers
Jason J Pulikkottil
 
Basic Synthesis Flow and Commands, Logic Synthesis
Basic Synthesis Flow and Commands, Logic SynthesisBasic Synthesis Flow and Commands, Logic Synthesis
Basic Synthesis Flow and Commands, Logic Synthesis
Jason J Pulikkottil
 
ASIC Design Types, Logical Libraries, Optimization
ASIC Design Types, Logical Libraries, OptimizationASIC Design Types, Logical Libraries, Optimization
ASIC Design Types, Logical Libraries, Optimization
Jason J Pulikkottil
 
Floorplanning and Powerplanning - Definitions and Notes
Floorplanning and Powerplanning - Definitions and NotesFloorplanning and Powerplanning - Definitions and Notes
Floorplanning and Powerplanning - Definitions and Notes
Jason J Pulikkottil
 
Physical Design Flow - Standard Cells and Special Cells
Physical Design Flow - Standard Cells and Special CellsPhysical Design Flow - Standard Cells and Special Cells
Physical Design Flow - Standard Cells and Special Cells
Jason J Pulikkottil
 
Physical Design - Import Design Flow Floorplan
Physical Design - Import Design Flow FloorplanPhysical Design - Import Design Flow Floorplan
Physical Design - Import Design Flow Floorplan
Jason J Pulikkottil
 
Physical Design-Floor Planning Goals And Placement
Physical Design-Floor Planning Goals And PlacementPhysical Design-Floor Planning Goals And Placement
Physical Design-Floor Planning Goals And Placement
Jason J Pulikkottil
 
Short Notes on Verilog and SystemVerilog
Short Notes on Verilog and SystemVerilogShort Notes on Verilog and SystemVerilog
Short Notes on Verilog and SystemVerilog
Jason J Pulikkottil
 
Ad

Recently uploaded (20)

First Come First Serve Scheduling in real time operating system.pptx
First Come First Serve Scheduling in real time operating system.pptxFirst Come First Serve Scheduling in real time operating system.pptx
First Come First Serve Scheduling in real time operating system.pptx
KavitaBagewadi2
 
Fundamentals of Digital Design_Class_12th April.pptx
Fundamentals of Digital Design_Class_12th April.pptxFundamentals of Digital Design_Class_12th April.pptx
Fundamentals of Digital Design_Class_12th April.pptx
drdebarshi1993
 
3. What is the principles of Teamwork_Module_V1.0.ppt
3. What is the principles of Teamwork_Module_V1.0.ppt3. What is the principles of Teamwork_Module_V1.0.ppt
3. What is the principles of Teamwork_Module_V1.0.ppt
engaash9
 
Week 6- PC HARDWARE AND MAINTENANCE-THEORY.pptx
Week 6- PC HARDWARE AND MAINTENANCE-THEORY.pptxWeek 6- PC HARDWARE AND MAINTENANCE-THEORY.pptx
Week 6- PC HARDWARE AND MAINTENANCE-THEORY.pptx
dayananda54
 
社内勉強会資料_Chain of Thought .
社内勉強会資料_Chain of Thought                           .社内勉強会資料_Chain of Thought                           .
社内勉強会資料_Chain of Thought .
NABLAS株式会社
 
WIRELESS COMMUNICATION SECURITY AND IT’S PROTECTION METHODS
WIRELESS COMMUNICATION SECURITY AND IT’S PROTECTION METHODSWIRELESS COMMUNICATION SECURITY AND IT’S PROTECTION METHODS
WIRELESS COMMUNICATION SECURITY AND IT’S PROTECTION METHODS
samueljackson3773
 
Development of Portable Biomass Briquetting Machine (S, A & D)-1.pptx
Development of Portable Biomass Briquetting Machine (S, A & D)-1.pptxDevelopment of Portable Biomass Briquetting Machine (S, A & D)-1.pptx
Development of Portable Biomass Briquetting Machine (S, A & D)-1.pptx
aniket862935
 
Decoding Kotlin - Your Guide to Solving the Mysterious in Kotlin - Devoxx PL ...
Decoding Kotlin - Your Guide to Solving the Mysterious in Kotlin - Devoxx PL ...Decoding Kotlin - Your Guide to Solving the Mysterious in Kotlin - Devoxx PL ...
Decoding Kotlin - Your Guide to Solving the Mysterious in Kotlin - Devoxx PL ...
João Esperancinha
 
Rigor, ethics, wellbeing and resilience in the ICT doctoral journey
Rigor, ethics, wellbeing and resilience in the ICT doctoral journeyRigor, ethics, wellbeing and resilience in the ICT doctoral journey
Rigor, ethics, wellbeing and resilience in the ICT doctoral journey
Yannis
 
The first edition of the AIAG-VDA FMEA.pptx
The first edition of the AIAG-VDA FMEA.pptxThe first edition of the AIAG-VDA FMEA.pptx
The first edition of the AIAG-VDA FMEA.pptx
Mayank Mathur
 
Understanding Amplitude Modulation : A Guide
Understanding Amplitude Modulation : A GuideUnderstanding Amplitude Modulation : A Guide
Understanding Amplitude Modulation : A Guide
CircuitDigest
 
Blood bank management system project report.pdf
Blood bank management system project report.pdfBlood bank management system project report.pdf
Blood bank management system project report.pdf
Kamal Acharya
 
362 Alec Data Center Solutions-Slysium Data Center-AUH-ABB Furse.pdf
362 Alec Data Center Solutions-Slysium Data Center-AUH-ABB Furse.pdf362 Alec Data Center Solutions-Slysium Data Center-AUH-ABB Furse.pdf
362 Alec Data Center Solutions-Slysium Data Center-AUH-ABB Furse.pdf
djiceramil
 
Flow Chart Proses Bisnis prosscesss.docx
Flow Chart Proses Bisnis prosscesss.docxFlow Chart Proses Bisnis prosscesss.docx
Flow Chart Proses Bisnis prosscesss.docx
rifka575530
 
COMPOSITE COLUMN IN STEEL CONCRETE COMPOSITES.ppt
COMPOSITE COLUMN IN STEEL CONCRETE COMPOSITES.pptCOMPOSITE COLUMN IN STEEL CONCRETE COMPOSITES.ppt
COMPOSITE COLUMN IN STEEL CONCRETE COMPOSITES.ppt
ravicivil
 
chemistry investigatory project for class 12
chemistry investigatory project for class 12chemistry investigatory project for class 12
chemistry investigatory project for class 12
Susis10
 
Tree_Traversals.pptbbbbbbbbbbbbbbbbbbbbbbbbb
Tree_Traversals.pptbbbbbbbbbbbbbbbbbbbbbbbbbTree_Traversals.pptbbbbbbbbbbbbbbbbbbbbbbbbb
Tree_Traversals.pptbbbbbbbbbbbbbbbbbbbbbbbbb
RATNANITINPATIL
 
NALCO Green Anode Plant,Compositions of CPC,Pitch
NALCO Green Anode Plant,Compositions of CPC,PitchNALCO Green Anode Plant,Compositions of CPC,Pitch
NALCO Green Anode Plant,Compositions of CPC,Pitch
arpitprachi123
 
最新版美国圣莫尼卡学院毕业证(SMC毕业证书)原版定制
最新版美国圣莫尼卡学院毕业证(SMC毕业证书)原版定制最新版美国圣莫尼卡学院毕业证(SMC毕业证书)原版定制
最新版美国圣莫尼卡学院毕业证(SMC毕业证书)原版定制
Taqyea
 
Water demand - Types , variations and WDS
Water demand - Types , variations and WDSWater demand - Types , variations and WDS
Water demand - Types , variations and WDS
dhanashree78
 
First Come First Serve Scheduling in real time operating system.pptx
First Come First Serve Scheduling in real time operating system.pptxFirst Come First Serve Scheduling in real time operating system.pptx
First Come First Serve Scheduling in real time operating system.pptx
KavitaBagewadi2
 
Fundamentals of Digital Design_Class_12th April.pptx
Fundamentals of Digital Design_Class_12th April.pptxFundamentals of Digital Design_Class_12th April.pptx
Fundamentals of Digital Design_Class_12th April.pptx
drdebarshi1993
 
3. What is the principles of Teamwork_Module_V1.0.ppt
3. What is the principles of Teamwork_Module_V1.0.ppt3. What is the principles of Teamwork_Module_V1.0.ppt
3. What is the principles of Teamwork_Module_V1.0.ppt
engaash9
 
Week 6- PC HARDWARE AND MAINTENANCE-THEORY.pptx
Week 6- PC HARDWARE AND MAINTENANCE-THEORY.pptxWeek 6- PC HARDWARE AND MAINTENANCE-THEORY.pptx
Week 6- PC HARDWARE AND MAINTENANCE-THEORY.pptx
dayananda54
 
社内勉強会資料_Chain of Thought .
社内勉強会資料_Chain of Thought                           .社内勉強会資料_Chain of Thought                           .
社内勉強会資料_Chain of Thought .
NABLAS株式会社
 
WIRELESS COMMUNICATION SECURITY AND IT’S PROTECTION METHODS
WIRELESS COMMUNICATION SECURITY AND IT’S PROTECTION METHODSWIRELESS COMMUNICATION SECURITY AND IT’S PROTECTION METHODS
WIRELESS COMMUNICATION SECURITY AND IT’S PROTECTION METHODS
samueljackson3773
 
Development of Portable Biomass Briquetting Machine (S, A & D)-1.pptx
Development of Portable Biomass Briquetting Machine (S, A & D)-1.pptxDevelopment of Portable Biomass Briquetting Machine (S, A & D)-1.pptx
Development of Portable Biomass Briquetting Machine (S, A & D)-1.pptx
aniket862935
 
Decoding Kotlin - Your Guide to Solving the Mysterious in Kotlin - Devoxx PL ...
Decoding Kotlin - Your Guide to Solving the Mysterious in Kotlin - Devoxx PL ...Decoding Kotlin - Your Guide to Solving the Mysterious in Kotlin - Devoxx PL ...
Decoding Kotlin - Your Guide to Solving the Mysterious in Kotlin - Devoxx PL ...
João Esperancinha
 
Rigor, ethics, wellbeing and resilience in the ICT doctoral journey
Rigor, ethics, wellbeing and resilience in the ICT doctoral journeyRigor, ethics, wellbeing and resilience in the ICT doctoral journey
Rigor, ethics, wellbeing and resilience in the ICT doctoral journey
Yannis
 
The first edition of the AIAG-VDA FMEA.pptx
The first edition of the AIAG-VDA FMEA.pptxThe first edition of the AIAG-VDA FMEA.pptx
The first edition of the AIAG-VDA FMEA.pptx
Mayank Mathur
 
Understanding Amplitude Modulation : A Guide
Understanding Amplitude Modulation : A GuideUnderstanding Amplitude Modulation : A Guide
Understanding Amplitude Modulation : A Guide
CircuitDigest
 
Blood bank management system project report.pdf
Blood bank management system project report.pdfBlood bank management system project report.pdf
Blood bank management system project report.pdf
Kamal Acharya
 
362 Alec Data Center Solutions-Slysium Data Center-AUH-ABB Furse.pdf
362 Alec Data Center Solutions-Slysium Data Center-AUH-ABB Furse.pdf362 Alec Data Center Solutions-Slysium Data Center-AUH-ABB Furse.pdf
362 Alec Data Center Solutions-Slysium Data Center-AUH-ABB Furse.pdf
djiceramil
 
Flow Chart Proses Bisnis prosscesss.docx
Flow Chart Proses Bisnis prosscesss.docxFlow Chart Proses Bisnis prosscesss.docx
Flow Chart Proses Bisnis prosscesss.docx
rifka575530
 
COMPOSITE COLUMN IN STEEL CONCRETE COMPOSITES.ppt
COMPOSITE COLUMN IN STEEL CONCRETE COMPOSITES.pptCOMPOSITE COLUMN IN STEEL CONCRETE COMPOSITES.ppt
COMPOSITE COLUMN IN STEEL CONCRETE COMPOSITES.ppt
ravicivil
 
chemistry investigatory project for class 12
chemistry investigatory project for class 12chemistry investigatory project for class 12
chemistry investigatory project for class 12
Susis10
 
Tree_Traversals.pptbbbbbbbbbbbbbbbbbbbbbbbbb
Tree_Traversals.pptbbbbbbbbbbbbbbbbbbbbbbbbbTree_Traversals.pptbbbbbbbbbbbbbbbbbbbbbbbbb
Tree_Traversals.pptbbbbbbbbbbbbbbbbbbbbbbbbb
RATNANITINPATIL
 
NALCO Green Anode Plant,Compositions of CPC,Pitch
NALCO Green Anode Plant,Compositions of CPC,PitchNALCO Green Anode Plant,Compositions of CPC,Pitch
NALCO Green Anode Plant,Compositions of CPC,Pitch
arpitprachi123
 
最新版美国圣莫尼卡学院毕业证(SMC毕业证书)原版定制
最新版美国圣莫尼卡学院毕业证(SMC毕业证书)原版定制最新版美国圣莫尼卡学院毕业证(SMC毕业证书)原版定制
最新版美国圣莫尼卡学院毕业证(SMC毕业证书)原版定制
Taqyea
 
Water demand - Types , variations and WDS
Water demand - Types , variations and WDSWater demand - Types , variations and WDS
Water demand - Types , variations and WDS
dhanashree78
 
Ad

Unix/Linux Command Reference - File Commands and Shortcuts

  • 1. Unix/Linux Command Reference File Commands 1. ls Directory listing 2. ls -al Formatted listing with hidden files 3. ls -lt Sorting the Formatted listing by time modification 4. cd dir Change directory to dir 5. cd Change to home directory 6. pwd Show current working directory 7. mkdir dir Creating a directory dir 8. cat >file Places the standard input into the file 9. more file Output the contents of the file 10. head file Output the first 10 lines of the file 11. tail file Output the last 10 lines of the file 12. tail -f file Output the contents of file as it grows,starting with the last 10 lines 13. touch file Create or update file 14. rm file Deleting the file 15. rm -r dir Deleting the directory 16. rm -f file Force to remove the file 17. rm -rf dir Force to remove the directory dir 18. cp file1 file2 Copy the contents of file1 to file2 19. cp -r dir1 dir2 Copy dir1 to dir2;create dir2 if not present 20. mv file1 file2 Rename or move file1 to file2,if file2 is an existing directory 21. ln -s file link Create symbolic link link to file Process management 1. ps To display the currently working processes 2. top Display all running process Unix/Linux Command Reference
  • 2. 3. kill pid Kill the process with given pid 4. killall proc Kill all the process named proc 5. pkill pattern Will kill all processes matching the pattern 6. bg List stopped or background jobs,resume a stopped job in the background 7. fg Brings the most recent job to foreground 8. fg n Brings job n to the foreground File permission 1. chmod octal file Change the permission of file to octal,which can be found separately for user,group,world by adding, • 4-read(r) • 2-write(w) • 1-execute(x) Searching 1. grep pattern file Search for pattern in file 2. grep -r pattern dir Search recursively for pattern in dir 3. command | grep pattern Search pattern in the output of a command 4. locate file Find all instances of file 5. find . -name filename Searches in the current directory (represented by a period) and below it, for files and directories with names starting with filename 6. pgrep pattern Searches for all the named processes , that matches with the pattern and, by default, returns their ID System Info 1. date Show the current date and time 2. cal Show this month's calender 3. uptime Show current uptime 4. w Display who is on line 5. whoami Who you are logged in as Unix/Linux Command Reference
  • 3. 6. finger user Display information about user 7. uname -a Show kernel information 8. cat /proc/cpuinfo Cpu information 9. cat proc/meminfo Memory information 10. man command Show the manual for command 11. df Show the disk usage 12. du Show directory space usage 13. free Show memory and swap usage 14. whereis app Show possible locations of app 15. which app Show which applications will be run by default Compression 1. tar cf file.tar file Create tar named file.tar containing file 2. tar xf file.tar Extract the files from file.tar 3. tar czf file.tar.gz files Create a tar with Gzip compression 4. tar xzf file.tar.gz Extract a tar using Gzip 5. tar cjf file.tar.bz2 Create tar with Bzip2 compression 6. tar xjf file.tar.bz2 Extract a tar using Bzip2 7. gzip file Compresses file and renames it to file.gz 8. gzip -d file.gz Decompresses file.gz back to file Network 1. ping host Ping host and output results 2. whois domain Get whois information for domains 3. dig domain Get DNS information for domain 4. dig -x host Reverse lookup host 5. wget file Download file 6. wget -c file Continue a stopped download Unix/Linux Command Reference
  • 4. Shortcuts 1. ctrl+c Halts the current command 2. ctrl+z Stops the current command, resume with fg in the foreground or bg in the background 3. ctrl+d Logout the current session, similar to exit 4. ctrl+w Erases one word in the current line 5. ctrl+u Erases the whole line 6. ctrl+r Type to bring up a recent command 7. !! Repeats the last command 8. exit Logout the current session Unix/Linux Command Reference