`
xy_z487
  • 浏览: 276789 次
  • 性别: Icon_minigender_1
  • 来自: 北京
社区版块
存档分类
最新评论

linux command remeber

阅读更多

  Linux提供了几百条命令,虽然这些命令的功能不同,但它们的使用方式和规则都是统一的。

  Linux命令的一般格式是:


QUOTE:
    命令名 [选项] [参数1] [参数2]……

◆命令名由小写的英文字母构成,往往是表示相应功能的英文单词或单词的缩写。例如,date表示日期;who表示谁在系统中;cp是copy的缩写,表示拷贝文件等。

    ◆方括号中的部分表明对命令行来讲不是必须的,即可有可无。例如,可以直接在提示符后面输入命令date,显示当前的日期和时间;也可以在date命令名后面带有选项和参数,如date -s 15:30:00,设置系统时间为下午3点30分。

    ◆选项是对命令的特别定义,以-开始,多个选项可用一个-连起来,如ls -l -a与ls -la相同。

    ◆命令行的参数提供命令运行的信息,或者是命令执行过程中所使用的文件名。通常参数是一些文件名,告诉命令从哪里可以得到输入,以及把输出送到什么地方。

    ◆如果命令行中没有提供参数,命令将从标准输入文件(即键盘)接受数据,输出结果显示在标准输出文件(即显示器)上,而错误信息则显示在标准错误输出文件(即显示器)上。可使用重定向功能对这些文件进行重定向。

    ◆命令在正常执行后返回一个0值,表示执行成功;如果命令执行过程中出错,没有完成全部工作,则返回一个非零值(在Shell中可用变量$?查看)。在Shell脚本中,可用命令返回值作为控制逻辑的一部分。

    ◆Linux操作系统的联机帮助对每个命令的准确语法都做了说明,可以使用命令man来获取相应命令的联机说明,如man ls。

 

/bin = BINaries
/dev = DEVices
/etc = ETCetera
/lib = LIBrary
/proc = PROCesses
/sbin = Superuser BINaries
/tmp = TeMPorary
/usr = Unix Shared Resources
/var = VARiable ?
FIFO = First In, First Out
GRUB = GRand Unified Bootloader
IFS = Internal Field Seperators
LILO = LInux LOader
MySQL = My是最初作者女儿的名字,SQL = Structured Query Language
PHP = Personal Home Page Tools = PHP Hypertext Preprocessor
PS = Prompt String
Perl = "Pratical Extraction and Report Language" = "Pathologically Eclectic Rubbish Lister"
Python 得名于电视剧Monty Python's Flying Circus
Tcl = Tool Command Language
Tk = ToolKit
VT = Video Terminal
YaST = Yet Another Setup Tool
apache = "a patchy" server
apt = Advanced Packaging Tool
ar = archiver
as = assembler
awk = "Aho Weiberger and Kernighan" 三个作者的姓的第一个字母
bash = Bourne Again SHell
bc = Basic (Better) Calculator
bg = BackGround
biff = 作者Heidi Stettner在U.C.Berkely养的一条狗,喜欢对邮递员汪汪叫。
cal = CALendar
cat = CATenate
cd = Change Directory
chgrp = CHange GRouP
chmod = CHange MODe
chown = CHange OWNer
chsh = CHange SHell
cmp = compare
cobra = Common Object Request Broker Architecture
comm = common
cp = CoPy
cpio = CoPy In and Out
cpp = C Pre Processor
cron = Chronos 希腊文时间
cups = Common Unix Printing System
cvs = Current Version System
daemon = Disk And Execution MONitor
dc = Desk Calculator
dd = Disk Dump
df = Disk Free
diff = DIFFerence
dmesg = diagnostic message
du = Disk Usage
ed = editor
egrep = Extended GREP
elf = Extensible Linking Format
elm = ELectronic Mail
emacs = Editor MACroS
eval = EVALuate
ex = EXtended
exec = EXECute
fd = file descriptors
fg = ForeGround
fgrep = Fixed GREP
fmt = format
fsck = File System ChecK
fstab = FileSystem TABle
fvwm = F*** Virtual Window Manager
gawk = GNU AWK
gpg = GNU Privacy Guard
groff = GNU troff
hal = Hardware Abstraction Layer
joe = Joe's Own Editor
ksh = Korn SHell
lame = Lame Ain't an MP3 Encoder
lex = LEXical analyser
lisp = LISt Processing = Lots of Irritating Superfluous Parentheses
ln = LiNk
lpr = Line PRint
ls = list
lsof = LiSt Open Files
m4 = Macro processor Version 4
man = MANual pages
mawk = Mike Brennan's AWK
mc = Midnight Commander
mkfs = MaKe FileSystem
mknod = MaKe NODe
motd = Message of The Day
mozilla = MOsaic GodZILLa
mtab = Mount TABle
mv = MoVe
nano = Nano's ANOther editor
nawk = New AWK
nl = Number of Lines
nm = names
nohup = No HangUP
nroff = New ROFF
od = Octal Dump
passwd = PASSWorD
pg = pager
pico = PIne's message COmposition editor
pine = "Program for Internet News & Email" = "Pine is not Elm"
ping = 拟声 又 = Packet InterNet Grouper
pirntcap = PRINTer CAPability
popd = POP Directory
pr = pre
printf = PRINT Formatted
ps = Processes Status
pty = pseudo tty
pushd = PUSH Directory
pwd = Print Working Directory
rc = runcom = run command, rc还是plan9的shell
rev = REVerse
rm = ReMove
rn = Read News
roff = RunOFF
rpm = RPM Package Manager = RedHat Package Manager
rsh, rlogin, rvim中的r = Remote
rxvt = ouR XVT
seamoneky = 我
sed = Stream EDitor
seq = SEQuence
shar = SHell ARchive
slrn = S-Lang rn
ssh = Secure SHell
ssl = Secure Sockets Layer
stty = Set TTY
su = Substitute User
svn = SubVersioN
tar = Tape ARchive
tcsh = TENEX C shell
tee = T (T形水管接口)
telnet = TEminaL over Network
termcap = terminal capability
terminfo = terminal information
tex = τέχνη的缩写,希腊文art
tr = traslate
troff = Typesetter new ROFF
tsort = Topological SORT
tty = TeleTypewriter
twm = Tom's Window Manager
tz = TimeZone
udev = Userspace DEV
ulimit = User's LIMIT
umask = User's MASK
uniq = UNIQue
vi = VIsual = Very Inconvenient
vim = Vi IMproved
wall = write all
wc = Word Count
wine = WINE Is Not an Emulator
xargs = eXtended ARGuments
xdm = X Display Manager
xlfd = X Logical Font Description
xmms = X Multimedia System
xrdb = X Resources DataBase
xwd = X Window Dump
yacc = yet another compiler compiler

 

 

最近有些空闲,于是开始看linux journal杂志,因为水平有限对新文章有很多的不懂,打算从第一期看起,没有想到以前的文章真是很好,体现了linux很多原始设计思想!写这点东西只是做为自己一些笔记,没有什么用途.

       虽然在unix,linux,AIx等操作系统上工作了将近四年,也制作过xteam linux的安装光盘,可就是没有弄明白linux的目录都是做什么用的,为什么在制作ramdisk时必须要那些目录?当看到linux journal 第二期上的The Linux FSSTD这篇文章时才明白,原来这些是linux文件系统规范的!本文的内容是来自URL ftp://tsx-11.mit.edu/pub/linux/docs/old/File_System_Standard在上层目录中有其他版本的文件系统结构标准.一下内容翻译自File_System_Standard:linux文件系统的文件结构的完整实现完全自愿不强制实现,linux标准工作组建议完整实现.linux 文件系统标准做为编写,移植里努西系统上的软件,使得软件在已安装系统上更易于安装,升级,修补.,

Root 目录:

                 文件:  规范没有定义文件;   目录:bin dev etc home lib mnt usr; 基本原则:不要混淆根目录和文件及存放文件的目录,根目录中不应包含用户程序.

/bin 目录:

                文件:sh init mount umount dd cat ls fsck mkfs (其他学要的); 目录:规范不做定义; 基本原则:/bin目录包含可执行程序,他们对恢复出现崩溃的文件系统至关重要./bin下不可执行的需要被正确的放置到其他文件系统中.

/dev目录:

              文件:所有设备文件; 目录:不定义目录; 基本原则:存放标准unix设备文件. 这个目录包含在标准linux内核中支持的所有设备,即便在系统中不存在这样设备也要建立文件.要注意在linux分发包中所有设备文件都存在,但是在安装时可以删除.

/etc 目录:

            文件:mtab passwd rc ttytab(其他需要的); 目录:规范没有明确定义; 基本原则:这里是系统启动所需文件的存放位置.此目录中的文件是系统特定的.系统升级大部分文件需要人的干涉.

/home 目录:

            文件:无; 目录:除去root的每个用户都只有一个; 基本原则:用户初始目录标准位置.root用户目录在/根目录下.

/lib 目录:

            文件:系统初始化时需要的库文件; 目录:规范没有定义; 基本原则:保持root分区精简占用空间小.此目录的文件应该只是被root分区中的文件使用.

/mnt 目录:

            文件:无; 目录:无; 基本原则:外部文件系统的标准挂载点.对于安装子系统必须可用,应该保持一个空目录.

/tmp 目录:

           文件:无; 目录:无; 基本原则:普通程序使用的临时文件空间,可以作为系统启动是挂载分区.

/usr 目录:

            文件:规范没有做出定义; 目录:adm bin spool local lib etc man include src tmp; 基本原则:/usr是第二个文件系统挂载点,它也有文件层次结构.

/usr/adm 目录

             文件:在规范中没有说明; 目录:在规范中没有说明; 基本原则:日志文件和记帐信息的存放位置.

/usr/bin 目录:

              文件:除去在/bin目录中来自标准分发包的所有可执行文件. 目录:规范中没有定义; 基本原则: 标准unix系统中的文件,不应有linux特别需要的.作为unix上的等价程序.

/usr/etc 目录:

             文件:规范中没有定义; 目录:规范中没有定义; 基本原则:包含/usr/bin/中程序需要的配置文件.希望保持/etc的清晰和精简.

/usr/spool 目录:

             文件:规范中没有定义; 目录:uucp mail; 基本原则:包含mail,打印,uucp的缓存文件;也可以做其他卷的挂载点.

/usr/local 目录:

             文件:无; 目录:bin lib etc man src; 基本原则:包含具体系统中的文件,不会被升级进程修改的.

/usr/lib 目录:

              文件:libc.a crt0.s (其他需要的); 目录:规范中没有说明; 基本原则:多用户系统操作中库文件的位置.应用程序使用的库应放在这里.

/usr/man 目录:

               文件:无; 目录:man1 man2 man3 man4 man5 man6 man7 man8  cat1 cat2 cat3 cat4 cat5 cat6 cat7 cat8 ;  基本原则:包含linux标准程序的手册.

/usr/include 目录:

               文件:程序员需要的头文件; 目录:按需要建立; 基本原则:系统头文件的标准位置.

/usr/src 目录:

               文件:无; 目录:bin lib linux usr.bin usr.lib; 基本原则:包含所有发行版中应用程序的源代码./usr/src/linux中包含内核构建需要的目录.

/usr/tmp 目录:

                文件:无; 目录:无; 基本原则:用作程序的额外空间,如果/tmp做挂载点,则/usr/tmp可以符号连接到/tmp.

写东西原来这么难受.还是做完笔记了哈哈!

如果有人看到想给提建议:QQ:20502417, Msn:xujb@softhouse.com.cn


本文来自CSDN博客,转载请标明出处:http://blog.csdn.net/xubai/archive/2006/05/19/745246.aspx

 

http://www.pathname.com/fhs/2.2/

分享到:
评论

相关推荐

    CompTIA.Linux.LPIC-1.Cert.Guide.07897545

    Key Topics icons flag every figure, table, or list you absolutely must understand and remember Chapter-ending Exam Preparation sections deliver even more exercises and troubleshooting scenarios Two ...

    linux in a nutshell

    As with other books in O'Reilly's "In a Nutshell" series, this book is geared toward users who know what they want to do and have some idea how to do it, but just can't remember the correct command ...

    The Red Team Field Manual (RTFM)

    The RTFM contains the basic syntax for commonly used Linux and Windows command line tools, but it also encapsulates unique use cases for powerful tools such as Python and Windows PowerShell....

    2009 达内Unix学习笔记

    DOS内部命令 用于退出当前的命令处理器(COMMAND.COM) 恢复前一个命令处理器。 Ctrl+d 跟exit一样效果,表中止本次操作。 logout 当csh时可用来退出,其他shell不可用。 clear 清屏,清除(之前的内容并未删除,只是...

    Maven-The Complete Reference.pdf

    If you have customized any environment variables, remember to revert them. **2.7 Getting Help with Maven** For help with Maven, refer to the official documentation available on the Apache Maven ...

    MobaXterm Pro 11.0.3816

    Improvement: with default syntax, URLs are now underlined – remember that you can ctrl+click them to open in default browser Improvement: improved size of main executable by removing unused code and ...

    drupal 6.12

    For more information on setting file permissions, see "Modifying Linux, Unix, and Mac file permissions" (http://drupal.org/node/202483) or "Modifying Windows file permissions" ...

    python实现备份目录的方法

    We use the zip command (in Unix/Linux) to put the files in a zip archive zip_command = "zip -qr '%s' %s" % (target, ' '.join(source)) # Run the backup if os.system(zip_command) == 0: print('...

Global site tag (gtag.js) - Google Analytics