SlideShare ist ein Scribd-Unternehmen logo
1 von 5
Downloaden Sie, um offline zu lesen
Basic Commands

1.ls -l         for listing the files as well as directories those are kept in
the particular working directory
syntax
[root@nettech root]#ls -l

2.ls -la        same as 'ls -l'but by this command we can also see the hiden
files.
syntax
[root@nettech root]#ls -la

3.ls -li        same as 'ls -la' but it will also shows us the inode number of
each and every file
syntax
[root@nettech root]#ls -li

4.ls            by this command we can see only file name nothing else
syntax
[root@nettech root]#ls


5.clear         it will clear the screen(short cut ctl+l)
syntax
[root@nettech root]#clear

6.exit          to end a current session as well current terminal logging
syntax
[root@nettech root]exit

7.touch         to create a new empty file
syntax
[root@nettech root]#touch

8.cd            to change the working/present directory
syntax
[root@nettech root]#cd /home/mango
                where '/home/mango' is the desired directory to be change from
'/root'


9.cat           to view the contents of a file and it is also used for creating a
new file with some contents
syntax
[root@nettech root]#cat <file name>       to view file contents
[root@nettech root]#cat > newfilename     enter,then you can write something in
the file and then to save the file contents press clt+d then enter

10.mkdir        to make a new directory
syntax
[root@nettech root]#mkdir newdirname
                you can also create a directory at your desired path without
changing your present working directory
syntax
[root@nettech root]#mkdir /home/mango/newdirname

11.rm           to remove a empty file
syntax
[root@nettech root]#rm filename

                                     Page 1
Basic Commands

12.rmdir        to remove a empty directory
syntax
[root@nettech root]#rmdir directoryname

13.rm [-i/-r/-f] to remove a directory with its subdirectories as well as its
files that is to remove a directory which already contains some files in it
syntax
[root@nettech root]#rm -i directory/filename
                 -i stands for interactively
                 -r stands for recursively
                 -f stands for forcefully
14.cp           to copy something in a destination file or directory
syntax
[root@nettech root]#cp sourcepath destinationpath
example: [root@nettech root]#cp /home/mango/webmin.rpm /root/abcd
                  in this example the webmin.rpm file will be copied in
/root/abcd directory

15.mv           to move one file or directory from one place to another place, it
is also used for renaming adirectory or file
syntax
[root@nettech root]#mv source destination
[root@nettech root]#mv oldfilename newfilename     [to change the file name]

16.man          to view the mannual page of commands for syntax
syntax
[root@nettech root]#man commandname

17.info         to view the information about any command
syntax
[root@nettech root]#mkdir info

18.--help       to view the help doccuments of a command
syntax
[root@nettech root]#commandname --help

19.dir          to view the subdirectories and filesn under the directory
syntax
[root@nettech root]#dir

