資源描述:
《Linux常用命令簡(jiǎn)介》由會(huì)員上傳分享,免費(fèi)在線閱讀,更多相關(guān)內(nèi)容在教育資源-天天文庫。
1、Linux常用命令簡(jiǎn)介一、相關(guān)知識(shí)Bourneshell是一個(gè)早期的shell,由StevenBourne(史蒂夫·伯恩)在1978年前后編寫。Bash(GNUBourne-AgainShell)是關(guān)于Bourneshell的一個(gè)雙關(guān)語(Bourneagain/bornagain),由BrianFox(布萊恩·福克斯)在1987年創(chuàng)造。Ubuntu默認(rèn)的shell是bash,在Ubuntu系統(tǒng)下,bash提供的命令是內(nèi)部命令,其他命令則是外部命令。二、有關(guān)幫助的命令1.help—獲取內(nèi)部命令的幫助信息zgj@wildgrass:~$helpcdcd:cd[-L
2、[
3、-P[-e]]][dir]Changetheshellworkingdirectory.ChangethecurrentdirectorytoDIR.ThedefaultDIRisthevalueoftheHOMEshellvariable.----------------------2.man—獲取外部命令的幫助信息(manual)zgj@wildgrass:~$mancpNAMEcp-copyfilesanddirectoriesSYNOPSIScp[OPTION]...[-T]SOURCEDEST.......................DESCRIPT
4、IONCopySOURCEtoDEST,ormultipleSOURCE(s)toDIRECTORY...............................注:按Q鍵退出幫助。附:常用選項(xiàng)說明:1)man-kkeyword:查找含有關(guān)鍵詞keyword的所有命令,并顯示簡(jiǎn)短的幫助信息。zgj@wildgrass:~$man-kmvmv(1)-move(rename)filesrpmverify(8)-RPMPackageManagerXGetIMValues(3)-open,close,andobtaininputmethodinformation.....
5、...................注:命令名后的數(shù)字表示的意義:1表示可執(zhí)行程序或shell命令;2表示系統(tǒng)調(diào)用;3表示庫函數(shù)調(diào)用;4表示特殊文件(如/dev目錄下的設(shè)備文件);5表示文件格式;6表示游戲;7表示雜項(xiàng);8表示系統(tǒng)管理命令(工具);9表示內(nèi)核例程。2)man-fcommand:顯示命令command的簡(jiǎn)短幫助信息。zgj@wildgrass:~$man-frmdirrmdir(1)-removeemptydirectoriesrmdir(2)-deleteadirectory3.info—獲取外部命令幫助信息zgj@wildgrass:~$inf
6、ocpFile:coreutils.info,Node:cpinvocation,Next:ddinvocation,Up:Basicoperations11.1`cp':Copyfilesanddirectories...........................Synopses:cp[OPTION]...[-T]SOURCEDEST.....................注:按Q鍵退出幫助。4.whatis—顯示命令的簡(jiǎn)短幫助信息zgj@wildgrass:~$whatislsls(1)-listdirectorycontentsLS(6)-displ
7、ayanimationsaimedtocorrectuserswhoaccident...5.apropos—查找含有指定字符串的所有命令,并顯示簡(jiǎn)短的幫助信息zgj@wildgrass:~$apropospwdlckpwdf(3)-getshadowpasswordfileentrypwd(1)-printnameofcurrent/workingdirectorypwdx(1)-reportcurrentworkingdirectoryofaprocess....................三、有關(guān)文件與文本處理的命令1.ls—列出文件清單信息常用選項(xiàng)說明
8、:1)-l:列出詳細(xì)信息zgj@wildgrass:~$ls-lc_c++drwxr-xr-x7zgjzgj40962月1309:18a_bdrwxr-xr-x4zgjzgj40962月1323:08BubbleSort.............................2)-a:列出所有文件(包括隱藏文件)zgj@wildgrass:~$ls-ac_c++.a_bhellohello.c~Hello.c~mytestmytest.c~vsort..BubbleSorthello.cHello.cHelloworldmytest.cStudentx_y注:顯
9、示了隱藏文