看了篇关于解决Ubuntu下的招行网银专业版的使用问题, 便装好了 VirtualBox 1.5.2, 一个Ubuntu下开源的虚拟机软件.
在VirtualBox上安装了 deepin XP 完美精简版 V5.8, 并按照相关的操作, 完全解决了困扰我很久的招行网银的问题!
VirtualBox真的很强大, 它不仅支持多语言, 还开源, 值得一提的是新的版本还支持无缝桌面 (Seamless Mode), 进入无缝桌面模式后, 当你点击windows程序时, 仅显示windows任务栏 (原有的Ubuntu任务栏被隐藏起来了), 当点击ubuntu程序和桌面时, 下方的任务栏便自动切换成原有的Ubuntu任务栏了, 真正地让你的windows (guest)与Linux Ubuntu (host)无缝结合.
于是现在, 除了招行网银搞定外, 什么QQ, MS Office都不再是问题了, 而Zoomplayer, TypeAndRun, Hoekey, Beyond Compare等经典Windows软件也可以正常运行, 终于不用装双系统了!
A Practical Guide to Linux Commands, Editors, and Shell Programming
Chapter 03 Command Line Utilities - 命令行工具 2/2
此章主要介绍最基本和最重要的Linux文本模式下的命令行工具, 以下为本章第2部分.
5) 四个更多的命令 Four more utilities
echo date script unix2dos
+ echo = ECHO 显示一行文本 (displays a line of text)
echo是个看起来非常简单的工具: 复制你在命令行输入的文字, 并再次显示在屏幕上. echo是一个很好的学习Shell或其它程序的工具, 如果你想知道星号 * (asterisk)是在Shell下代表什么意思, 输入以下命令试试: echo star: * (冒号与星号之间要有空格)
+ date = DATE 显示时间和日期 (displays the time and date)
+ script = SCRIPT 记录一段时间内的终端输入输出到文件 (make typescript of terminal session)
script工具可以记录整个或部分系统登陆过程, 包含你所输入的命令和系统的执行结果. 使用方法是输入script开始录制, 输入exit结束录制.
+ unix2dos = UNIX to DOS 把Linux文件格式转换成Windows格式 (converts Linux files to Windows format)
dos2unix功能类似但正好相反.
tip: 在Ubuntu下, 使用下列命令安装unix2dos和dos2unix: sudo apt-get install tofrodos (tofrodos = to from dos), 另外, 工具 flip 也有同样的文本转换功能, 具体请看 man flip.
6) 压缩和归档文件 Compressing and archiving files
bzip2 bunzip2 bzcat gzip gunzip zcat compress tar
+ bzip2 = BZIP2 压缩文件 (compresses a file)
bzip2是 redhat 主导开发的非常有效的文件压缩工具, 比同类的工具gzip和compress的压缩效率都要高. 若被压缩的文件中含有重复的内容, 效率会更高. 执行压缩以后, 会在被压缩文件后面添加.bz2的后缀.
+ bunzip2 = BUNZIP2 解压缩文件 (decompress a file)
++ bzcat = BZip2 CATenate 解压缩文件并输出到标准终端 (decompress a file to standard output)
++ bzip2recover = BZIP2 RECOVER 恢复被损坏的bzip2压缩文件 (recovers data from damaged bzip2 files)
+ gzip = Gnu ZIP 压缩文件 (compresses a file)
bzip2是GNU主导开发的文件压缩工具, 它比bzip2的压缩效率要差些, 但比compress要好. 执行压缩以后, 会在被压缩文件后面添加.gz的后缀.
命令工具gzip, gunzip, zcat与bzip2, bunzip2, bzcat的功能和用法都基本一致.
+ compress = COMPRESS 压缩文件 (compresses a file)
相比bzip2和gzip, compress没有前两者强大. 被compress压缩的文件以.Z结尾.
+ tar = Tape ARchive 打包和解包文件 (packs and unpacks files)
tar命令主要是将多个文件打包成一个文件, 或者反过来使用. 一些重要参数的意义如下: -c (create = 创建), -v (verbose = 显示详细内容), -f (write to or read from a file = 写入或读取文件), 例子: 将当前目录下的三个文件 g b d 打包归档成一个名叫all.tar的文件:
$ tar -cvf all.tar g b d
解包all.tar文件:
$ tar -xvf all.tar (-x = extract) (用-t代替-x可以仅仅查看all.tar文件中的文件清单 -t = table)
+ 你可以使用bzip2, compress或gzip来压缩tar档案文件.
使用bzip2压缩的档案文件后缀名是.tar.bz2, 而gzip压缩的是.tz或.tar.gz, 使用compress压缩的自然也就是.tar.Z了.
+ 标准的解压缩.tar.gz文件需要两步, 下面以一个例子来说明这一过程:
解压缩和解包文件make-3.75.tar.gz (可从ftp.gnu.org/pub/gnu/make/make-3.75.tar.gz下载)
$ ls -l mak*
-rw-r–r– 1 imacee imacee 598078 2007-12-21 21:35 make-3.75.tar.gz
$ gunzip mak*
$ ls -l mak*
-rw-r–r– 1 imacee imacee 2263040 2007-12-21 21:35 make-3.75.tar
$ tar -xvf mak*
make-3.75/README
make-3.75/INSTALL
make-3.75/COPYING
…
make-3.75/make.info-7
make-3.75/make.info-8
++在解压tar文件中, 有2点值得注意:
a. 有时候tar文件会包含许多文件, 在使用-x参数直接解包之前, 最好先用-t参数代替-x参数, 来看一下待解包的文件有多少个 (也就是使用tar -tvf 代替 tar -xvf). 若的确包含文件较多, 请先用mkdir命令建立一个新目录, 把tar文件移动到新目录内, 再使用tar -xvf命令解包. 这样做也可以避免解包出来的文件与原有文件混在一起, 也就避免给操作解包文件(如删除)带来困难.
b. tar命令的-x参数解包时会覆盖原有同名文件, 因此上述将待解包的tar文件放入新建目录中也可避免覆盖.
+ 除了标准两步走解压之外, 当然有更加简便和智能化的, 否则就不叫Linux了
++ 使用管道 | (pipe) 让两个命令合二为一
$ gunzip -c make-3.75.tar.gz | tar -xvf - (不要忘记后面还有个”-”)
gunzip后面的-c参数让gunzip把结果通过管道输出, 而不是创建文件.
++ 让tar使用参数-z调用gunzip
$ tar -xzvf make-3.75.tar.gz
是不是有点熟悉, 这是最常用的命令! 请使用参数-j来调用bunzip2.
7) 定位命令位置 Locating commands
which whereis apropos slocate
+ which = WHICH 定位命令的位置 (locate a command)
which工具通过显示全路径来定位一个命令.
因为有时候, 一个命令会有几个版本, 且分别存在不同位置, 它们都是同名的. 当你执行一个命令时, Shell会搜索一个目录清单, 去寻找你所输入的命令名, 且它会运行它所找到的第一个. 这个目录清单叫做搜索路径 (search path). 我们是可以更改搜索路径的.
因此which工具会告诉你, 你所运行的命令是在什么位置, 因为which也是通过与Shell同样的搜索路径的方式来显示一个命令的位置.
你可以用which which来得到which工具的位置在哪.
+ whereis = WHERE IS 定位一个命令的二进制执行文件, 源文件和帮助文件的位置 (locate the binary, source, and manual page files for a command)
如: $ whereis tar
tar: /bin/tar /usr/include/tar.h /usr/share/man/man1/tar.1.gz
+ 有些命令是内置在Shell里面的, 叫做壳内置命令 (Shell builtins) , which 和 whereis 不会寻找并报告壳内置命令. 也就是说whereis 和 which命令可能会提供错误的信息. 比如, echo是一个壳内置命令.
$ whereis echo
echo: /bin/echo /usr/share/man/man1/echo.1.gz /usr/share/man/man3/echo.3ncurses.gz
$ which echo
/bin/echo
而实际上, Shell执行的是内置在它里面的echo命令, 而不是以上所列出的.
在bash下面, 你可以使用type命令来确认某个命令是否为壳内置命令:
type echo
echo is a shell builtin
+ apropos = APROPOS 搜索命令的帮助手册及其描述 (search the man page names and descriptions)
你可以使用apropos搜索任何关键字, 它实际搜索的是一个whatis数据库(由makewhatis工具维护). 本质是说, apropos 命令与 man -k 命令是完全等同的, 显示的结果也完全相同.
whatis = WHAT IS 显示工具描述 (display manual page descriptions)
whatis与apropos类似, 但只有当要查找的命令名完全匹配时, whatis才显示相应的结果. 所以当你知道一个工具的确切名字, 而不知道它的作用时, 可以使用whatis.
+ slocate = Security enhanced LOCATE 搜索文件 (searches for a file)
slocate命令搜索本地的所有文件!
在使用slocate工具之前, 需要使用updatedb工具来建立/更新slocate的数据库. 当然, 你可以设置把每天自动更新此数据库的工作交给cron脚本, 详情可参考man crontab.
8 ) 获取用户和系统信息 Obtaining user and system information
who w finger write mesg
如果你不在Linux系统网络上, 可以忽略以下信息.
+ who = WHO 显示哪些用户已经登陆系统 (show who is logged on)
如果你想知道你登陆在哪个终端和登陆时间, 可以使用whoami 命令.
+ finger = FINGER 查看用户信息 (lookup user information)
基于安全考虑, 系统管理员可能会禁用finger命令.
+ w = W 查看哪些用户已登陆且他们在做什么 (show who is logged on and what they are doing)
相对来说, w和finger的功能较多, who较少.
+ write = WRITE 发送信息给另外一个用户 (send a message to another user)
+ mesg = MESsaGe 拒绝或接受来自别的用户的信息 (denies or accepts messages)
其它 Others
verbose = 详述 (许多命令中 -v 参数就代表verbose, 意思是详细显示工作状态, 一般在命令执行完以后显示)
A Practical Guide to Linux Commands, Editors, and Shell Programming
Chapter 03 Command Line Utilities - 命令行工具 1/2
此章主要介绍最基本和最重要的Linux文本模式下的命令行工具.
1) 特殊字符 Special characters
+ 特殊字符对Shell来说, 有特殊的意义, 所以尽量不要让文件名中含有特殊字符:
& ; | * ? ‘ ” ` [ ] ( ) $ < > { } ^ # / % ! ~ +
若想知道特殊字符的英文读法, 请看这里.
+ 当然, 回车键 (RETURN), 空格键 (SPACE), TAB键也对Shell有特殊的意义, 也尽量不要用在文件名中.
+ 如果你非要在文件名中使用特殊字符, 也是可以的, 只是在引用时有些麻烦. 引用此文件时, 有2种方法:
++ 在每一个特殊字符前面都加一个反斜线 (backslash), 如你想使用**, 你必须输入 **. 当然, 若你想使用, 你需要输入\.
++ 使用一对单引号 (single quotation marks) 引用特殊字符. 若你想用**, 输入 ‘**’ 即可. 单引号中可以包含一般字符 (regular character), 如 ‘This is a special character:>’ .
2) 基本命令工具 Basic utilities
ls cat rm less more hostname
+ ls = LIst 显示文件名 (displays the names of files)
如 ls -al | less 逐屏显示当前目录的详细文件清单
+ cat = conCATenate 显示文本文件内容 (displays contents of text files)
concatenate的意思是一个一个连接在一起, 所以cat也可以同时显示多个文件的内容, 这里暂不讨论.
+ rm = ReMove 删除文件或目录 (remove files or directories)
默认情况下, rm直接删除指定的文件, 无需经过再次确认. 一个更安全的方法是使用选项-i (i = interactive 互动), 这让你有个互动式的再次确认的机会, 可以有效地防止误删文件, 如:
rm -i toollist
rm: remove regular file ‘toollist’? y
你可以通过在startup文件中创建alias, 来让rm在不输入-i的情况下, 默认采用以上的互动模式.
+ less = LESS is more 将文本文件一次只显示一个屏幕的内容 (displaying a text file one screen at a time)
less和more功能一样, 只有细微的差别, 一般配合管道 | (pipe) 一起使用.
+ tip: 当你输入文件名时, 只输入一部分文件名, 按一下Tab键, Shell会帮你自动完成文件名.
+ hostname = HOSTNAME 显示电脑主机名 (displays the system name)
3) 与文件操作相关的命令 Working with files
cp mv lpr grep head tail sort uniq diff file
+ cp = CoPy 复制文件和目录 (copy files and directories)
格式: cy source-file destination-file 如 cp memo memo.copy , cp命令也会覆盖同名目标文件, 也可使用互动选项-i.
+ mv = MoVe 移动/重命名文件 (move/rename a file)
格式: mv source-filename destination-filename 如将文件memo改名为memo.1216 mv memo memo.1216 , mv命令会覆盖同名目标文件, 也可使用互动选项-i. 注意: 复制文件cp和移动/重命名文件mv是不同的.
+ lpr = Line PRinter 打印文件 (print a file)
将文件report打印到名为mailroom的打印机: lpr -Pmailroom report . 另外, lpq 可查看打印队列, lprm 可取消打印.
+ grep = Global Regular Expression Print 查找字符串 (finds a string)
grep可以在一个或多个文件中查找指定的字符串, 如在文件memo中查找字符串credit: grep ‘credit’ memo 需要查找的字符串可以不用单引号, 但使用单引号可以允许你查找含有空格和特殊字符的内容. 在上例中, 含有discredit, creditor, accreditation的内容是符合查找规则的, 因为这些词包含了credit字符串, 使用选项-w (grep -w ‘credit’ memo) 可以让grep只显示符合含有完整单词credit的内容.
+ head = HEAD 显示文件的开始部分 (displays the beginning of a file)*
默认, head只显示文件的前10行, 你可以指定显示的行数, 如仅显示文件months的第一行 head -1 months
+ tail = TAIL 显示文件的结束部分 (displays the end of a file) *
与head的用法类似.
+ sort = SORT 为文本文件的每行排序并显示 (sort lines of text file) *
sort是按字母顺序显示文件内容.
+ uniq = UNIQue 移除文件重复的行 (duplicate lines from a file) *
使用 sort -u 可以达到同样的效果.
+ diff = DIFFerence 逐行比较文件 (compare files line by line) *
diff逐行比较文件并显示不同的地方.
使用选项 -u (unified output format) 可以更好地显示两文件间的差别: 此选项会把长的多行的文件分成块 (hunks), 每块的开始和结束都有@@ (two at signs), 同时, 一个文件(如A)被标识为减号 - (a minus sign), 而另一个文件(如B)被标识为加号 + (a plus sign), 显示结果时, 前面有减号的内容表示仅出现在A文件中, 前面有加号的内容表示仅出现在B文件中, 前面没有任何符号的内容表示两个文件都有. 请看下例:
diff -u colors.1 colors.2
— colors.1 Fri Dec 16 18:20:32 2007
+++ colors.2 Fri Dec 16 18:21:53 2007
@@ -1,6 +1,5 @@
red
+blue
green
yellow
-pink
-purple
orange
若从上例中看不出colors.1文件和colors.2文件分别有哪些内容, 说明你还没有弄懂, 建议自己弄个例子亲自试试.
+ file = FILE 确定文件的类型 (determine file type)
简单地说, file就是向你报告你指定的文件是什么类型的文件.
*此工具不会更改原文件的内容.
4) | (管道) 进程间的通信 (Pipe) Communications between processes
一个进程就是指一个命令的执行, 进程间的通信是Unix/Linux系统的特征之一. 管道 (pipe) 用一个竖条表示, | (vertical bar), 提供进程间通信的最简单的形式. 管道接收一个工具的输出, 把这个输出发送给另一个工具作为输入. (a pipe takes the output of one utility and sends that output as input to another utility.)
如, 打印months文件的最后十行 tail months | lpr
其它 Others
A directory is a folder that can hold files.
utilities less and more have subtle differences. (subtle = slight and delicate)
用上Linux Ubuntu也很有一段时间了, 一直期待并寻找能与Windows下的 TypeAndRun 相媲美的软件, 今天有了些小小收获: GNOME Do.
介绍
GNOME Do是个简单小巧开源软件, 但功能还远不及TypeAndRun强大.
官方网站有两个:
http://do.davebsd.com/
https://edge.launchpad.net/gc
安装
在Ubuntu下可以用apt-get安装, 首先输入
sudo gedit /etc/apt/sources.list
添加下列源到文件最后:
deb http://ppa.launchpad.net/rharding/ubuntu gutsy main
deb-src http://ppa.launchpad.net/rharding/ubuntu gutsy main
保存后执行:
sudo apt-get install gnome-do
安装完毕后GNOME Do可以在Applications–>Accessories里面找到, 也可以用默认的Super键+空格键调出.
设置
习惯了TypeAndRun 默认的按 Scroll Lock键一键呼出, 研究了一番, 终于把GNOME Do默认的键改成了Scroll Lock一键呼出.
方法是在终端输入
gconf-editor
调出Gnome Configuration Editor, 进入 /apps/gnome-do/preferences/key_binding 并把默认的值 <Super>space 更改为 Scroll_Lock .
另外, Ubuntu 7.10 默认也带个 Deskbar Applet, 也有类似于 GNOME Do 的功能, 默认用 Alt+F3 可以调出.
A Practical Guide to Linux Commands, Editors, and Shell Programming
Chapter 02 Getting Started - 开始
本章主要讲述本书所用的惯例规则, 登陆Linux的方法, 获取资料和寻求帮助的途径等基本知识, 让你进入Linux开始最最基本操作!
1) 登陆 Logging in
+ 登陆Linux需要用户名 (user name) 和密码 (password), 如果系统没有显示login提示, 有如下方法: 按回车键几次, 按Ctrl+Q键, 输入ssh或telnet. 如还不能登陆, 请确保你所登陆的是正确的机器, 你的密码和用户名是配套且正确的 (Linux是对大小写敏感的系统.)
+ 远程登陆Linux的方法主要有两种:ssh和telnet, ssh比telnet要安全, 因为ssh传递的所有信息都会先加密, 而telnet不加密, 甚至包括你的用户名和密码在内都是用明文 (cleartext) 传递的, 所以如果可能请尽量用ssh登陆.
+ Shell是个命令解释器. (Shell is a command interpreter.) Shell分很多种, 常见有bash, tcsh, zsh……
ps = ProceSs 显示当前进程 (report a snapshot of the current processes)
chsh = CHang SHell 更改用户登陆时所用的Shell (change login shell)
+ 退出登陆 (logging out): 请按Ctrl+D
2) 纠正错误 Correcting mistakes
在输入命令时可用到的编辑键, 及命令的中止和重复
+ 删除一个字符* (erasing a character): BACKSPACE键, 若不行请试DELETE键或Ctrl+H键
+ 删除一个单词 (deleting a word): Ctrl+W
+ 删除一行* (deleting a line): Ctrl+U (line kill key)
+ 暂停程序执行 (suspends a program): Ctrl+Z (suspend key) (暂停后, 此程序还在后台等待进一步指令)
+ 中止/取消程序执行 (aborting execution): Ctrl+C, 有时是DELETE键 (interrupt key)
若不能中止程序执行, 请用Ctrl+Z暂停, 输入jobs命令, 确认你想中止的程序的进程号 (job number), 然后用kill命令发送中止信号到指定的程序, 如:
kill %1 (进程号前面需要加%, 1为进程号, 注意与百分数不同, %是在进程号前面)
若还无效, 请用:
kill -KILL %1
kill 发送信号给进程 (send a signal to a process)
+ 重复/编辑命令行 (repeating / editing command lines): 按上箭头键 (UP ARROW key) 可调出上一个已输入过的命令, 下箭头键 (DOWN ARROW key) 反向显示, 左右箭头键 (LEFT / RIGHT ARROW key) 分别向左或向右移光标. 特别适合当你输入命令时多了或少了字符, 但又已经执行了的情况, 或者你想再次执行上一个执行过的命令, 这个小知识会为你省不少力和时间.
*若上述操作无效, 请输入 stty ek 命令来恢复相关键到默认值.
3) 高级用户访问 Superuser Access
superuser = root = system administrator
不要在用高级用户账户做实验, 确保你充分了解将要进行操作, 因为一旦操作错误, 你可能会毁掉整个Linux系统!
4) 得到事实: 怎样寻找文档 Getting the facts: Where to find documentation
最常用的两个工具是 man 和 info, 还有 apropos 搜索和相关网站文档信息.
+ man = MANual 显示系统文档 (displays the system manual)
可以输入命令 man man 以了解更多, 意思是显示关于man工具的文档
根据文件系统等级标准, Linux系统文档被分为10部分:
1. User Commands / 2. System Calls / 3. Subroutines / 4. Devices / 5. File Formats / 6. Games / 7. Miscellaneous / 8. System Administration / 9. Local / 10. New
你可以指定man在某一个部分寻找文档信息, 如 man 2 write
+ info = INFOrmation 显示命令信息 (displays information about utilities)
info命令是GNU开发的一个目录型的超文本系统, 包括info工具自身的指导手册 (输入info info) 和许多GNU开发的Shell, 工具和程序的文档 (输入 info).
++ 进入info后, 可以使用如下info命令: 空格键显示下一屏, ?显示可以在info中使用的命令, h显示帮助信息, q退出
++ 输入info后, 可以进入其目录系统的首页, 可以发现很多行前面都有一个星号, 或者正式点叫通配符 (asterisk), 这表示此行是一个链接, 含有关于此项更详细信息, 移动光标到星号上, 按回车键, 即可到达关于此项的更详细的描述, 也可以, 输入m加上工具名, 如想看此页中含有的sleep工具的详细信息, 直接输入 m sleep , 回车即可.
++ 你会发现, 目录系统中, 有许多工具列表, 它们是按照功能相关性而不是按照字母顺序摆列在一个主题中的, 这样便于我们查找, 很人性化, 主题下的每个工具链接被叫做节点 (node). 如Directory listing主题中有 ls, dir, vdir, dircolors 四个命令, 每个命令都是一个节点. 在一个节点内时, 可以自由地跳到同主题的任一节点中: n跳到下一个节点, p跳到上一个节点. 你可以随时按d跳到目录系统首页.
++ 另外, 在info中, C-h表示Ctrl+H, M-x表示Alt+X或Meta+X.
++ 总之, info涵盖包含基本命令在内的许多工具程序信息, 是一个很有用的文档查询工具, 建议像我这样的新手经常去info里看看.
++ man和info的功能基本一样, 但略有不同: 显然, info显示的信息比man更加全面和更新.
+ 另外, 可使用 –help 或 -h 选项获得某个命令的帮助
如: ls –help | less
以上的命令表示逐页显示ls命令的帮助信息, “|”表示管道 (pipe), less 是一个页面调度程序 (pager).
less = LESS is more 将文本文件一次只显示一个屏幕的内容 (displaying a text file one screen at a time)
当在less显示状态时, 按空格键下翻一页, h显示less命令清单, q退出.
+ apropos 搜索关键字 (searches for a keyword)
如: apropos foo | less 搜索包含foo关键字的内容, 并分屏显示结果
+ Howtos: 怎样做…. Find out how things work
Howto文档包括在Linux中怎样做……The Linux Documentation Project 管理维护Howto文档, 需要用浏览器访问.
+ 另外, GNU Manuals 上也有许多关于Linux的文档.
TLDP Links 上有许多有用的关于Linux链接.
5) 更改密码 Changing your password
+ 要更改密码, 使用passwd命令.
passwd = PASSWorD 更改用户密码 (change user password)
一个好的密码是一个包含有数字组合, 大写字母, 小写字母, 标点符号的7位或8位字符集合. 请不要使用控制字符(如Ctrl+H), 不要使用英语单词或其它语言的单词字母组合, 或者其它任何容易被人猜到的字符.
+ 密码安全 password security
++ 保护密码 protect your password
不要让别人找到密码: 不要把密码放在没有加密的文件中, 不要让别人看着你输入密码, 不要把密码给别人
++ 选择很难被猜中的密码
不要使用电话号码, 宠物或小孩的名字, 生日, 字典中的单词(包括其它语言的字典)
++ 把重要的密码和不太重要的密码分开
重要的密码和非重要的密码不要相同.
+ Linux系统规定密码长度必须不少于6个字符.
其它 Others
$ means dollar sign.
Linux is case sensitive.
ls = LiSting 列出目录文件 (listing directory contents)
cat = conCATenate 连接文件并显示文件内容 (concatenates and displays files)
who 显示登陆的用户名 (show who is logged on)
A Practical Guide to Linux Commands, Editors, and Shell Programming
Chapter 01 Welcome to Linux - 欢迎进入Linux系统
1) The GNU-Linux Connection - Linux与GNU的关系
Fate to 1983: Richard Stallman announces the GNU Project for creating an operating system, both kernel and system programs.
远在1983年: Richard Stallman宣告创建一个包含内核和系统程序在内的操作系统的GNU项目.
Free software is software that users have the freedom to distribute and change.
自由软件是指用户有修改和发布的自由的软件.
Next scene, 1991: Much of the GNU operating system, except for the kernel, is complete.
下一幕, 1991: 除了内核, GNU操作系统的大部分工作已完成.
The code is free: You can obtain Linux at no cost over the Internet.
代码免费: 你可以免费在网上获得Linux.
Have fun! The UNIX-now Linux-culture is steeped in humor that can be seen throughout the system. For example, less is more.-GNU has replaced the UNIX paging utility named more with an improved utility named less.
享受乐趣! UNIX-现在是Linx-文化植根于可以从整个系统之中感受到幽默之中. 例如, less就是more, GNU开发了一个名叫less的改进的页面工具来代替UNIX上一个名叫more的页面工具.
2) The Heritage of Linux: UNIX - Linux的遗产
The UNIX system was developed by researchers who needed a set of modern computing tools to help them with their projects.
UNIX系统由需要一系列现代计算工具来帮助他们的项目的研究人员开发.
3) What is So Good About Linux? - Linux有什么优点
Why linux is popular with hardware companies and developers
为什么linux流行于硬件厂商和开发者之间.
Like hardware manufacturers , software develpers need a generic operating system…Linux emerged to serve both needs. It is a generic operating system that takes advantage of available hardware power.
同硬件制造商一样, 软件开发者需要一个通用的操作系统……Linux可满足他们两者的需求. 它是一个善于利用现有硬件能力的通用操作系统.
Linux is Portable
Linux是可移植的.
A portable operating system is one that can run on many different machines.
一个可移植的操作系统是指可以运行在许多不同类型的机器上的系统.
Standard
标准
Linux support POSIX (Portable Operating System Interface for computer Environments) standard.
Linux支持POSIX (电脑环境可移植操作系统接口) 标准
The C programming Language
C编程语言
Ken Thompson wrote the UNIX operating system in 1969 in PDP-7 assembly language…Dennis Ritchie developed the C programming language by modifying B and, with Thompson, rewrote UNIX in C in 1973…C can be used to write machine-independent programs…Another researcher at Bell Labs, Bjarne Stroustrup, created an object-oriented programming language named C++, which is built on the foundation of C.
Ken Thompson在1969年用PDP-7 assembly语言写出了UNIX操作系统……Dennis Ritchie在B语言的基础上开发了C编程语言, 并与Thompson一起, 在1973年用C语言重写了UNIX……C语言可以用来编写不依赖机器的程序……另外一个在贝尔实验室工作的研究人员, Bjarne Stroustrup, 在C语言的基础上创建了面向对象的编程语言C++.
4) Overview of Linux - Linux概览
Linux has a kernel programming interface
Linux拥有一个内核编程界面
The heart of the Linux operating system is the Linux kernel, which is responsible for allocating the computer’s resources and scheduling user jobs so that each one gets its fair share of system resources.
Linux操作系统的心脏是Linux内核, 它负责分配电脑资料和安排用户任务, 以让每个人都可以平等地分享系统资源.
Linux can support many users
Linux支持多用户
a Linux system can support from 1 to more than 1,000 users…The use of costly resources can be maximized, and the cost per user can be minimized.
一个Linux系统可以支持从1到多于1000个用户……这样资源成本的利用可以最大化, 同时每个用户付出的成本可以最小化.
Linux can run many tasks
Linux可以运行多任务
Linux is a fully protected multitasking operating system.
Linux是一个充分保护的多任务操作系统.
Linux provides a secure hierarchical filesystem
Linux提供一个安全的等级制文件系统
A file is a collection of information… Access Control Lists (ACLs) have recently been added to the Linux kernel.
文件是信息的集合……访问控制清单(ACLs)最近被添加到Linux内核中.
The shell: command interpreter and programming language
壳: 命令解释器和编程语言
In a textual environment, the shell — the command interpreter — acts as an interface between you and the operating system…the shell is a high-level programming language. Shell commands can be arranged in a file for later execution. Linux calls these files shell scripts.
在文本界面中, 壳–命令解释器–扮演操作系统与你之间的界面……壳是一个高级编程语言. 壳命令可以被放在一个文件当中, 便于以后执行. Linux称这些文件为Shell脚本语言.
Filename Generation
文件名的生成
Device-independent input and output
不依赖设备的输入和输出
Shell Functions
壳的功能
One of the most important features of the shell is that users can use it as a programming language.
壳最重要的功能之一就是用户可以把它当作一个编程语言来使用.
A large collection of useful utilities
数量繁多的有用工具
Linux includes a family of several hundred utility programs, often referred to as commands.
Linux包含数百个工具程序, 通常被称作命名.
Interprocess communication
进程间的通信
A pipe sends the output of one program to another program as input. A filter is a special form of a pipe that processes a stream of input data to yield a stream of output data.
管道把一个程序的输出发送给另一个程序作为输入. 过滤器是一个特别形式的管道, 它可以处理一连串的输入数据, 并生成一连串的输出数据.
System administration
系统管理
5) Additional Features of Linux - Linux的附加特点
GUIs: graphical user interfaces - GUIs: 图形用户界面
Usually two layers run under X: a desktop manager and a window manager.
通常在X下有两层界面: 桌面管理器和窗口管理器
A desktop manager is a picture-oriented user interface that enables you to interact with system programs by manipulating icons instead of typing the corresponding commands to a shell. GNOME and KDE are the most popular desktop managers.
一个桌面管理器是一个面向图形的用户界面, 它让你通过操作图标而不是输入命令给壳来与系统程序互动. GNOME和KDE是最流行的桌面管理器.
A window manager is a program that runs under the desktop manager and allows you to open and close windows, start programs running, and set up a mouse so it does different things depending on how and where you click. Several popular window managers run under X and Linux, including Metacity (default under GNOME) and kwin (default under KDE). Other window managers, such as Sawfish and WindowMaker, are also available.
一个窗口管理器是一个在桌面管理器下运行的程序, 它允许你打开关闭窗口, 使程序开始运行, 设置鼠标来根据你点击的方式和位置来做不同的事. 有些流行的窗口管理器在X和Linux下运行, 包括Metacity (GNOME下默认)和kwin (KDE下默认). 其它的窗口管理器有Sawfish和WindowMaker, 也是可用的.
(Inter)networking utilities
网络工具
Software development
软件开发
One of Linux’s major strengths is its rich software development environment.
Linux最主要的优势之一就是它的丰富多样的软件开发环境
Words of this Chapter
liberty = freedom 自由
manifesto 宣言, 声明
footnote 脚注
solidarity 团结, 一致
conscience 良心
tendency 倾向, 趋势
resign 辞职, 放弃
nominal 名义上的, 不实际的
proprietary 所有权, 专利
heritage 遗产, 继承物
sophisticated 精良的
lag 落后
hierarchical 等级制的, 按等级划分的
二年前, 我在forum.ubuntu.org.cn上发布了一个贴子, 推荐一本帮助学习Linux系统的英文原版入门书: A Practical Guide to Linux Commands, Editors, and Shell Programming.
三个月后, 我在amazon上买了英文原版, 准备好好学学. 其间多多少少陆陆续续看了些, 但都没时间系统地学习过.
在2007年10月份装了Linux Ubuntu 7.10 Gutsy Gibbon后, 我在图形界面下用得十分顺手, 感觉Microsoft Windows离我是越来越远了.
所以, 今天痛下决心: 从现在开始, 把此书从头到尾学一遍, 以加深对Linux的理解和运用. Goodbye, Windows!
我会把学习笔记放在weblog上, 敬请期待.
A Practical Guide to Linux Commands, Editors, and Shell Programming, 这本厚达965页的书, 由Linux畅销书作者Mark G. Sobell编写, 主要讲解Linux下命令行工具, 编辑器和Shell编程, 是Linux很好的入门书, 英文原版更为我们进一步学习和理解Linux打下良好的基础, 毕竟英文Linux资料是最新的.
本书的前言(Perface), 列举了本书的主要内容:
PART I: THE LINUX OPERATING SYSTEM — Linux操作系统
Welcome to Linux / Getting Started / Command Line Utilities / The Linux Filesystem / The Shell
PART II: THE EDITORS — 编辑器
The vim Editor / The emacs Editor
PART III: THE SHELLS — 命令解释器 (用户和Linux系统之间的接口)
The Bourne Again Shell / The TC Shell
PART IV: PROGRAMMING TOOLS — 编程工具
Programming Tools / Programming the Bourne Again Shell / The gawk Pattern Processing Language / The sed Editor
PART V: COMMAND REFERENCE — 命令参考
extensive examples of the use of more than 80 of the most important utilities
PART VI: APPENDIXES — 附录
Appendix A. Regular Expressions / Appendix B. Help / Appendix C. Keeping the System Up-to-date / Glossary / Index
安装Linux Ubuntu 7.10 Gutsy Gibbon也有一段时间了, 今天有幸, 简要翻译了一下 Mark G. Sobell 著的 A practical Guide to Linux Commands, Editors, and Shell Programming 一书中的Linux标准系统目录, 供自己使用, 也供大家参考.
Linux标准系统目录 Linux System Standard Directories and Files
/bin 基本命令二进制文件 ( essential command binaries )
/boot 引导加载器的固有文件 ( static files of the boot loader )
/dev 设备文件 ( device files )
/etc 本地系统配置文件 ( machine-local system configuration )
/etc/X11 本地X窗口系统配置文件 ( machine-local configuration for the X window system )
/etc/opt 保存在/opt中的附加软件包配置文件 ( configuration files for add-on software packages kept in /opt )
/home 用户本地目录 ( user home directories )
/lib 共享系统库文件和核心模块 ( shared libraries and kernel modules )
/lib/modules 可加载的核心模块 ( loadable kernel modules )
/mnt 系统文件临时挂载点 ( mount point for temporary mounting of filesystems )
/opt 附加软件包(可选) ( add-on software packages (optional packages) )
/proc 核心和进程信息虚拟文件系统 ( kernel and process information virtual filesystem )
/root 根用户的本地目录 ( home directory for root )
/sbin 基本系统二进制文件 ( essential system binaries )
/tmp 临时文件 ( temporary files )
/usr 次重要的分级文件系统 ( second major hierarchy )
/usr/bin 大部分的用户命令 ( most user commands )
/usr/bin/X11 到/usr/X11R6/bin的符号链接 ( symbolic link to /usr/X11R6/bin )
/usr/games 游戏和教育程序 ( games and educational programs )
/usr/include C编程语言的头文件 ( header files included by C programs )
/usr/include/X11 到 /usr/X11R6/include/X11的符号链接 ( symbolic link to /usr/X11R6/include/X11 )
/usr/lib 库文件 ( libraries )
/usr/lib/X11 到 /usr/X11R6/lib/X11的符号链接 ( symbolic link to /usr/X11R6/lib/X11 )
/usr/local 本地分级文件系统 ( local hierarchy )
/usr/man 在线文档 online manuals
/usr/sbin 次重要的系统管理二进制文件 ( nonvital system administration binaries )
/usr/share 独立性结构数据 ( architecture-independent data )
/usr/share/doc 其它杂项文档 ( miscellaneous documentation )
/usr/share/info GNU信息系统主要目录 ( GNU info system’s primary directory )
/usr/src 源码 ( source code )
/usr/X11R6 第11版本第6次修正的X窗口系统协议 ( X window system, version 11 release 6 )
/var 变量数据 ( variable data )
/var/log 日志文件 ( log files )
/var/spool 应用程序队列数据 ( spooled applicaion data )
声明: 英文原文解释来自 A practical Guide to Liunx Commands, Editors, and Shell Programming 书中第86-88页.