20.su -         to become a super user
syntax
[mango@nettech mango]$su -
output wil be
[root@nettech root#]


21.who          by this command you can see the user name and their ip addresses
who have loged in on your server
syntax
[root@nettech root]#who

22.whoami       this command shows your current logged in terminal user name
syntax
[root@nettech root]#whoami


23.who am i     this command shows you the logged in terminal number and user
name and more detailed information
                                      Page 2
Basic Commands
syntax
[root@nettech root]#who am i

24.pwd          to view the present working directory
syntax
[root@nettech root]#pwd


25.rpm -ivh     to intall a rpm package
syntax
[root@nettech root]#rpm -ivh packagename.rpm
                rpm stands for 'redhat package manager'
                -i stands for install
                -v stands for verbose mode
                -h stands for with hash sign(#)


26.rpm -q               to querry about any rpm package
syntax
[root@nettech root]#rpm -q packagename

27.rpm -e       to uninstall a rpm package
synatx
[root@nettech root]#rpm -e package



28.find / -name to find any file or directory in linux file system
syntax
[root@nettech root]#find / -name filename

29.su username to switch from one user to another users home directory
syntax
[root@nettech root]#su mango
output will be
[mango@nettech root]#cd
[mango@nettech mango]#


30.su - username        to switch from one user to another user users home
directory directly
syntax
[root@nettech root]#su - mango

31.useradd      to create a new user
synatx
[root@nettech root]#useradd username

32.passwd       to give a password of a user
syntax
[root@nettech root]#passwd tarun
output will be
give a password for user tarun:(here you have to type a password for tarun user)
confirm password:(again type the same password)

33.userdel      to remove a user from linux
syntax
[root@nettech root]#userdel tarun


                                       Page 3
Basic Commands
34.groupadd     to add a new group
syntax
[root@nettech root]#groupadd groupname


35.gruopdel     to delete a group
syntax
[root@nettech root]#groupdel groupname



36.chown        to change the ownership of a file or directory
syntax
[root@nettech root]#chown ownername filename
example:
[root@nettech /]#ls -l
output
drwxrw-rw-    2 root   root       4096 Mar 11 12:03 abcd
(permission)   (own) (group own)(size)             (name)
[root@nettech root]#chown tarun /abcd
in this example /abcd directory owner will be change to tarun user
effect
[root@nettech /]#ls -l
drwxrw-rw-    2 tarun   root       4096 Mar 11 12:03 abcd


37.chgrp        to change the group ownership of a file or directory
syntax
[root@nettec root]#chgrp newgroupownername filename
example
[root@nettech /]#ls -l
drwxrw-rw-    2 tarun   root       4096 Mar 11 12:03 abcd
[root@nettech root]#chgrp tarun /abcd
effect
[root@nettech /]#ls -l
drwxrw-rw-    2 tarun   tarun       4096 Mar 11 12:03 abcd


38.chmod          to change the permission of a file or directory
drwxrw-rw-      2 root   root       4096 Mar 11 12:03 abcd
(permission)     (ownr) (grpownr) (size)             (name)                   IN
OCTAL VALUE
                 d stands for directiry                                  READ=4
                 r stands for read only permission                       WRITE=2
                 w stands for write only permission                      EXECUTE=1
                 x stands for execute only permission
  drwxrw-rw-     FIRST OCTET FOR DENOTING THE DIRECTORY OR FILE OR LINK FILE ETC.
                 SECOND THREE OCTET FOR USER OR OWNER PERMISSION (rwx OR 7 IN
OCTAL VALUE)
                  THIRD THREE OCTET FOR GROUP PERMISSION (rw- OR 6 IN OCTAL VALUE)
                FORTH THREE OCTET FOR OTHERS PERMISSION (rw- OR 6 IN OCTAL VALUE)
SYNTAX
[root@nettec root]#chmod value fileordirectoryname
example

[root@nettech   /]#ls -l
drwxrw-rw-      2 tarun   root       4096 Mar 11 12:03 abcd
[root@nettech   /]#chmod 402 /abcd
[root@nettech   /]#ls -l
drw-----w-      2 tarun   tarun       4096 Mar 11 12:03 abcd

40.usermod       to modify the user profile
                                       Page 4
Basic Commands
synatx
[root@nettech root]#usermod -parameter groupname username




                                     Page 5

Weitere Àhnliche Inhalte

Was ist angesagt?

Linux system admin useful commands
Linux system admin useful commandsLinux system admin useful commands
Linux system admin useful commandsali98091
 
DNS Server Configuration
DNS Server ConfigurationDNS Server Configuration
DNS Server Configurationchacheng oo
 
Linux Commands
Linux CommandsLinux Commands
Linux Commandslucita cabral
 
linux-commandline-magic-Joomla-World-Conference-2014
linux-commandline-magic-Joomla-World-Conference-2014linux-commandline-magic-Joomla-World-Conference-2014
linux-commandline-magic-Joomla-World-Conference-2014Peter Martin
 
Gnome terminal basics
Gnome terminal basicsGnome terminal basics
Gnome terminal basicsKamrul Hasan
 
BIND DNS Configuration Red Hat 5
BIND DNS Configuration Red Hat 5BIND DNS Configuration Red Hat 5
BIND DNS Configuration Red Hat 5Cheri Amour Calicdan
 
Introduction to linux day-3
Introduction to linux day-3Introduction to linux day-3
Introduction to linux day-3Gourav Varma
 
Linux And perl
Linux And perlLinux And perl
Linux And perlSagar Kumar
 
Rhel 6.2 complete ebook
Rhel 6.2  complete ebookRhel 6.2  complete ebook
Rhel 6.2 complete ebookYash Gulati
 
Linux commands
Linux commandsLinux commands
Linux commandsshekhar70
 
Rhel 6.2 complete ebook
Rhel 6.2 complete ebookRhel 6.2 complete ebook
Rhel 6.2 complete ebookYash Gulati
 
Linux Bash Shell Cheat Sheet for Beginners
Linux Bash Shell Cheat Sheet for BeginnersLinux Bash Shell Cheat Sheet for Beginners
Linux Bash Shell Cheat Sheet for BeginnersDavide Ciambelli
 

Was ist angesagt? (17)

Linux system admin useful commands
Linux system admin useful commandsLinux system admin useful commands
Linux system admin useful commands
 
Linux system admin
Linux system adminLinux system admin
Linux system admin
 
40 basic linux command
40 basic linux command40 basic linux command
40 basic linux command
 
DNS Server Configuration
DNS Server ConfigurationDNS Server Configuration
DNS Server Configuration
 
Linux Commands
Linux CommandsLinux Commands
Linux Commands
 
Basics of unix
Basics of unixBasics of unix
Basics of unix
 
Linux basic commands
Linux basic commandsLinux basic commands
Linux basic commands
 
linux-commandline-magic-Joomla-World-Conference-2014
linux-commandline-magic-Joomla-World-Conference-2014linux-commandline-magic-Joomla-World-Conference-2014
linux-commandline-magic-Joomla-World-Conference-2014
 
Gnome terminal basics
Gnome terminal basicsGnome terminal basics
Gnome terminal basics
 
BIND DNS Configuration Red Hat 5
BIND DNS Configuration Red Hat 5BIND DNS Configuration Red Hat 5
BIND DNS Configuration Red Hat 5
 
Introduction to linux day-3
Introduction to linux day-3Introduction to linux day-3
Introduction to linux day-3
 
Linux And perl
Linux And perlLinux And perl
Linux And perl
 
Rhel 6.2 complete ebook
Rhel 6.2  complete ebookRhel 6.2  complete ebook
Rhel 6.2 complete ebook
 
Linux commands
Linux commandsLinux commands
Linux commands
 
Unix command quickref
Unix command quickrefUnix command quickref
Unix command quickref
 
Rhel 6.2 complete ebook
Rhel 6.2 complete ebookRhel 6.2 complete ebook
Rhel 6.2 complete ebook
 
Linux Bash Shell Cheat Sheet for Beginners
Linux Bash Shell Cheat Sheet for BeginnersLinux Bash Shell Cheat Sheet for Beginners
Linux Bash Shell Cheat Sheet for Beginners
 

Andere mochten auch

Basic commands of linux By Adam
Basic commands of linux By Adam Basic commands of linux By Adam
Basic commands of linux By Adam Mohammed Adam
 
Basic linux commands
Basic linux commands Basic linux commands
Basic linux commands Raghav Arora
 
Hhs en02 windows_and_linux
Hhs en02 windows_and_linuxHhs en02 windows_and_linux
Hhs en02 windows_and_linuxShoaib Sheikh
 
Basic linux commands
Basic linux commandsBasic linux commands
Basic linux commandsNguyen Vinh
 
Basic commands (linux)
Basic commands (linux)Basic commands (linux)
Basic commands (linux)Faysal Khan
 
basic linux command (questions)
basic linux command (questions)basic linux command (questions)
basic linux command (questions)Sukhraj Singh
 
Linux basic commands tutorial
Linux basic commands tutorialLinux basic commands tutorial
Linux basic commands tutorialTeja Bheemanapally
 
ntroduction to GNU/Linux Linux Installation and Basic Commands
ntroduction to GNU/Linux Linux Installation and Basic Commands ntroduction to GNU/Linux Linux Installation and Basic Commands
ntroduction to GNU/Linux Linux Installation and Basic Commands Jaganadh Gopinadhan
 
Basic command for linux
Basic command for linuxBasic command for linux
Basic command for linuxgt0ne
 
Linux Commands - 3
Linux Commands - 3Linux Commands - 3
Linux Commands - 3Kanchilug
 
Quick Guide with Linux Command Line
Quick Guide with Linux Command LineQuick Guide with Linux Command Line
Quick Guide with Linux Command LineAnuchit Chalothorn
 
Basic linux commands
Basic linux commandsBasic linux commands
Basic linux commandsAniket Thakur
 
Linux System Monitoring basic commands
Linux System Monitoring basic commandsLinux System Monitoring basic commands
Linux System Monitoring basic commandsMohammad Rafiee
 
Basic Commands 1 By Thanigai
Basic Commands  1 By ThanigaiBasic Commands  1 By Thanigai
Basic Commands 1 By ThanigaiKanchilug
 
Anandha ganesh linux1.ppt
Anandha ganesh linux1.pptAnandha ganesh linux1.ppt
Anandha ganesh linux1.pptanandha ganesh
 

Andere mochten auch (20)

Basic commands of linux By Adam
Basic commands of linux By Adam Basic commands of linux By Adam
Basic commands of linux By Adam
 
Basic linux commands
Basic linux commands Basic linux commands
Basic linux commands
 
Basic linux commands
Basic linux commandsBasic linux commands
Basic linux commands
 
Hhs en02 windows_and_linux
Hhs en02 windows_and_linuxHhs en02 windows_and_linux
Hhs en02 windows_and_linux
 
Basic linux commands
Basic linux commandsBasic linux commands
Basic linux commands
 
Basic commands (linux)
Basic commands (linux)Basic commands (linux)
Basic commands (linux)
 
Linex
LinexLinex
Linex
 
basic linux command (questions)
basic linux command (questions)basic linux command (questions)
basic linux command (questions)
 
Linux basic commands tutorial
Linux basic commands tutorialLinux basic commands tutorial
Linux basic commands tutorial
 
ntroduction to GNU/Linux Linux Installation and Basic Commands
ntroduction to GNU/Linux Linux Installation and Basic Commands ntroduction to GNU/Linux Linux Installation and Basic Commands
ntroduction to GNU/Linux Linux Installation and Basic Commands
 
Basic command for linux
Basic command for linuxBasic command for linux
Basic command for linux
 
Sahul
SahulSahul
Sahul
 
Linux Commands - 3
Linux Commands - 3Linux Commands - 3
Linux Commands - 3
 
Quick Guide with Linux Command Line
Quick Guide with Linux Command LineQuick Guide with Linux Command Line
Quick Guide with Linux Command Line
 
Basic linux commands
Basic linux commandsBasic linux commands
Basic linux commands
 
Basic linux commands
Basic linux commandsBasic linux commands
Basic linux commands
 
Linux System Monitoring basic commands
Linux System Monitoring basic commandsLinux System Monitoring basic commands
Linux System Monitoring basic commands
 
Basic Commands 1 By Thanigai
Basic Commands  1 By ThanigaiBasic Commands  1 By Thanigai
Basic Commands 1 By Thanigai
 
Anandha ganesh linux1.ppt
Anandha ganesh linux1.pptAnandha ganesh linux1.ppt
Anandha ganesh linux1.ppt
 
Linux syllabus
Linux syllabusLinux syllabus
Linux syllabus
 

Ähnlich wie Basic linux commands

Basic commands
Basic commandsBasic commands
Basic commandsVinay Thota
 
Linux basics part 1
Linux basics part 1Linux basics part 1
Linux basics part 1Lilesh Pathe
 
Linux presentation
Linux presentationLinux presentation
Linux presentationNikhil Jain
 
Basic
BasicBasic
BasicARYA TM
 
Unix Basics Commands
Unix Basics CommandsUnix Basics Commands
Unix Basics CommandsSameeran Jenna
 
Termux commands-list
Termux commands-listTermux commands-list
Termux commands-listDhanushR24
 
55 best linux tips, tricks and command lines
55 best linux tips, tricks and command lines55 best linux tips, tricks and command lines
55 best linux tips, tricks and command linesArif Wahyudi
 
Common linux ubuntu commands overview
Common linux  ubuntu commands overviewCommon linux  ubuntu commands overview
Common linux ubuntu commands overviewAmeer Sameer
 
Most frequently used unix commands for database administrator
Most frequently used unix commands for database administratorMost frequently used unix commands for database administrator
Most frequently used unix commands for database administratorDinesh jaisankar
 
Linux file commands and shell scripts
Linux file commands and shell scriptsLinux file commands and shell scripts
Linux file commands and shell scriptsPrashantTechment
 
Redhat 6 & 7
Redhat 6 & 7Redhat 6 & 7
Redhat 6 & 7r9social
 
Linux Terminal commands for Devops.pdf
Linux Terminal commands for Devops.pdfLinux Terminal commands for Devops.pdf
Linux Terminal commands for Devops.pdfNambi Nam
 
Linux commands
Linux commandsLinux commands
Linux commandsAjaigururaj R
 
Linux commands
Linux commandsLinux commands
Linux commandsHemakumar.S
 
Linux commands
Linux commandsLinux commands
Linux commandsHemakumar.S
 
101 3.3 perform basic file management
101 3.3 perform basic file management101 3.3 perform basic file management
101 3.3 perform basic file managementAcĂĄcio Oliveira
 

Ähnlich wie Basic linux commands (20)

Basic commands
Basic commandsBasic commands
Basic commands
 
Linux basics part 1
Linux basics part 1Linux basics part 1
Linux basics part 1
 
Linux presentation
Linux presentationLinux presentation
Linux presentation
 
Basic
BasicBasic
Basic
 
Unix Basics Commands
Unix Basics CommandsUnix Basics Commands
Unix Basics Commands
 
Termux commands-list
Termux commands-listTermux commands-list
Termux commands-list
 
55 best linux tips, tricks and command lines
55 best linux tips, tricks and command lines55 best linux tips, tricks and command lines
55 best linux tips, tricks and command lines
 
Common linux ubuntu commands overview
Common linux  ubuntu commands overviewCommon linux  ubuntu commands overview
Common linux ubuntu commands overview
 
40 basic linux command
40 basic linux command40 basic linux command
40 basic linux command
 
Most frequently used unix commands for database administrator
Most frequently used unix commands for database administratorMost frequently used unix commands for database administrator
Most frequently used unix commands for database administrator
 
Linux file commands and shell scripts
Linux file commands and shell scriptsLinux file commands and shell scripts
Linux file commands and shell scripts
 
Linux ppt
Linux pptLinux ppt
Linux ppt
 
Redhat 6 & 7
Redhat 6 & 7Redhat 6 & 7
Redhat 6 & 7
 
Linux Terminal commands for Devops.pdf
Linux Terminal commands for Devops.pdfLinux Terminal commands for Devops.pdf
Linux Terminal commands for Devops.pdf
 
Linux commands
Linux commandsLinux commands
Linux commands
 
Linux commands
Linux commandsLinux commands
Linux commands
 
Linux commands
Linux commandsLinux commands
Linux commands
 
101 3.3 perform basic file management
101 3.3 perform basic file management101 3.3 perform basic file management
101 3.3 perform basic file management
 
Basics of Linux
Basics of LinuxBasics of Linux
Basics of Linux
 
Linux ppt
Linux pptLinux ppt
Linux ppt
 

KĂŒrzlich hochgeladen

Oppenheimer Film Discussion for Philosophy and Film
Oppenheimer Film Discussion for Philosophy and FilmOppenheimer Film Discussion for Philosophy and Film
Oppenheimer Film Discussion for Philosophy and FilmStan Meyer
 
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdf
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdfGrade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdf
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdfJemuel Francisco
 
Visit to a blind student's school🧑‍🩯🧑‍🩯(community medicine)
Visit to a blind student's school🧑‍🩯🧑‍🩯(community medicine)Visit to a blind student's school🧑‍🩯🧑‍🩯(community medicine)
Visit to a blind student's school🧑‍🩯🧑‍🩯(community medicine)lakshayb543
 
Congestive Cardiac Failure..presentation
Congestive Cardiac Failure..presentationCongestive Cardiac Failure..presentation
Congestive Cardiac Failure..presentationdeepaannamalai16
 
Q4-PPT-Music9_Lesson-1-Romantic-Opera.pptx
Q4-PPT-Music9_Lesson-1-Romantic-Opera.pptxQ4-PPT-Music9_Lesson-1-Romantic-Opera.pptx
Q4-PPT-Music9_Lesson-1-Romantic-Opera.pptxlancelewisportillo
 
Expanded definition: technical and operational
Expanded definition: technical and operationalExpanded definition: technical and operational
Expanded definition: technical and operationalssuser3e220a
 
DIFFERENT BASKETRY IN THE PHILIPPINES PPT.pptx
DIFFERENT BASKETRY IN THE PHILIPPINES PPT.pptxDIFFERENT BASKETRY IN THE PHILIPPINES PPT.pptx
DIFFERENT BASKETRY IN THE PHILIPPINES PPT.pptxMichelleTuguinay1
 
Narcotic and Non Narcotic Analgesic..pdf
Narcotic and Non Narcotic Analgesic..pdfNarcotic and Non Narcotic Analgesic..pdf
Narcotic and Non Narcotic Analgesic..pdfPrerana Jadhav
 
Team Lead Succeed – Helping you and your team achieve high-performance teamwo...
Team Lead Succeed – Helping you and your team achieve high-performance teamwo...Team Lead Succeed – Helping you and your team achieve high-performance teamwo...
Team Lead Succeed – Helping you and your team achieve high-performance teamwo...Association for Project Management
 
31 ĐỀ THI THỏ VÀO LỚP 10 - TIáșŸNG ANH - FORM MỚI 2025 - 40 CÂU HỎI - BÙI VĂN V...
31 ĐỀ THI THỏ VÀO LỚP 10 - TIáșŸNG ANH - FORM MỚI 2025 - 40 CÂU HỎI - BÙI VĂN V...31 ĐỀ THI THỏ VÀO LỚP 10 - TIáșŸNG ANH - FORM MỚI 2025 - 40 CÂU HỎI - BÙI VĂN V...
31 ĐỀ THI THỏ VÀO LỚP 10 - TIáșŸNG ANH - FORM MỚI 2025 - 40 CÂU HỎI - BÙI VĂN V...Nguyen Thanh Tu Collection
 
Q-Factor HISPOL Quiz-6th April 2024, Quiz Club NITW
Q-Factor HISPOL Quiz-6th April 2024, Quiz Club NITWQ-Factor HISPOL Quiz-6th April 2024, Quiz Club NITW
Q-Factor HISPOL Quiz-6th April 2024, Quiz Club NITWQuiz Club NITW
 
Daily Lesson Plan in Mathematics Quarter 4
Daily Lesson Plan in Mathematics Quarter 4Daily Lesson Plan in Mathematics Quarter 4
Daily Lesson Plan in Mathematics Quarter 4JOYLYNSAMANIEGO
 
Textual Evidence in Reading and Writing of SHS
Textual Evidence in Reading and Writing of SHSTextual Evidence in Reading and Writing of SHS
Textual Evidence in Reading and Writing of SHSMae Pangan
 
Beauty Amidst the Bytes_ Unearthing Unexpected Advantages of the Digital Wast...
Beauty Amidst the Bytes_ Unearthing Unexpected Advantages of the Digital Wast...Beauty Amidst the Bytes_ Unearthing Unexpected Advantages of the Digital Wast...
Beauty Amidst the Bytes_ Unearthing Unexpected Advantages of the Digital Wast...DhatriParmar
 
Man or Manufactured_ Redefining Humanity Through Biopunk Narratives.pptx
Man or Manufactured_ Redefining Humanity Through Biopunk Narratives.pptxMan or Manufactured_ Redefining Humanity Through Biopunk Narratives.pptx
Man or Manufactured_ Redefining Humanity Through Biopunk Narratives.pptxDhatriParmar
 
4.11.24 Mass Incarceration and the New Jim Crow.pptx
4.11.24 Mass Incarceration and the New Jim Crow.pptx4.11.24 Mass Incarceration and the New Jim Crow.pptx
4.11.24 Mass Incarceration and the New Jim Crow.pptxmary850239
 
INTRODUCTION TO CATHOLIC CHRISTOLOGY.pptx
INTRODUCTION TO CATHOLIC CHRISTOLOGY.pptxINTRODUCTION TO CATHOLIC CHRISTOLOGY.pptx
INTRODUCTION TO CATHOLIC CHRISTOLOGY.pptxHumphrey A Beña
 
Multi Domain Alias In the Odoo 17 ERP Module
Multi Domain Alias In the Odoo 17 ERP ModuleMulti Domain Alias In the Odoo 17 ERP Module
Multi Domain Alias In the Odoo 17 ERP ModuleCeline George
 

KĂŒrzlich hochgeladen (20)

Oppenheimer Film Discussion for Philosophy and Film
Oppenheimer Film Discussion for Philosophy and FilmOppenheimer Film Discussion for Philosophy and Film
Oppenheimer Film Discussion for Philosophy and Film
 
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdf
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdfGrade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdf
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdf
 
Visit to a blind student's school🧑‍🩯🧑‍🩯(community medicine)
Visit to a blind student's school🧑‍🩯🧑‍🩯(community medicine)Visit to a blind student's school🧑‍🩯🧑‍🩯(community medicine)
Visit to a blind student's school🧑‍🩯🧑‍🩯(community medicine)
 
Congestive Cardiac Failure..presentation
Congestive Cardiac Failure..presentationCongestive Cardiac Failure..presentation
Congestive Cardiac Failure..presentation
 
Q4-PPT-Music9_Lesson-1-Romantic-Opera.pptx
Q4-PPT-Music9_Lesson-1-Romantic-Opera.pptxQ4-PPT-Music9_Lesson-1-Romantic-Opera.pptx
Q4-PPT-Music9_Lesson-1-Romantic-Opera.pptx
 
Expanded definition: technical and operational
Expanded definition: technical and operationalExpanded definition: technical and operational
Expanded definition: technical and operational
 
DIFFERENT BASKETRY IN THE PHILIPPINES PPT.pptx
DIFFERENT BASKETRY IN THE PHILIPPINES PPT.pptxDIFFERENT BASKETRY IN THE PHILIPPINES PPT.pptx
DIFFERENT BASKETRY IN THE PHILIPPINES PPT.pptx
 
Narcotic and Non Narcotic Analgesic..pdf
Narcotic and Non Narcotic Analgesic..pdfNarcotic and Non Narcotic Analgesic..pdf
Narcotic and Non Narcotic Analgesic..pdf
 
Faculty Profile prashantha K EEE dept Sri Sairam college of Engineering
Faculty Profile prashantha K EEE dept Sri Sairam college of EngineeringFaculty Profile prashantha K EEE dept Sri Sairam college of Engineering
Faculty Profile prashantha K EEE dept Sri Sairam college of Engineering
 
Team Lead Succeed – Helping you and your team achieve high-performance teamwo...
Team Lead Succeed – Helping you and your team achieve high-performance teamwo...Team Lead Succeed – Helping you and your team achieve high-performance teamwo...
Team Lead Succeed – Helping you and your team achieve high-performance teamwo...
 
31 ĐỀ THI THỏ VÀO LỚP 10 - TIáșŸNG ANH - FORM MỚI 2025 - 40 CÂU HỎI - BÙI VĂN V...
31 ĐỀ THI THỏ VÀO LỚP 10 - TIáșŸNG ANH - FORM MỚI 2025 - 40 CÂU HỎI - BÙI VĂN V...31 ĐỀ THI THỏ VÀO LỚP 10 - TIáșŸNG ANH - FORM MỚI 2025 - 40 CÂU HỎI - BÙI VĂN V...
31 ĐỀ THI THỏ VÀO LỚP 10 - TIáșŸNG ANH - FORM MỚI 2025 - 40 CÂU HỎI - BÙI VĂN V...
 
Q-Factor HISPOL Quiz-6th April 2024, Quiz Club NITW
Q-Factor HISPOL Quiz-6th April 2024, Quiz Club NITWQ-Factor HISPOL Quiz-6th April 2024, Quiz Club NITW
Q-Factor HISPOL Quiz-6th April 2024, Quiz Club NITW
 
Daily Lesson Plan in Mathematics Quarter 4
Daily Lesson Plan in Mathematics Quarter 4Daily Lesson Plan in Mathematics Quarter 4
Daily Lesson Plan in Mathematics Quarter 4
 
Textual Evidence in Reading and Writing of SHS
Textual Evidence in Reading and Writing of SHSTextual Evidence in Reading and Writing of SHS
Textual Evidence in Reading and Writing of SHS
 
Mattingly "AI & Prompt Design: Large Language Models"
Mattingly "AI & Prompt Design: Large Language Models"Mattingly "AI & Prompt Design: Large Language Models"
Mattingly "AI & Prompt Design: Large Language Models"
 
Beauty Amidst the Bytes_ Unearthing Unexpected Advantages of the Digital Wast...
Beauty Amidst the Bytes_ Unearthing Unexpected Advantages of the Digital Wast...Beauty Amidst the Bytes_ Unearthing Unexpected Advantages of the Digital Wast...
Beauty Amidst the Bytes_ Unearthing Unexpected Advantages of the Digital Wast...
 
Man or Manufactured_ Redefining Humanity Through Biopunk Narratives.pptx
Man or Manufactured_ Redefining Humanity Through Biopunk Narratives.pptxMan or Manufactured_ Redefining Humanity Through Biopunk Narratives.pptx
Man or Manufactured_ Redefining Humanity Through Biopunk Narratives.pptx
 
4.11.24 Mass Incarceration and the New Jim Crow.pptx
4.11.24 Mass Incarceration and the New Jim Crow.pptx4.11.24 Mass Incarceration and the New Jim Crow.pptx
4.11.24 Mass Incarceration and the New Jim Crow.pptx
 
INTRODUCTION TO CATHOLIC CHRISTOLOGY.pptx
INTRODUCTION TO CATHOLIC CHRISTOLOGY.pptxINTRODUCTION TO CATHOLIC CHRISTOLOGY.pptx
INTRODUCTION TO CATHOLIC CHRISTOLOGY.pptx
 
Multi Domain Alias In the Odoo 17 ERP Module
Multi Domain Alias In the Odoo 17 ERP ModuleMulti Domain Alias In the Odoo 17 ERP Module
Multi Domain Alias In the Odoo 17 ERP Module
 

Basic linux commands

  • 1. Basic Commands 1.ls -l for listing the files as well as directories those are kept in the particular working directory syntax [root@nettech root]#ls -l 2.ls -la same as 'ls -l'but by this command we can also see the hiden files. syntax [root@nettech root]#ls -la 3.ls -li same as 'ls -la' but it will also shows us the inode number of each and every file syntax [root@nettech root]#ls -li 4.ls by this command we can see only file name nothing else syntax [root@nettech root]#ls 5.clear it will clear the screen(short cut ctl+l) syntax [root@nettech root]#clear 6.exit to end a current session as well current terminal logging syntax [root@nettech root]exit 7.touch to create a new empty file syntax [root@nettech root]#touch 8.cd to change the working/present directory syntax [root@nettech root]#cd /home/mango where '/home/mango' is the desired directory to be change from '/root' 9.cat to view the contents of a file and it is also used for creating a new file with some contents syntax [root@nettech root]#cat <file name> to view file contents [root@nettech root]#cat > newfilename enter,then you can write something in the file and then to save the file contents press clt+d then enter 10.mkdir to make a new directory syntax [root@nettech root]#mkdir newdirname you can also create a directory at your desired path without changing your present working directory syntax [root@nettech root]#mkdir /home/mango/newdirname 11.rm to remove a empty file syntax [root@nettech root]#rm filename Page 1
  • 2. Basic Commands 12.rmdir to remove a empty directory syntax [root@nettech root]#rmdir directoryname 13.rm [-i/-r/-f] to remove a directory with its subdirectories as well as its files that is to remove a directory which already contains some files in it syntax [root@nettech root]#rm -i directory/filename -i stands for interactively -r stands for recursively -f stands for forcefully 14.cp to copy something in a destination file or directory syntax [root@nettech root]#cp sourcepath destinationpath example: [root@nettech root]#cp /home/mango/webmin.rpm /root/abcd in this example the webmin.rpm file will be copied in /root/abcd directory 15.mv to move one file or directory from one place to another place, it is also used for renaming adirectory or file syntax [root@nettech root]#mv source destination [root@nettech root]#mv oldfilename newfilename [to change the file name] 16.man to view the mannual page of commands for syntax syntax [root@nettech root]#man commandname 17.info to view the information about any command syntax [root@nettech root]#mkdir info 18.--help to view the help doccuments of a command syntax [root@nettech root]#commandname --help 19.dir to view the subdirectories and filesn under the directory syntax [root@nettech root]#dir 20.su - to become a super user syntax [mango@nettech mango]$su - output wil be [root@nettech root#] 21.who by this command you can see the user name and their ip addresses who have loged in on your server syntax [root@nettech root]#who 22.whoami this command shows your current logged in terminal user name syntax [root@nettech root]#whoami 23.who am i this command shows you the logged in terminal number and user name and more detailed information Page 2
  • 3. Basic Commands syntax [root@nettech root]#who am i 24.pwd to view the present working directory syntax [root@nettech root]#pwd 25.rpm -ivh to intall a rpm package syntax [root@nettech root]#rpm -ivh packagename.rpm rpm stands for 'redhat package manager' -i stands for install -v stands for verbose mode -h stands for with hash sign(#) 26.rpm -q to querry about any rpm package syntax [root@nettech root]#rpm -q packagename 27.rpm -e to uninstall a rpm package synatx [root@nettech root]#rpm -e package 28.find / -name to find any file or directory in linux file system syntax [root@nettech root]#find / -name filename 29.su username to switch from one user to another users home directory syntax [root@nettech root]#su mango output will be [mango@nettech root]#cd [mango@nettech mango]# 30.su - username to switch from one user to another user users home directory directly syntax [root@nettech root]#su - mango 31.useradd to create a new user synatx [root@nettech root]#useradd username 32.passwd to give a password of a user syntax [root@nettech root]#passwd tarun output will be give a password for user tarun:(here you have to type a password for tarun user) confirm password:(again type the same password) 33.userdel to remove a user from linux syntax [root@nettech root]#userdel tarun Page 3
  • 4. Basic Commands 34.groupadd to add a new group syntax [root@nettech root]#groupadd groupname 35.gruopdel to delete a group syntax [root@nettech root]#groupdel groupname 36.chown to change the ownership of a file or directory syntax [root@nettech root]#chown ownername filename example: [root@nettech /]#ls -l output drwxrw-rw- 2 root root 4096 Mar 11 12:03 abcd (permission) (own) (group own)(size) (name) [root@nettech root]#chown tarun /abcd in this example /abcd directory owner will be change to tarun user effect [root@nettech /]#ls -l drwxrw-rw- 2 tarun root 4096 Mar 11 12:03 abcd 37.chgrp to change the group ownership of a file or directory syntax [root@nettec root]#chgrp newgroupownername filename example [root@nettech /]#ls -l drwxrw-rw- 2 tarun root 4096 Mar 11 12:03 abcd [root@nettech root]#chgrp tarun /abcd effect [root@nettech /]#ls -l drwxrw-rw- 2 tarun tarun 4096 Mar 11 12:03 abcd 38.chmod to change the permission of a file or directory drwxrw-rw- 2 root root 4096 Mar 11 12:03 abcd (permission) (ownr) (grpownr) (size) (name) IN OCTAL VALUE d stands for directiry READ=4 r stands for read only permission WRITE=2 w stands for write only permission EXECUTE=1 x stands for execute only permission drwxrw-rw- FIRST OCTET FOR DENOTING THE DIRECTORY OR FILE OR LINK FILE ETC. SECOND THREE OCTET FOR USER OR OWNER PERMISSION (rwx OR 7 IN OCTAL VALUE) THIRD THREE OCTET FOR GROUP PERMISSION (rw- OR 6 IN OCTAL VALUE) FORTH THREE OCTET FOR OTHERS PERMISSION (rw- OR 6 IN OCTAL VALUE) SYNTAX [root@nettec root]#chmod value fileordirectoryname example [root@nettech /]#ls -l drwxrw-rw- 2 tarun root 4096 Mar 11 12:03 abcd [root@nettech /]#chmod 402 /abcd [root@nettech /]#ls -l drw-----w- 2 tarun tarun 4096 Mar 11 12:03 abcd 40.usermod to modify the user profile Page 4
  • 5. Basic Commands synatx [root@nettech root]#usermod -parameter groupname username Page 5