mb_convert_encoding();
我直接调用函数:mb_convert_encoding();却提示此函数未定义,”Call to undefined function:mb_convert_encoding()”,
1、需要加载php_mbstring扩展
2、windows下修改php.ini文件
把;extension=php_mbstring.dll前的分号去掉,重起apache
我直接调用函数:mb_convert_encoding();却提示此函数未定义,”Call to undefined function:mb_convert_encoding()”,
1、需要加载php_mbstring扩展
2、windows下修改php.ini文件
把;extension=php_mbstring.dll前的分号去掉,重起apache
64位技术:这里的64位技术是相对于32位而言的,这个位数指的是CPU GPRs(General-Purpose Registers,通用寄存器)的数据宽度为64位,64位指令集就是运行64位数据的指令,也就是说处理器一次可以运行64bit数据。64bit处理器并非现在才有的,在高端的RISC(Reduced Instruction Set Computing,精简指令集计算机)很早就有64bit处理器了,比如SUN公司的UltraSparc Ⅲ、IBM公司的POWER5、HP公司的Alpha等。
64bit计算主要有两大优点:可以进行更大范围的整数运算;可以支持更大的内存。不能因为数字上的变化,而简单的认为64bit处理器的性能是32bit处理器性能的两倍。实际上在32bit应用下,32bit处理器的性能甚至会更强,即使是64bit处理器,目前情况下也是在32bit应用下性能更强。所以要认清64bit处理器的优势,但不可迷信64bit。
要实现真正意义上的64位计算,光有64位的处理器是不行的,还必须得有64位的操作系统以及64位的应用软件才行,三者缺一不可,缺少其中任何一种要素都是无法实现64位计算的。目前,在64位处理器方面,Intel和AMD两大处理器厂商都发布了多个系列多种规格的64位处理器;而在操作系统和应用软件方面,目前的情况不容乐观。因为真正适合于个人使用的64位操作系统现在就只有Windows XP X64,而Windows XP X64本身也只是一个过渡性质的64位操作系统,在Windows Vista发布以后就将被淘汰,而且Windows XP X64本身也不太完善,易用性不高,一个明显的例子就是各种硬件设备的驱动程序很不完善,而且现在64位的应用软件还基本上没有,确实硬件厂商和软件厂商也不愿意去为一个过渡性质的操作系统编写驱动程序和应用软件。所以要想实现真正的64位计算,恐怕还得等到Windows Vista普及一段时间之后才行。
目前主流CPU使用的64位技术主要有AMD公司的AMD64位技术、Intel公司的EM64T技术、和Intel公司的IA-64技术。其中IA-64是Intel独立开发,不兼容现在的传统的32位计算机,仅用于Itanium(安腾)以及后续产品Itanium 2,一般用户不会涉及到,因此这里仅对AMD64位技术和Intel的EM64T技术做一下简单介绍。
AMD64位技术X86-64:
AMD64的位技术是在原始32位X86指令集的基础上加入了X86-64扩展64位X86指令集,使这款芯片在硬件上兼容原来的32位X86软件,并同时支持X86-64的扩展64位计算,使得这款芯片成为真正的64位X86芯片。这是一个真正的64位的标准,X86-64具有64位的寻址能力。
X86-64新增的几组CPU寄存器将提供更快的执行效率。寄存器是CPU内部用来创建和储存CPU运算结果和其它运算结果的地方。标准的32-bit x86架构包括8个通用寄存器(GPR),AMD在X86-64中又增加了8组(R8-R9),将寄存器的数目提高到了16组。X86-64寄存器默认位64-bit。还增加了8组128-bit XMM寄存器(也叫SSE寄存器,XMM8-XMM15),将能给单指令多数据流技术(SIMD)运算提供更多的空间,这些128位的寄存器将提供在矢量和标量计算模式下进行128位双精度处理,为3D建模、矢量分析和虚拟现实的实现提供了硬件基础。通过提供了更多的寄存器,按照X86-64标准生产的CPU可以更有效的处理数据,可以在一个时钟周期中传输更多的信息。
EM64T技术
Intel官方是给EM64T这样定义的:EM64T全称Extended Memory 64 Technology,即扩展64bit内存技术。EM64T是Intel IA-32架构的扩展,即IA-32e(Intel Architectur-32 extension)。IA-32处理器通过附加EM64T技术,便可在兼容IA-32软件的情况下,允许软件利用更多的内存地址空间,并且允许软件进行32 bit线性地址写入。EM64T特别强调的是对32 bit和64 bit的兼容性。Intel为新核心增加了8个64 bit GPRs(R8-R15),并且把原有GRPs全部扩展为64 bit,这样可以提高整数运算能力。增加8个128bit SSE寄存器(XMM8-XMM15),是为了增强多媒体性能,包括对SSE、SSE2和SSE3的支持。
Intel为支持EM64T技术的处理器设计了两大模式:传统IA-32模式(legacy IA-32 mode)和IA-32e扩展模式(IA-32e mode)。在支持EM64T技术的处理器内有一个称之为扩展功能激活寄存器(extended feature enable register,IA32_EFER)的部件,其中的Bit10控制着EM64T是否激活。Bit10被称作IA-32e模式有效(IA-32e mode active)或长模式有效(long mode active,LMA)。当LMA=0时,处理器便作为一颗标准的32 bit(IA32)处理器运行在传统IA-32模式;当LMA=1时,EM64T便被激活,处理器会运行在IA-32e扩展模式下。
目前AMD方面支持64位技术的CPU有Athlon 64系列、Athlon FX系列和Opteron系列。Intel方面支持64位技术的CPU有使用Nocona核心的Xeon系列、使用Prescott 2M核心的Pentium 4 6系列和使用Prescott 2M核心的P4 EE系列。
浅谈 EM64T技术和AMD64区别X86-64 (AMD64 / EM64T) :
AMD公司设计,可以在同一时间内处理64位的整数运算,并兼容于X86-32架构。其中支持64位逻辑定址,同时提供转换为32位定址选项;但数据操作指令默认为32位和8位,提供转换成64位和16位的选项;支持常规用途寄存器,如果是32位运算操作,就要将结果扩展成完整的64位。这样,指令中有“直接执行”和“转换执行”的区别,其指令字段是8位或32位,可以避免字段过长。
x86-64(AMD64)的产生也并非空穴来风,x86处理器的32bit寻址空间限制在4GB内存,而IA-64的处理器又不能兼容x86。 AMD充分考虑顾客的需求,加强x86指令集的功能,使这套指令集可同时支持64位的运算模式,因此AMD把它们的结构称之为x86-64。在技术上 AMD在x86-64架构中为了进行64位运算,AMD为其引入了新增了R8-R15通用寄存器作为原有X86处理器寄存器的扩充,但在而在32位环境下并不完全使用到这些寄存器。原来的寄存器诸如EAX、EBX也由32位扩张至64位。在SSE单元中新加入了8个新寄存器以提供对SSE2的支持。寄存器数量的增加将带来性能的提升。与此同时,为了同时支持32和64位代码及寄存器,x86-64架构允许处理器工作在以下两种模式:Long Mode(长模式)和Legacy Mode(遗传模式),Long模式又分为两种子模式(64bit模式和Compatibility mode兼容模式)。该标准已经被引进在AMD服务器处理器中的Opteron处理器。
而今年也推出了支持64位的EM64T技术,再还没被正式命为EM64T之前是IA32E,这是英特尔64位扩展技术的名字,用来区别X86指令集。Intel的EM64T支持64位sub-mode,和AMD的X86-64技术类似,采用64位的线性平面寻址,加入8个新的通用寄存器(GPRs),还增加8个寄存器支持SSE指令。与AMD相类似,Intel的64位技术将兼容IA32和IA32E,只有在运行64位操作系统下的时候,才将会采用IA32E。IA32E将由2个sub-mode组成:64位sub-mode和32位sub-mode,同AMD64一样是向下兼容的。 Intel的EM64T将完全兼容AMD的X86-64技术。现在Nocona处理器已经加入了一些64位技术,Intel的Pentium 4E处理器也支持64位技术。
应该说,这两者都是兼容x86指令集的64位微处理器架构,但EM64T与AMD64还是有一些不一样的地方,AMD64处理器中的NX位在Intel的处理器中将没有提供。
Grep的常用命令语法1. 双引号引用和单引号引用
在g r e p命令中输入字符串参数时,最好将其用双引号括起来。例如:”m y s t r i n g”。这样做有两个原因,一是以防被误解为 s h e l l命令,二是可以用来查找多个单词组成的字符串,例如:”jet plane”,如果不用双引号将其括起来,那么单词 p l a n e将被误认为是一个文件,查询结果将返回”文件不存在”的错误信息。
在调用变量时,也应该使用双引号,诸如: g r e p”$ M Y VA R”文件名,如果不这样,将
没有返回结果。
在调用模式匹配时,应使用单引号.[root@mypc ]# echo `grep 123 111.txt` (#注意是反单引号)
2. 常用的g r e p选项有:
-c 只输出匹配行的计数。
-i 不区分大小写(只适用于单字符)。
-h 查询多文件时不显示文件名。
-l 查询多文件时只输出包含匹配字符的文件名。
-n 显示匹配行及行号。
-s 不显示不存在或无匹配文本的错误信息。
-v 显示不包含匹配文本的所有行。
3. 特殊的–在多个文件中进行查询
$ grep “sort”*.doc ( #在当前目录下所有. d o c文件中查找字符串”s o r t”)
$ grep “sort it” * (#或在所有文件中查询单词”sort it”)
接下来的所有示例是指在单个文件中进行查询
4. 行匹配
$ grep -c “48″ data.f
$ 4 (#g r e p返回数字4,意义是有4行包含字符串”4 8″。)
$ grep “48″ data.f (#显示包含”4 8″字符串的4行文本)
5. 显示满足匹配模式的所有行行数:
[root@mypc oid2000]# grep -n 1234 111.txt
1:1234
3:1234ab
6. 精确匹配
[root@mypc oid2000]# grep “1234\>” 111.txt
1234
7. 查询空行,查询以某个条件开头或者结尾的行。
结合使用^和$可查询空行。使用- n参数显示实际行数
[root@mypc oid2000]# grep -n “^$” 111.txt (返回结果 2: #说明第二行是空行)
[root@mypc oid2000]# grep -n “^abc” 111.txt (#查询以abc开头的行)
[root@mypc oid2000]# grep -n “abc$” 111.txt (#查询以abc结尾的行)
8. 匹配特殊字符,查询有特殊含义的字符,诸如$ . ‘ ” * [] ^ | \ + ? ,必须在特定字符前加\。
[root@mypc oid2000]# grep “\.” 111.txt (#在111.txt中查询包含”.”的所有行)
[root@mypc oid2000]# grep “my\.conf” 111.txt (#查询有文件名my. c o n f的行)
9. 目录的查询
[root@mypc oid2000]# ls -l |grep “^d” (#如果要查询目录列表中的目录)
[root@mypc oid2000]# ls -l |grep “^d[d]” (#在一个目录中查询不包含目录的所有文件)
[root@mypc]# ls -l |grpe “^d…..x..x” (#查询其他用户和用户组成员有可执行权限的目录集合)
Awk的常用命令语法
awk命令擅长格式化报文或从一个大的文本文件中抽取数据包,下面是该命令的基本语法
awk [-F filed-separator] “commands” input-file(s)
[ - F域分隔符]是可选的,a w k使用空格作为缺省的域分隔符,如果在要处理的文件中是以冒号作为分割域的(如passwd文件),则在处理的时候要这样指明 awk -F: command input-file(s)
1.1域和记录
a w k执行时,其浏览域标记为$ 1,$ 2 . . . $ n。这种方法称为域标识。使用$ 1 , $ 3表示参照第1和第3域,注意这里用逗号做域分隔。如果希望打印一个有 5个域的记录的所有域,不必指明 $ 1 , $ 2 , $ 3 , $ 4 , $ 5,可使用$ 0,意即所有域。
1.2保存a w k输出
$ awk ‘{print $0}’ input-files > out-files (#重定向保存输出)
$ awk ‘{print $0}’ input-files | tee out-files (#使用t e e命令,输出到文件的同时输出到屏幕)
1.3 常用的awk命令举例
[root@mypc /]# awk ‘$0 ~ /user/’ /etc/passwd (#如果某域含有user就将该行打印出来)
rpc:x:32:32:Portmapper RPC user:/:/sbin/nologin
rpcuser:x:29:29:RPC Service User:/var/lib/nfs:/sbin/nologin
[root@mypc /]# awk ‘/user/’ /etc/passwd (#同上)
[root@mypc /]# awk -F: ‘{if ($5 ~ /user/) print $0}’ /etc/passwd (#如第五域有user则输出该行)
rpc:x:32:32:Portmapper RPC user:/:/sbin/nologin
[root@mypc /]# ifconfig | awk ‘/inet/{print $2}’ (#从ifconfig的输出中抽取含inet的行并打印第二域)
[root@mypc /]# ifconfig | awk ‘/inet/{print $2}’ | awk -F: ‘{print $2}’ (#在上面的基础上再抽取,这个命令可以让你直接得到本机的ip地址)
Sed的常用命令语法
Sed是一个非交互性文本流编辑器。它编辑文件或标准输入导出的文本拷贝。
1.行的匹配
[root@mypc /]# sed -n ‘2p’ /etc/passwd 打印出第2行
[root@mypc /]# sed -n ‘1,3p’ /etc/passwd 打印出第1到第3行
[root@mypc /]# sed -n ‘$p’ /etc/passwd 打印出最后一行
[root@mypc /]# sed -n ‘/user/’p /etc/passwd 打印出含有user的行
rpc:x:32:32:Portmapper RPC user:/:/sbin/nologin
rpcuser:x:29:29:RPC Service User:/var/lib/nfs:/sbin/nologin
[root@mypc /]# sed -n ‘/\$/’p /etc/passwd 打印出含有$元字符的行,$意为最后一行
2.插入文本和附加文本(插入新行)
[root@mypc /]# sed -n ‘/FTP/p’ /etc/passwd 打印出有FTP的行
ftp:x:14:50:FTP User:/var/ftp:/sbin/nologin
[root@mypc /]# sed ‘/FTP/ a\ 456′ /etc/passwd 在含有FTP的行后面新插入一行,内容为456
[root@mypc /]# sed ‘/FTP/ i\ 123′ /etc/passwd在含有FTP的行前面新插入一行,内容为123
[root@mypc /]# sed ‘/FTP/ i\ “123″‘ /etc/passwd在含有FTP的行前面新插入一行,内容为”123″
[root@mypc /]# sed ‘5 a\ 123′ /etc/passwd 在第5行后插入一新行,内容为123
[root@mypc /]# sed ‘5 i\ “12345″‘ /etc/passwd 在第5行前插入一新行,内容为”12345″
3.删除文本
[root@mypc /]# sed ‘1d’ /etc/passwd 删除第1行
[root@mypc /]# sed ‘1,3d’ /etc/passwd 删除第1至3行
[root@mypc /]# sed ‘/user/d’ /etc/passwd 删除带有user的行
4. 替换文本,替换命令用替换模式替换指定模式,格式为:
[ a d d r e s s [,address]] s/ pattern-to-find /replacement-pattern/[g p w n]
[root@mypc /]# sed ’s/user/USER/’ /etc/passwd 将第1个user替换成USER,g表明全局替换
[root@mypc /]# sed ’s/user/USER/g’ /etc/passwd 将所有user替换成USER
[root@mypc /]# sed ’s/user/#user/’ /etc/passwd 将第1个user替换成#user,如用于屏蔽作用
[root@mypc /]# sed ’s/user//’ /etc/passwd 将第1个user替换成空
[root@mypc /]# sed ’s/user/&11111111111111/’ /etc/passwd 如果要附加或修改一个很长的字符串,可以使用( &)命令,&命令保存发现模式以便重新调用它,然后把它放在替换字符串里面,这里是把&放前面
[root@mypc /]# sed ’s/user/11111111111111&/’ /etc/passwd 这里是将&放后面
5. 快速一行命令
下面是一些一行命令集。([ ]表示空格,[ ]表示t a b键)
‘s / \ . $ / / g’ 删除以句点结尾行
‘-e /abcd/d’ 删除包含a b c d的行
‘s / [ ] [ ] [ ] * / [ ] / g’ 删除一个以上空格,用一个空格代替
‘s / ^ [ ] [ ] * / / g’ 删除行首空格
‘s / \ . [ ] [ ] * / [ ] / g’ 删除句点后跟两个或更多空格,代之以一个空格
‘/ ^ $ / d’ 删除空行
‘s / ^ . / / g’ 删除第一个字符
‘s /COL \ ( . . . \ ) / / g’ 删除紧跟C O L的后三个字母
‘s / ^ \ / / / g’ 从路径中删除第一个\
‘s / [ ] / [ ] / / g’ 删除所有空格并用t a b键替代
‘S / ^ [ ] / / g’ 删除行首所有t a b键
‘s / [ ] * / / g’ 删除所有t a b键
如果使用s e d对文件进行过滤,最好将问题分成几步,分步执行,且边执行边测试结果。
经验告诉我们,这是执行一个复杂任务的最有效方式。
http://en.wikipedia.org/wiki/Joe_job
2008-06-24 13:22:26 no host name found for IP address 58.248.7.24
2008-06-24 13:22:27 H=(yahoo.com.cn) [58.248.7.24] Warning: Sender rate 4.1 / 1h
2008-06-24 13:22:28 H=(yahoo.com.cn) [58.248.7.24] F=<lkjww11@yahoo.com.cn> rejected RCPT <info@xxxxx.com>: (yahoo.com.cn) [58.248.7.24] is currently not permitted to relay through this server. Perhaps you have not logged into the pop/imap server in the last 30 minutes or do not have SMTP Authentication turned on in your email client.
/etc/localdomains
/etc/init.d -why the timestamp has been changed ? (files under the folder)
Unix has many commands to list users who are logged in.
These commands include `w`, `who`, and `users`:
To list all users on a Unix system, even the ones who are not logged in, look at the /etc/password file.
$ cat /etc/passwd
...
george:*:1009:1009:George Washington:/home/george:/usr/bin/bash
tom:*:1016:1016:Thomas Jefferson:/home/tom:/usr/bin/bash
al:*:1017:1017:Alexander Hamilton:/home/alex:/usr/bin/bash
...
You can use the `cut` command to only see one field from the password file.
For example, to just see the Unix user names, use the command “$ cat /etc/passwd | cut -d: -f1″.
$ cat /etc/passwd | cut -d: -f1
...
george
tom
al
...
Or, to only see the GECOS field (i.e. the account holders real name), try this:
$ cat /etc/passwd | cut -d: -f5
...
George Washinton
Thomas Jefferson
Alexander Hamilton
...
Note that you will also see Unix system accounts, such as “root
Name |
Manual Page |
Description |
| alias | csh(1) | Create an alias for a command sequence, see csh(1) |
| apropos | apropos(1) | locate commands by keyword lookup |
| banner | banner(1V) | display a string in large letters |
| bc | bc(1) | arbitrary-precision arithmetic language |
| bg | csh(1) | Run a suspended job in the background, see csh(1) |
| cal | cal(1) | display a calendar |
| cancel | lp(1) | send/cancel requests to a printer |
| cat | cat(1V) | concatenate and display |
| cc | cc(1V) | C compiler |
| cd | cd(1) | change working directory |
| chgrp | chgrp(1) | change the group ownership of a file |
| chmod | chmod(1V) | change the permissions mode of a file |
| chsh | passwd(1) | change local or NIS password information |
| clear | clear(1) | clear the terminal screen |
| compress | compress(1) | compress or expand files |
| cp | cp(1) | copy files |
| crontab | crontab(1) | install, edit, remove or list a user’s crontab file |
| csh | csh(1) | shell with a C-like syntax and advanced interactive features |
| date | date(1V) | display or set the date |
| dbx | dbx(1) | source-level debugger |
| df | df(1V) | report free disk space on file systems |
| diff | diff(1) | display line-by-line differences between pairs of text files |
| dircmp | dircmp(1V) | compare directories |
| dirs | csh(1) | Display the directory stack, see csh(1) |
| dos2unix | dos2unix(1) | convert text file from DOS format to ISO format |
| du | du(1V) | display the number of disk blocks used per directory or file |
| echo | echo(1V) | echo arguments to the standard output |
| egrep | grep(1V) | search a file for a string or regular expression |
| eject | eject(1) | eject media device from drive |
| exec | csh(1) | Execute a command in place of the current shell, see csh(1) |
| exit | csh(1) | Exit the current shell, see csh(1) |
| fdformat | fdformat(1) | format diskettes |
| fg | csh(1) | Resume executing a suspended job in the foreground, see csh(1) |
| fgrep | grep(1V) | search a file for a string or regular expression |
| file | file(1) | determine the type of a file by examining its contents |
| find | find(1) | find files by name, or by other characteristics |
| finger | finger(1) | display information about users |
| from | from(1) | display the sender and date of newly-arrived mail messages |
| ftp | ftp(1C) | file transfer program |
| grep | grep(1V) | search a file for a string or regular expression |
| groups | groups(1) | display a user’s group memberships |
| head | head(1) | display first few lines of specified files |
| history | csh(1) | Display recently typed commands, see csh(1) |
| hostid | hostid(1) | print the numeric identifier of the current host |
| hostname | hostname(1) | set or print name of current host system |
| id | id(1V) | print the user name and ID, and group name and ID |
| jobs | csh(1) | List jobs suspended or backgrounded from this shell, see csh(1) |
| kill | kill(1) | send a signal to a process, or terminate a process |
| last | last(1) | indicate last logins by user or terminal |
| limit | csh(1) | Set or display resource limits, see csh(1) |
| line | line(1) | read one line |
| lint | lint(1V) | a C program verifier |
| ln | ln(1V) | make hard or symbolic links to files |
| login | login(1) | log in to the system |
| logname | logname(1) | get the name by which you logged in |
| logout | csh(1) | Terminate a login shell, see csh(1) |
| lp | lp(1) | send/cancel requests to a printer |
| lpq | lpq(1) | display the queue of printer jobs |
| lpr | lpr(1) | send a job to the printer |
| lprm | lprm(1) | remove jobs from the printer queue |
| lpstat | lpstat(1) | display the printer status information |
| ls | ls(1V) | list the contents of a directory |
| mach | mach(1) | display the processor type of the current host |
| man | man(1) | display reference manual pages |
| mesg | mesg(1) | permit or deny messages on the terminal |
| mkdir | mkdir(1) | make a directory |
| more | more(1) | browse or page through a text file |
| mv | mv(1) | move or rename files |
| newgrp | newgrp(1) | log in to a new group |
| nice | nice(1) | run a command at low priority |
| passwd | passwd(1) | change local or password information |
| popd | csh(1) | Pop the directory stack, see csh(1) |
| printenv | printenv(1) | display environment variables currently set |
| ps | ps(1) | display the status of current processes |
| pushd | csh(1) | Push a directory onto the directory stack, see csh(1) |
| pwd | pwd(1) | display the pathname of the current working directory |
| quota | quota(1) | display a user’s disk quota and usage |
| rehash | csh(1) | Rescan the execution path, see csh(1) |
| reset | tset(1) | establish or restore terminal characteristics |
| rlogin | rlogin(1C) | remote login |
| rm | rm(1) | remove (unlink) files or directories |
| rmdir | rm(1) | remove (unlink) files or directories |
| rsh | rsh(1C) | remote shell |
| rup | rup(1C) | show host status of local machines (RPC version) |
| ruptime | ruptime(1C) | show host status of local machines |
| rusers | rusers(1C) | who’s logged in on local machines (RPC version) |
| rwall | rwall(1C) | write to all users over a network |
| rwho | rwho(1C) | who’s logged in on local machines |
| script | script(1) | make typescript of a terminal session |
| setenv | csh(1) | Set or display environment variables, see csh(1) |
| set | csh(1) | Set or display shell variables, see csh(1) |
| sh | sh(1) | standard UNIX system shell and command-level language |
| sleep | sleep(1) | suspend execution for a specified interval |
| sort | sort(1V) | sort and collate lines |
| source | csh(1) | Read commands from a file, see csh(1) |
| spell | spell(1) | report spelling errors |
| spellin | spell(1) | report spelling errors |
| strings | strings(1) | find printable strings in an object file or binary |
| strip | strip(1) | remove symbols and relocation bits from an object file |
| stty | stty(1V) | set or alter the options for a terminal |
| su | su(1V) | super-user, temporarily switch to a new user ID |
| suspend | csh(1) | Suspend the shell, see csh(1) |
| sync | sync(1) | update the super block; force changed blocks to the disk |
| tail | tail(1) | display the last part of a file |
| talk | talk(1) | talk to another user |
| tar | tar(1) | create tape archives, and add or extract files |
| telnet | telnet(1C) | user interface to a remote system using the TELNET protocol |
| time | time(1V) | time a command |
| touch | touch(1V) | update the access and modification times of a file |
| trace | trace(1) | trace system calls and signals |
| tset | tset(1) | establish or restore terminal characteristics |
| tty | tty(1) | display the name of the terminal |
| umask | csh(1) | Set or display the file permissions mask, see csh(1) |
| unalias | csh(1) | Discard an alias, see csh(1) |
| uncompress | compress(1) | compress or expand files, display expanded contents |
| unix2dos | unix2dos(1) | convert text file from ISO format to DOS format |
| unlimit | csh(1) | Remove a limit on a resource, see csh(1) |
| unset | csh(1) | Discard a shell variable, see csh(1) |
| unsetenv | csh(1) | Discard an envrionment variable, see csh(1) |
| uptime | uptime(1) | show how long the system has been up |
| users | users(1) | display a compact list of users logged in |
| uudecode | uuencode(1C) | encode a binary file, or decode its ASCII representation |
| uuencode | uuencode(1C) | encode a binary file, or decode its ASCII representation |
| vacation | vacation(1) | reply to mail automatically |
| w | w(1) | who is logged in, and what are they doing |
| wall | wall(1) | write to all users logged in |
| wc | wc(1) | display a count of lines, words and characters |
| whatis | whatis(1) | display a one-line summary about a keyword |
| whereis | whereis(1) | locate the binary, source, and manual page for a command |
| which | which(1) | locate a command; display its pathname or alias |
| who | who(1) | who is logged in on the system |
| whoami | whoami(1) | display the effective current username |
| whois | whois(1) | Internet user name directory service |
| write | write(1) | write a message to another user |
2、在shell中使用find结合grep进行文件的替换
# find ./ -exec grep str1 ‘{}’ \; -exec sed -i.bak s/str1/str2/g ‘{}’ \;
上面命令可以在当前目录下(包括子目录)查找包含str1的文件,自动替换成str2,并且生成源文件的bak文件
更多方法正在不断收集更新中。。。
Powered by hoder.org