Linux เคฎें เคिเคธी เคाเคฐ्เคฏ เคो เคธเคฎ्เคชाเคฆिเคค เคเคฐเคจे เคे เคฒिเค Command เคी เคเคตเคถ्เคฏเคเคคा เคนोเคคी เคนै |
Linux Command เคा เคช्เคฐเคฏोเค เคเคฐเคจे เคธे เคชเคนเคฒे เคจिเคฎ्เคจ เคฌाเคคों เคा เคง्เคฏाเคจ เคฐเคเคจा เคเคตเคถ्เคฏเค เคนै –
- เคธเคญी Linux เคे Command เค ंเค्เคฐेเคी เคी เคोเคी เคตเคฐ्เคฃเคฎाเคฒा (Lower case) เคฎें Type เคिเคฏे เคाเคคे เคนै |
-
Command เคे เคจाเคฎ เคเคตं เคตिเคเคฒ्เคช เคे เคฎเคง्เคฏ (Option) เคे เคฎเคง्เคฏ เคเค เคธ्เคชेเคธ เคฆेเคจा เคเคตเคถ्เคฏเค เคนै
เคैเคธे –
$ ls-l Invailid Command เคนै เคเคฌเคि
$ ls-l Vailid Command เคนै | -
เคฆो เคฏा เคฆो เคธे เค
เคงिเค Option เคो เคเค เคธाเคฅ เคोเฅ เคเคฐ เคฒिเคा เคा เคธเคเคคा เคนै
เคैเคธे –
$ ls-l-a
$ ls-la
Linux เคฎें เคธเคฌ เคกाเคฏเคฐेเค्เคเคฐी เคो เคต्เคฏเค्เคค เคเคฐเคจे เคे เคฒिเค เคिเคจ्เคน เคा เคช्เคฐเคฏोเค เคเคฐเคคे เคนै, เคैเคธे Lusers/Body เคเคฆि |
Linux เคฎें เคนเคฎ Command Terminal เคชเคฐ Type เคเคฐเคคे เคนै Terminal เคो Open เคเคฐเคจे เคा เคคเคฐीเคा เคจिเคฎ्เคจ เคนै –
- Desktop เคชเคฐ Right Click เคเคฐเคे Open in Terminal เคเคฐเคे เคญी เคนเคฎ Terminal เคो Open เคเคฐ เคธเคเคคे เคนै |
- เคเคฐ Keyboard เคธे Sort Cut Key (Alt+F2) Press เคเคฐเคे Run Application Open เคเคฐ เคธเคเคคे เคนै |เคเคฐ เคเคธเคฎे เคนเคฎ Gnome-Terminal Type เคเคฐเคे เคญी Open เคเคฐ เคธเคเคคे เคนै
- Application – System Tools –Terminal Open
- Ctrl+Alt+F2 = Local host Login :
1) Pwd Command :- Pwd Command เคो Use เคเคฐเคे เคนเคฎ เคिเคธ เคญी Prirectory เคฎें work เคเคฐ เคฐเคนे เคนै เคเคธे เคฆेเค เคธเคเคคे เคนै |
Syntax : $ Pwd↵
/root เคฏा /home/Yash
2)ls Command :- ls Command เคे Use เคธे เคนเคฎ Linux เคฎें File เคฏा Folder เคฆेเค เคธเคเคคे เคนै |
Syntax : $ ls↵
Blue color = Folder เคเคฐ เคฌाเคी File เคนै | Desktop, Document, Downloads. e.t.c.
3)Mkdir :- เคเคธ Command เคे Use เคธे เคนเคฎ Folder เคो Gease เคเคฐ เคธเคเคคे เคนै |
Syntax : $ mkdir ร iti copa↵
4)Cd :- เคเคธ Command เคे Use เคธे เคนเคฎ Directory เคो Change เคเคฐ เคธเคเคคे เคนै เค
เคฐ्เคฅाเคค् เคฏเคฆि เคนเคฎ เคฎें เคนै เคคो เคนเคฎ เคिเคธी เคฆूเคธเคฐे เคฎें เคा เคธเคเคคे เคนै |
Syntax : $ cd ร iti copa↵
/iti copa $ เคฏा $
5)Cd ร.. :- cd ร.. Command เคी เคธเคนाเคฏเคคा เคธे Directory เคฎें เคเค Step เคชीเคे เค เคธเคเคคे เคนै |
Syntax : $ cd ร..↵
Exp. root/iti copa /batch $
6) Rmdir :- เคเคธ Command เคी เคธเคนाเคฏเคคा เคธे เคนเคฎ เคिเคธी เคญी เคाเคฒी Directory เคฏा Folder เคो Remove เคเคฐ เคธเคเคคे เคนै |
Syntax : $ rmdir ร directory name↵
Exp. root /iti copa $ rmdir ร batch
[Text file]
7) Touch :- เคเคธ Command เคी เคธเคนाเคฏเคคा เคธे เคाเคฒी (Empty) เคซाเคเคฒ เคฌเคจा เคธเคเคคे เคนै |
Syntax : $ touch ร file name↵
Exp. $ touch ร ram↵
8) Cat :- เคเคธ Command เคे Use เคธे เคนเคฎ เคซाเคเคฒ เคे เค
ंเคฆเคฐ Matter เคो เคฒिเค เคธเคเคคे เคนै |
Syntax : $ cat ร > ram↵
Ram is a good boy.
เคเคธे save เคเคฐเคจे เคे เคฒिเค เคนเคฎें ctrl+d, ctrl+z press เคเคฐเคจा เคนोเคคा เคนै |
-
Cat command เคा use new file create เคเคฐเคจे เคे เคธाเคฅ–เคธाเคฅ เคนเคฎ เคเคธ file เคฎें matter เคญी เคฒिเค เคธเคเคคे เคนै |
Syntax : $ cat ร >yash↵
Yash is a last student (ctrl+d) เคฏा (ctrl+z) -
Cat command เคा use file เคฎें เคฒिเคे เคเค matter เคो Edit เคฏा Change เคเคฐเคจे เคे เคฒिเค เคญी เคिเคฏा เคाเคคा เคนै |
Syntax : $ cat ร >yash↵
Yash is a good boy (ctrl+d) -
Cat command เคा use file เคฎें เคฒिเคे เคเค matter เคो เคिเคธी เคฆूเคธเคฐे file เคฎें copy เคเคฐเคจे เคे เคฒिเค เคिเคฏा เคाเคคा เคนै |
Syntax : $ cat ร old file name ร > torgate file name↵
Exp. cat ร ram ร >yash
Ram is a good boy. -
Cat command เคा use file เคฎें เคฒिเคे เคเค matter เคो เคिเคธी เคฆूเคธเคฐे file เคฎें copy เคเคฐเคจे เคे เคธाเคฅ matter เคो over write เคเคฐ เคธเคเคคे เคนै เค
เคฐ्เคฅाเคค् เคตเคน matter เคเค เคฌाเคฐ เคเคฐ copy เคนोเคा |
Syntax : $ cat ร ram ร >>yash↵
Ram is a good boy.
Ram is a good boy. -
cat ร-n file name command เคे use เคธे เคนเคฎ เคिเคธी เคญी file เคฎें เคिเคคเคจे line เคนै เคเคธे number เคे เคฐूเคช เคฎें เคฆेเค เคธเคเคคे เคนै |
Syntax : $ cat ร-n file name↵
Exp. cat ร-n yash↵
Ram is a good boy.
Ram is a good boy.
Remove/Delete
9) Rm :- เคเคธ command เคा use text file เคो delete เคเคฐเคจे เคे เคฒिเค เคिเคฏा เคाเคคा เคนै |
Syntax : $ rm ร file name↵
Exp. rm ร yash↵
-
Rm ร-i :- เคเคธ command เคा use เคญी text file เคो delete เคเคฐเคจे เคे เคฒिเค เคिเคฏा เคाเคคा เคนै เคชเคฐเคจ्เคคु เคเคธเคฎें เคเคฌ เคนเคฎ file เคो rm ร-i เคฆेเคคे เคนै เคคो เคนเคฎเคธे เคชूเคเคคा เคนै file เคो delete เคเคฐเคจा เคนै เคฏा เคจเคนी เคฏเคฆि เคเคฐเคจा เคนै เคคो Y เคฏा N press เคเคฐเคคे เคนै |
Syntax : $ rm ร-i ร file name↵
Exp. rm ร-i ร yash↵
rm : remove regular file ‘yash’ ? (Y/N)
$ which rm↵
alias rm = ‘rm’-i
/bin/rm (rm-i,rm เคा เคกुเคช्เคฒीเคेเค เคนै ) -
Rm ร-r :- เคเคธ command เคी เคธเคนाเคฏเคคा เคธे เคนเคฎ เคिเคธी เคญเคฐी file เคฏा folder เคो delete เคเคฐ เคธเคเคคे เคนै |
Syntax : $ rm ร-r ร abc↵
Exp. mkdir ร abc↵ (Directory)
touch ร abc / test (File)
rm ร-r ร abc (Delete) -
Rm ร-f :- เคเคธ command เคी เคธเคนाเคฏเคคा เคธे เคนเคฎ เคिเคธी เคญी file เคฏा folder เคो delete เคเคฐเคจे เคे เคฒिเค เคเคฐเคคे เคนै |เคชเคฐ เคเคธ command เคฎें เคนเคฎเคธे เคชूเคेเคा เคญी เคจเคนी เคी file เคฏा folder เคो delete เคเคฐเคจा เคนै เคฏा เคจเคนी Direct file irect file เคฏा folder เคो delete เคเคฐ เคฆेเคा |
Syntax : $ rm ร-f ร file name เคฏा folder name↵
10) Whatis :- เคเคธ command เคी เคธเคนाเคฏเคคा เคธे เคिเคธ command เคे เคฌाเคฐे เคฎें Help เคฒेเคจा เคाเคนเคคे เคนै เคเคธเคे เคฌाเคฐे เคฎें Single line description เคตिเคตเคฐเคฃ เคฆेเคคा เคนै |
Syntax : $ whatis รrm↵
11) Man :- เคเคธ command เคी เคธเคนाเคฏเคคा เคธे เคนเคฎ เคिเคธ เคญी command เคे เคฌाเคฐे เคฎें Help เคाเคนเคคे เคนै เคเคธเคा เคชूเคฐा manual เคฆेเคคा เคนै |
Syntax : $ man รrm↵ (เคฌाเคนเคฐ เคเคจे เคे เคฒिเค Q press เคเคฐเคจा เคนै)
12) Info :- เคเคธ command เคा use เคिเคธी เคญी command เคी information เคฆेเคเคจे เคे เคฒिเค เคी เคाเคคी เคนै |
Syntax : $ info รrm↵
13) Help :- เคเคธ command เคा use เคिเคธी เคญी command เคी help เคธे related เคाเคจเคाเคฐी เคฆेเค เคธเคเคคे เคนै |
Syntax : $ rmร- -help↵
14) Which :- เคเคธ command เคी เคธเคนाเคฏเคคा เคธे เคนเคฎ เคिเคธ เคญी command เคे เคฌाเคฐे เคฎें เคाเคจเคจा เคाเคนเคคे เคนै เคตเคน เค्เคฏा command เคนै เคเคฐ เคตเคน command เคिเคธ เคเคเคน store เคนै เคเคธे เคฆेเค เคธเคเคคे เคนै |
Syntax : $ which รrm↵
alias rm = ‘rm-i’
/bin/rm
15) Cd/user/share/doc :- เคเคธเคธे เคนเคฎ linux เคे เค
ंเคฆเคฐ เคिเคคเคจी file เคเคฒ เคฐเคนी เคนै เคเคฐ เคเคธเคे file เคे เค
ंเคฆเคฐ เคाเคเคฐ read เคญी เคเคฐ เคธเคเคคे เคนै |
Syntax : cd/user/share/doc↵
Ls
Display file
Ls
Display all file
cdร help
/user/share/doc/help $ cotร README
All read
16) Mv :- เคเคธ command เคी เคธเคนाเคฏเคคा เคธे เคนเคฎ file เคो เคเค เคธ्เคฅाเคจ เคธे เคฆूเคธเคฐे เคธ्เคฅाเคจ เคฎें move เคเคฐ เคธเคเคคे เคนै |
Syntax : mvร file name ร move folder name↵
-
เคเคธ command เคी เคธเคนाเคฏเคคा เคธे เคนเคฎ file เคा เคจाเคฎ เคญी change เคเคฐ เคธเคเคคे เคนै |
Syntax : mvร old file nameร new file name↵
Exp. mvร newร new file↵
- เคเคธ command เคी เคธเคนाเคฏเคคा เคธे เคนเคฎ file เคो move เคเคฐเคจे เคे เคธाเคฅ-เคธाเคฅ file เคा เคจाเคฎ เคญी change เคเคฐ เคธเคเคคे เคนै |
17) History :- เคเคธ command เคी เคธเคนाเคฏเคคा เคธे เคนเคฎ เคชเคนเคฒे เคिเคคเคจे เคญी command use เคिเคฏे เคนै เคตเคน display เคนोเคคा เคนै |
Syntax – history↵
linux เคฎें เคนเคฎ เคिเคธी เคญी file เคो hidden เคो เคเคฐเคจे เคे เคฒिเค file เคे เคจाเคฎ เคे เคชเคนเคฒे (.) เคฒเคเคจा เคชเฅเคคा เคนै |
Syntax – mvร old file name ร.new file name↵
mvร pen ร .pen↵
hidden file เคो เคฆेเคเคจे เคे เคฒिเค lsร-a command เคा use เคिเคฏा เคाเคคा เคนै
Syntax : ls ร-a↵
18) ls :- เคเคธ command เคा use เคนเคฎ current location path เคฎें เคเคชเคธ्เคฅिเคค directory เคเคฐ เคซाเคเคฒ เคो เคฆेเคเคจे เคे เคฒिเค เคिเคฏा เคाเคคा เคนै |
Syntax : ls↵
-
ls ร path name :- เคฏเคฆि เคนเคฎ directory เคฎें เคนै เคเคฐ เคนเคฎे desktop directory เคฎें เคिเคคเคจे directory เคเคฐ เคซाเคเคฒ เคนै เคฎें เคนเคฎ เคธเคญी เคฆेเค เคธเคเคคे เคนै |
Syntax : ls ร path name(directory name)↵
Exp. ls ร desktop↵ -
ls ร –l :- เคเคธ command เคธे เคนเคฎ เคिเคธ เคญी directory เคฎें เคนै เคเคธเคी long list เคฆेเค เคธเคเคคे เคนै |
Syntax : ls ร –l↵ -
ls ร –a :- เคเคธ command เคธे เคนเคฎ เคธเคญी เคช्เคฐเคाเคฐ เคी file เคฏा directory เคो เคฆेเค เคธเคเคคे เคนै normal file เคนो เคฏा hidden file เคนो |
Syntax : ls ร –a↵ (list all) -
ls ร ? :- เคเคธ command เคธे เคेเคตเคฒ เคเค character เคชเคนเคฒा file display เคนोเคคा เคนै |
Syntax : ls ร ?↵
Exp. a,b,c
Note - ls ร เคเคฐเคे เคนเคฎ เคिเคคเคจा เคญी ? เคฒเคाเคฏेंเคे เคเคคเคจा character เคा file display เคนोเคा | -
ls ร character* :- เคเคธ command เคธे เคนเคฎ เคिเคธ character เคธे เคถुเคฐू เคนोเคจे เคตाเคฒी file เคो เคนเคฎ เคฆेเค เคธเคเคคे เคนै |
Exp. ls รa*↵ (aเคธे เคถुเคฐू เคนोเคจे เคตाเคฒी file display)
ls รb*↵ (b เคธे เคถुเคฐू เคนोเคจे เคตाเคฒी file display)
19) Cp :- เคเคธ command เคी เคธเคนाเคฏเคคा เคธे เคนเคฎ file เคो copy เคเคฐ เคธเคเคคे เคนै เคเคฐ copy เคเคฐเคจे เคे เคธाเคฅ-เคธाเคฅ file เคो Rename เคเคฐเคे เคญी copy เคเคฐ เคธเคเคคे เคนै |
Syntax : cpร file name รdirectory name↵
Exp. cpร Amit รDesktop↵ (เคฌเคธ file copy เคนोเคा)
cpร Amit รDesktop/Amit↵ (file เคคो copy เคนोเคा เคชเคฐ rename เคญी เคนोเคा)
20) History-c :- เคเคธ command เคธे เคนเคฎ เคธเคญी History เคो delete เคเคฐ เคธเคเคคे เคนै |
Syntax : historyร-c↵
!(exalotion mark)
! รnumber – เคเคธ command เคธे เคนเคฎ history display เคนुเค command เคฏเคฆि เคिเคธ number เคฎें เคนो เคเคธे type เคเคฐเคे use เคเคฐ เคธเคเคคे เคนै |
Exp. History
cp
clear
Exp. !2
!c (bottom to top)
21) Clear :- เคเคธ command เคธे เคนเคฎ screen เคो เคธाเฅ เคเคฐ เคธเคเคคे เคนै |
Syntax : clear↵
22) Cal :- เคเคธ command เคธे เคนเคฎ current month เคी calender เคो เคฆेเค เคธเคเคคे เคนै
Syntax : cal↵
-
เคฏเคฆि เคนเคฎें เคिเคธी เคญी เคชुเคฐे เคธाเคฒ เคा calender เคฆेเคเคจा เคนो เคคो -
Syntax : Calร year↵
Calร 2022↵
เคเคธเคธे 2022 เคा calender display เคนोเคा เคเคฐ เคเคชเคฐ เคจिเคे เคे เคฒिเค (shift+PgUp) (Pgdn)press เคเคฐेंเคे | -
เคฏเคฆि เคนเคฎे เคिเคธी เคญी เคฎें 1month เคा calender เคฆेเคเคจा เคนो เคคो –
Syntex : Calร monthร year↵
Calร 05ร 2000↵
23) Bc :- เคเคธ command เคธे เคนเคฎ basic calculator เคो use เคเคฐ เคธเคเคคे เคนै |
Syntex : bc↵
2+3
5 (เคฌाเคนเคฐ เคเคจे เคे เคฒिเค quit type เคเคฐเคจा เคชเฅेเคा)
24) W :- เคเคธ command เคธे เคนเคฎें เคฏเคน เคชเคคा เคเคฒเคคा เคนै เคी เคนเคฎाเคฐे root directory เคฎें เคिเคคเคจे user เคाเคฎ เคเคฐ เคฐเคนे เคนै |
Syntex : w↵
Exp. 1user
25) Whoami :- เคเคธ command เคธे เคนเคฎें เคชเคคा เคเคฒेเคा เคी เคนเคฎ เคเคนा เคชเคฐ เคाเคฎ เคเคฐ เคฐเคนे เคนै |
Syntex : whoami↵
Exp. yash เคฎै yash เคे เค
ंเคฆเคฐ เคाเคฎ เคเคฐ เคฐเคนा เคนूँ |
26) Wc (word count) :- เคเคธ command เคธे เคนเคฎ file เคฎें line,charecters,words เคो count เคเคฐ เคธเคเคคे เคนै |
-l number &line - wc ร-l ร file name↵
-c number character - space count เคเคฐเคे เคฌเคคाเคคा เคนै |
-w number &word - wc ร - w ร file name↵
27)Diff – เคเคธ command use เคฆो file เคो compare เคเคฐเคจे เคे เคฒिเค เคिเคฏा เคाเคคा เคนै |
- เคฏเคฆि เคฆोเคจों เคฎें same word เคฒिเคे เคนै เคคो เคुเค เคญी เคจเคนीं เคฆिเคेเคा |
- b) เคฏเคฆि เคฆोเคจों เคฎें เคुเค word some เคเคฐ เคुเค word เค เคฒเค เคตो เคคो เค เคฒเค word display เคนोเคคा เคนै |
exp – cat > z1 ↵
hello
cat > z2↵
hello
เคฆोเคจों file เคฎें same word เคฒिเคा เคนै เคคो เคुเค เคญी เคจเคนी display เคนोเคा |
exp – cat > a1 ↵
hello
cat > a2 ↵
hello
my name
เคเคธเคฎें เคฆोเคจों file เคฎें my name เค เคฒเค word เคนै เคคो เคตเคนी display เคนोเคा | > my name
28)date – เคเคธ command เคธे เคนเคฎ current date เคฆेเค เคธเคเคคे เคนै เคเคฐ เคเคธे change เคเคฐ เคธเคเคคे เคนै |
syntex – date ↵
change - date ร month date hour minute year ↵
29) kill – เคเคธ command เคธे เคนเคฎ เค
เคชเคจे system เคฎें เคเคฒ เคฐเคนे เคिเคธी program/command เคो kill เคฏा เคฐोเค เคธเคเคคे เคนै |
syntex – kill ร command ↵
30) ps ร –a – เคเคธ command เคा use prossed id เคฆेเคเคจे เคे เคฒिเค เคिเคฏा เคाเคคा เคนै |
syntex - ps ร -a ↵
31) du ร –h – เคเคธ command เคธे เคนเคฎ เคिเคธी เคญी file เคฏा folder เคी size เคฆेเค เคธเคเคคे เคนै |
syntex – du ร –h ร filename/dirname ↵
32) chmod – เคเคธ command เคा use file เคी permission เคो เคฌเคฆเคฒเคจे เคे เคฒिเค เคिเคฏा เคนै |
syntex – chmod ร rw-rw-rw-file ↵
33) logname – เคเคธ เคเคฎांเคก เคा use user เคे logname เคो เคฆेเคเคจे เคे เคฒिเค เคिเคฏा เคाเคคा เคนै |
syntax – logname ↵
34) who - เคเคธ เคเคฎांเคก เคा use เคตเคฐ्เคคเคฎाเคจ เคธเคฎเคฏ เคฎें เคौเคจ – เคौเคจ เคธे เคฏूเคเคฐ login เคนै เคเคธเคी เคाเคจเคाเคฐी เคช्เคฐเคฆเคฐ्เคถिเคค เคเคฐเคคी เคนै |
syntax – who ↵
35) passwd – เคเคธ เคเคฎांเคก เคा use login เคนुเค เคฏूเคเคฐ เคा password change เคเคฐเคจे เคे เคฒिเค เคिเคฏा เคाเคคा เคนै |
syntax - passwd ↵
36) sort – เคเคธ เคเคฎांเคก เคा use file เคฎें เคฒिเคे เคंเคेंเค เคो เค्เคฐเคฎเคฌเคฆ्เคง เคเคฐเคจे เคे เคฒिเค เคिเคฏा เคाเคคा เคนै |
syntax – sort ร filename ↵
sort –r Reverse normal order
sort –n sort in numeric order
sort –nr sort in reverse numeric order
37) grep – เคเคธ เคเคฎांเคก เคा use text file เคฎें เคिเคธी เคถเคฌ्เคฆ เคो เคोเคเคจे เคे เคฒिเค เคिเคฏे เคाเคคा เคนै |
เคैเคธे เคฏเคฆि เคนเคฎें เคเค เคถเคฌ्เคฆ “the” เคो song file เคฎें เคोเคเคจा เคนै เคคो –
syntax – grep ร word ร filename ↵
exp. – grep the song
38) echo – เคเคธ เคเคฎांเคก เคा use เคถैเคฒ programming เคฎें mesaage เคช्เคฐเคฆเคฐ्เคถिเคค เคเคฐเคจे เคे เคฒिเค เคिเคฏा เคाเคคा เคนै |
syntax – echo ร message ↵
39) vi – เคเคธ เคเคฎांเคก เคा use text file เคฌเคจाเคจे เคฎें เคฏा เคฌเคจी เคนुเค เคซाเคเคฒ เคो เคธंเคถोเคงिเคค เคเคฐเคจे เคे เคฒिเค เคिเคฏा เคाเคคा เคนै |
syntax – vi ร filename ↵
Post a Comment
If you have any doubts,Please let me know