diff --git a/translated/talk/20140724 What are useful online tools for Linux.md b/published/20140724 What are useful online tools for Linux.md similarity index 62% rename from translated/talk/20140724 What are useful online tools for Linux.md rename to published/20140724 What are useful online tools for Linux.md index b01b5b189a..cfeadfc3b8 100644 --- a/translated/talk/20140724 What are useful online tools for Linux.md +++ b/published/20140724 What are useful online tools for Linux.md @@ -1,6 +1,7 @@ -适用于Linux的在线工具 +16个 Linux 方面的在线工具类网站 ================================================================================ -众所周知,GNU Linux不仅仅只是一款操作系统。看起来通过互联网全球许多人都在致力于这款企鹅图标(即Linux)的操作系统。如果你读到这篇文章,你可能倾向于读到关于Linux联机的内容。在可以找到的所有关于这个主题的网页中,有一些网站是每个Linux爱好者都应该收藏起来的。这些网站不仅仅只是教程或回顾,更是可以随时随地访问并与他人共享的实用工具。所以,今天我会建议一份包含16个应该收藏的网址清单。它们中的一些对Windows或Mac用户同样有用:这是在他们的能力范围内可以做到的。(译者注:Windows和Mac一样可以很好地体验Linux) +众所周知,GNU Linux不仅仅只是一款操作系统。看起来通过互联网全球许多人都在致力于这款以企鹅为吉祥物的操作系统。如果你读到这篇文章,你可能希望读一些关于Linux在线资源的内容。在可以找到的所有关于这个主题的网页中,有一些网站是每个Linux爱好者都应该收藏起来的。这些网站不仅仅只是教程或回顾,更是可以随时随地访问并与他人共享的实用工具。所以,今天我会建议一份包含16个应该收藏的网址清单。它们中的一些对Windows或Mac用户同样有用:这是在他们的能力范围内可以做到的。(译者注:Windows和Mac一样可以很好地体验Linux) + ### 1. [ExplainShell.com][1] ### [![](https://farm4.staticflickr.com/3841/14517716647_3b6a1a564d_z.jpg)][2] @@ -11,43 +12,43 @@ [![](https://farm4.staticflickr.com/3900/14703872782_033e5acdb8_z.jpg)][4] -如果你想开始学习Linux命令行,或者想快速地得到一个自定义的shell命令提示符,但不知道从何下手,这个网站会为你生成PS1提示代码,在家目录下放置.bashrc文件。你可以拖拽任何你想在提示符里看到的元素,譬如用户名和当前时间,这个网站都会为你编写易懂可读的代码。绝对是懒人必备! +如果你想开始学习Linux命令行,或者想快速地生成一个自定义的shell命令提示符,但不知道从何下手,这个网站可以为你生成PS1提示的代码,将代码放到家目录下的.bashrc文件中即可。你可以拖拽任何你想在提示符里看到的元素,譬如用户名和当前时间,这个网站都会为你编写易懂可读的代码。绝对是懒人必备! ### 3. [Vim-adventures.com][5] ### [![](https://farm4.staticflickr.com/3838/14681149696_0c533fd6de_z.jpg)][6] -我是最近才发现这个网站的,但我的生活已经深陷其中。简而言之:它就是一个使用Vim命令的RPG游戏。在等距的水平上使用‘h,j,k,l’四个键移动字母,获取新的命令/能力,收集关键词,非常快速地学习高效地使用Vim。 +我是最近才发现这个网站的,但我的生活已经深陷其中。简而言之:它就是一个使用Vim命令的RPG游戏。在地图的平面上使用‘h,j,k,l’四个键移动你的角色、得到新的命令/能力、收集钥匙,可以帮助你非常快速地学习如何高效使用Vim。 ### 4. [Try Github][7] ### [![](https://farm4.staticflickr.com/3874/14517499739_0452848d68_z.jpg)][8] -目标很简单:15分钟学会Git。这个网站模拟一个控制台,带你遍历这种协作编辑的每一步。界面非常时尚,目的十分有用。唯一不足的是对Git敏感,但Git绝对是一项不错的技能,这里也是学习Git的绝佳之处。 +目标很简单:15分钟学会Git。这个网站模拟一个控制台,带你遍历这种协作编辑的每一步。界面非常时尚,目的十分有用。唯一不足的是对Git感兴趣,但Git绝对是一项不错的技能,这里也是学习Git的绝佳之处。 ### 5. [Shortcutfoo.com][9] ### [![](https://farm4.staticflickr.com/3906/14517499799_f142ea37cb_z.jpg)][10] -又一个包含众多快捷键数据库的网站,shortcutfoo以更标准的方式将其内容呈现给用户,但绝对比有趣的迷你游戏更直截了当。这里有许多软件的快捷键,并按类别分组。虽然它不像Vim一类完全依赖快捷键的软件那么全面,但也足以提供快速的提示或一般性的概述。 +又一个包含众多快捷键数据库的网站,shortcutfoo以更标准的方式将其内容呈现给用户,但绝对比有趣的迷你游戏更直截了当。这里有许多软件的快捷键,并按类别分组。虽然像Vim一类的软件它没有给出超级完整的快捷键列表,但也足以提供快速的提示或一般性的概述。 ### 6. [GitHub Free Programming Books][11] ### [![](https://farm4.staticflickr.com/3867/14517499989_408a28d8be_z.jpg)][12] -正如你从URL上猜到的一样,这个网站就是免费在线编程书籍的集合,使用Git协作方式编写。上面的内容非常好,作者们应该为做出这些工作受到表扬。它可能不是最容易阅读的,但一定是最有启发性的之一。我们只希望这项运动能持续进行。 +正如你从URL上猜到的一样,这个网站就是免费在线编程书籍的集合,使用Git协作方式编写。上面的内容非常好,作者们应该为他们做出的这些贡献受到表扬。它可能不是最容易阅读的,但一定是最有启发性的之一。我们只希望这项运动能持续进行。 ### 7. [Collabedit.com][13] ### [![](https://farm3.staticflickr.com/2940/14681150086_2d169d67f9_z.jpg)][14] -如果你曾经准备过电话面试,你应该先试试collabedit。它让你创建文件,选择你想使用的编程语言,然后通过URL共享文档。打开链接的人可以免费地实时使用文本交互,使你可以评判他们的编程水平或只是交换一些程序片段。这里甚至还提供合适的语法高亮和聊天功能。换句话说,这就是程序员的即时Google文档。 +如果你曾经计划过电话面试,你应该先试试collabedit。它让你创建文件,选择你想使用的编程语言,然后通过URL共享文档。打开链接的人可以免费地实时使用文本交互,使你可以评判他们的编程水平或只是交换一些程序片段。这里甚至还提供合适的语法高亮和聊天功能。换句话说,这就是程序员的即时Google Doucment。 ### 8. [Cpp.sh][15] ### [![](https://farm4.staticflickr.com/3840/14700981001_af3ac40b65_z.jpg)][16] -尽管这个网站超出了Linux范围,但因为它非常有用,所以值得将它放在这里。简单地说,这是一个C++在线开发环境。只需在导航栏里编写程序,然后运行它。作为奖励,你可以使用自动补全、Ctrl+Z,以及和你的小伙伴共享URL。这些有趣的事情,你只需要通过一个简单的浏览器就能做到。 +尽管这个网站超出了Linux范围,但因为它非常有用,所以值得将它放在这里。简单地说,这是一个C++在线开发环境。只需在浏览器里编写程序,然后运行它。作为奖励,你可以使用自动补全、Ctrl+Z,以及和你的小伙伴分享你的作品的URL。这些有趣的事情,你只需要通过一个简单的浏览器就能做到。 ### 9. [Copy.sh][17] ### @@ -59,13 +60,13 @@ [![](https://farm4.staticflickr.com/3887/14517495938_ca3b831ca9_z.jpg)][21] -我们总是在自己的电脑上保存着一大段类似于“gems”的命令行【翻译得不准确,麻烦校正】,commandlinefu的目标是把这些片段释放给全世界。作为一个协作式数据库,它就像是命令行里的维基百科。每个人可以免费注册,把自己最钟爱的命令提交到这个网站上给其他人看。你将能够获取来自四面八方的知识并与人分享。如果你对精通shell饶有兴趣,commandlinefu也可以提供一些优秀的特性,比如随机命令和每天学习新知识的新闻订阅。 +我们总是在自己的电脑上保存着一大段命令行“宝石”,commandlinefu的目标是把这些片段释放给全世界。作为一个协作式数据库,它就像是命令行里的维基百科。每个人可以免费注册,把自己最钟爱的命令提交到这个网站上给其他人看。你将能够获取来自四面八方的知识并与人分享。如果你对精通shell饶有兴趣,commandlinefu也可以提供一些优秀的特性,比如随机命令和每天学习新知识的新闻订阅。 ### 11. [Alias.sh][22] ### [![](https://farm4.staticflickr.com/3868/14701762124_a7b3547aca_z.jpg)][23] -另一协作式数据库,alias.sh(我爱死这个URL了)有点像commandlinefu,但是为shell别名开发的。你可以共享和发现一些有用的别名,来使你的CLI(命令行界面)体验更加舒服。我个人喜欢这个获取图片维度的别名。 +另一协作式数据库,alias.sh(我爱死这个URL了)有点像commandlinefu,但是为shell别名开发的。你可以共享和发现一些有用的别名,来使你的CLI(命令行界面)体验更加舒服。我个人喜欢这个获取图片维度的别名命令。 function dim(){ sips $1 -g pixelWidth -g pixelHeight } @@ -75,40 +76,41 @@ [![](https://farm3.staticflickr.com/2910/14681149996_50a45bff78_z.jpg)][25] -有谁不知道Distrowatch?除了基于这个网站流行度给出一个精确的Linux发行版排名,Distrowatch也是一个非常有用的数据库。无论你正苦苦寻找一个新的发行版,还是只是出于好奇,它都能为你能找到的每个Linux版本呈现一个详尽的描述,包含默认的桌面环境,包管理系统,默认应用程序等信息,还有所有的版本号,以及可用的下载链接。总而言之,这就是个Linux宝库。 +有谁不知道Distrowatch?除了基于这个网站流行度给出一个精确的Linux发行版排名,Distrowatch也是一个非常有用的数据库。无论你正苦苦寻找一个新的发行版,还是只是出于好奇,它都能为你能找到的每个Linux版本呈现一个详尽的描述,包含默认的桌面环境、包管理系统、默认应用程序等信息,还有所有的版本号,以及可用的下载链接。总而言之,这就是个Linux宝库。 ### 13. [Linuxmanpages.com][26] ### [![](https://farm4.staticflickr.com/3911/14704165765_8e30cb3d3f_z.jpg)][27] -一切都在URL中:随时随地获取主流命令的手册页面。尽管不确信对于Linux用户是否真的有用,因为他们可以从真实的终端中获取这些信息,但这里的内容还是值得关注的。 +一切尽在URL中说明了:随时随地获取主流命令的手册页面。尽管不确信对于Linux用户是否真的有用,因为他们可以从真实的终端中获取这些信息,但这里的内容还是值得关注的。 ### 14. [AwesomeCow.com][28] ### [![](https://farm6.staticflickr.com/5558/14704165965_02b10ee293_z.jpg)][29] -这里可能少一些核心的Linux内容,但肯定是有一些用的。Awesomecow是一个搜索引擎,来寻找Windows软件在Linux上的替代品。它对那些迁移到企鹅操作系统(Linux)或习惯Windows软件的人很有帮助。我认为这个网站代表一种能力,表明了在谈到软件质量时Linux也可以适用于专业领域。大家至少可以尝试一下。 +这可能对于骨灰级 Linux 没啥用,但是对于其他人也许有用。Awesomecow是一个搜索引擎,来寻找Windows软件在Linux上对应的替代品。它对那些迁移到企鹅操作系统(Linux)或习惯Windows软件的人很有帮助。我认为这个网站代表一种能力,表明了在谈到软件质量时Linux也可以适用于专业领域。大家至少可以尝试一下。 ### 15. [PenguSpy.com][30] ### [![](https://farm4.staticflickr.com/3904/14517495728_f6877e8e3b_z.jpg)][31] -Steam在Linux上崭露头角之前,游戏性可能是Linux的软肋。但这个名为“pengsupy”的网站不遗余力地弥补这个软肋,通过使用漂亮的接口在数据库中收集所有兼容Linux的游戏。游戏按照类别、发行日期、评分等指标分类。我真心希望这一类的网站不会因为Steam的存在走向衰亡,毕竟这是我在这个列表里最喜爱的网站之一。 +Steam在Linux上崭露头角之前,可玩性可能是Linux的软肋。但这个名为“pengsupy”的网站不遗余力地弥补这个软肋,通过使用漂亮的界面展现了数据库中收集的所有兼容Linux的游戏。游戏按照类别、发行日期、评分等指标分类。我真心希望这一类的网站不会因为Steam的存在走向衰亡,毕竟这是我在这个列表里最喜爱的网站之一。 ### 16. [Linux Cross Reference by Free Electrons][32] ### [![](https://farm4.staticflickr.com/3913/14712049464_6b666e2cfa_z.jpg)][33] -最后,对所有的专家和好奇的用户,lxr是源自Linux Cross Reference的回文构词法,使我们能交互地在线查看Linux内核代码。通过标识符可以很方便地使用导航栏,你可以使用标准的diff标记对比文件的不同版本。这个网站的界面看起来严肃直接,毕竟这只是一个希望完美阐述开源观点的网站。 +最后,对所有的专家和好奇的用户,lxr 是源于 Linux Cross Reference 的另外一种形式,使我们能交互地在线查看Linux内核代码。可以通过各种标识符在代码中很方便地导航,你可以使用标准的diff标记对比文件的不同版本。这个网站的界面看起来严肃直接,毕竟这只是一个希望完美阐述开源观点的网站。 总而言之,应该列出更多这一类的网站,作为这篇文章第二部分的主题。但这篇文章是一个好的开始,是一道为Linux用户寻找在线工具的开胃菜。如果你有其它任何想要分享的页面,而且是紧跟这个主题的,在评论里写出来。这将有助于续写这个列表。 + -------------------------------------------------------------------------------- via: http://xmodulo.com/2014/07/useful-online-tools-linux.html 原文作者:[Adrien Brochard][a](我是一名来自法国的Linux狂热爱好者。在尝试过众多的发行版后,我最终选择了Archlinux。但我一直会通过叠加技巧和窍门来优化我的系统。) -译者:[KayGuoWhu](https://github.com/KayGuoWhu) 校对:[校对者ID](https://github.com/校对者ID) +译者:[KayGuoWhu](https://github.com/KayGuoWhu) 校对:[wxy](https://github.com/wxy) 本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 diff --git a/translated/tech/20140729 How to use awk command in Linux.md b/published/20140729 How to use awk command in Linux.md similarity index 79% rename from translated/tech/20140729 How to use awk command in Linux.md rename to published/20140729 How to use awk command in Linux.md index 6208316dc9..c4fded9e5c 100644 --- a/translated/tech/20140729 How to use awk command in Linux.md +++ b/published/20140729 How to use awk command in Linux.md @@ -1,8 +1,8 @@ 如何在Linux中使用awk命令 ================================================================================ -文本处理是Unix的核心。从管道到/proc子系统,“一切都是文件”的理念贯穿于操作系统和所有基于它构造的工具。正因为如此,轻松地处理文本是一个期望成为Linux系统管理员甚至是资深用户的最重要的技能之一,awk是通用编程语言之外最强大的文本处理工具之一。 +文本处理是Unix的核心。从管道到/proc子系统,“一切都是文件”的理念贯穿于操作系统和所有基于它构造的工具。正因为如此,轻松地处理文本是一个期望成为Linux系统管理员甚至是资深用户的最重要的技能之一,而 awk是通用编程语言之外最强大的文本处理工具之一。 -最简单的awk的任务是从标准输入中选择字段;如果你对awk除了这个没有学习过其他的,它还是会是你身边一个非常有用的工具。 +最简单的awk的任务是从标准输入中选择字段;如果你对awk除了这个用途之外,从来没了解过它的其他用途,你会发现它还是会是你身边一个非常有用的工具。 默认情况下,awk通过空格分隔输入。如果您想选择输入的第一个字段,你只需要告诉awk输出$ 1: @@ -30,13 +30,13 @@ > foo: three | bar: one -好吧,如果你的输入不是由空格分隔怎么办?只需用awk中的'-F'标志后带上你的分隔符: +好吧,如果你的输入不是由空格分隔怎么办?只需用awk中的'-F'标志指定你的分隔符: $ echo 'one mississippi,two mississippi,three mississippi,four mississippi' | awk -F , '{print $4}' > four mississippi -偶尔间,你会发现自己正在处理拥有不同的字段数量的数据,但你只知道你想要的*最后*字段。 awk中内置的$NF变量代表*字段的数量*,这样你就可以用它来抓取最后一个元素: +偶尔间,你会发现自己正在处理字段数量不同的数据,但你只知道你想要的*最后*字段。 awk中内置的$NF变量代表*字段的数量*,这样你就可以用它来抓取最后一个元素: $ echo 'one two three four' | awk '{print $NF}' @@ -54,9 +54,9 @@ > three -而且这一切都非常有用,同样你可以摆脱强制使用sed,cut,和grep来得到这些结果(尽管有大量的工作)。 +而且这一切都非常有用,同样你可以摆脱强制使用sed,cut,和grep来得到这些结果(尽管要做更多的操作)。 -因此,我将为你留下awk的最后介绍特性,维护跨行状态。 +因此,我将最后为你介绍awk的一个特性,维持跨行状态。 $ echo -e 'one 1\ntwo 2' | awk '{print $2}' @@ -68,7 +68,7 @@ > 3 -(END代表的是我们在执行完每行的处理**之后**只处理下面的代码块 +(END代表的是我们在执行完每行的处理**之后**只处理下面的代码块) 这里我使用的例子是统计web服务器请求日志的字节大小。想象一下我们有如下这样的日志: @@ -104,7 +104,7 @@ > 31657 -如果你正在寻找关于awk的更多资料,你可以在Amazon中在15美元内找到[原始awk手册][1]的副本。你同样可以使用Eric Pement的[单行awk命令收集][2]这本书 +如果你正在寻找关于awk的更多资料,你可以在Amazon中花费不到15美元买到[原始awk手册][1]的二手书。你也许还可以看看Eric Pement的[单行awk命令收集][2]这本书。 -------------------------------------------------------------------------------- @@ -112,7 +112,7 @@ via: http://xmodulo.com/2014/07/use-awk-command-linux.html 作者:[James Pearson][a] 译者:[geekpi](https://github.com/geekpi) -校对:[校对者ID](https://github.com/校对者ID) +校对:[wxy](https://github.com/wxy) 本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 diff --git a/translated/tech/20140804 How to install and configure Nvidia Optimus driver on Ubuntu.md b/published/20140804 How to install and configure Nvidia Optimus driver on Ubuntu.md similarity index 76% rename from translated/tech/20140804 How to install and configure Nvidia Optimus driver on Ubuntu.md rename to published/20140804 How to install and configure Nvidia Optimus driver on Ubuntu.md index 62b0c99dd6..79ce3d44f1 100644 --- a/translated/tech/20140804 How to install and configure Nvidia Optimus driver on Ubuntu.md +++ b/published/20140804 How to install and configure Nvidia Optimus driver on Ubuntu.md @@ -4,19 +4,20 @@ Nvidia Optimus是一款利用“双显卡切换”技术的混合GPU系统,但 ### 背景知识 ### 对那些不熟悉Nvidia Optimus的读者,在板载Intel图形芯片组和使用被称为“GPU切换”、对需求有着更强大处理能力的NVIDA显卡这两者之间的进行切换是很有必要的。这么做的主要目的是延长笔记本电池的使用寿命,以便在不需要Nvidia GPU的时候将其关闭。带来的好处是显而易见的,比如说你只是想简单地打打字,笔记本电池可以撑8个小时;如果看高清视频,可能就只能撑3个小时了。使用Windows时经常如此。 + ![](https://farm6.staticflickr.com/5581/14612159387_2e89a52085_z.jpg) 几年前,我买了一台上网本(Asus VX6),犯的最蠢的一个错误就是没有检查Linux驱动兼容性。因为在以前,特别是对于一台上网本大小的设备,这根本不会是问题。即便某些驱动不是现成可用的,我也可以找到其它的办法让它正常工作,比如安装专门模块或者使用反向移植。对我来说这是第一次——我的电脑预先配备了Nvidia ION2图形显卡。 在那时候,Nvidia的Optimus混合GPU硬件还是相当新的产品,而我也没有预见到在这台机器上运行Linux会遇到什么限制。如果你读到了这里,恰好对Linux系统有经验,而且也在几年前买过一台笔记本,你可能对这种痛苦感同身受。 -[Bumblebee][4]项目直到最近因为得到Linux系统对混合图形方面的支持才变得好起来。事实上,如果配置正确的话,通过命令行接口(如“optirun vlc”)为想要的应用程序去利用Nvidia显卡的功能是可能的,但让HDMI一类的功能运转起来就很不同了。(译者注:Bumblebee 项目是把Nvidia的Optimus技术移到Linux上来。) +[Bumblebee][4]项目直到最近因为得到Linux系统对混合图形方面的支持才变得好起来。事实上,如果配置正确的话,通过命令行接口(如“optirun vlc”)让你选定的应用程序能利用Nvidia显卡功能是可行的,但让HDMI一类的功能运转起来就很不同了。(译者注:Bumblebee 项目是把Nvidia的Optimus技术移到Linux上来。) -我之所以使用“如果配置正确的话”这个短语,是因为实际上为了让它发挥出性能往往不只是通过几次尝试去改变Xorg的配置就能做到的。如果你以前没有使用过ppa-purge或者运行过“dpkg-reconfigure -phigh xserver-xorg”这类命令,那么我可以向你保证修补Bumblebee的过程会让你受益匪浅。 +我之所以使用“如果配置正确的话”这个短语,是因为实际上为了让它发挥出性能来往往不只是通过几次尝试去改变Xorg的配置就能做到的。如果你以前没有使用过ppa-purge或者运行过“dpkg-reconfigure -phigh xserver-xorg”这类命令,那么我可以向你保证修补Bumblebee的过程会让你受益匪浅。 [![](https://farm6.staticflickr.com/5588/14798680495_947c38b043_o.png)][2] -等待了很长一段时间,Nvidia才发布了支持Optimus的Linux驱动,但我们仍然没有获取对双显卡切换的真正支持。然而,现在有了Ubuntu 14.04、nvidia-prime和nvidia-331驱动,任何人都可以在Intel芯片和Nvidia显卡之间轻松切换。不幸的是,为了使切换生效,还是会受限于要重启X11视窗系统(通过注销登录实现)。 +在等待了很长一段时间后,Nvidia才发布了支持Optimus的Linux驱动,但我们仍然没有得到对双显卡切换的真正支持。然而,现在有了Ubuntu 14.04、nvidia-prime和nvidia-331驱动,任何人都可以在Intel芯片和Nvidia显卡之间轻松切换。不过不幸的是,为了使切换生效,还是会受限于需要重启X11视窗系统(通过注销登录实现)。 为了减轻这种不便,有一个小型程序用于快速切换,稍后我会给出。这个驱动程序的安装就此成为一件轻而易举的事了,HDMI也可以正常工作,这足以让我心满意足了。 @@ -24,11 +25,11 @@ Nvidia Optimus是一款利用“双显卡切换”技术的混合GPU系统,但 为了更快地描述这个过程,我假设你已经安装好Ubuntu 14.04或者Mint 17。 -作为一名系统管理员,最近我发现90%的Linux通过命令行执行起来更快,但这次我推荐使用“Additional Drivers”这个应用程序,你可能使用它安装过网卡或声卡驱动。 +作为一名系统管理员,最近我发现90%的Linux操作通过命令行执行起来更快,但这次我推荐使用“Additional Drivers”这个应用程序,你可能使用它安装过网卡或声卡驱动。 ![](https://farm4.staticflickr.com/3886/14795564221_753f9e2d99_z.jpg) -**注意:下面的所有命令都是在~#前执行的,需要root权限执行。在运行命令前,要么使用“sudo su”(切换到root权限),要么在每条命令的开头使用速冻运行。** +**注意:下面的所有命令都是在~#提示符下执行的,需要root权限执行。在运行命令前,要么使用“sudo su”(切换到root权限),要么在每条命令的开头使用sudo运行。** 你也可以在命令行输入如下命令进行安装: @@ -44,19 +45,19 @@ Nvidia Optimus是一款利用“双显卡切换”技术的混合GPU系统,但 ~$ nvidia-settings -#### 注意:~$表示不以root用户身份执行。 #### +**注意:~$表示不以root用户身份执行。** ![](https://farm4.staticflickr.com/3921/14796320814_de5c9882c2_z.jpg) 你也可以使用命令行设置默认使用哪一块显卡: - ~# prime-select intel (or nvidia) + ~# prime-select intel (或 nvidia) 使用这个命令进行切换: - ~# prime-switch intel (or nvidia) + ~# prime-switch intel (或 nvidia) -两个命令的生效都需要重启X11,可以通过注销和重新登录实现。重启电脑也行。 +两个命令的生效都需要重启X11,可以通过注销和重新登录实现。当然重启电脑也行。 对Ubuntu用户键入命令: @@ -70,7 +71,7 @@ Nvidia Optimus是一款利用“双显卡切换”技术的混合GPU系统,但 ~# prime-select query -最后,你可以通过添加ppa:nilarimogard/webupd8来安装叫做prime-indicator的程序包,实现通过工具栏快速切换来重启Xserver会话。为了安装它,只需要运行: +最后,你可以通过添加ppa:nilarimogard/webupd8来安装叫做prime-indicator的程序包,实现通过工具栏快速切换来重启Xserver会话。要安装它,只需要运行: ~# add-apt-repository ppa:nilarimogard/webupd8 ~# apt-get update @@ -84,7 +85,7 @@ Nvidia Optimus是一款利用“双显卡切换”技术的混合GPU系统,但 也可以花时间查看一下这个我偶然发现的[脚本][3],用来方便地在Bumblebee和Nvidia-Prime之间进行切换,但我必须强调并没有亲自对此进行实验。 -最后,我感到非常惭愧写了这么多才得以为Linux上的显卡提供了专门支持,但仍然不能实现双显卡切换,因为混合图形技术似乎是便携式设备的未来。一般情况下,AMD会发布Linux平台上的驱动支持,但我认为Optimus是目前为止我遇到过的最糟糕的硬件支持问题。 +最后,我感到非常惭愧,写了这么多才得以为Linux上的显卡提供了专门支持,但仍然不能实现双显卡切换,因为混合图形技术似乎是便携式设备的未来。一般情况下,AMD会发布Linux平台上的驱动支持,但我认为Optimus是目前为止我遇到过的最糟糕的硬件支持问题。 不管这篇教程对你的使用是否完美,但这确实是利用这块Nvidia显卡最容易的方法。你可以试着在Intel显卡上只运行最新的Unity,然后考虑2到3个小时的电池寿命是否值得权衡。 @@ -94,7 +95,7 @@ via: http://xmodulo.com/2014/08/install-configure-nvidia-optimus-driver-ubuntu.h 作者:[Christopher Ward][a] 译者:[KayGuoWhu](https://github.com/KayGuoWhu) -校对:[校对者ID](https://github.com/校对者ID) +校对:[wxy](https://github.com/wxy) 本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 diff --git a/translated/tech/20140808 How to install Puppet server and client on CentOS and RHEL.md b/published/20140808 How to install Puppet server and client on CentOS and RHEL.md similarity index 93% rename from translated/tech/20140808 How to install Puppet server and client on CentOS and RHEL.md rename to published/20140808 How to install Puppet server and client on CentOS and RHEL.md index a84062730f..ded986fab8 100644 --- a/translated/tech/20140808 How to install Puppet server and client on CentOS and RHEL.md +++ b/published/20140808 How to install Puppet server and client on CentOS and RHEL.md @@ -4,7 +4,7 @@ ### Puppet 是什么? ### -Puppet 是一款为 IT 系统管理员和顾问设计的自动化软件,你可以用它自动化地完成诸如安装应用程序和服务、补丁管理和部署等工作。所有资源的相关配置都以“manifests”的方式保存,单台机器或者多台机器都可以使用。如果你想了解更多内容,Puppet 实验室的网站上有关于 [Puppet 及其工作原理][1]的更详细的介绍。 +Puppet 是一款为 IT 系统管理员和顾问们设计的自动化软件,你可以用它自动化地完成诸如安装应用程序和服务、补丁管理和部署等工作。所有资源的相关配置都以“manifests”的方式保存,单台机器或者多台机器都可以使用。如果你想了解更多内容,Puppet 实验室的网站上有关于 [Puppet 及其工作原理][1]的更详细的介绍。 ### 本教程要做些什么? ### @@ -58,7 +58,7 @@ Puppet 是一款为 IT 系统管理员和顾问设计的自动化软件,你可 # chkconfig puppet on -Puppet 客户端需要知道 Puppet master 服务器的地址。最佳方案是使用 DNS 服务器解析 Puppet master 服务器地址。如果你没有 DNS 服务器,在 `/etc/hosts` 里添加下面这几行也可以: +Puppet 客户端需要知道 Puppet master 服务器的地址。最佳方案是使用 DNS 服务器解析 Puppet master 服务器地址。如果你没有 DNS 服务器,在 `/etc/hosts` 里添加类似下面这几行也可以: > 1.2.3.4 server.your.domain @@ -125,7 +125,7 @@ master 服务器名也要在 `/etc/puppet/puppet.conf` 文件的“[agent]”小 > runinterval = -这个选项的值可以是秒(格式比如 30 或者 30s),分钟(30m),小时(6h),天(2d)以及年(5y)。值得注意的是,0 意味着“立即执行”而不是“从不执行”。 +这个选项的值可以是秒(格式比如 30 或者 30s),分钟(30m),小时(6h),天(2d)以及年(5y)。值得注意的是,**0 意味着“立即执行”而不是“从不执行”**。 ### 提示和技巧 ### @@ -139,7 +139,7 @@ master 服务器名也要在 `/etc/puppet/puppet.conf` 文件的“[agent]”小 # puppet agent -t --debug -Debug 选项会显示 Puppet 本次运行时的差不多每一个步骤,这在调试非常复杂的问题时很有用。另一个很有用的选项是: +debug 选项会显示 Puppet 本次运行时的差不多每一个步骤,这在调试非常复杂的问题时很有用。另一个很有用的选项是: # puppet agent -t --noop @@ -187,7 +187,7 @@ via: http://xmodulo.com/2014/08/install-puppet-server-client-centos-rhel.html 作者:[Jaroslav Štěpánek][a] 译者:[sailing](https://github.com/sailing) -校对:[校对者ID](https://github.com/校对者ID) +校对:[wxy](https://github.com/wxy) 本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 diff --git a/translated/tech/20140811 How to improve your productivity in terminal environment with Tmux.md b/published/20140811 How to improve your productivity in terminal environment with Tmux.md similarity index 51% rename from translated/tech/20140811 How to improve your productivity in terminal environment with Tmux.md rename to published/20140811 How to improve your productivity in terminal environment with Tmux.md index c94df0b81b..5bdb273d06 100644 --- a/translated/tech/20140811 How to improve your productivity in terminal environment with Tmux.md +++ b/published/20140811 How to improve your productivity in terminal environment with Tmux.md @@ -1,15 +1,15 @@ -如何使用Tmux提高终端环境下的生产率 +如何使用Tmux提高终端环境下的效率 === -鼠标的采用是次精彩的创新,它让电脑更加接近普通人。但从程序员和系统管理员的角度,使用电脑办公时,手一旦离开键盘,就会有些分心 +鼠标的发明是了不起的创新,它让电脑更加接近普通人。但从程序员和系统管理员的角度,使用电脑工作时,手一旦离开键盘,就会有些分心。 -作为一名系统管理员,我大量的工作都需要在终端环境下。打开很多标签,然后在多个终端之间切换窗口会让我慢下来。而且当我的服务器出问题的时候,我不能浪费任何时间 +作为一名系统管理员,我大量的工作都需要在终端环境下。打开很多标签,然后在多个终端之间切换窗口会让我慢下来。尤其是当我的服务器出问题的时候,我不能浪费任何时间! ![](https://farm6.staticflickr.com/5563/14853747084_e14cf18e8f_z.jpg) -[Tmux][1]是我日常工作必要的工具之一。我可以借助Tmux创造出复杂的开发环境,同时还可以在一旁进行SSH远程连接。我可以开出很多窗口,拆分成很多面板,附加和分离会话等等。掌握了Tmux之后,你就可以扔掉鼠标了(只是个玩笑:D) +[Tmux][1]是我日常工作必要的工具之一。我可以借助Tmux构建出复杂的开发环境,同时还可以在一旁进行SSH远程连接。我可以开出很多窗口,将其拆分成很多面板,接管和分离会话等等。掌握了Tmux之后,你就可以扔掉鼠标了(只是个玩笑:D)。 -Tmux("Terminal Multiplexer"的简称)可以让我们在单个屏幕的灵活布局下开出很多终端,我们就可以协作地使用它们。举个例子,在一个面板中,我们用Vim修改一些配置文件,在另一个面板,我们使用irssi聊天,而在其余的面板,跟踪一些日志。然后,我们还可以打开新的窗口来升级系统,再开一个新窗口来进行服务器的ssh连接。在这些窗口面板间浏览切换和创建它们一样简单。它的高度可配置和可定制的,让其成为你心中的延伸 +Tmux("Terminal Multiplexer"的简称)可以让我们在单个屏幕的灵活布局下开出很多终端,我们就可以协作地使用它们。举个例子,在一个面板中,我们用Vim修改一些配置文件,在另一个面板,我们使用`irssi`聊天,而在其余的面板,可以跟踪一些日志。然后,我们还可以打开新的窗口来升级系统,再开一个新窗口来进行服务器的ssh连接。在这些窗口面板间浏览切换和创建它们一样简单。它的高度可配置和可定制的,让其成为你心中的延伸 ### 在Linux/OSX下安装Tmux ### @@ -20,22 +20,21 @@ Tmux("Terminal Multiplexer"的简称)可以让我们在单个屏幕的灵活布 # sudo brew install tmux # sudo port install tmux -### Debian/Ubuntu ### +#### Debian/Ubuntu: #### # sudo apt-get install tmux -RHEL/CentOS/Fedora(RHEL/CentOS 要求 [EPEL repo][2]): +####RHEL/CentOS/Fedora(RHEL/CentOS 要求 [EPEL repo][2]):#### $ sudo yum install tmux -Archlinux: +####Archlinux:#### $ sudo pacman -S tmux ### 使用不同会话工作 ### -使用Tmux的最好方式是使用不同的会话,这样你就可以以你想要的方式,将任务和应用组织到不同的会话中。如果你想改变一个会话,会话里面的任何工作都无须停止或者杀掉,让我们来看看这是怎么工作的 - +使用Tmux的最好方式是使用会话的方式,这样你就可以以你想要的方式,将任务和应用组织到不同的会话中。如果你想改变一个会话,会话里面的任何工作都无须停止或者杀掉。让我们来看看这是怎么工作的。 让我们开始一个叫做"session"的会话,并且运行top命令 @@ -46,20 +45,20 @@ Archlinux: $ tmux attach-session -t session -之后你会看到top操作仍然运行在重新连接的会话上 +之后你会看到top操作仍然运行在重新连接的会话上。 一些管理sessions的命令: $ tmux list-session - $ tmux new-session - $ tmux attach-session -t - $ tmux rename-session -t - $ tmux choose-session -t - $ tmux kill-session -t + $ tmux new-session <会话名> + $ tmux attach-session -t <会话名> + $ tmux rename-session -t <会话名> + $ tmux choose-session -t <会话名> + $ tmux kill-session -t <会话名> ### 使用不同的窗口工作 -很多情况下,你需要在一个会话中运行多个命令,并且执行多个任务。我们可以在一个会话的多个窗口里组织他们。在现代化的GUI终端(比如 iTerm或者Konsole),一个窗口被视为一个标签。在会话中配置了我们默认的环境,我们就能够在一个会话中创建许多我们需要的窗口。窗口就像运行在会话中的应用程序,当我们脱离当前会话的时候,它仍在持续,让我们来看一个例子: +很多情况下,你需要在一个会话中运行多个命令,执行多个任务。我们可以在一个会话的多个窗口里组织他们。在现代的GUI终端(比如 iTerm或者Konsole),一个窗口被视为一个标签。在会话中配置了我们默认的环境之后,我们就能够在一个会话中创建许多我们需要的窗口。窗口就像运行在会话中的应用程序,当我们脱离当前会话的时候,它仍在持续,让我们来看一个例子: $ tmux new -s my_session @@ -67,7 +66,7 @@ Archlinux: 按下**CTRL-b c** -这将会创建一个新的窗口,然后屏幕的光标移向它。现在你就可以在新窗口下运行你的新应用。你可以写下你当前窗口的名字。在目前的案例下,我运行的top程序,所以top就是该窗口的名字 +这将会创建一个新的窗口,然后屏幕的光标移向它。现在你就可以在新窗口下运行你的新应用。你可以修改你当前窗口的名字。在目前的例子里,我运行的top程序,所以top就是该窗口的名字 如果你想要重命名,只需要按下: @@ -77,15 +76,15 @@ Archlinux: ![](https://farm6.staticflickr.com/5579/14855868482_d52516a357_z.jpg) -一旦在一个会话中创建多个窗口,我们需要在这些窗口间移动的办法。窗口以数组的形式被组织在一起,每个窗口都有一个从0开始计数的号码,想要快速跳转到其余窗口: +一旦在一个会话中创建多个窗口,我们需要在这些窗口间移动的办法。窗口像数组一样组织在一起,从0开始用数字标记每个窗口,想要快速跳转到其余窗口: -**CTRL-b ** +**CTRL-b <窗口号>** -如果我们给窗口起了名字,我们可以使用下面的命令切换: +如果我们给窗口起了名字,我们可以使用下面的命令找到它们: **CTRL-b f** -列出所有窗口: +也可以列出所有窗口: **CTRL-b w** @@ -94,21 +93,21 @@ Archlinux: **CTRL-b n**(到达下一个窗口) **CTRL-b p**(到达上一个窗口) -想要离开一个窗口: +想要离开一个窗口,可以输入 exit 或者: **CTRL-b &** -关闭窗口之前,你需要确认一下 +关闭窗口之前,你需要确认一下。 ### 把窗口分成许多面板 -有时候你在编辑器工作的同时,需要查看日志文件。编辑的同时追踪日志真的很有帮助。Tmux可以让我们把窗口分成许多面板。举了例子,我们可以创建一个控制台监测我们的服务器,同时拥有一个复杂的编辑器环境,这样就能同时进行编译和debug +有时候你在编辑器工作的同时,需要查看日志文件。在编辑的同时追踪日志真的很有帮助。Tmux可以让我们把窗口分成许多面板。举个例子,我们可以创建一个控制台监测我们的服务器,同时用编辑器构造复杂的开发环境,这样就能同时进行编译和调试了。 -让我们创建另一个Tmux会话,让其以面板的方式工作。首先,如果我们在某个会话中,那就从Tmux会话中脱离出来 +让我们创建另一个Tmux会话,让其以面板的方式工作。首先,如果我们在某个会话中,那就从Tmux会话中脱离出来: **CTRL-b d** -开始一个叫做"panes"的新会话 +开始一个叫做"panes"的新会话: $ tmux new -s panes @@ -120,17 +119,17 @@ Archlinux: **CRTL-b %** -又增加了两个 +又增加了两个: ![](https://farm4.staticflickr.com/3881/14669677417_bc1bdce255_z.jpg) 在他们之间移动: -**CTRL-b ** +**CTRL-b <光标键>** ### 结论 -我希望这篇教程能对你有作用。作为奖励,像[Tmuxinator][3] 或者 [Tmuxifier][4]这样的工具,可以简化Tmux会话,窗口和面板的创建及加载,你可以很容易就配置Tmux。如果你没有使用过这些,尝试一下吧 +我希望这篇教程能对你有作用。此外,像[Tmuxinator][3] 或者 [Tmuxifier][4]这样的工具,可以简化Tmux会话,窗口和面板的创建及加载,你可以很容易就配置Tmux。如果你没有使用过这些,尝试一下吧! -------------------------------------------------------------------------------- @@ -138,7 +137,7 @@ via: http://xmodulo.com/2014/08/improve-productivity-terminal-environment-tmux.h 作者:[Christopher Valerio][a] 译者:[su-kaiyao](https://github.com/su-kaiyao) -校对:[校对者ID](https://github.com/校对者ID) +校对:[wxy](https://github.com/wxy) 本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 diff --git a/translated/tech/20140822 15 Practical Examples of 'echo' command in Linux.md b/published/20140822 15 Practical Examples of 'echo' command in Linux.md similarity index 73% rename from translated/tech/20140822 15 Practical Examples of 'echo' command in Linux.md rename to published/20140822 15 Practical Examples of 'echo' command in Linux.md index 6b906232b1..b5898209e7 100644 --- a/translated/tech/20140822 15 Practical Examples of 'echo' command in Linux.md +++ b/published/20140822 15 Practical Examples of 'echo' command in Linux.md @@ -1,15 +1,16 @@ -Linux中15个‘echo’ 实例 +Linux中的15个‘echo’ 命令实例 ================================================================================ **echo**是一种最常用的与广泛使用的内置于Linux的bash和C shell的命令,通常用在脚本语言和批处理文件中来在标准输出或者文件中显示一行文本或者字符串。 ![echo command examples](http://www.tecmint.com/wp-content/uploads/2014/08/echo-command.png) + echo命令例子 echo命令的语法是: echo [选项] [字符串] -**1.** 输入一行文本并显示在标准输出上 +###**1.** 输入一行文本并显示在标准输出上 $ echo Tecmint is a community of Linux Nerds @@ -17,7 +18,9 @@ echo命令的语法是: Tecmint is a community of Linux Nerds -**2.** 声明一个变量并输出它的值。比如,声明变量**x**并给它赋值为**10**。 +###**2.** 输出一个声明的变量值 + +比如,声明变量**x**并给它赋值为**10**。 $ x=10 @@ -27,15 +30,20 @@ echo命令的语法是: The value of variable x = 10 -**注意:** Linux中的选项‘**-e**‘扮演了转义字符反斜线的翻译器。 -**3.** 使用‘**\b**‘选项- ‘**-e**‘后带上'\b'会删除字符间的所有空格。 +###**3.** 使用‘**\b**‘选项 + +‘**-e**‘后带上'\b'会删除字符间的所有空格。 + +**注意:** Linux中的选项‘**-e**‘扮演了转义字符反斜线的翻译器。 $ echo -e "Tecmint \bis \ba \bcommunity \bof \bLinux \bNerds" TecmintisacommunityofLinuxNerds -**4.** 使用‘**\n**‘选项- ‘**-e**‘后面的带上‘\n’行会在遇到的地方作为新的一行 +###**4.** 使用‘**\n**‘选项 + +‘**-e**‘后面的带上‘\n’行会在遇到的地方作为新的一行 $ echo -e "Tecmint \nis \na \ncommunity \nof \nLinux \nNerds" @@ -47,13 +55,15 @@ echo命令的语法是: Linux Nerds -**5.** 使用‘**\t**‘选项 - ‘**-e**‘后面跟上‘\t’会在空格间加上水平制表符。 +###**5.** 使用‘**\t**‘选项 + +‘**-e**‘后面跟上‘\t’会在空格间加上水平制表符。 $ echo -e "Tecmint \tis \ta \tcommunity \tof \tLinux \tNerds" Tecmint is a community of Linux Nerds -**6.** 也可以同时使用换行‘**\n**‘与水平制表符‘**\t**‘。 +###**6.** 也可以同时使用换行‘**\n**‘与水平制表符‘**\t**‘ $ echo -e "\n\tTecmint \n\tis \n\ta \n\tcommunity \n\tof \n\tLinux \n\tNerds" @@ -65,7 +75,9 @@ echo命令的语法是: Linux Nerds -**7.** 使用‘**\v**‘选项 - ‘**-e**‘后面跟上‘\v’会加上垂直制表符。 +###**7.** 使用‘**\v**‘选项 + +‘**-e**‘后面跟上‘\v’会加上垂直制表符。 $ echo -e "\vTecmint \vis \va \vcommunity \vof \vLinux \vNerds" @@ -77,7 +89,7 @@ echo命令的语法是: Linux Nerds -**8.** 也可以同时使用换行‘**\n**‘与垂直制表符‘**\v**‘。 +###**8.** 也可以同时使用换行‘**\n**‘与垂直制表符‘**\v**‘ $ echo -e "\n\vTecmint \n\vis \n\va \n\vcommunity \n\vof \n\vLinux \n\vNerds" @@ -98,43 +110,51 @@ echo命令的语法是: **注意:** 你可以按照你的需求连续使用两个或者多个垂直制表符,水平制表符与换行符。 -**9.** 使用‘**\r**‘选项 - ‘**-e**‘后面跟上‘\r’来指定输出中的回车符。 +###**9.** 使用‘**\r**‘选项 + +‘**-e**‘后面跟上‘\r’来指定输出中的回车符。(LCTT 译注:会覆写行开头的字符) $ echo -e "Tecmint \ris a community of Linux Nerds" is a community of Linux Nerds -**10.** 使用‘**\c**‘选项 - ‘**-e**‘后面跟上‘\c’会抑制输出后面的字符并且最后不会换新行。 +###**10.** 使用‘**\c**‘选项 + +‘**-e**‘后面跟上‘\c’会抑制输出后面的字符并且最后不会换新行。 $ echo -e "Tecmint is a community \cof Linux Nerds" Tecmint is a community @tecmint:~$ -**11.** ‘**-n**‘会在echo完后不会输出新行。 +###**11.** ‘**-n**‘会在echo完后不会输出新行 $ echo -n "Tecmint is a community of Linux Nerds" Tecmint is a community of Linux Nerds@tecmint:~/Documents$ -**12.** 使用‘**\c**‘选项 - ‘**-e**‘后面跟上‘\a’选项会听到声音警告。 +###**12.** 使用‘**\a**‘选项 + +‘**-e**‘后面跟上‘\a’选项会听到声音警告。 $ echo -e "Tecmint is a community of \aLinux Nerds" Tecmint is a community of Linux Nerds -**注意:** 在你开始前,请先检查你的音量键。 +**注意:** 在你开始前,请先检查你的音量设置。 -**13.** 使用echo命令打印所有的文件和文件夹(ls命令的替代)。 +###**13.** 使用echo命令打印所有的文件和文件夹(ls命令的替代) $ echo * 103.odt 103.pdf 104.odt 104.pdf 105.odt 105.pdf 106.odt 106.pdf 107.odt 107.pdf 108a.odt 108.odt 108.pdf 109.odt 109.pdf 110b.odt 110.odt 110.pdf 111.odt 111.pdf 112.odt 112.pdf 113.odt linux-headers-3.16.0-customkernel_1_amd64.deb linux-image-3.16.0-customkernel_1_amd64.deb network.jpeg -**14.** 打印制定的文件类型。比如,让我们假设你想要打印所有的‘**.jpeg**‘文件,使用下面的命令。 +###**14.** 打印制定的文件类型 + +比如,让我们假设你想要打印所有的‘**.jpeg**‘文件,使用下面的命令。 $ echo *.jpeg network.jpeg -**15.** echo可以使用重定向符来输出到一个文件而不是标准输出。 +###**15.** echo可以使用重定向符来输出到一个文件而不是标准输出 $ echo "Test Page" > testpage @@ -142,7 +162,7 @@ echo命令的语法是: avi@tecmint:~$ cat testpage Test Page -### echo 选项 ### +### echo 选项列表 ### @@ -187,14 +207,15 @@ echo命令的语法是:
-就是这些了,不要忘记在下面留下你有价值的反馈。 +就是这些了,不要忘记在下面留下你的反馈。 + -------------------------------------------------------------------------------- via: http://www.tecmint.com/echo-command-in-linux/ 作者:[Avishek Kumar][a] 译者:[geekpi](https://github.com/geekpi) -校对:[校对者ID](https://github.com/校对者ID) +校对:[wxy](https://github.com/wxy) 本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 diff --git a/translated/tech/20140825 Linux FAQs with Answers--How to install Shutter on CentOS.md b/published/20140825 Linux FAQs with Answers--How to install Shutter on CentOS.md similarity index 74% rename from translated/tech/20140825 Linux FAQs with Answers--How to install Shutter on CentOS.md rename to published/20140825 Linux FAQs with Answers--How to install Shutter on CentOS.md index ca52077ab0..2f84ed9a8d 100644 --- a/translated/tech/20140825 Linux FAQs with Answers--How to install Shutter on CentOS.md +++ b/published/20140825 Linux FAQs with Answers--How to install Shutter on CentOS.md @@ -1,9 +1,10 @@ -Linux有问必答——如何在CentOS上安装Shutter +Linux有问必答:如何在CentOS上安装Shutter ================================================================================ > **问题**:我想要在我的CentOS桌面上试试Shutter屏幕截图程序,但是,当我试着用yum来安装Shutter时,它总是告诉我“没有shutter包可用”。我怎样才能在CentOS上安装Shutter啊? [Shutter][1]是一个用于Linux桌面的开源(GPLv3)屏幕截图工具。它打包有大量用户友好的功能,这让它成为Linux中功能最强大的屏幕截图程序之一。你可以用Shutter来捕捉一个规则区域、一个窗口、整个桌面屏幕、或者甚至是来自任意专用地址的一个网页的截图。除此之外,你也可以用它内建的图像编辑器来对捕获的截图进行编辑,应用不同的效果,将图像导出为不同的图像格式(svg,pdf,ps),或者上传图片到公共图像主机或者FTP站点。 -Shutter is not available as a pre-built package on CentOS (as of version 7). Fortunately, there exists a third-party RPM repository called Nux Dextop, which offers Shutter package. So [enable Nux Dextop repository][2] on CentOS. Then use the following command to install Shutter. + +Shutter 在 CentOS (截止至版本 7)上没有预先构建好的软件包。幸运的是,有一个第三方提供的叫做 Nux Dextop 的 RPM 中提供了 Shutter 软件包。 所以在 CentOS 上[启用 Nux Dextop 软件库][2],然后使用下列命令来安装它: $ sudo yum --enablerepo=nux-dextop install shutter @@ -14,9 +15,9 @@ Shutter is not available as a pre-built package on CentOS (as of version 7). For via: http://ask.xmodulo.com/install-shutter-centos.html 译者:[GOLinux](https://github.com/GOLinux) -校对:[校对者ID](https://github.com/校对者ID) +校对:[wxy](https://github.com/wxy) 本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 [1]:http://shutter-project.org/ -[2]:http://ask.xmodulo.com/enable-nux-dextop-repository-centos-rhel.html +[2]:http://linux.cn/article-3889-1.html diff --git a/translated/tech/20140825 Linux FAQs with Answers--How to show a MAC learning table of Linux bridge.md b/published/20140825 Linux FAQs with Answers--How to show a MAC learning table of Linux bridge.md similarity index 93% rename from translated/tech/20140825 Linux FAQs with Answers--How to show a MAC learning table of Linux bridge.md rename to published/20140825 Linux FAQs with Answers--How to show a MAC learning table of Linux bridge.md index 3cf867ff1b..53a448b51f 100644 --- a/translated/tech/20140825 Linux FAQs with Answers--How to show a MAC learning table of Linux bridge.md +++ b/published/20140825 Linux FAQs with Answers--How to show a MAC learning table of Linux bridge.md @@ -1,4 +1,4 @@ -Linux有问必答——如何显示Linux网桥的MAC学习表 +Linux有问必答:如何显示Linux网桥的MAC学习表 ================================================================================ > **问题**:我想要检查一下我用brctl工具创建的Linux网桥的MAC地址学习状态。请问,我要怎样才能查看Linux网桥的MAC学习表(或者转发表)? @@ -18,6 +18,6 @@ Linux网桥是网桥的软件实现,这是Linux内核的内核部分。与硬 via: http://ask.xmodulo.com/show-mac-learning-table-linux-bridge.html 译者:[GOLinux](https://github.com/GOLinux) -校对:[校对者ID](https://github.com/校对者ID) +校对:[wxy](https://github.com/wxy) 本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 diff --git a/published/20140826 Linus Torvalds Promotes Linux for Desktops, Embedded Computing.md b/published/20140826 Linus Torvalds Promotes Linux for Desktops, Embedded Computing.md new file mode 100644 index 0000000000..4e7ac1dbc1 --- /dev/null +++ b/published/20140826 Linus Torvalds Promotes Linux for Desktops, Embedded Computing.md @@ -0,0 +1,31 @@ +Linus Torvalds 希望推动Linux在桌面和嵌入式计算方面共同发展 +================================================================================ +> Linux的内核开发者和开源领袖Linus Torvalds前一段时间表达了关于Linux桌面和嵌入式设备中Linux的未来的看法。 + +![](http://thevarguy.com/site-files/thevarguy.com/files/imagecache/medium_img/uploads/2014/08/linus-torvalds-1.jpg) + +什么是Linux桌面和嵌入式设备中Linux的未来?这是个值得讨论的问题,不过Linux的创始人和开源巨人Linus Torvalds在最近一届 [Linux 基金会][1] 的LinuxCon大会上,在一次对话中表达了一些有趣的观点。 + +作为敲出第一版Linux内核代码并且在1991年将它们共享在互联网上的家伙,Torvalds毫无疑问是开源软件甚至是所有软件中最著名的开发者,如今他依然活跃在其中。在此期间,Torvalds是许多人和组织中唯一一个引领着Linux发展的个体,它的观点往往能影响着开源社区,而且,作为一个内核开发者的角色赋予了他能决定哪些特点和代码能被放进操作系统内部的强大权利。 + +所以说,关注Torvalds所说的话是很值得的, "我还是挺想要桌面的。" [他在上月的LinuxCon大会上这样说道][2] 那表明他仍然着眼于作为使PC更加强大的操作系统Linux的未来,尽管十年来Linux桌面市场的份额一直很少,而且大部分围绕Linux的商业活动都去涉及服务器或者安卓手机去了。 + +但是,Torvalds还说,确保Linux桌面能有个宏伟的未来意味着解决了受阻的 “基础设施问题”,庞大的开源软件生态系统和硬件世界让他充满信心。这不是Linux核心代码本身的问题,而是要让Linux桌面渠道友好,这可能是伟大的Torvalds和他开发同伴们所需要花精力去达到的目标。这取决于app的开发者、硬件制造商和其它有志于实现人们能方便使用基于Linux的计算平台的各方力量。 + +另一方面,Torvalds也提到了他的憧憬,就是内核开发者们能简化嵌入式装置中的Linux代码——这也许和让Linux内核更加桌面友好化的任务有所分歧。但这也不一定,因为无论如何,Linux都是以模块化设计的,单内核代码库不能同时满足桌面用户和嵌入式开发者的需求,这是没有道理的,因为这取决于他们使用的模块。 + +作为一个一直想看到更多搭载Linux的嵌入式设备出现的Linux桌面用户,我希望Torvalds的所有愿望都可以实现,到那时我就可以只用Linux来做所有我想做的事情,无论是在电脑桌面上、手机上、车上,或者是任何其它的地方。 + +-------------------------------------------------------------------------------- + +via: http://thevarguy.com/open-source-application-software-companies/082514/linus-torvalds-promotes-linux-desktops-and-embedded-compu + +作者:[Christopher Tozzi][a] +译者:[ZTinoZ](https://github.com/ZTinoZ) +校对:[wxy](https://github.com/wxy) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://thevarguy.com/author/christopher-tozzi +[1]:http://linuxfoundation.org/ +[2]:http://www.eweek.com/enterprise-apps/linux-founder-linus-torvalds-still-wants-the-desktop.html diff --git a/published/20140904 Making MySQL Better at GitHub.md b/published/20140904 Making MySQL Better at GitHub.md new file mode 100644 index 0000000000..1aeea36c03 --- /dev/null +++ b/published/20140904 Making MySQL Better at GitHub.md @@ -0,0 +1,92 @@ + GitHub 是如何迁移 MySQL 集群的 +================================================================================ +> 在 GitHub 我们总是说“如果网站响应速度不够快,我们就不应该让它上线运营”。我们之前在[前端的体验速度][1]这篇文章中介绍了一些提高网站响应速率的方法,但这只是故事的一部分。真正影响到 GitHub.com 性能的因素是 MySQL 数据库架构。让我们来瞧瞧我们的基础架构团队是如何无缝升级了 MySQL 架构吧,这事儿发生在去年8月份,成果就是大大提高了 GitHub 网站的速度。 + +### 任务 ### + +去年我们把 GitHub 上的大部分数据移到了新的数据中心,这个中心有世界顶级的硬件资源和网络平台。自从使用了 MySQL 作为我们的后端系统的基础,我们一直期望着一些改进来大大提高数据库性能,但是在数据中心使用全新的硬件来部署一套全新的集群环境并不是一件简单的工作,所以我们制定了一套计划和测试工作,以便数据能平滑过渡到新环境。 + +### 准备工作 ### + +像我们这种关于架构上的巨大改变,在执行的每一步都需要收集数据指标。新机器上安装好了基本的操作系统,接下来就是测试新配置下的各种性能。为了模拟真实的工作负载环境,我们使用 tcpdump 工具从旧的集群那里复制正在发生的 SELECT 请求,并在新集群上重新回放一遍。 + +MySQL 调优是个繁琐的细致活,像众所周知的 innodb_buffer_pool_size 这个参数往往能对 MySQL 性能产生巨大的影响。对于这类参数,我们必须考虑在内,所以我们列了一份参数清单,包括 innodb_thread_concurrency,innodb_io_capacity,和 innodb_buffer_pool_instances,还有其它的。 + +在每次测试中,我们都很小心地只改变一个参数,并且让一次测试至少运行12小时。我们会观察响应时间的变化曲线,每秒的响应次数,以及有可能会导致并发性降低的参数。我们使用 “SHOW ENGINE INNODB STATUS” 命令打印 InnoDB 性能信息,特别观察了 “SEMAPHORES” 一节的内容,它为我们提供了工作负载的状态信息。 + +当我们在设置参数后对运行结果感到满意,然后就开始将我们最大的数据表格之一迁移到一套独立的集群上,这个步骤作为整个迁移过程的早期测试,以保证我们的核心集群有更多的缓存池空间,并且为故障切换和存储功能提供更强的灵活性。这步初始迁移方案也引入了一个有趣的挑战:我们必须维持多条客户连接,并且要将这些连接指向到正确的集群上。 + +除了硬件性能的提升,还需要补充一点,我们同时也对处理进程和拓扑结构进行了改进:我们添加了延时拷贝技术,更快、更高频地备份数据,以及更多的读拷贝空间。这些功能已经准备上线。 + +### 列出任务清单,三思后行 ### + +每天有上百万用户的使用 GitHub.com,我们不可能有机会等没有人用了才进行实际数据切换。我们有一个详细的[任务清单][2]来执行迁移: + +![](https://cloud.githubusercontent.com/assets/1155781/4116929/13fc6f50-328b-11e4-837b-922aad3055a8.png) + +我们还规划了一个维护期,并且[在我们的博客中通知了大家][3],让用户注意到这件事情。 + +### 迁移时间到 ### + +太平洋时间星期六上午5点,我们的迁移团队上线集合对话,同时数据迁移正式开始: + +![](https://cloud.githubusercontent.com/assets/1155781/4060850/39f52cd4-2df3-11e4-9aca-1f54a4870d24.png) + +我们将 GitHub 网站设置为维护模式,并在 Twitter 上发表声明,然后开始按上述任务清单的步骤开始工作: + +![](https://cloud.githubusercontent.com/assets/1155781/4060864/54ff6bac-2df3-11e4-95da-b059c0ec668f.png) + +**13 分钟**后,我们确保新的集群能正常工作: + +![](https://cloud.githubusercontent.com/assets/1155781/4060870/6a4c0060-2df3-11e4-8dab-654562fe628d.png) + +然后我们让 GitHub.com 脱离维护模式,并且让全世界的用户都知道我们的最新状态: + +![](https://cloud.githubusercontent.com/assets/1155781/4060878/79b9884c-2df3-11e4-98ed-d11818c8915a.png) + +大量前期的测试工作与准备工作,让我们将维护期缩到最短。 + +### 检验最终的成果 ### + +在接下来的几周时间里,我们密切监视着 GitHub.com 的性能和响应时间。我们发现迁移后网站的平均加载时间减少一半,并且在99%的时间里,能减少*三分之二*: + +![](https://cloud.githubusercontent.com/assets/1155781/4060886/9106e54e-2df3-11e4-8fda-a4c64c229ba1.png) + +### 我们学到了什么 ### + +#### 功能划分 #### + +在迁移过程中,我们采用了一个比较好的方法是:将大的数据表(主要记录了一些历史数据)先迁移过去,空出旧集群的磁盘空间和缓存池空间。这一步给我们留下了更多的资源用于“热”数据,将一些连接请求分离到多套集群里面。这步为我们之后的胜利奠定了基础,我们以后还会使用这种模式来进行迁移工作。 + +#### 测试测试测试 #### + +为你的应用做验收测试和回归测试,越多越好,多多益善,不要嫌多。从老集群复制数据到新集群的过程中,如果进行验收测试和响应状态测试,得到的数据是不准的,如果数据不理想,这是正常的,不要惊讶,不要试图拿这些数据去分析原因。 + +#### 合作的力量 #### + +对基础架构进行大的改变,通常需要涉及到很多人,我们要像一个团队一样为共同的目标而合作。我们的团队成员来自全球各地。 + +团队成员地图: + +https://render.githubusercontent.com/view/geojson?url=https://gist.githubusercontent.com/anonymous/5fa29a7ccbd0101630da/raw/map.geojson + +本次合作新创了一种工作流程:我们提交更改(pull request),获取实时反馈,查看修改了错误的 commit —— 全程没有电话交流或面对面的会议。当所有东西都可以通过 URL 提供信息,不同区域的人群之间的交流和反馈会变得非常简单。 + +### 一年后…… ### + +整整一年时间过去了,我们很高兴地宣布这次数据迁移是很成功的 —— MySQL 性能和可靠性一直处于我们期望的状态。另外,新的集群还能让我们进一步去升级,提供更好的可靠性和响应时间。我将继续记录这些优化过程。 + +-------------------------------------------------------------------------------- + +via: https://github.com/blog/1880-making-mysql-better-at-github + +作者:[samlambert][a] +译者:[bazz2](https://github.com/bazz2) +校对:[wxy](https://github.com/wxy) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:https://github.com/samlambert +[1]:https://github.com/blog/1756-optimizing-large-selector-sets +[2]:https://help.github.com/articles/writing-on-github#task-lists +[3]:https://github.com/blog/1603-site-maintenance-august-31st-2013 diff --git a/published/20140915 Linux FAQs with Answers--How to change hostname on CentOS or RHEL 7.md b/published/20140915 Linux FAQs with Answers--How to change hostname on CentOS or RHEL 7.md new file mode 100644 index 0000000000..fd680ad8c6 --- /dev/null +++ b/published/20140915 Linux FAQs with Answers--How to change hostname on CentOS or RHEL 7.md @@ -0,0 +1,42 @@ +Linux有问必答:如何在CentOS或RHEL 7上修改主机名 +================================================================================ +> 问题:在CentOS/RHEL 7上修改主机名的正确方法是什么(永久或临时)? + +在CentOS或RHEL中,有三种定义的主机名:a、静态的(static),b、瞬态的(transient),以及 c、灵活的(pretty)。“静态”主机名也称为内核主机名,是系统在启动时从/etc/hostname自动初始化的主机名。“瞬态”主机名是在系统运行时临时分配的主机名,例如,通过DHCP或mDNS服务器分配。静态主机名和瞬态主机名都遵从作为互联网域名同样的字符限制规则。而另一方面,“灵活”主机名则允许使用自由形式(包括特殊/空白字符)的主机名,以展示给终端用户(如Dan's Computer)。 + +在CentOS/RHEL 7中,有个叫hostnamectl的命令行工具,它允许你查看或修改与主机名相关的配置。 + +要查看主机名相关的设置: + + $ hostnamectl status + +![](https://farm4.staticflickr.com/3844/15113861225_e0e19783a7.jpg) + +只查看静态、瞬态或灵活主机名,分别使用“--static”,“--transient”或“--pretty”选项。 + + $ hostnamectl status [--static|--transient|--pretty] + +要同时修改所有三个主机名:静态、瞬态和灵活主机名: + + $ sudo hostnamectl set-hostname + +![](https://farm4.staticflickr.com/3855/15113489172_4e25ac87fa_z.jpg) + +就像上面展示的那样,在修改静态/瞬态主机名时,任何特殊字符或空白字符会被移除,而提供的参数中的任何大写字母会自动转化为小写。一旦修改了静态主机名,/etc/hostname 将被自动更新。然而,/etc/hosts 不会更新以保存所做的修改,所以你需要手动更新/etc/hosts。 + +如果你只想修改特定的主机名(静态,瞬态或灵活),你可以使用“--static”,“--transient”或“--pretty”选项。 + +例如,要永久修改主机名,你可以修改静态主机名: + + $ sudo hostnamectl --static set-hostname + +注意,你不必重启机器以激活永久主机名修改。上面的命令会立即修改内核主机名。注销并重新登入后在命令行提示来观察新的静态主机名。 + +-------------------------------------------------------------------------------- + +via: http://ask.xmodulo.com/change-hostname-centos-rhel-7.html + +译者:[GOLinux](https://github.com/GOLinux) +校对:[Caroline](https://github.com/carolinewuyan) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 diff --git a/published/20140915 Linux FAQs with Answers--How to remove PPA repository from command line on Ubuntu.md b/published/20140915 Linux FAQs with Answers--How to remove PPA repository from command line on Ubuntu.md new file mode 100644 index 0000000000..e7171b6c3d --- /dev/null +++ b/published/20140915 Linux FAQs with Answers--How to remove PPA repository from command line on Ubuntu.md @@ -0,0 +1,38 @@ +Linux有问必答:Ubuntu如何使用命令行移除PPA仓库 +================================================================================ +> **问题**: 前段时间,我的Ubuntu增加了一个第三方的PPA仓库,如何才能移除这个PPA仓库呢? + +个人软件包档案(PPA)是Ubuntu独有的解决方案,允许独立开发者和贡献者构建、贡献任何定制的软件包来作为通过启动面板的第三方APT仓库。如果你是Ubuntu用户,有可能你已经增加一些流行的第三方PPA仓库到你的Ubuntu系统。如果你需要删除掉已经预先配置好的PPA仓库,下面将教你怎么做。 + +假如你想增加一个叫“ppa:webapps/preview”第三方PPA仓库到你的系统中,如下: + + $ sudo add-apt-repository ppa:webapps/preview + +如果你想要 **单独地删除某个PPA仓库**,运行下面的命令: + + $ sudo add-apt-repository --remove ppa:someppa/ppa + +注意,上述命令不会同时删除任何已经安装或更新的软件包。 + +如果你想要 **完整的删除一个PPA仓库并包括来自这个PPA安装或更新过的软件包**,你需要ppa-purge命令。 + +首先要安装ppa-purge软件包: + + $ sudo apt-get install ppa-purge + +然后使用如下命令删除PPA仓库和与之相关的软件包: + + $ sudo ppa-purge ppa:webapps/preview + +特别滴,在发行版更新后,当你[分辨和清除已损坏的PPA仓库][1]时这个方法特别有用! + +-------------------------------------------------------------------------------- + +via: http://ask.xmodulo.com/how-to-remove-ppa-repository-from-command-line-on-ubuntu.html + +译者:[Vic___](http://www.vicyu.net) +校对:[wxy](https://github.com/wxy) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[1]:http://ask.xmodulo.com/find-remove-obsolete-ppa-repositories-ubuntu.html diff --git a/published/20140925 Linux FAQs with Answers--How to catch and handle a signal in Perl.md b/published/20140925 Linux FAQs with Answers--How to catch and handle a signal in Perl.md new file mode 100644 index 0000000000..80272c60a0 --- /dev/null +++ b/published/20140925 Linux FAQs with Answers--How to catch and handle a signal in Perl.md @@ -0,0 +1,30 @@ +Linux 有问必答:如何在Perl中捕捉并处理信号 +================================================================================ +> **提问**: 我需要通过使用Perl的自定义信号处理程序来处理一个中断信号。在一般情况下,我怎么在Perl程序中捕获并处理各种信号(如INT,TERM)? + +作为POSIX标准的异步通知机制,信号由操作系统发送给进程某个事件来通知它。当产生信号时,操作系统会中断目标程序的执行,并且该信号被发送到该程序的信号处理函数。可以定义和注册自己的信号处理程序或使用默认的信号处理程序。 + +在Perl中,信号可以被捕获,并由一个全局的%SIG哈希变量指定处理函数。这个%SIG哈希变量的键名是信号值,键值是对应的信号处理程序的引用。因此,如果你想为特定的信号定义自己的信号处理程序,你可以直接在%SIG中设置信号的哈希值。 + +下面是一个代码段来处理使用自定义信号处理程序中断(INT)和终止(TERM)的信号。 + + $SIG{INT} = \&signal_handler; + $SIG{TERM} = \&signal_handler; + + sub signal_handler { + print "This is a custom signal handler\n"; + die "Caught a signal $!"; + } + +![](https://farm4.staticflickr.com/3910/15141131060_f7958f20fb.jpg) + +%SIG其他的可用的键值有'IGNORE'和'DEFAULT'。当所指定的键值是'IGNORE'(例如,$SIG{CHLD}='IGNORE')时,相应的信号将被忽略。指定'DEFAULT'的键值(例如,$SIG{HUP}='DEFAULT'),意味着我们将使用一个(系统)默认的信号处理程序。 + +-------------------------------------------------------------------------------- + +via: http://ask.xmodulo.com/catch-handle-interrupt-signal-perl.html + +译者:[geekpi](https://github.com/geekpi) +校对:[wxy](https://github.com/wxy) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 \ No newline at end of file diff --git a/published/20140925 Linux FAQs with Answers--How to detect a Linux distribution in Perl.md b/published/20140925 Linux FAQs with Answers--How to detect a Linux distribution in Perl.md new file mode 100644 index 0000000000..6793ab5565 --- /dev/null +++ b/published/20140925 Linux FAQs with Answers--How to detect a Linux distribution in Perl.md @@ -0,0 +1,53 @@ +Linux有问必答:如何用Perl检测Linux的发行版本 +================================================================================ +> **提问**:我需要写一个Perl程序,它会包含Linux发行版相关的代码。为此,Perl程序需要能够自动检测运行中的Linux的发行版(如Ubuntu、CentOS、Debian、Fedora等等),以及它是什么版本号。如何用Perl检测Linux的发行版本? + +如果要用Perl脚本检测Linux的发行版,你可以使用一个名为[Linux::Distribution][1]的Perl模块。该模块通过检查/etc/lsb-release以及其他在/etc下的发行版特定的目录来猜测底层Linux操作系统。它支持检测所有主要的Linux发行版,包括Fedora、CentOS、Arch Linux、Debian、Ubuntu、SUSE、Red Hat、Gentoo、Slackware、Knoppix和Mandrake。 + +要在Perl中使用这个模块,你首先需要安装它。 + +### 在Debian或者Ubuntu上安装 Linux::Distribution ### + +基于Debian的系统直接用apt-get安装 + + $ sudo apt-get install liblinux-distribution-packages-perl + +### 在Fedora、CentOS 或者RHEL上安装 Linux::Distribution ### + +如果你的Linux没有Linux::Distribution模块的安装包(如基于红帽的系统),你可以使用CPAN来构建。 + +首先确保你的Linux系统安装了CPAN + + $ sudo yum -y install perl-CPAN + +然后,使用这条命令来构建并安装模块: + + $ sudo perl -MCPAN -e 'install Linux::Distribution' + +### 用Perl确定Linux发行版 ### + +Linux::Distribution模块安装完成之后,你可以使用下面的代码片段来确定你运行的Linux发行版本。 + + use Linux::Distribution qw(distribution_name distribution_version); + + my $linux = Linux::Distribution->new; + + if ($linux) { + my $distro = $linux->distribution_name(); + my $version = $linux->distribution_version(); + print "Distro: $distro $version\n"; + } + else { + print "Distro: unknown\n"; + } + +-------------------------------------------------------------------------------- + +via: http://ask.xmodulo.com/detect-linux-distribution-in-perl.html + +译者:[geekpi](https://github.com/geekpi) +校对:[wxy](https://github.com/wxy) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[1]:https://metacpan.org/pod/Linux::Distribution \ No newline at end of file diff --git a/published/20140928 Oracle Linux 5.11 Features Updated Unbreakable Linux Kernel.md b/published/20140928 Oracle Linux 5.11 Features Updated Unbreakable Linux Kernel.md new file mode 100644 index 0000000000..1debab469b --- /dev/null +++ b/published/20140928 Oracle Linux 5.11 Features Updated Unbreakable Linux Kernel.md @@ -0,0 +1,51 @@ +Oracle Linux 5.11更新了其Unbreakable Linux内核 +================================================================================ +> 此版本更新了很多软件包 + +![This is the last release for this branch](http://i1-news.softpedia-static.com/images/news2/Oracle-Linux-5-11-Features-Updated-Unbreakable-Linux-Kernel-460129-2.jpg) + +这是这个分支的最后一个版本更新(随同 RHEL 5.11的落幕,CentOS 和 Oracle Linux 的5.x 系列也纷纷释出该系列的最后版本)。 + +>**甲骨文公司宣布,Oracle Linux5.11版已提供下载,但是这是企业版,需要用户注册才能下载。** + +这个新的Oracle Linux是这个系列的最后一次更新。该系统基于Red Hat和该公司最近推送的RHEL 5X分支更新,这意味着这也是Oracle此产品线的最后一次更新。 + +Oracle Linux还带来了一系列有趣的功能,就像一个名为Ksplice的零宕机内核更新,它最初是针对openSUSE,包括Oracle数据库和Oracle应用软件开发的,它们在基于x86的Oracle系统中使用。 + +### Oracle Linux有哪些特别的 ### + +尽管Oracle Linux基于红帽,它的开发者曾经举出了很多你不应该使用RHEL的原因。理由有很多,但最主要的是,任何人都可以下载Oracle Linux(注册后),而RHEL实际上限制了非付费会员下载。 + +开发者在其网站上说:“为企业应用和系统提供先进的可扩展性和可靠性,Oracle Linux提供了极高的性能,并且在采用x86架构的Oracle工程系统中使用。Oracle Linux是免费使用,免费派发,免费更新,并可轻松下载。它是唯一带来生产中零宕机补丁Oracle Ksplice支持的Linux发行版,允许客户无需重启而部署安全或者其他更新,并且同时提供诊断功能来调试生产系统中的内核问题。” + +Oracle Linux其中一个最有趣且独一无二的功能是其Unbreakable Kernel(坚不可摧的内核)。这是它的开发者实际使用的名称。它基于来自3.0.36分支的旧Linux内核。用户还可以使用红帽兼容内核(内核2.6.18-398.el5),这在发行版中默认提供。 + +此外,Oracle Linux Release 5.11企业版内核提供了对大量硬件和设备的支持,但这个最新的更新带来了更好的支持。 + +您可以查看Oracle Linux 5.11全部[发布通告][1],这可能需要花费一些时间去读。 + +你也可以从下面下载Oracle Linux 5.11: + +- [Oracle Enterprise Linux 6.5 (ISO) 64-bit][2] +- [Oracle Enterprise Linux 6.5 (ISO) 32-bit][3] +- [Oracle Enterprise Linux 7.0 (ISO) 64-bit][4] +- [Oracle Enterprise Linux 5.11 (ISO) 64-bit][5] +- [Oracle Enterprise Linux 5.11 (ISO) 32-bit][6] + +-------------------------------------------------------------------------------- + +via: http://news.softpedia.com/news/Oracle-Linux-5-11-Features-Updated-Unbreakable-Linux-Kernel-460129.shtml + +作者:[Silviu Stahie][a] +译者:[geekpi](https://github.com/geekpi) +校对:[wxy](https://github.com/wxy) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://news.softpedia.com/editors/browse/silviu-stahie +[1]:https://oss.oracle.com/ol5/docs/RELEASE-NOTES-U11-en.html#Kernel_and_Driver_Updates +[2]:http://mirrors.dotsrc.org/oracle-linux/OL6/U5/i386/OracleLinux-R6-U5-Server-i386-dvd.iso +[3]:http://mirrors.dotsrc.org/oracle-linux/OL6/U5/x86_64/OracleLinux-R6-U5-Server-x86_64-dvd.iso +[4]:https://edelivery.oracle.com/linux/ +[5]:http://ftp5.gwdg.de/pub/linux/oracle/EL5/U11/x86_64/Enterprise-R5-U11-Server-x86_64-dvd.iso +[6]:http://ftp5.gwdg.de/pub/linux/oracle/EL5/U11/i386/Enterprise-R5-U11-Server-i386-dvd.iso \ No newline at end of file diff --git a/published/20140930 Check If Your Linux System Is Vulnerable To Shellshock And Fix It.md b/published/20140930 Check If Your Linux System Is Vulnerable To Shellshock And Fix It.md new file mode 100644 index 0000000000..c9ef13ca11 --- /dev/null +++ b/published/20140930 Check If Your Linux System Is Vulnerable To Shellshock And Fix It.md @@ -0,0 +1,65 @@ +检查你的系统系统是否有“Shellshock”漏洞并修复它 +================================================================================ +![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/09/shellshock_Linux_check.jpeg) + +快速地向你展示**如何检查你的系统是否受到Shellshock的影响**,如果有,**怎样修复你的系统免于被Bash漏洞利用**。 + +如果你正跟踪新闻,你可能已经听说过在[Bash][1]中发现了一个漏洞,这被称为**Bash Bug**或者** Shellshock**。 [红帽][2]是第一个发现这个漏洞的机构。Shellshock错误允许攻击者注入自己的代码,从而使系统开放各给种恶意软件和远程攻击。事实上,[黑客已经利用它来启动DDoS攻击][3]。 + +由于Bash在所有的类Unix系统中都有,如果这些都运行bash的特定版本,它会让所有的Linux系统都容易受到这种Shellshock错误的影响。 + +想知道如果你的Linux系统是否已经受到Shellshock影响?有一个简单的方法来检查它,这就是我们要看到的。 + +### 检查Linux系统的Shellshock漏洞 ### + +打开一个终端,在它运行以下命令: + + env x='() { :;}; echo vulnerable' bash -c 'echo hello' + +如果你的系统没有漏洞,你会看到这样的输出: + + bash: warning: x: ignoring function definition attempt + bash: error importing function definition for `x’ + hello + +如果你的系统有Shellshock漏洞,你会看到一个像这样的输出: + + vulnerable + hello + +我尝试在我的Ubuntu14.10上运行,我得到了这个: + +![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/09/Shellshock_Linux_Check.jpeg) + +您还可以通过使用下面的命令查看bash的版本: + + bash --version + +如果bash的版本是3.2.51(1),你就应该更新了。 + +#### 为有Shellshock漏洞的Linux系统打补丁 #### + +如果你运行的是基于Debian的Linux操作系统,如Ubuntu、Linux Mint的等,请使用以下命令升级Bash: + + sudo apt-get update && sudo apt-get install --only-upgrade bash + +对于如Fedora,Red Hat,Cent OS等操作系统,请使用以下命令 + + yum -y update bash + +我希望这个小技巧可以帮助你,看看你是否受到Shellshock漏洞的影响并解决它。有任何问题和建议,欢迎来提。 + +-------------------------------------------------------------------------------- + +via: http://itsfoss.com/linux-shellshock-check-fix/ + +作者:[Abhishek][a] +译者:[geekpi](https://github.com/geekpi) +校对:[wxy](https://github.com/wxy) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://itsfoss.com/author/Abhishek/ +[1]:http://en.wikipedia.org/wiki/Bash_(Unix_shell) +[2]:https://securityblog.redhat.com/2014/09/24/bash-specially-crafted-environment-variables-code-injection-attack/ +[3]:http://www.wired.com/2014/09/hackers-already-using-shellshock-bug-create-botnets-ddos-attacks/ \ No newline at end of file diff --git a/published/201410/20140610 How does the cloud affect the everyday linux user.md b/published/201410/20140610 How does the cloud affect the everyday linux user.md new file mode 100644 index 0000000000..f467fe5b04 --- /dev/null +++ b/published/201410/20140610 How does the cloud affect the everyday linux user.md @@ -0,0 +1,195 @@ +“云”是怎么影响着每一位linux用户的? +================================================================================ +### “云”简介 ### + +不论是报纸、在线资讯、播客、科技博客、科技门户网站,甚至是电台和电视。“云计算”永远都是人们津津乐道的主题。 + +然而,因为“云计算”包含了太多的东西,现在并没有一个明确的定义,所以你认为“云计算”应该是什么呢? + +> **云计算** 过去常常被当做是网络计算的一个模型,网络计算就是把用户程序或者是应用运行在一个联网的服务器或是一个服务器集群,而不是像个人电脑、平板以及智能手机这一类运算设备。比如像传统的client-server (客户机-服务器模型) 和老一代的大型机,^[1] 用户通过连接服务器来执行一项任务。这和“云计算”是不同的,“云计算”是利用虚拟化的技术,把运算进程运行在一个或多个服务器上。利用虚拟技术,越来越多的物理化的服务器被配置和划分成多个独立的“虚拟”服务器,每个服务独立运行,对于用户来说,就像是运行在一个独立的物理服务器上一样。虚拟服务器本质上还是从他们的物理服务器中分离出来的,由于这种灵活的配置方式,使得人们可以按照意愿移动服务器和按比例分配资源而不影响最终的用户体验。计算机资源已成“颗粒”,给用户和管理人员提供方便,包括提供按需自助服务,支持更广泛的跨平台之间的访问,资源共享,快速重新部署,可被监控与量测服务。^[2] + +以上引用摘自维基百科。 + +在过去,我们要么用哑终端连接大型电脑主机,要么近年来使用桌面电脑连接运行在内部服务器上的应用,就像网站连接数据库一样。 + +现在,所有桌面、应用和服务器的管理都已经本地化,都需要来自它们所属公司的技术支持。 + +然而这只对软件公司等少数的公司有利,却对其他的一些商业公司不利,比如说银行、保险公司和石油公司。信息技术公司没有银行的职能,就好像是做餐饮的钻不出地下的石油一样。 + +大公司早已把很多服务外包给专业的公司。例如,让餐饮公司为他们的员工提供食堂,以及我们所熟知的离岸呼叫中心处理银行业务的客户电话。 + +IT 行业的很多服务也逐渐转向外包,许多的技术支持和开发的业务都被打包给中国、印度、马来西亚和东欧。 + +云计算与传统的典型模型有很大不同的一方面在于虚拟化,这种虚拟化的技术把服务运行于虚拟服务器上,服务器可以被放置在同一个地方或者是相隔千山万水,但是,这并不重要,你也不用担心,因为那不是你该担心的事情。 + +> 现在,“云计算”已经成为云计算基础设施的简称。^[4] 这个术语来源于早年一些网络工程师用云状的符号表示那些对他们来说未知的网络。^[5] 后来,营销者普及了这个云的概念,指的是软件、平台和一些可以买卖的基础设施。比如,远程登录互联网。 + +因此,这篇文章讲述了和云相关的所有,对于linux的用户来说,这意味着你想用它做什么和它能为自己做些什么,当然,这有可能也会给我们造成一些误区。 + +从一个终端用户和家庭使用者的角度来看,云计算最基本的就是提供在线服务。 + +所以,让我们来说一说云能到底能给每一位linux用户提供些什么有用的服务? + +### 电子邮件 ### + +当你读到这里的时候,如果你还没有一个电子邮箱,我只能说你OUT了。 + +据PC杂志顾问统计分析,截至2014三月份,电子邮箱的用户最多的前六名分别是Outlook、GMail、Yahoo、icloud、AOL和GMX。 + +### 办公套件 ### + +和电子邮件客户端一样,对于每个人来说,另一个最常用的工具之一就是办公套件。 + +在以前,当人们刚刚进入电脑世界的时候,买一个电脑会带回一个超大型的机器和半打子CD,刻着几个没用的 Microsoft Works ( 微软工作软件 )。 (LCTT译注:Microsoft Works Mirosoft Works是微软的一种家用综合软件,它主要面向低端的家庭用户,提供基本的能提高生活效率的工具,比如提供简单的文档处理、数据库、电子表格的入门级办公包功能。) 微软工作软件是一个廉价,而且无用到几乎要被砍掉的微软office版本。 + +而现在,你甚至不需要在你的电脑上安装任何的办公套件,即便是有LibreOffice和Kingsoft这样好的软件供选择。 + +最好的选择当然是Google Docs和Office 365。对于Office 365能否很好的运行于Linux平台,这篇来自2012期专业电脑的文章似乎说明了这个问题。 + +![](http://www.linuxnews.pro/wp-content/uploads/2014/06/office365_1.png) + +有人说这怎么可能呢,我不相信,所以,我注册并登录了Office 365,想看看到底是什么情况。 + +注册,可以免费试用一个月,并且会赠送包括Word、Excel、和Outlook等一些在线应用。 + +![](http://www.linuxnews.pro/wp-content/uploads/2014/06/office365_2.png) + +一切看起来都挺好,我打开了Microsoft Word,选择了一个模板来使用,当然根本就没有打开成功。 + +Office 365 并没有很好的支持linux设备,况且,说实话,你也不需要这东西。so,咱们继续。 + +![](http://www.linuxnews.pro/wp-content/uploads/2014/06/office365_3.png) + +Google Docs对于一般的办公支持非常完美,它能完成很多的事情,并且有很多的模板针对文字处理,演示工具,电子表格等。即使它始终也代替不了Excel,因为他并没有成百上千的开发人员为其创建宏和编写VBA脚本。 + +![](http://www.linuxnews.pro/wp-content/uploads/2014/06/zoho_1.png) + +另一个可供选择的办公套件是Zoho。 + +和Google Docs一样,Zoho也包含有文字处理工具,演示程序,电子表格程序和电子邮件。 + +此外,还有很多金融和客户管理系统。 + +![](http://www.linuxnews.pro/wp-content/uploads/2014/06/zoho_2.png) + +这个工具的界面看起来真的很简洁,很棒。 + +它和Google Docs和Zoho这些在线服务一样,给予了人们相互协作的便利。 + +很多文档被不同的人分享,然后在不同的地方被不同的人修改完善。 + +这里会给出一些理由来帮助你从Google Docs和Zoho中选择一个适合你的办公套件。 + +### 在线文件存储 ### + +Google Docs和Zoho给我们提供了其他一些很好的服务,就是很好的线上存储能力,你们可以线上存储很多文档和创建很多文件。 + +也有一些其他的服务,比如说Dropbox,仅仅只提供在云存储服务。 + +像Dropbox这样的云存储的好处是如果你的东西被偷了或者是不小心房子着火了,而这时,你仍然有一份离岸备份是安好无缺的。你仍然可以在任何地方获取你的文件。 + +Dropbox对于前2G的容量是免费的,如果你还有更多的东西要存储,每天还有更多的事情要做,每个月只要9.9美刀,你就能拥有100G的存储空间,另外,Dropbox也提供商务版本,每个月15美刀。 + +当然,并不是说Dropbox没有可替代的方案,这个网站也提供了很多很好的一些在线备份的方案。 + +### 相册 ### + +自从有了数码照相机和智能手机,现在越来越多的人们利用存储卡来保存照片。 + +我相信肯定有人因为电话坏了而丢失照片,因为他的照片是存储在电话上的,而不是其他的存储设备,甚至,有些因为丢失了电话而丢失了他们孩子的运动会照片或者是其他一些具有纪念意义的照片资料。 + +丢失电话肯定不是什么好事情,如果你放机灵一点,情况可能要好一点,因为很多人的电话和email,facebook,Twitter的账户是同步的,甚至在线存储也是。 + +当然,丢失手机时,我们可以更改以上那些账户的密码,可是丢失的照片却是再也找不回来了,这让人有一点点伤心。 + +备份资料到电脑当然是一种很好的解决方法,不过要是你的笔记本哪天不小心坏了,你也只能变得一无所有,从头再来。 + +在线照片存储的网站是一个很好的资源,因为他们不止要保证你的照片的安全,你也可以很方便的把照片分享给你选择的人。省去了那些把同样的照片做无数次的拷贝分别发给妈妈,奶奶,妹妹,阿姨和岳母等各种亲戚朋友的麻烦。 + +我常用的一个是谷歌的Picasa相册工具,但是大家也可能听说过像Flickr这样的网络相册。 + +Lifehacker给出了最好的5个网络分享的相册。 + +请记住,他们仅仅是被称作相册分享工具,并不是说你一定要分享,你也可以自己保留他们。 + +### 音乐 ### + +我得到的第一个唱片是20世纪80年代初“Adam and the Ants”的"Kings of the wild frontier"里的一个12英寸的碟子。 + +在20世纪80年代后的很长一段时间里,唱片逐渐被磁带所取代,就好像是我积累了很多的磁带以后,磁带却被CD所取代。 + +后来,成百上千的CD和MP3越来越普遍,直至成为了一种潮流。 + +而音频流媒体始终也跟着潮流一起进步,比如像Spotify。 + +Spotify是一个免费的软件,但是里面包含广告,对于使用的人们而言,它就像是一个你可以定制的私人电台,当然你也可以交月费来去除广告。 + +Grooveshark和last.fm也有提供很多相似的服务。 + +Techradar给出了7种Spotify的替代方案。 + +### 电影 ### + +小飞象 (Dumbo) 是我最早在电影院看的一部电影。而我最早接触录像是“Krull”,它讲述了Dulph Lundgren的年轻时候的经历,录像的格式是Beta Max。(当时我的邻居就有一个) 。 + +有一天,爸爸从收音机租赁处带回来一个录像机,我和我的姐姐就轮流去录像店租带子看。我清楚的记得,我第一次租的带子名字叫“黑洞”(The Black Hole)。 + +直到有声电影的出现,你就不得不拿一个很大的东西来装电影带子,所以有些天才就发明了DVD,甚至是制造出了蓝光碟片。 + +现在,流媒体已经充斥着我们生活的每一天,要是你有个牛X的网络就更完美了。 + +其中,最出名的流媒体提供商是Netflix和Lovefilm (Netflix和Lovefilm都是在线的影片租赁公司)。 + +linuxnews给了我们一些更好的选择来替代Netflix,因为并不是所有的服务都能无缝的在linux上工作,包括Netflix。 + +### 游戏 ### + +继音乐,电影搬到线上以后,游戏也登上了在线的舞台。 + +对游戏来说就要困难一些,因为音乐只占用很少的带宽,而电影的要求相对高一点,但是也仅仅是为了得到一幅清晰的画面。 + +游戏始终需要很高的帧速支持,不然即使你手上有一个很好玩的游戏,可能也不值得去尝试。 + +当前,很多游戏服务商都有提供基于云的游戏,包括OnLive和StreamMyGame也有提供。 + +linuxnews给出了6个和OnLive竞争的游戏服务提供商。 + +### 争议 ### + +云计算也并不是没有争议。 + +首先,最大的问题就是安全问题,如果有人进入了你的在线存储空间和你的电子邮箱,并盗取了你的个人信息。 + +那么在线存储你都会存些什么呢?像Megaupload.com这样的网站,上面都有很多有价值的客户资料。 + +Megaupload.com这个网站本来提供的大容量文件的存储,而问题却是,很多人用它来分享一些有版权的资料,美国的当局就不依不饶的下来检查,所以这个服务被迫关掉了。 + +现在,因为很多人丢失了资料,当局的这样做也是无可厚非的,但是对于那些没有做错事的人来说,他们的数据资料也丢失了,美国当局拒绝还给本人。 + +最后给出了一个服务正在维护的答复,如果你的电子邮件停了一天你能应付,那么3天呢?甚至是一个月你还能应付得了吗,那么你也就只能任由服务提供商摆布了。 + +很多大公司已经取回了丢失的数据,但是仍然有很多心脏病漏洞(openssl的heartbleed安全漏洞)的消息在,这是ssl应用多年中发现的一个重大的安全漏洞。 + +所以说,如果你用了别人提供的在线服务,那么你必须信赖他们技术支持人员,你也必须相信他们不会出现被黑客攻击,硬件故障,缺乏备份和无法恢复系统这样的情况。 + +### 总结 ### + +现在云计算早已成了充斥着在线服务的主题,你的浏览器就是一个客户端,连接世界上任意一个地方的服务器或者是服务器集群。重点是你没必要去关注,而且你也不需要知道。 + +一般来说,我们仅仅触及的是它的表面,所有我们每天接触到的云,对于我们大多数人来说甚至都不用去关注它。 + +至于说云到底是怎样影响着每一位linux用户,事实去证明是有很多的。 + +云到底是好是坏?又或许什么都不是。每一种服务的好坏都要看它的优势。 + +或许云仅仅是营销人员炒起来的一个概念,也只会让技术新闻感到兴奋。是否还有人记得我们一直在用的“Web 2.0”? + +感谢您的阅读。 + +-------------------------------------------------------------------------------- + +via: http://www.linuxnews.pro/how-does-the-cloud-affect-the-everyday-linux-user/ + +译者:[barney-ro](https://github.com/译者ID) 校对:[wxy](https://github.com/wxy) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 \ No newline at end of file diff --git a/published/201410/20140624 Staying free--should GCC allow non-free plug ins.md b/published/201410/20140624 Staying free--should GCC allow non-free plug ins.md new file mode 100644 index 0000000000..717276273d --- /dev/null +++ b/published/201410/20140624 Staying free--should GCC allow non-free plug ins.md @@ -0,0 +1,38 @@ +保持自由 - GCC应该接受收费插件吗? +================================================================================ + +> GCC邮件列表中在争论GCC是否应该接受收费插件,但是认为GCC是一个免费软件开发的媒介的论调占得了上风 + +Gcc以及它在模块化方面的缺失又一次作为一个问题被提出来,并且和市场上的新的编译器LLVM做了对比。GCC巨大而古老:5百万行代码,30年研发时间,并且还在继续增长。相比较而言,LLVM更加年轻,更加模块化,并且允许所有的语言都作为一个模块添加进去。 + +LLVM的核心是‘开放源代码’。GCC是反著作权(copyleft)代表,是严格的免费软件,她不允许以任何形式收费的插件的代码进入到GCC的代码中。争论的一种意见,正如Eric Raymond说的,“FSF不可能既阻止持有所有权的供应者添加他们的插件到一个免费编译器中,又让这个编译器得到发展。就像马儿已经偏离了跑道,反对插件策略的战略目标已经彻底的失败了”。 + +LLVM已经被苹果公司采用作为OS X和苹果硬件上GCC的替代品,并且正在变得流行起来,特别是在BSD系列操作系统的用户中间。LLVM的拥护者推测LLVM将会在更广阔的应用程序和移动设备开发市场上成为GCC的替代者。GCC的反对者们的观点是GCC太过复杂,并且开发者们必须遵守她的‘反著作权(copyleft)’。这限制了那些不想在‘反著作权(copyleft)’许可证下发布他们的语言或者软件产品。作为典型,苹果公司有一个很长的厌恶免费软件的历史。他们也不允许遵守‘反著作权(copyleft)’的软件通过他们的App Store发布。 + +LLVM和GCC之间的争论其实是GNU/Linux和BSD系列、开放源代码和免费软件之间历史差异的翻新版。开放源码的开发者允许代码被以任何形式的使用,免费或者维持版权。免费软件则严格地规定,代码或者针对代码做的更新,必须保持永久免费。免费软件的支持者认为完整的‘反著作权’授权有助于GCC的发展,并且已经将Linux和免费软件带到一个其他方式无法到达的高度,同时保证了免费软件不会被收购或者堕落成商业利益。开放源码的支持者则认为开放源码更加的自由,因为使用这没有受到限制,他们可以随意使用,包括开发非开源的版本。 + +GNU编译器集合(GCC)一直是免费软件发展的关键。编译器是稀有且昂贵的商品,版权软件公司也充斥着对不符合标准的特性的需求。让软件兼容不同的机器和操作系统是一个非必需的复杂任务。GCC作为第一个真正免费的跨平台编译器,简化了这个过程。 + +GCC对于软件开发者和移动设备开发者来说也是一个划时代的产品,而不仅仅对于那些免费软件概念提出者。GCC不但免费和可移植,她跨越不同硬件架构的普遍性和公用性使得更加容易做到软件的兼容性、鲁棒性和一致性。这和John Gilmore,Michael Tiemann和David Henkel-Wallace在开发GCC时发现的一样。这也是Cygnus Solutions公司主要的卖点,Cygnus Solutions是第一家靠卖免费软件赚钱的公司。[译注:Cygnus Solutions是John Gilmore, Michael Tiemann and David Henkel- Wallace创办的公司,同时也是GNU几个主要产品的贡献者] + +LLVM和GCC之间主要的技术差异集中在组成‘前端’,‘中端’,‘后端’的模块分割。‘前端’用来翻译特定的语言。‘中端’对翻译后产生的代码进行优化。‘后端’将优化后的代码转化成特定硬件架构的机器码。LLVM将这些模块分割成不同的实体,但是由于语义的和历史的原因,GCC模糊了这些模块之间的界限。 + +对于一个免费软件项目,添加一种新的语言或者架构到GCC也许是一个非常困难的过程,添加有版权的插件也是不允许的。由于模块间界限非常不明确,最容易的添加方法就是让添加的特性遵循免费软件许可证。最初的开发者也许想保持代码的封闭和版权,但最后不得不将代码以免费软件发布。早期的C++以及Objective C就被认为是其中典型的例子。 + +与此相反,LLVM允许,甚至也许可以说是鼓励添加和发展版权语言和架构,比如英伟达基于Clang和LLVM的对于GPU开发的NVCC。NVCC的源代码是免费软件或者开源软件开发者获取不到的。 + +Richard Stallman[对这方面的演讲中][1]旗帜鲜明地宣布:“在免费软件运动中,我们为自由而战。免费软件的的价值观从根本上就和开源软件不同,后者以写‘更好的代码’为终极目标。如果GCC从免费的编译器变成非免费的编译器,她将不再能够达成自由的目标。 + +“Clang和LLVM的开发者不认可我们的价值观和目标,所以得出了跟我们不一样的结论。他们反对我们采取的捍卫自由的措施,因为他们只看到这对他们造成的不便,却没有看到(或者不关心)他们真正的需求。我猜测他们把他们的工作定义为‘开源’,并且漠视自由。” + +GCC开发者们不可能在许可证的条件上妥协。LLVM在某些行业的部门非常流行,因为它很年轻很新,在编程语言的浪潮中跳跃式发展着。流行的风向着更加开放奔跑,GCC决心跟商业利益死磕也许是这个长期演进路上的一大助力。Unix公司们从80和90年代的Unix战争中学到了一些东西。语言和操作系统都是工具,它们最好是开放和共享的。GCC是免费软件,不属于任何人。 + +-------------------------------------------------------------------------------- + +via: http://www.linuxuser.co.uk/features/staying-free-should-gcc-allow-non-free-plug-ins + +译者:[love\_daisy\_love](https://github.com/CNprober) 校对:[wxy](https://github.com/wxy) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[1]:http://lwn.net/articles/582241 diff --git a/published/20140716 Linux FAQs with Answers--How to define PATH environment variable for sudo commands.md b/published/201410/20140716 Linux FAQs with Answers--How to define PATH environment variable for sudo commands.md similarity index 100% rename from published/20140716 Linux FAQs with Answers--How to define PATH environment variable for sudo commands.md rename to published/201410/20140716 Linux FAQs with Answers--How to define PATH environment variable for sudo commands.md diff --git a/published/201410/20140718 Need Microsoft Office on Ubuntu--Install the Official Webapps.md b/published/201410/20140718 Need Microsoft Office on Ubuntu--Install the Official Webapps.md new file mode 100644 index 0000000000..e5439c5edf --- /dev/null +++ b/published/201410/20140718 Need Microsoft Office on Ubuntu--Install the Official Webapps.md @@ -0,0 +1,58 @@ +在Ubuntu上要用微软OFFICE?去安装官方的Web应用吧 +================================================== +![](http://www.omgubuntu.co.uk/wp-content/uploads/2014/07/office-web-app-.jpg) + +**不论你喜欢与否,微软 Office 及其文件格式是大多数工作和学习环境所必须的,无论是好用还是不好用** + +通过使用[LibreOffice的应用程序套件][1],在Ubuntu上阅读、编辑和保存这些专有文件格式出现是基本可行的。 Writer、Calc和Impress都不同程度的和微软 Office 可以互通,虽然以我的实际经验来看(幸好很短暂),不是很完美。 + +有时候你会不得不使用微软Office(虽然我们大多数人都心里向着开放标准,但是我们不应该无视实际问题),但你如果不太想去购买一个完整的微软OFFICE许可证,并通过 WINE来运行它,那么微软的在线网络应用程序就是完美的解决方法。 + +###在Ubuntu安装微软在线办公软件上的应用程序### + +为了更容易地从Ubuntu的桌面访问这些在线版本,“Linux的Web应用项目”创造了一个小的、非官方的安装程序。它可以添加Web应用程序的快捷方式(“漂亮的书签”)到您的应用程序启动器。 + +![](http://www.omgubuntu.co.uk/wp-content/uploads/2014/07/microsoft-office-web-apps.jpg) + +通过快捷方式,可以在你的默认的浏览器中打开相应的Microsoft Web应用,不可能有比这更简单的了。听起来不错吧?你可以找到这些Web 应用的快捷方式: + +- Word +- Excel +- PowerPoint +- Outlook +- OneDrive +- Calendar +- OneNote +- People + +该软件包还创建了一个新的应用程序类别来容纳这些链接,不但可以让您把这些快捷方式从其他应用程序单独分开来,而且是直接位于常见的“办公软件”应用程序下。 + +这些都是必不可少的吗?不见得。他们有用吗?这取决于你的工作需要。但它是不错的选择吗?一定是的。 + +你可以从下面的链接下载.deb文件安装程序。适用于Ubuntu14.04 LTS和更高版本。 + +- [下载微软的在线办公应用(.deb)][2] + +###其他可选项### + +![](http://d0od.wpengine.netdna-cdn.com/wp-content/uploads/2014/04/Screen-Shot-2014-04-15-at-15.29.35-350x200.png) + +类似的替代方案是[安装Chrome官方网上应用商店的在线办公应用程序][3],然后添加应用程序启动器到Linux。这也会在 Dash 中为它们创建启动快捷方式,不过那些可以被设置为打开自己的窗口框架中,而且不需要安装任何第三方软件包。 + +同时,谷歌最近在整合完整的Office功能(由于其购买了QuickOffice)[到自己的文档,幻灯片和表单应用][4]。Android应用程序Quickoffice退出了舞台,而以Chrome扩展的方式再次出现。 + +如果你是一个深度的谷歌网络硬盘/文档的用户,那么这个解决方案可能对你来说更好。 + +-------------------------------------------------- ------------------------------ + +via: http://www.omgubuntu.co.uk/2014/07/run-microsoft-office-web-apps-ubuntu-desktop + +译者:[cereuz](https://github.com/cereuz) +校对:[wxy](https://github.com/wxy) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[1]:http://www.libreoffice.org/ +[2]:https://docs.google.com/file/d/0ByQnaVw7riBQMjNCUFh4ZlM4Y0E/edit?usp=sharing +[3]:http://www.omgchrome.com/microsoft-brings-office-online-chrome-web-store/ +[4]:http://www.omgchrome.com/quickoffice-chrome-extension-gets-name-change/ diff --git a/published/20140722 How to manage DigitalOcean VPS droplets from the command line on Linux.md b/published/201410/20140722 How to manage DigitalOcean VPS droplets from the command line on Linux.md similarity index 100% rename from published/20140722 How to manage DigitalOcean VPS droplets from the command line on Linux.md rename to published/201410/20140722 How to manage DigitalOcean VPS droplets from the command line on Linux.md diff --git a/published/20140723 How to access SoundCloud from the command line in Linux.md b/published/201410/20140723 How to access SoundCloud from the command line in Linux.md similarity index 100% rename from published/20140723 How to access SoundCloud from the command line in Linux.md rename to published/201410/20140723 How to access SoundCloud from the command line in Linux.md diff --git a/published/20140723 Top 10 Fun On The Command Line.md b/published/201410/20140723 Top 10 Fun On The Command Line.md similarity index 100% rename from published/20140723 Top 10 Fun On The Command Line.md rename to published/201410/20140723 Top 10 Fun On The Command Line.md diff --git a/translated/talk/20140724 diff -u--What is New in Kernel Development.md b/published/201410/20140724 diff -u--What is New in Kernel Development.md similarity index 52% rename from translated/talk/20140724 diff -u--What is New in Kernel Development.md rename to published/201410/20140724 diff -u--What is New in Kernel Development.md index f97f22695e..39d60bae93 100644 --- a/translated/talk/20140724 diff -u--What is New in Kernel Development.md +++ b/published/201410/20140724 diff -u--What is New in Kernel Development.md @@ -1,22 +1,22 @@ diff -u: 内核开发里的新鲜事儿 ================================================================================ -偶尔总会有人指出Linux中的POSIX违规(注:violation此处暂译为违规,若不妥,请修正),通常的回答是修复违规问题,但有时李纳斯·托瓦兹认为POSIX特性是不完整的,至少他们维护Linux特性的情形下是这样的。因此,他们或许应该构建一层POSIX兼容层,即便这个分层会相对较慢和低效。 +偶尔总会有人指出Linux中的POSIX违规(violation),通常的回答是“修复违规问题”,但有时李纳斯·托瓦兹认为POSIX特性是不完整的,至少他们维护Linux特性的情形下是这样的。因此,他们或许应该构建一层POSIX兼容层,即便这个分层会相对较慢和低效。 -这一次,*迈克尔·凯利斯克*报告了一个影响文件操作的POSIX违规。显然,在多线程操作期间读写文件会导致竞争出现,重写其它操作的改变。 +这一次,*迈克尔·凯利斯克(Michael Kerrisk)*报告了一个影响文件操作的POSIX违规。显然,在多线程操作期间读写文件会导致竞争出现,重写其它操作的改变。 -关于这是否是POSIX的一个违规存在一些讨论,但到最后又有谁关心呢?数据重写是很糟糕的。在迈克尔提交部分代码去重现这个问题后,讨论的问题集中到该做什么去修复它。但迈克尔确实提出了“Linux从早期开始就与UNIX不一致。(如在1992年版的史蒂夫的APUE的191页讨论到fork()操作后在父进程与子进程之间文件偏移量的共享问题。尽管史蒂夫没有显式地讲清楚一致性的保证,但缺乏这个保证的推论这里的讨论可能有些没意义。)”的观点。 +关于这是否是POSIX的一个违规存在一些讨论,但到最后又有谁关心呢?数据重写(clobbering)是很糟糕的事情。在迈克尔提交部分代码去重现这个问题后,讨论的问题集中到该做什么去修复它。但迈克尔的观点是:“Linux从早期开始就与UNIX不一致。(如在1992年版的史蒂夫的APUE的191页讨论到fork()操作后在父进程与子进程之间文件偏移量的共享问题。尽管史蒂夫没有显式地讲清楚一致性的保证,但缺乏这个保证的推论这里的讨论可能有些没意义。)” -艾尔·维洛和李纳斯一起设法解决这个修复。李纳斯尝试引入一个简单的互斥量去锁住文件,以便写操作无法互相重写。艾尔提出了自己的改进以改善李纳斯的补丁。 +艾尔·维洛(Al Viro)和李纳斯一起设法解决这个修复。李纳斯尝试引入一个简单的互斥量去锁住文件,以便写操作无法互相重写。艾尔提出了自己的改进以改善李纳斯的补丁。 李纳斯一度解释过这个故障自身的历史。显然,从前这个用来告诉系统去哪里写文件的文件指针已经被锁在一个信号量中,所以只有一个进程可以在某一时刻对这个文件做任何操作。但是,他们从中拿走了这个信号量,以便在任何时候可以适应设备文件和其它非常规文件,因为当用户被禁止写入其中时它们就会陷入竞争状态。 -这就是错误的由来。那时候,它悄悄通过了检查,未被发现。因为实际上对常规文件的读写仍然由内核自动处理。只有文件指针自身可以避免同步。而且,因为高速线程化的文件操作是一个非常罕见的需求,所以对任何人来说都需要很长时间才能遇到这个问题并报告它。 +这就是错误的由来。那个时候,它悄悄地通过了检查,未被发现。因为实际上对常规文件的读写仍然由内核自动处理。只有文件指针自身可以避免同步。而且,因为高速线程化的文件操作是一个非常罕见的需求,所以对任何人来说都需要很长时间才能遇到这个问题并报告它。 -一个有趣的小细节是当李纳斯和艾尔在寻找一个修复方案时,艾尔一度抱怨李纳斯采用的方法并不能支持确定的架构,包括*ARM*和*PowerPC*。李纳斯的回应是“我怀疑关心这个是否有意义。[...]如果使用ARM/PPC架构的人停止抱怨,他们可以往gcc中加入struct-return的支持。” +一个有趣的小细节是当李纳斯和艾尔在寻找一个修复方案时,艾尔一度抱怨李纳斯采用的方法并不能支持一些确定的架构,包括*ARM*和*PowerPC*。李纳斯的回应是“我怀疑关心这个是否有意义。[...]如果使用ARM/PPC架构的人停止抱怨,他们可以往gcc中加入struct-return的支持。” 看到这些问题突然产生并得到处理通常是很有趣的。在某些情况下,这个修复的部分工作必须在内核中进行,部分在GCC中,部分在其它地方。在这个特例里,艾尔认为整个事情都应该在内核里处理,他在灵感的激发下往补丁中写入了自己的版本,李纳斯也接受了。 -*安迪·克伦*则想为*perf*增加底层CPU事件支持。问题在于这可能会导致大量的底层事件,而且会因CPU的变化而改变。即使为了所有类型的CPU把可能的时间都存储在内存里,也可能会显著地增加内核的运行大小。因此,把这个信息硬编码进内核的方法是有问题的。 +*安迪·克伦(Andi Kleen)*则想为*perf*增加底层CPU事件支持。问题在于这可能会导致大量的底层事件,而且会因CPU的变化而改变。即使为了所有类型的CPU把可能的时间都存储在内存里,也可能会显著地增加内核的运行大小。因此,把这个信息硬编码进内核的方法是有问题的。 他也指出*OProfile*工具依赖于这些时间的公开可用列表,尽管他表示OProfile开发者并非总维持他们的列表与最新的可用版本一致。 @@ -24,20 +24,21 @@ diff -u: 内核开发里的新鲜事儿 有各种各样对安迪代码的反馈,其中大部分涉及到应该在哪个目录下保存事件列表和文件如何命名。这份代码本身的特性似乎得到了很好的回应。一处细节证明了安迪的代码比其他人的更有争议,就是将列表下载到用户家目录下的一个子目录。安迪表示如果不这样做的话,用户可能会以系统管理员的身份去下载事件列表,这会是危害安全的操作。 -萨沙·莱文最近发布了一个脚本来从堆栈转储中把*十六进制的偏移量*翻译成有意义的指向内核源码文件的行号。因此诸如“ffffffff811f0ec8”形式的十六进制表示可以被翻译成“fs/proc/generic.c:445”。 +萨沙·莱文(Sasha Levin)最近发布了一个脚本来从堆栈转储中把*十六进制的偏移量*翻译成有意义的指向内核源码文件的行号。因此诸如“ffffffff811f0ec8”形式的十六进制表示可以被翻译成“fs/proc/generic.c:445”。 -然而,结果表明李纳斯·托瓦兹正打算从堆栈转储中移除十六进制偏移量,具体原因是他们难以理解。所以萨沙的代码看起来过时了。【译者注:程序媛,伤不起!】 +然而,结果表明李纳斯·托瓦兹正打算从堆栈转储中移除十六进制偏移量,具体原因是他们难以理解。所以萨沙的代码看起来过时了。[译者注:程序媛,伤不起!:< ] 他们在这个问题上纠结了一番。起初,萨沙打算依赖存储在System.map文件里的数据区补偿,但李纳斯指出包括他在内的有些人并不会保留System.map文件。李纳斯推荐使用/usr/bin/nm从编译好的内核文件中提取符号表。 所以,似乎萨沙的脚本可能确实为调试堆栈转储提供了有意义的文件和行号,假设堆栈转储提供足够的信息去完成计算。 + -------------------------------------------------------------------------------- via: http://www.linuxjournal.com/content/diff-u-whats-new-kernel-development-0 原文作者:[Zack Brown][a] -译者:[KayGuoWhu](https://github.com/KayGuoWhu) 校对:[校对者ID](https://github.com/校对者ID) +译者:[KayGuoWhu](https://github.com/KayGuoWhu) 校对:[wxy](https://github.com/wxy) 本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 diff --git a/published/201410/20140729 10 Useful 'Squid Proxy Server' Interview Questions and Answers in Linux.md b/published/201410/20140729 10 Useful 'Squid Proxy Server' Interview Questions and Answers in Linux.md new file mode 100644 index 0000000000..13e2c05b05 --- /dev/null +++ b/published/201410/20140729 10 Useful 'Squid Proxy Server' Interview Questions and Answers in Linux.md @@ -0,0 +1,132 @@ +10个关于linux中Squid代理服务器的实用面试问答 +================================================================================ +不仅是系统管理员和网络管理员时不时会听到“代理服务器”这个词,我们也经常听到。代理服务器已经成为一种企业常态,而且经常会接触到它。它现在也出现在一些小型的学校或者大型跨国公司的自助餐厅里。Squid(常被视作代理服务的代名词)就是这样一个应用程序,它不但可以被作为代理服务器,其同时也是在该类工具中比较被广泛使用的一种。 + +本文旨在提高你在遇到关于代理服务器面试点时的一些基本应对能力。 + +![Squid Interview Questions](http://www.tecmint.com/wp-content/uploads/2014/07/Squid-Interview-Questions.png) + +以下为面试问答的内容 + +### 1. 什么是代理服务器?代理服务器在计算机网络中有什么用途? ### + +> **回答** : 代理服务器是指那些作为客户端和资源提供商或服务器之间的中间件的物理机或者应用程序。客户端从代理服务器中寻找文件、页面或者是数据,而且代理服务器能处理客户端与服务器之间所有复杂事务,从而满足客户端的生成的需求。 + +代理服务器是WWW(万维网)的支柱,它们其中大部分都是Web代理。一台代理服务器能处理客户端与服务器之间的复杂通信事务。此外,它在网络上提供的是匿名信息(LCTT 译注:指浏览者的 IP、浏览器信息等被隐藏),这就意味着你的身份和浏览痕迹都是安全的。代理可以去配置允许哪些网站的客户能看到,哪些网站被屏蔽了。 + +### 2. Squid是什么? ### + +> **回答** : Squid是一个在GNU/GPL协议下发布的既可作为代理服务器,同时也可作为Web缓存守护进程的应用软件。Squid主要是支持像HTTP和FTP那样的协议,但是对其它的协议比如HTTPS,SSL,TLS等同样也能支持。其特点是Web缓存守护进程通过从经常上访问的网站里缓存Web和DNS数据,从而让上网速度更快。Squid支持所有的主流平台,包括Linux,UNIX,微软公司的Windows和苹果公司的Mac。 + +### 3. Squid的默认端口是什么?怎么去修改它的操作端口? ### + +> **回答** : Squid运行时的默认端口是3128。我们可以通过编辑它的配置文件来把它的默认端口修改成未被用户使用的端口,路径是 /etc/squid/squid.conf ,建议如下。 + +用你的编辑器打开 ‘/etc/squid/squid.conf’ 文件。 + + # nano /etc/squid/squid.conf + +现在把它修改成未被使用的其它端口,并保存退出。 + + http_port 3128 + +重新启动Squid代理服务,如下显示。 + + # service squid restart + +### 4. 你的公司管理层要求你通过Squid代理服务器屏蔽掉一些域名,你怎么做? ### + +> **回答** : 屏蔽域名是一个在配置文件中实现的功能模块。我们只需要执行一个小的手动配置即可,建议如下。 + +a. 在 ‘/etc/squid’ 目录下创建一个名为 ‘blacklist’ 的文件。 + + # touch /etc/squid/blacklist + +b. 用nano编辑器打开这个文件。 + + # nano /etc/squid/blacklist + +c. 以每行一个域名的方式将想要屏蔽的域名写进这个文件里。 + + .facebook.com + .twitter.com + .gmail.com + .yahoo.com + ... + +d. 保存退出,然后从 ‘/etc/squid/squid.conf’ 打开Squid配置文件。 + + # nano /etc/squid/squid.conf + +e. 在配置文件中添加如下行。 + + acl BLACKLIST dstdom_regex -i “/etc/squid/blacklist” + http_access deny blacklist + +f. 保存配置文件并退出,重启Squid服务让其生效。 + + # service squid restart + +### 5. 在Squid中什么是媒体范围限制(Media Range Limitation)和部分下载? ### + +> **回答** : 媒体范围限制是Squid的一种特殊的功能,它只从服务器中获取所需要的数据而不是整个文件。这个功能很好的实现了用户在各种视频流媒体网站如YouTube和Metacafe看视频时,可以点击视频中的进度条来选择进度,因此整个视频不用全部都加载,除了一些需要的部分。 + +Squid部分下载功能的特点是很好地实现了类似在Windows更新时能以一个个小数据包的形式下载,并可以暂停,正因为它的这个特点,正在下载文件的Windows机器可以重新继续下载,而不用担心数据会丢失。Squid的媒体范围限制和部分下载功能只有在存储了一个完整文件的副本之后才行。此外,当用户访问另一个页面时,除非Squid进行了特定的配置,部分下载下来的文件会被删除且不留在缓存中。 + +### 6. 什么是Squid的反向代理? ### + +> **回答** : 反向代理是Squid的一个功能,这个功能被用来加快最终用户的上网速度。下面用缩写 ‘RS’ 的表示包含了资源的原服务器,而代理服务器则称作 ‘PS’ 。初次访问时,它会从RS得到其提供的数据,并将其副本按照配置好的时间存储在PS上。这样的话每次从PS上请求的数据就相当于就是从原服务器上获取的。这样就会减轻网络拥堵,减少CPU使用率,降低网络资源的利用率,从而缓解原来实际服务器的负载压力。但是RS统计不了总流量的数据,因为PS分担了部分原服务器的任务。‘X-Forwarded-For HTTP’ 信息能用于记录下通过HTTP代理或负载均衡方式连接到RS的客户端最原始的IP地址。 + +从技术上说,用单个Squid服务器同时作为正向代理服务器和反向代理服务器是可行的。 + +### 7. 由于Squid能作为一个Web缓存守护进程,那缓存可以删除吗?怎么删除? ### + +> **回答** : 当然!作为一个Web缓存守护进程,Squid能加快网页的访问速度,清除缓存也是非常简单的。 + +a. 首先停止Squid代理服务,然后从这个 ‘/var/lib/squid/cache’ 目录中删除缓存。 + + # service squid stop + # rm -rf /var/lib/squid/cache/*< + +b. 创建交换分区目录。 + + # squid -z + +### 8. 你有一台工作中的机器可以访问代理服务器,如果想要限制你的孩子的访问时间,你会怎么去设置那个场景? ### + +把允许访问的时间设置成晚上4点到7点三个小时,跨度为星期一到星期五。 + +a. 想要限制Web访问时间在星期一到星期五的晚上4点到7点,要先打开Squid的配置文件。 + + # nano /etc/squid/squid.conf + +b. 在配置文件中添加如下行,保存文件并退出。 + + acl ALLOW_TIME time M T W H F 16:00-19:00 + shttp_access allow ALLOW_TIME + +c. 重启Squid服务。 + + # service squid restart + +### 9. Squid存储的数据是什么文件格式? ### + +> **回答** : Squid存储的数据是UFS文件格式的。UFS是一种老的,使用比较广泛的Squid存储格式 + +### 10. Squid的缓存会存储到哪里? ### + +> **回答** : Squid存储的缓存是位于 ‘/var/spool/squid’ 的特定目录下。 + +以上就是全部内容了,很快我还会带着其它有趣的内容回到这里。 + +-------------------------------------------------------------------------------- + +via: http://www.tecmint.com/squid-interview-questions/ + +作者:[Avishek Kumar][a] +译者:[ZTinoZ](https://github.com/ZTinoZ) +校对:[wxy](https://github.com/wxy) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://www.tecmint.com/author/avishek/ diff --git a/translated/tech/20140729 How to access Linux command cheat sheets from the command line.md b/published/201410/20140729 How to access Linux command cheat sheets from the command line.md similarity index 71% rename from translated/tech/20140729 How to access Linux command cheat sheets from the command line.md rename to published/201410/20140729 How to access Linux command cheat sheets from the command line.md index b1914563fa..cbd40b56c3 100644 --- a/translated/tech/20140729 How to access Linux command cheat sheets from the command line.md +++ b/published/201410/20140729 How to access Linux command cheat sheets from the command line.md @@ -1,12 +1,12 @@ 从命令行访问Linux命令小抄 ================================================================================ -Linux命令行的强大在于其灵活及多样化,各个Linux命令都带有它自己那部分命令行选项和参数。混合并匹配它们,甚至还可以通过管道和重定向来联结不同的命令。理论上讲,你可以借助几个基本的命令来产生数以百计的使用案例。甚至对于浸淫多年的管理员而言,也难以完全使用它们。那正是命令行小抄成为我们救命稻草的一刻。 +Linux命令行的强大在于其灵活及多样化,各个Linux命令都带有它自己专属的命令行选项和参数。混合并匹配这些命令,甚至还可以通过管道和重定向来联结不同的命令。理论上讲,你可以借助几个基本的命令来产生数以百计的使用案例。甚至对于浸淫多年的管理员而言,也难以完全使用它们。那正是命令行小抄成为我们救命稻草的一刻。 [![](https://farm6.staticflickr.com/5562/14752051134_5a7c3d2aa4_z.jpg)][1] -我知道联机手册页仍然是我们的良师益友,但我们想通过我们能自行支配的快速参考卡让这一切更为高效和有目的性。最终极的小抄可能被自豪地挂在你的办公室里,也可能作为PDF文件隐秘地存储在你的硬盘上,或者甚至设置成了你的桌面背景图。 +我知道联机手册页(man)仍然是我们的良师益友,但我们想通过我们能自行支配的快速参考卡让这一切更为高效和有目的性。最终极的小抄可能被自豪地挂在你的办公室里,也可能作为PDF文件隐秘地存储在你的硬盘上,或者甚至设置成了你的桌面背景图。 -最为一个选择,也可以通过另外一个命令来访问你最爱的命令行小抄。那就是,使用[cheat][2]。这是一个命令行工具,它可以让你从命令行读取、创建或更新小抄。这个想法很简单,不过cheat经证明是十分有用的。本教程主要介绍Linux下cheat命令的使用方法。你不需要为cheat命令做个小抄了,它真的很简单。 +做为一个选择,也可以通过另外一个命令来访问你最爱的命令行小抄。那就是,使用[cheat][2]。这是一个命令行工具,它可以让你从命令行读取、创建或更新小抄。这个想法很简单,不过cheat经证明是十分有用的。本教程主要介绍Linux下cheat命令的使用方法。你不需要为cheat命令做个小抄了,它真的很简单。 ### 安装Cheat到Linux ### @@ -59,9 +59,9 @@ cheat命令一个很酷的事是,它自带有超过90个的常用Linux命令 $ cheat -s -在许多情况下,小抄适用于那些正派的人,而对其他某些人却没什么帮助。要想让内建的小抄更具个性化,cheat命令也允许你创建新的小抄,或者更新现存的那些。要这么做的话,cheat命令也会帮你在本地~/.cheat目录中保存一份小抄的副本。 +在许多情况下,小抄适用于某些人,而对另外一些人却没什么帮助。要想让内建的小抄更具个性化,cheat命令也允许你创建新的小抄,或者更新现存的那些。要这么做的话,cheat命令也会帮你在本地~/.cheat目录中保存一份小抄的副本。 -要使用cheat的编辑功能,首先确保EDITOR环境变量设置为了你默认编辑器所在位置的完整路径。然后,复制(不可编辑)内建小抄到~/.cheat目录。你可以通过下面的命令找到内建小抄所在的位置。一旦你找到了它们的位置,只不过是将它们拷贝到~/.cheat目录。 +要使用cheat的编辑功能,首先确保EDITOR环境变量设置为你默认编辑器所在位置的完整路径。然后,复制(不可编辑)内建小抄到~/.cheat目录。你可以通过下面的命令找到内建小抄所在的位置。一旦你找到了它们的位置,只不过是将它们拷贝到~/.cheat目录。 $ cheat -d @@ -85,7 +85,7 @@ via: http://xmodulo.com/2014/07/access-linux-command-cheat-sheets-command-line.h 作者:[Dan Nanni][a] 译者:[GOLinux](https://github.com/GOLinux) -校对:[校对者ID](https://github.com/校对者ID) +校对:[wxy](https://github.com/wxy) 本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 diff --git a/translated/tech/20140730 How to use variables in shell Scripting.md b/published/201410/20140730 How to use variables in shell Scripting.md similarity index 81% rename from translated/tech/20140730 How to use variables in shell Scripting.md rename to published/201410/20140730 How to use variables in shell Scripting.md index 98768a499f..0e09b5cd5e 100644 --- a/translated/tech/20140730 How to use variables in shell Scripting.md +++ b/published/201410/20140730 How to use variables in shell Scripting.md @@ -13,56 +13,56 @@ shell脚本中的变量是用来**调用**一个**数值**或者**字符值**的 - - + + - + - + - + - + - + - + - + - + - + - + - + - +
System Defined Variables Meaning 系统定义的变量 意义
BASH=/bin/bash Shell Name Bash Shell 名称
BASH_VERSION=4.1.2(1) Bash Version Bash 版本
COLUMNS=80 No. of columns for our screen 你的屏幕宽度(列数)
HOME=/home/linuxtechi Home Directory of the User 用户家目录
LINES=25 No. of columns for our screen 你的屏幕高度(行数)
LOGNAME=LinuxTechi LinuxTechi Our logging name 当前登录用户的名字
OSTYPE=Linux OS type 操作系统类型
PATH=/usr/bin:/sbin:/bin:/usr/sbin Path Settings 可执行文件搜索路径
PS1=[\u@\h \W]\$ Prompt Settings 命令行提示符
PWD=/home/linuxtechi Current Working Directory 当前工作目录
SHELL=/bin/bash Shell Name Shell 名称
USERNAME=linuxtechi User name who is currently login to system 当前登录的用户名
@@ -87,7 +87,7 @@ shell脚本中的变量是用来**调用**一个**数值**或者**字符值**的 $ echo “The cost of the item is $15” The cost of the item is 5 -很明显,那不是我们说希望的。无论何时,当脚本遇见引号中的美元符号时,它都会认为你是在调用一个变量。在本例中,改脚本试着显示**变量$1**(而这个变量并没有定义),然后显示数字5。要显示实际上的美元符号,你**必须前置**一个**反斜线字符**: +很明显,那不是我们说希望的。无论何时,当脚本遇见引号中的美元符号时,它都会认为你是在调用一个变量。在本例中,该脚本试着显示**变量$1**(而这个变量并没有定义),然后显示数字5。要显示实际上的美元符号,你**必须前置**一个**反斜线字符**: $ echo “The cost of the item is \$15” The cost of the item is $15 @@ -98,7 +98,7 @@ shell脚本中的变量是用来**调用**一个**数值**或者**字符值**的 这些变量由**用户**定义。shell脚本允许我们在脚本中设置并使用我们**自己的变量**。设置变量允许你**临时存储数据**并在脚本中使用,让shell脚本看起来像一个真正的计算机程序。 -**用户变量**可以是任何不超过**20个字母,数字**的文本字符串,或者**一个下划线字符**。用户变量是大小写敏感的,因此,变量Var1和变量var1是不同的变量。这个小规则常常让新手编写脚本时麻烦重重。 +**用户变量**可以是任何不超过**20个的字母、数字**或者**下划线字符**的文本字符串(LCTT 译注:变量只能以字母或下划线开头)。用户变量是大小写敏感的,因此,变量Var1和变量var1是不同的变量。这个小规则常常让新手编写脚本时麻烦重重。 我们可以通过**等于号**为变量赋值。变量,等于号和值(对于新手又是个麻烦的地方)之间不能有空格。下面是几个给用户变量赋值的例子: @@ -130,7 +130,7 @@ shell脚本为变量值**自动确定数据类型**。shell脚本内定义的变 Jessica checked in 5 days ago $ -每次变量被**调用**,它都会产生当前分配给它的值。记住这一点很重要,当调用一个变量值时,你使用**美元符号**,但是当调用一个变量来为其分配一个值时,你不能用美元符号。下面用例子来说明: +每次变量被**调用**,它都会变成了当前分配给它的值。有一点很重要,当调用一个变量值时,你使用**美元符号**,但是当为一个变量分配一个值时,你不能用美元符号。下面用例子来说明: $ cat test4 #!/bin/bash @@ -180,7 +180,7 @@ shell会在**反引号**中运行命令,然后将输出结果赋值给变量te $ ./test5 The date and time are: Mon Jan 31 20:23:25 EDT 2011 -**注**:在bash中,你也可以选用$(...)语法来替换反引号(`),它有个优点就是可以重用。 +**注**:在bash中,你也可以选用$(...)语法来替换反引号(`),它有个优点就是可以重用(re-entrant)。 例: @@ -192,8 +192,8 @@ shell会在**反引号**中运行命令,然后将输出结果赋值给变量te via: http://www.linuxtechi.com/variables-in-shell-scripting/ 作者:[Pradeep Kumar][a] -译者:[GOLinux](https://github.com/GOLinux) -校对:[校对者ID](https://github.com/校对者ID) +译者:[ ](https://github.com/GOLinux) +校对:[wxy](https://github.com/wxy) 本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 diff --git a/translated/tech/20140731 Easy Steps to Make GNOME 3 More Efficient.md b/published/201410/20140731 Easy Steps to Make GNOME 3 More Efficient.md similarity index 66% rename from translated/tech/20140731 Easy Steps to Make GNOME 3 More Efficient.md rename to published/201410/20140731 Easy Steps to Make GNOME 3 More Efficient.md index 629e04cdfa..edffe7c30c 100644 --- a/translated/tech/20140731 Easy Steps to Make GNOME 3 More Efficient.md +++ b/published/201410/20140731 Easy Steps to Make GNOME 3 More Efficient.md @@ -8,12 +8,13 @@ ### 添加窗口按钮 ### -处于一些未知的原因,GNOME的开发者们决定对标准的窗口按钮(关闭,最小化,最大化)不屑一顾,而支持只有单个关闭按钮的窗口了。我缺少了最大化按钮(虽然你可以简单地拖动窗口到屏幕顶部来将它最大化),然而也可以通过在标题栏右击选择最小化或者最大化来进行最小化/最大化操作。这种变化仅仅增加了操作步骤,因此缺少最小化按钮实在搞得人云里雾里。所幸的是,有个简单的修复工具可以解决这个问题,下面说说怎样做吧: +出于一些未知的原因,GNOME的开发者们决定对标准的窗口按钮(关闭,最小化,最大化)不屑一顾,而支持只有单个关闭按钮的窗口了。我缺少了最大化按钮(虽然你可以简单地拖动窗口到屏幕顶部来将它最大化),而且也可以通过在标题栏右击选择最小化或者最大化来进行最小化/最大化操作。这种变化仅仅增加了操作步骤,因此缺少最小化按钮实在搞得人云里雾里。所幸的是,有个简单的修复工具可以解决这个问题,下面说说怎样做吧: -默认情况下,你应该安装了GNOME优化工具。通过该工具,你可以打开最大化或最小化按钮(图1)。 +默认情况下,你应该安装了GNOME优化工具(GNOME Tweak Tool)。通过该工具,你可以打开最大化或最小化按钮(图1)。 -![Figure 1: Adding the minimize button back to the GNOME 3 windows.](http://www.linux.com/images/stories/41373/gnome3-max-min-window.png) -Figure 1: 添加回最小化按钮到GNOME 3窗口 +
![图 1: Adding the minimize button back to the GNOME 3 windows.](http://www.linux.com/images/stories/41373/gnome3-max-min-window.png) + +*图 1: 添加回最小化按钮到GNOME 3窗口*
添加完后,你就可以看到最小化按钮了,它在关闭按钮的左边,等着为你服务呢。你的窗口现在管理起来更方便了。 @@ -27,36 +28,39 @@ Figure 1: 添加回最小化按钮到GNOME 3窗口 ### 添加扩展 ### -GNOME 3的最佳特性之一,就是shell扩展,这些扩展为GNOME带来了全部种类的有用的特性。关于shell扩展,没必要从包管理器去安装。你可以访问[GNOME Shell扩展][2]站点,搜索你想要添加的扩展,点击扩展列表,点击打开按钮,然后扩展就安装完成了;或者你也可以从GNOME优化工具中添加它们(你在网站上会找到更多可用的扩展)。 +GNOME 3的最佳特性之一,就是shell扩展,这些扩展为GNOME带来了各种类别的有用特性。关于shell扩展,没必要从包管理器去安装。你可以访问[GNOME Shell扩展][2]站点,搜索你想要添加的扩展,点击扩展列表,点击打开按钮,然后扩展就安装完成了;或者你也可以从GNOME优化工具中添加它们(你在网站上会找到更多可用的扩展)。 注:你可能需要在浏览器中允许扩展安装。如果出现这样的情况,你会在第一次访问GNOME Shell扩展站点时见到警告信息。当出现提示时,只要点击允许即可。 -令人印象更为深刻的(而又得心应手的扩展)之一,就是[Dash to Dock][3]。 +令人印象更为深刻的(而又得心应手的)扩展之一,就是[Dash to Dock][3]。 + 该扩展将Dash移出应用程序概览,并将它转变为相当标准的停靠栏(图2)。 -![Figure 2: Dash to Dock adds a dock to GNOME 3.](http://www.linux.com/images/stories/41373/gnome3-dash.png) -Figure 2: Dash to Dock添加一个停靠栏到GNOME 3. +
![图 2: Dash to Dock adds a dock to GNOME 3.](http://www.linux.com/images/stories/41373/gnome3-dash.png) + +*图 2: Dash to Dock添加一个停靠栏到GNOME 3*
当你添加应用程序到Dash后,他们也将被添加到Dash to Dock。你也可以通过点击Dock底部的6点图标访问应用程序概览。 -还有大量其它扩展聚焦于讲GNOME 3打造成一个更为高效的桌面,在这些更好的扩展中,包括以下这些: +还有大量其它扩展致力于将GNOME 3打造成一个更为高效的桌面,在这些不错的扩展中,包括以下这些: - [最近项目][4]: 添加一个最近使用项目的下拉菜单到面板。 -- [搜索Firefox书签提供者][5]: 从概览搜索(并启动)书签。 +- [Firefox书签搜索][5]: 从概览搜索(并启动)书签。 - [跳转列表][6]: 添加一个跳转列表弹出菜单到Dash图标(该扩展可以让你快速打开和程序关联的新文档,甚至更多) - [待办列表][7]: 添加一个下拉列表到面板,它允许你添加项目到该列表。 -- [网页搜索对话框][8]: 允许你通过敲击Ctrl+空格来快速搜索网页并输入一个文本字符串(结果在新的浏览器标签页中显示)。 +- [网页搜索框][8]: 允许你通过敲击Ctrl+空格来快速搜索网页并输入一个文本字符串(结果在新的浏览器标签页中显示)。 ### 添加一个完整停靠栏 ### -如果Dash to dock对于而言功能还是太有限(你想要通知区域,甚至更多),那么向你推荐我最喜爱的停靠栏之一[Cairo Dock][9](图3)。 +如果Dash to dock对于你而言功能还是太有限(你想要“通知区域”,甚至更多),那么向你推荐我最喜爱的停靠栏之一[Cairo Dock][9](图3)。 -![Figure 3: Cairo Dock ready for action.](http://www.linux.com/images/stories/41373/gnome3-Cairo-dock.png) -Figure 3: Cairo Dock待命 +
![图 3: Cairo Dock ready for action.](http://www.linux.com/images/stories/41373/gnome3-Cairo-dock.png) -在Cairo Dock添加到GNOME 3后,你的体验将成倍地增长。从你的发行版的包管理器中安装这个优秀的停靠栏吧。 +*图 3: Cairo Dock待命*
-不必将GNOME 3看作是一个效率不高的,用户不友好的桌面。只要稍作调整,GNOME 3可以成为和其它可用的桌面一样强大而用户友好的桌面。 +在将Cairo Dock添加到GNOME 3后,你的体验将成倍地增长。从你的发行版的包管理器中安装这个优秀的停靠栏吧。 + +不要将GNOME 3看作是一个效率不高的,用户不友好的桌面。只要稍作调整,GNOME 3可以成为和其它可用的桌面一样强大而用户友好的桌面。 -------------------------------------------------------------------------------- @@ -64,7 +68,7 @@ via: http://www.linux.com/learn/tutorials/781916-easy-steps-to-make-gnome-3-more 作者:[Jack Wallen][a] 译者:[GOLinux](https://github.com/GOLinux) -校对:[校对者ID](https://github.com/校对者ID) +校对:[ wxy](https://github.com/wxy) 本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 diff --git a/published/20140801 How To Install Java On Ubuntu 14.04.md b/published/201410/20140801 How To Install Java On Ubuntu 14.04.md similarity index 100% rename from published/20140801 How To Install Java On Ubuntu 14.04.md rename to published/201410/20140801 How To Install Java On Ubuntu 14.04.md diff --git a/published/20140801 How to Create an Ubuntu Kiosk Computer.md b/published/201410/20140801 How to Create an Ubuntu Kiosk Computer.md similarity index 100% rename from published/20140801 How to Create an Ubuntu Kiosk Computer.md rename to published/201410/20140801 How to Create an Ubuntu Kiosk Computer.md diff --git a/published/20140804 Cheat--An Ultimate Command Line 'Cheat-Sheet' for Linux Beginners and Administrators.md b/published/201410/20140804 Cheat--An Ultimate Command Line 'Cheat-Sheet' for Linux Beginners and Administrators.md similarity index 100% rename from published/20140804 Cheat--An Ultimate Command Line 'Cheat-Sheet' for Linux Beginners and Administrators.md rename to published/201410/20140804 Cheat--An Ultimate Command Line 'Cheat-Sheet' for Linux Beginners and Administrators.md diff --git a/translated/talk/20140808 When Linux Was Perfect Enough.md b/published/201410/20140808 When Linux Was Perfect Enough.md similarity index 86% rename from translated/talk/20140808 When Linux Was Perfect Enough.md rename to published/201410/20140808 When Linux Was Perfect Enough.md index 3bd911b982..b10d02bd05 100644 --- a/translated/talk/20140808 When Linux Was Perfect Enough.md +++ b/published/201410/20140808 When Linux Was Perfect Enough.md @@ -1,4 +1,4 @@ -什么时候Linux才能完美 +什么时候Linux才能完美? ================================================================================ 前几天我的同事兼损友,Ken Starks,在FOSS Force上发表了[一篇文章][1],关于他最喜欢发牢骚的内容:Linux系统中那些不能正常工作的事情。这次他抱怨的是在Mint里使用KDE时碰到的字体问题。这对于Ken来说也不是什么新鲜事了。过去他写了一些文章,关于各种Linux发行版中的缺陷从来都没有被认真修复过。他的观点是,这些在一次又一次的发布中从没有被修复过的“小问题”,对于Linux桌面系统在赢得大众方面的失败需要负主要责任。 @@ -14,21 +14,21 @@ ### 也不全是这样子的 ### -早在2002年的时候,我第一次安装使用GNU/Linux,像大多数美国人那样,我搞不定拨号连接,在我呆的这个小地方当时宽带还没普及。我在当地Best Buy商店里花了差不多70美元买了用热缩膜包装的Mandrake 9.0的Powerpack版,当时那里同时在卖Mandrake和Red Hat,现在仍然还在经营桌面业务。 +早在2002年的时候,我第一次安装使用GNU/Linux,像大多数美国人那样,我搞不定拨号连接,在我呆的这个小地方当时宽带还没普及。我在当地Best Buy商店里花了差不多70美元买了用热缩膜包装的Mandrake 9.0的Powerpack版,当时那里同时在卖Mandrake和Red Hat,现在仍然还在经营桌面PC业务。 在那个恐龙时代,Mandrake被认为是易用的Linux发行版中做的最好的。它安装简单,还有人说比Windows还简单,它自带的分区工具更是让划分磁盘像切苹果馅饼一样简单。不过实际上,Linux老手们经常公开嘲笑Mandrake,暗示易用的Linux不是真的Linux。 但是我很喜欢它,感觉来到了一个全新的世界。再也不用担心Windows的蓝屏死机和几乎每天一死了。不幸的是,之前在Windows下“能用”的很多外围设备也随之而去。 -安装完Mandrake之后我要做的第一件事就是,把我的小白盒拿给[Dragonware Computers][2]的Michelle,把便宜的winmodem换成硬件调制解调器。就算,一个硬件猫意味着计算机响应更快,但是计算机商店却在40英里外的地方,并不是很方便,而且费用我也有点压力。 +安装完Mandrake之后我要做的第一件事就是,把我的小白盒拿给[Dragonware Computers][2]的Michelle,把便宜的winmodem换成硬件调制解调器。就算是一个硬件猫意味着计算机响应更快,但是计算机商店却在40英里外的地方,并不是很方便,而且费用对我也有点压力。 但是我不介意。我对Microsoft并不感冒--而且使用一个“不同”的操作系统让我感觉自己就像一个计算机天才。 -打印机也是个麻烦,但是这个问题对于Mandrake还好,不像其他大多数发行版还需要命令行里的操作才能解决。Mandrake提供了一个华丽的图形界面来设置打印机-如果你正好幸运的有一台能在Linux下工作的打印机的话。很多,不是大多数,都不行。 +打印机也是个麻烦,但是这个问题对于Mandrake还好,不像其他大多数发行版还需要命令行里的操作才能解决。Mandrake提供了一个华丽的图形界面来设置打印机-如果你正好幸运的有一台能在Linux下工作的打印机的话。很多打印机——就算不是大多数——都不行。 我的还在保修期的Lexmark,在Windows下比其他打印机多出很多华而不实的小功能,厂商并不支持Linux版本,但是我找到一个多少能用的开源逆向工程驱动。它能在Mozilla浏览器里正常打印网页,但是在Star Office软件里打印的话会是用很小的字体塞到页面的右上角里。打印机还会发出很大的机械响声,让我想起了汽车变速箱在报废时发出的噪音。 -Star Office问题的变通方案是把所有文字都保存到文本文件,然后在文本编辑器里打印。而对于那个听上去像是打印机处于自解体模式的噪音?我的方法是尽量不要打印。 +Star Office问题的变通方案是把所有文字都保存到文本文件,然后在文本编辑器里打印。而对于那个听上去像是打印机处于天魔解体模式的噪音?我的方法是尽量不要打印。 ### 更多的其他问题-对我来说太多了都快忘了 ### @@ -36,12 +36,13 @@ Star Office问题的变通方案是把所有文字都保存到文本文件,然 好吧,我还有个并口扫描仪,在我转移到Linux之前两个星期买的,之后它就基本是块砖了,因为没有Linux下的驱动。 -我的观点是在那个年代里这些都不重要。我们大多数人都习惯了修改配置文件之类的事情,即便是运行微软产品的“IBM兼容”计算机。就像那个年代的大多数用户,我刚学开始接触使用命令行的DOS机器,在它上面打印机需要针对每个程序单独设置,而且写写简单的autoexec.bat是必须的技能。 +我的观点是在那个年代里这些都不重要。我们大多数人都习惯了修改配置文件之类的事情,即便是运行微软产品的“IBM兼容”计算机。就像那个年代的大多数用户,我刚学开始接触使用命令行的DOS机器,在它上面打印机需要针对每个程序单独设置,而且写写简单的autoexec.bat是必备的技能。 -![Linux as a 1966 “goat.”](http://fossforce.com/wp-content/uploads/2014/08/Pontiac_GTO_1966-300x224.jpg) -Linux就像1966年的“山羊” +
![Linux as a 1966 “goat.”](http://fossforce.com/wp-content/uploads/2014/08/Pontiac_GTO_1966-300x224.jpg)
-能够摆弄操作系统内部的配置是能够拥有一台计算机的一个简单部分。我们大多数使用计算机的人要么是极客或是希望成为极客。我们为这种能够调整计算机按我们想要的方式运行的能力而感到骄傲。我们就是那个年代里高科技版本的好男孩,他们会在周六下午在树荫下改装他们肌肉车上的排气管,通风管,化油器之类的。 +
Linux就像1966年的“山羊”
+ +那时,能够摆弄操作系统内部的配置是能够拥有一台计算机的一个简单部分。我们大多数使用计算机的人要么是极客或是希望成为极客。我们为这种能够调整计算机按我们想要的方式运行的能力而感到骄傲。我们就是那个年代里高科技版本的好男孩,他们会在周六下午在树荫下改装他们肌肉车上的排气管,通风管,化油器之类的。 ### 不过现在大家不是这样使用计算机的 ### @@ -59,7 +60,7 @@ via: http://fossforce.com/2014/08/when-linux-was-perfect-enough/ 作者:Christine Hall 译者:[zpl1025](https://github.com/zpl1025) -校对:[校对者ID](https://github.com/校对者ID) +校对:[wxy](https://github.com/wxy) 本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 diff --git a/published/20140811 Disable or Password Protect Single User Mode or RHEL ro CentOS ro 5.x ro 6.x.md b/published/201410/20140811 Disable or Password Protect Single User Mode or RHEL ro CentOS ro 5.x ro 6.x.md similarity index 100% rename from published/20140811 Disable or Password Protect Single User Mode or RHEL ro CentOS ro 5.x ro 6.x.md rename to published/201410/20140811 Disable or Password Protect Single User Mode or RHEL ro CentOS ro 5.x ro 6.x.md diff --git a/translated/tech/20140811 How to Image and Clone Hard Drives with Clonezilla.md b/published/201410/20140811 How to Image and Clone Hard Drives with Clonezilla.md similarity index 68% rename from translated/tech/20140811 How to Image and Clone Hard Drives with Clonezilla.md rename to published/201410/20140811 How to Image and Clone Hard Drives with Clonezilla.md index 4671ac4c6b..eb07e4bb14 100644 --- a/translated/tech/20140811 How to Image and Clone Hard Drives with Clonezilla.md +++ b/published/201410/20140811 How to Image and Clone Hard Drives with Clonezilla.md @@ -1,20 +1,17 @@ 使用Clonezilla对硬盘进行镜像和克隆 ================================================================================ -![Figure 1: Creating a partition on the USB stick for Clonezilla.](http://www.linux.com/images/stories/41373/fig-1-gparted.jpeg) -图1: 在USB存储棒上为Clonezilla创建分区 +Clonezilla是一个用于Linux,Free-Net-OpenBSD,Mac OS X,Windows以及Minix的分区和磁盘克隆程序。它支持所有主要的文件系统,包括EXT,NTFS,FAT,XFS,JFS和Btrfs,LVM2,以及VMWare的企业集群文件系统VMFS3和VMFS5。Clonezilla支持32位和64位系统,同时支持旧版BIOS和UEFI BIOS,并且同时支持MBR和GPT分区表。它是一个用于完整备份Windows系统和所有安装于上的应用软件的好工具,而我喜欢用它来为Linux测试系统做备份,以便我可以在其上做疯狂的实验搞坏后,可以快速恢复它们。 -Clonezilla是一个用于Linux,Free-Net-,OpenBSD,Mac OS X,Windows以及Minix的分区和磁盘克隆程序。它支持所有主要的文件系统,包括EXT,NTFS,FAT,XFS,JFS和Btrfs,LVM2,以及VMWare的企业集群文件系统VMFS3和VMFS5。Clonezilla支持32位和64位系统,同时支持旧版BIOS和UEFI BIOS,并且同时支持MBR和GPT分区表。它是一个用于完整备份Windows系统和所有安装于上的应用软件的好工具,而我喜欢用它来为Linux测试系统做备份,以便我可以在其上做疯狂的实验搞坏后,可以快速恢复它们。 +Clonezilla也可以使用dd命令来备份不支持的文件系统,该命令可以复制块而非文件,因而不必在意文件系统。简单点说,就是Clonezilla可以复制任何东西。(关于块的快速说明:磁盘扇区是磁盘上最小的可编址存储单元,而块是由单个或者多个扇区组成的逻辑数据结构。) -Clonezilla也可以使用dd命令来备份不支持的文件系统,该命令可以复制块而非文件,因而不必弄明白文件系统。因此,简单点说,就是Clonezilla可以复制任何东西。(关于块的快速说明:磁盘扇区是磁盘上最小的可编址存储单元,而块是由单个或者多个扇区组成的逻辑数据结构。) - -Clonezilla分为两个版本:Clonezilla Live和Clonezilla Server Edition(SE)。Clonezilla Live对于将单个计算机克隆岛本地存储设备或者网络共享来说是一流的。而Clonezilla SE则适合更大的部署,用于一次性快速多点克隆整个网络中的PC。Clonezilla SE是一个神奇的软件,我们将在今后讨论。今天,我们将创建一个Clonezilla Live USB存储棒,克隆某个系统,然后恢复它。 +Clonezilla分为两个版本:Clonezilla Live和Clonezilla Server Edition(SE)。Clonezilla Live对于将单个计算机克隆到本地存储设备或者网络共享来说是一流的。而Clonezilla SE则适合更大的部署,用于一次性快速多点克隆整个网络中的PC。Clonezilla SE是一个神奇的软件,我们将在今后讨论。今天,我们将创建一个Clonezilla Live USB存储棒,克隆某个系统,然后恢复它。 ### Clonezilla和Tuxboot ### 当你访问下载页时,你会看到[稳定版和可选稳定发行版][1]。也有测试版本,如果你有兴趣帮助改善Clonezilla,那么我推荐你使用此版本。稳定版基于Debian,不含有非自由软件。可选稳定版基于Ubuntu,包含有一些非自由固件,并支持UEFI安全启动。 -在你[下载Clonezilla][2]后,请安装[Tuxboot][3]来复制Clonezilla到USB存储棒。Tuxboot是一个Unetbootin的修改版,它支持Clonezilla;你不能使用Unetbootin,因为它无法工作。安装Tuxboot有点让人头痛,然而Ubuntu用户通过个人包归档压缩包(PPA)方便地安装: +在你[下载Clonezilla][2]后,请安装[Tuxboot][3]来复制Clonezilla到USB存储棒。Tuxboot是一个Unetbootin的修改版,它支持Clonezilla;你不能使用Unetbootin,因为它无法配合工作。安装Tuxboot有点让人头痛,然而Ubuntu用户通过个人包归档包(PPA)方便地安装: $ sudo apt-add-repository ppa:thomas.tsai/ubuntu-tuxboot $ sudo apt-get update @@ -22,18 +19,24 @@ Clonezilla分为两个版本:Clonezilla Live和Clonezilla Server Edition(SE 如果你没有运行Ubuntu,并且你的发行版不包含打包好的Tuxboot版本,那么请[下载源代码tarball][4],并遵循README.txt文件中的说明来编译并安装。 -安装完Tuxboot后,就可以使用它来创建你精巧的可直接启动的Clonezilla USB存储棒了。首先,创建一个最小200MB的FAT 32分区;图1(上面)展示了使用GParted来进行分区。我喜欢使用标签,比如“Clonezilla”,这会让我知道它是个什么东西。该例子中展示了将一个2GB的存储棒格式化成一个单个分区。 -Then fire up Tuxboot (figure 2). Check "Pre-downloaded" and click the button with the ellipsis to select your Clonezilla file. It should find your USB stick automatically, and you should check the partition number to make sure it found the right one. In my example that is /dev/sdd1. Click OK, and when it's finished click Exit. It asks you if you want to reboot now, but don't worry because it won't. Now you have a nice portable Clonezilla USB stick you can use almost anywhere. -然后,启动Tuxboot(图2)。选中“预下载的(Pre-downloaded)”然后点击带省略号的按钮来选择Clonezilla文件。它会自动发现你的USB存储棒,而你需要选中分区号来确保它找到的是正确的那个,我的例子中是/dev/sdd1。点击确定,然后当它完成后点击退出。它会问你是否要重启动,请不要担心,因为它不会的。现在你有一个精巧的便携式Clonezilla USB存储棒了,你可以随时随地使用它了。 +
![Figure 1: Creating a partition on the USB stick for Clonezilla.](http://www.linux.com/images/stories/41373/fig-1-gparted.jpeg)
-![Figure 2: Fire up Tuxboot.](http://www.linux.com/images/stories/41373/fig-2-tuxboot.jpeg) -图2: 启动Tuxboot +
*图1: 在USB存储棒上为Clonezilla创建分区*
+ + +安装完Tuxboot后,就可以使用它来创建你精巧的可直接启动的Clonezilla USB存储棒了。首先,创建一个最小200MB的FAT 32分区;图1(上图)展示了使用GParted来进行分区。我喜欢使用类似“Clonezilla”这样的标签,这会让我知道它是个什么东西。该例子中展示了将一个2GB的存储棒格式化成一个单个分区。 + +然后,启动Tuxboot(图2)。选中“预下载的(Pre-downloaded)”然后点击带省略号的按钮来选择Clonezilla文件。它会自动发现你的USB存储棒,而你需要选中分区号来确保它找到的是正确的那个,我的例子中是/dev/sdd1。点击确定,然后当它完成后点击退出。它会问你是否要重启动,不要担心,现在不用重启。现在你有一个精巧的便携式Clonezilla USB存储棒了,你可以随时随地使用它了。 + +
![Figure 2: Fire up Tuxboot.](http://www.linux.com/images/stories/41373/fig-2-tuxboot.jpeg)
+ +
*图2: 启动Tuxboot*
### 创建磁盘镜像 ### 在你想要备份的计算机上启动Clonezilla USB存储棒,第一个映入你眼帘的是常规的启动菜单。启动到默认条目。你会被问及使用何种语言和键盘,而当你到达启动Clonezilla菜单时,请选择启动Clonezilla。在下一级菜单中选择设备镜像,然后进入下一屏。 -这一屏有点让人摸不着头脑,里头有什么local_dev,ssh_server,samba_server,以及nfs_server之类的选项。这里就是要你选择将备份的镜像拷贝到哪里,目标分区或者驱动器必须和你要拷贝的卷要一样大,甚至更大。如果你选择local_dev,那么你需要一个足够大的本地分区来存储你的镜像。附加USB硬盘驱动器是一个不错的,快速而又简单的选项。如果你选择任何服务器选项,你需要有线连接到服务器,并提供IP地址并登录上去。我将使用一个本地分区,这就是说要选择local_dev。 +这一屏有点让人摸不着头脑,里头有什么local_dev,ssh_server,samba_server,以及nfs_server之类的选项。这里就是要你选择将备份的镜像拷贝到哪里,目标分区或者驱动器必须和你要拷贝的卷要一样大,甚至更大。如果你选择local_dev,那么你需要一个足够大的本地分区来存储你的镜像。附加的USB硬盘驱动器是一个不错的,快速而又简单的选项。如果你选择任何服务器选项,你需要能连接到服务器,并提供IP地址并登录上去。我将使用一个本地分区,这就是说要选择local_dev。 当你选择local_dev时,Clonezilla会扫描所有连接到本地的存储折本,包括硬盘和USB存储设备。然后,它会列出所有分区。选择你想要存储镜像的分区,然后它会问你使用哪个目录并列出目录。选择你所需要的目录,然后进入下一屏,它会显示所有的挂载以及已使用/可用的空间。按回车进入下一屏,请选择初学者还是专家模式。我选择初学者模式。 @@ -41,12 +44,13 @@ Then fire up Tuxboot (figure 2). Check "Pre-downloaded" and click the button wit 下一屏中,它会问你新建镜像的名称。在接受默认名称,或者输入你自己的名称后,进入下一屏。Clonezilla会扫描你所有的分区并创建一个检查列表,你可以从中选择你想要拷贝的。选择完后,在下一屏中会让你选择是否进行文件系统检查并修复。我才没这耐心,所以直接跳过了。 -下一屏中,会问你是否想要Clonezilla检查你新创建的镜像,以确保它是可恢复的。选是吧,确保万无一失。接下来,它会给你一个命令行提示,如果你想用命令行而非GUI,那么你必须再次按回车。你需要再次确认,并输入y来确认制作拷贝。 +下一屏中,会问你是否想要Clonezilla检查你新创建的镜像,以确保它是可恢复的。选“是”吧,确保万无一失。接下来,它会给你一个命令行提示,如果你想用命令行而非GUI,那么你必须再次按回车。你需要再次确认,并输入y来确认制作拷贝。 在Clonezilla创建新镜像的时候,你可以好好欣赏一下这个友好的红、白、蓝三色的进度屏(图3)。 -![Figure 3: Watch the creation of your new image.](http://www.linux.com/images/stories/41373/fig-3-export.jpeg) -图3: 守候创建新镜像 +
![Figure 3: Watch the creation of your new image.](http://www.linux.com/images/stories/41373/fig-3-export.jpeg)
+ +
*图3: 守候创建新镜像*
全部完成后,按回车然后选择重启,记得拔下你的Clonezilla USB存储棒。正常启动计算机,然后去看看你新创建的Clonezilla镜像吧。你应该看到像下面这样的东西: @@ -81,7 +85,7 @@ via: http://www.linux.com/learn/tutorials/783416-how-to-image-and-clone-hard-dri 作者:[Carla Schroder][a] 译者:[GOLinux](https://github.com/GOLinux) -校对:[校对者ID](https://github.com/校对者ID) +校对:[wxy](https://github.com/wxy) 本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 diff --git a/published/20140811 Linux FAQs with Answers--How to check the last time system was rebooted on Linux.md b/published/201410/20140811 Linux FAQs with Answers--How to check the last time system was rebooted on Linux.md similarity index 100% rename from published/20140811 Linux FAQs with Answers--How to check the last time system was rebooted on Linux.md rename to published/201410/20140811 Linux FAQs with Answers--How to check the last time system was rebooted on Linux.md diff --git a/translated/tech/20140818 Linux FAQs with Answers--How to set a static MAC address on VMware ESXi virtual machine.md b/published/201410/20140818 Linux FAQs with Answers--How to set a static MAC address on VMware ESXi virtual machine.md similarity index 78% rename from translated/tech/20140818 Linux FAQs with Answers--How to set a static MAC address on VMware ESXi virtual machine.md rename to published/201410/20140818 Linux FAQs with Answers--How to set a static MAC address on VMware ESXi virtual machine.md index 4d115bf279..dacd04fc3b 100644 --- a/translated/tech/20140818 Linux FAQs with Answers--How to set a static MAC address on VMware ESXi virtual machine.md +++ b/published/201410/20140818 Linux FAQs with Answers--How to set a static MAC address on VMware ESXi virtual machine.md @@ -1,6 +1,6 @@ -Linux FAQ -- 如何在VMware ESXi虚拟机上设置静态MAC地址。 +Linux有问必答:如何在VMware ESXi虚拟机上设置静态MAC地址 ================================================================================ -> **问题**:我想给VMware ESXi上的一台虚拟机分配一个静态的MAC地址。然而当我开始这么做的时候,虚拟机就不能启动了不且抛出了一个这样一个错误"00:0c:29:1f:4a:ab is not an allowed static Ethernet address. It conflicts with VMware reserved MACs"(00:0c:29:1f:4a:ab不是一个合法的静态以太网地址。它与VMWare的保留MAC地址冲突)。我该如何在VMware ESXi虚拟机上设置静态MAC地址? +> **问题**:我想给VMware ESXi上的一台虚拟机分配一个静态的MAC地址。然而当我开始这么做的时候,虚拟机就不能启动了,并且抛出了一个这样一个错误"00:0c:29:1f:4a:ab is not an allowed static Ethernet address. It conflicts with VMware reserved MACs"(00:0c:29:1f:4a:ab不是一个合法的静态以太网地址。它与VMWare的保留MAC地址冲突)。我该如何在VMware ESXi虚拟机上设置静态MAC地址? 当你在VMware ESXi上创建虚拟机时,虚拟机的每个网络接口就被分配了一个动态的NAC地址。如果你想要改变默认的行为并给你的虚拟机分配一个静态MAC地址时就这样做 @@ -16,7 +16,7 @@ Linux FAQ -- 如何在VMware ESXi虚拟机上设置静态MAC地址。 首先关闭你想要分配静态MAC地址的虚拟机。 -[对你的ESXi主机启用SSH访问][1]如果你还没这么做的话。接着通过SSH登录ESXi主机。 +[对你的ESXi主机启用SSH访问][1],如果你还没这么做的话。接着通过SSH登录ESXi主机。 移到你虚拟机的.vmx文件所在目录。 @@ -35,7 +35,7 @@ Linux FAQ -- 如何在VMware ESXi虚拟机上设置静态MAC地址。 via: http://ask.xmodulo.com/static-mac-address-vmware-esxi-virtual-machine.html 译者:[geekpi](https://github.com/geekpi) -校对:[校对者ID](https://github.com/校对者ID) +校对:[wxy](https://github.com/wxy) 本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 diff --git a/published/201410/20140818 Where And How To Code--Choosing The Best Free Code Editor.md b/published/201410/20140818 Where And How To Code--Choosing The Best Free Code Editor.md new file mode 100644 index 0000000000..771f0c10b3 --- /dev/null +++ b/published/201410/20140818 Where And How To Code--Choosing The Best Free Code Editor.md @@ -0,0 +1,104 @@ +何处写,如何写:选择最好的免费在线代码编辑器 +================================================================================ +> 深入了解一下Cloud9,Koding和Nitrous.IO。 + +![](http://a2.files.readwrite.com/image/upload/c_fill,h_900,q_70,w_1600/MTIzMDQ5NjYzODM4NDU1MzA4.jpg) + +已经准备好开始你的第一个编程项目了吗?很好!只要配置一下终端或命令行,学习如何使用它,然后安装所有要用到的编程语言,插件库和API函数库。当最终准备好一切以后,再安装好[Visual Studio][1]就可以开始了,然后才可以预览自己的工作。 + +至少这是大家过去已经熟悉的方式。 + +也难怪初学程序员们逐渐喜欢上在线的集成开发环境(IDE)了。IDE是一个代码编辑器,不过已经准备好编程语言以及所有需要的依赖,可以让你避免把它们一一安装到电脑上的麻烦。 + +我想搞清楚到底是哪些因素能组成一个典型的IDE,所以我试用了一下免费级别的时下最受欢迎的三款集成开发环境:[Cloud9][2],[Koding][3]和[Nitrous.IO][4]。在这个过程中,我了解了许多程序员应该或不应该使用IDE的各种情形。 + +### 为什么要用IDE? ### + +假如有一个像Microsoft Word那样的文字编辑器,想想类似Google Drive那样的IDE吧。你可以拥有类似的功能,但是它还能支持从任意电脑上访问,还能随时共享。因为因特网在项目工作流中的影响已经越来越重要,IDE也让生活更轻松。 + +在我最近的一篇ReadWrite教程中我使用了Nitrous.IO,这是在文章“[创建一个你自己的像Yo那样的极端简单的聊天应用][5]”里的一个Python应用。当使用IDE的时候,你只要选择你要用的编程语言,然后通过IDE特别为运行这种语言程序而设计的虚拟机(VM),你就可以测试和预览你的应用了。 + +如果你读过那篇教程,就会知道我的那个应用只用到了两个API库-信息服务Twilio和Python微框架Flask。在我的电脑上就算是使用文字编辑器和终端来做也是很简单的,不过我选择使用IDE还有一个方便的地方:如果大家都使用同样的开发环境,跟着教程一步步走下去就更简单了。 + +### IDE不能做的事情 ### + +到目前为止,IDE还不是一个长期托管方案。 + +当你使用IDE工作的时候,你可以在云上构建,测试和预览你的应用。你甚至还可以直接通过链接共享你的最终作品。 + +但是不能用IDE来永久存储你的整个项目。把帖子保存在Google Drive文件中不会让你的博客丢失。类似Google Drive,IDE可以让你创建链接用于共享内容,但是任何一个都还不足以替代真正的托管服务器。 + +还有,IDE并不是设计成方便广泛共享。尽管各种IDE都在不断改善大多数文字编辑器的预览功能,还只能用来给你的朋友或同事展示一下应用的预览,而不是像Hacker News一样的主页。那样的话,占用太多带宽的IDE也许会让你崩溃。 + +这样说吧:IDE只是构建和测试你的应用的地方,托管服务器才是它们生存的地方。所以一旦完成了你的应用,你会希望把它布置到能长期托管的云服务器上,最好是能免费托管的那种,例如[Heroku][6]。 + +### 选择一个IDE ### + +![](http://a2.files.readwrite.com/image/upload/c_fit,w_630/MTIzNjEzMTg5MjA2NDc2MzAy.png) + +随着IDE变得越来越流行,选择也越来越多。在我眼里,没有一个是完美的。不过,还是有些IDE在完成某些工作方面相对来说有些优势。 + +我尝试了一下免费级别的三个最受欢迎的集成开发环境:Cloud9,Koding和Nitrous.IO。每一个都有自己的优点,当然跟你用来做的事情有关系。下面就是我的发现。 + +### Cloud9:乐于协作 ### + +当我完成了Cloud9的注册后,它提示的第一件事情就是添加我的GitHub和BitBucket账号。马上,所有我的GitHub项目,个人的和协作的,都可以直接克隆到本地并使用Cloud9的开发工具开始工作。其他的IDE在和GitHub集成的方面都没有达到这种水准。 + +在我测试的这三款IDE中,Cloud9看起来更加侧重于一个可以让协同工作的人们无缝衔接工作的环境。在这里,它并不是角落里放个聊天窗口。实际上,按照其CEO Ruben Daniels说的,试用Cloud9的协作者可以互相看到其他人实时的编码情况,就像Google Drive上的合作者那样。 + +“大多数IDE服务的协同功能只能操作单一文件”,Daniels说,“而我们的产品可以支持整个项目中的不同文件。协同功能被完美集成到了我们的IDE中。” + +### Koding:在你需要的时候能提供帮助 ### + +IDE可以提供你所需的工具来构建和测试所有开源编程语言的应用。对于初学者来说,看起来有点吓人。举个例子,如果我要做一个项目同时用到Python和Ruby组件,那我要用哪个VM来测试? + +答案是两个都要,尽管使用免费账号的话,只能够同时打开一个VM用于测试。我就在Koding的控制面板里找到了答案,一个折叠起来的地方,用户可以提供或获得他们Koding项目的各种经验。在这三者中间,它是最容易使用的,拥有一个你可以寻求帮助并很快有人回答的地方。 + +“我们在这款产品里加入了一个积极的社区功能”,Koding的首席商务官Nitin Gupta说,“我们希望搭建一个环境,真正吸引那些希望得到帮助和愿意提供帮助的人们。” + +### Nitrous.IO: An IDE Wherever You Want ### + +相对于自己的桌面环境,使用IDE的最大优势是它是自足的。你不需要安装任何其他的东西就可以使用。而另一方面,使用自己的桌面环境的最大优势就是你可以在本地工作,甚至在没有互联网的情况下。 + +Nitrous.IO结合了这两个优势。“你可以在网站上在线使用这个IDE,你也可以把它下载到自己的电脑上”,其共同创始人AJ Solimine这样说。优点是你可以结合Nitrous的集成性和你最喜欢的文字编辑器的熟悉。 + +他说:“你可以使用任意现代浏览器访问Nitrous.IO的在线IDE网站,但我们仍然提供了方便的Windows和Mac桌面应用,可以让你使用你最喜欢的编辑器来写代码。” + +### 底线 ### + +这一个星期[使用][7]三个不同IDE的最让我意外的收获是什么?它们是如此相似。[当用来做最基本的代码编辑的时候][8],它们都一样的好用。 + +Cloud9,Koding,[和Nitrous.IO都支持][9]所有主流的开源编程语言,从Ruby到Python到PHP到HTML5。你可以选择任何一种VM。 + +Cloud9和Nitrous.IO都实现了GitHub的一键集成。Koding需要[多几个步骤][10],不过也是可以实现的。 + +每一个都轻松地集成了我需要的API。每一个也都可以让我自己安装喜欢的包(Koding需要超级用户权限)。它们都带有内置的终端,可以用来轻松地测试和布置项目。三个都支持轻松地预览项目。当然,它们也都把我的项目托管在云服务器中,所以我在任意地方都可以在上边工作。 + +不好的一面,它们都有相同的缺陷,不过考虑到它们都是免费的也还合理。你每次只能同时运行一个VM来测试特定编程语言写出的程序。而当你一段时间没有使用VM之后,IDE会把VM切换成休眠模式以节省带宽,而下次要用的时候就得等它重新加载(Cloud9在这一点上更加费力)。它们中也没有任何一个为已完成的项目提供像样的永久托管服务。 + +所以,对咨询我是否有一个完美的免费IDE的人来说,答案是可能没有。但是这也要看你侧重的地方,对你的某个项目来说也许有一个完美的IDE。 + +图片由[Shutterstock][11]友情提供 + +-------------------------------------------------------------------------------- + +via: http://readwrite.com/2014/08/14/cloud9-koding-nitrousio-integrated-development-environment-ide-coding + +作者:[Lauren Orsini][a] +译者:[zpl1025](https://github.com/zpl1025) +校对:[wxy](https://github.com/wxy) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://readwrite.com/author/lauren-orsini +[1]:http://www.visualstudio.com/ +[2]:http://c9.io/ +[3]:https://koding.com/ +[4]:http://nitrous.io/ +[5]:http://readwrite.com/2014/07/11/one-click-messaging-app +[6]:http://heroku.com/ +[7]:http://help.nitrous.io/ide-general/ +[8]:https://www.nitrous.io/desktop +[9]:https://www.nitrous.io/desktop +[10]:https://koding.com/Activity/steps-clone-projects-github-koding-1-create-account-github-2-open-your-terminal-3 +[11]:http://www.shutterstock.com/ diff --git a/published/201410/20140819 8 Options to Trace or Debug Programs using Linux strace Command.md b/published/201410/20140819 8 Options to Trace or Debug Programs using Linux strace Command.md new file mode 100644 index 0000000000..a840ee7b59 --- /dev/null +++ b/published/201410/20140819 8 Options to Trace or Debug Programs using Linux strace Command.md @@ -0,0 +1,116 @@ +使用 Linux 的 strace 命令跟踪/调试程序的常用选项 +================================================================================ + +在调试的时候,strace能帮助你追踪到一个程序所执行的系统调用。当你想知道程序和操作系统如何交互的时候,这是极其方便的,比如你想知道执行了哪些系统调用,并且以何种顺序执行。 + +这个简单而又强大的工具几乎在所有的Linux操作系统上可用,并且可被用来调试大量的程序。 + +### 命令用法 ### + +让我们看看strace命令如何追踪一个程序的执行情况。 + +最简单的形式,strace后面可以跟任何命令。它将列出许许多多的系统调用。一开始,我们并不能理解所有的输出,但是如果你正在寻找一些特殊的东西,那么你应该能从输出中发现它。 + +让我们来看看简单命令ls的系统调用跟踪情况。 + + raghu@raghu-Linoxide ~ $ strace ls + +![Stracing ls command](http://linoxide.com/wp-content/uploads/2014/08/01.strace_ls.png) + +这是strace命令输出的前几行。其他输出被截去了。 + +![Strace write system call (ls)](http://linoxide.com/wp-content/uploads/2014/08/02.strace_ls_write.png) + +上面的输出部分展示了write系统调用,它把当前目录的列表输出到标准输出。 + +下面的图片展示了使用ls命令列出的目录内容(没有使用strace)。 + + raghu@raghu-Linoxide ~ $ ls + +![ls command output](http://linoxide.com/wp-content/uploads/2014/08/03.ls_.png) + +#### 选项1 寻找被程序读取的配置文件 #### + +Strace 的用法之一(除了调试某些问题以外)是你能找到被一个程序读取的配置文件。例如, + + raghu@raghu-Linoxide ~ $ strace php 2>&1 | grep php.ini + +![Strace config file read by program](http://linoxide.com/wp-content/uploads/2014/08/04.strace_php_configuration.png) + +#### 选项2 跟踪指定的系统调用 #### + +strace命令的-e选项仅仅被用来展示特定的系统调用(例如,open,write等等) + +让我们跟踪一下cat命令的‘open’系统调用。 + + raghu@raghu-Linoxide ~ $ strace -e open cat dead.letter + +![Stracing specific system call (open here)](http://linoxide.com/wp-content/uploads/2014/08/05.strace_open_systemcall.png) + +#### 选项3 跟踪进程 #### + +strace不但能用在命令上,而且通过使用-p选项能用在运行的进程上。 + + raghu@raghu-Linoxide ~ $ sudo strace -p 1846 + +![Strace a process](http://linoxide.com/wp-content/uploads/2014/08/06.strace_process.png) + +#### 选项4 strace的统计概要 #### + +它包括系统调用的概要,执行时间,错误等等。使用-c选项能够以一种整洁的方式展示: + + raghu@raghu-Linoxide ~ $ strace -c ls + +![Strace summary display](http://linoxide.com/wp-content/uploads/2014/08/07.strace_summary.png) + +#### 选项5 保存输出结果 #### + +通过使用-o选项可以把strace命令的输出结果保存到一个文件中。 + + raghu@raghu-Linoxide ~ $ sudo strace -o process_strace -p 3229 + +![Strace a process](http://linoxide.com/wp-content/uploads/2014/08/08.strace_output_file.png) + +之所以以sudo来运行上面的命令,是为了防止用户ID与所查看进程的所有者ID不匹配的情况。 + +### 选项6 显示时间戳 ### + +使用-t选项,可以在每行的输出之前添加时间戳。 + + raghu@raghu-Linoxide ~ $ strace -t ls + +![Timestamp before each output line](http://linoxide.com/wp-content/uploads/2014/08/09.strace_timestamp.png) + +#### 选项7 更精细的时间戳 #### + +-tt选项可以展示微秒级别的时间戳。 + + raghu@raghu-Linoxide ~ $ strace -tt ls + +![Time - Microseconds](http://linoxide.com/wp-content/uploads/2014/08/010.strace_finer_timestamp.png) + +-ttt也可以向上面那样展示微秒级的时间戳,但是它并不是打印当前时间,而是显示自从epoch(译注:1970年1月1日00:00:00 UTC)以来的所经过的秒数。 + + raghu@raghu-Linoxide ~ $ strace -ttt ls + +![Seconds since epoch](http://linoxide.com/wp-content/uploads/2014/08/011.strace_epoch_seconds.png) + +#### 选项8 相对时间 #### + +-r选项展示系统调用之间的相对时间戳。 + + raghu@raghu-Linoxide ~ $ strace -r ls + +![Relative Timestamp](http://linoxide.com/wp-content/uploads/2014/08/012.strace_relative-time.png) + +-------------------------------------------------------------------------------- + +via: http://linoxide.com/linux-command/linux-strace-command-examples/ + +作者:[Raghu][a] +译者:[guodongxiaren](https://github.com/guodongxiaren) +校对:[wxy](https://github.com/wxy) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://linoxide.com/author/raghu/ diff --git a/translated/tech/20140819 A Pocket Guide for Linux ssh Command with Examples.md b/published/201410/20140819 A Pocket Guide for Linux ssh Command with Examples.md similarity index 81% rename from translated/tech/20140819 A Pocket Guide for Linux ssh Command with Examples.md rename to published/201410/20140819 A Pocket Guide for Linux ssh Command with Examples.md index 8673d7b208..bd3799ff7a 100644 --- a/translated/tech/20140819 A Pocket Guide for Linux ssh Command with Examples.md +++ b/published/201410/20140819 A Pocket Guide for Linux ssh Command with Examples.md @@ -1,16 +1,16 @@ Linux 下 SSH 命令实例指南 ================================================================================ -如果你已经接触计算机比较长时间, 应该对 SSH 这个了不起的工具及其安全特性有所耳闻吧. 本教程可以让你在短时间内掌握通过 SSH 安全便利地连接到远程计算机的技术. +如果你已经在IT圈内混了很长时间, 应该对 SSH 这个了不起的工具及其安全特性有所耳闻吧. 本教程可以让你在短时间内掌握通过 SSH 安全便利地连接到远程计算机的技术. 如果你对 SSH 还没什么概念, 可以先访问 [维基百科][1] 进行了解. ### 基本用法 ### -最简单的 SSH 命令只需要提供用户名和主机名参数即可. 主机名可以是 IP 地址或者域名. 命令格式如下: +最简单的 SSH 命令只需要指定用户名和主机名参数即可. 主机名可以是 IP 地址或者域名. 命令格式如下: $ ssh user@hostname -比如要登录到局域网内我的一个树莓派系统, 只需要简单的在命令行输入如下命令: +比如要在我的局域网内登录一个树莓派系统, 只需要简单的在命令行输入如下命令: $ ssh pi@10.42.0.47 @@ -22,7 +22,7 @@ Linux 下 SSH 命令实例指南 ### 使用其他端口 ### -SSH 默认连接到目标主机的 22 端口上, 但是由于各种原因你可能需要连接到其他端口. +SSH 默认连接到目标主机的 22 端口上,但是由于各种原因你可能需要连接到其他端口. $ ssh -p 10022 user@hostname @@ -30,7 +30,7 @@ SSH 默认连接到目标主机的 22 端口上, 但是由于各种原因你可 ### 远程执行命令 ### -有时需要很方便地在远程主机执行一条命令并显示到本地, 然后继续本地工作. SSH 就能满足这个需求: +有时在远程主机执行一条命令并显示到本地, 然后继续本地工作是很方便的. SSH 就能满足这个需求: $ ssh pi@10.42.0.47 ls -l @@ -38,9 +38,9 @@ SSH 默认连接到目标主机的 22 端口上, 但是由于各种原因你可 ![remote command](http://linoxide.com/wp-content/uploads/2014/08/remote-command.png) -### 挂在远程文件系统 ### +### 挂载远程文件系统 ### -有一个很赞的基于 SSH 的工具叫 sshfs. sshfs 可以让你在本地直接挂载远程主机的文件系统. +另外一个很赞的基于 SSH 的工具叫 sshfs. sshfs 可以让你在本地直接挂载远程主机的文件系统. $ sshfs -o idmap=user user@hostname:/home/user ~/Remote @@ -50,7 +50,7 @@ SSH 默认连接到目标主机的 22 端口上, 但是由于各种原因你可 该命令就将远程主机 pi 用户的主目录挂载到本地主目录下的 Pi 文件夹. -要详细了解可以参考 [sshfs 入门教程][2]. +要详细了解可以参考 [sshfs 教程][2]. ### X11 图形界面 ### @@ -114,7 +114,7 @@ SSH 提供了多样的转义字符功能. 用 SSH 连接到任意一台远程主 ### 总结 ### -通过以上的内容你应该可以很轻松的使用 SSH 了. SSH 还有很多功能值得你去发掘, 这就要看你的想象力了. +通过以上的内容你应该可以轻松使用 SSH 了. SSH 还有很多功能值得你去发掘, 这就要看你的想象力了。 -------------------------------------------------------------------------------- @@ -123,7 +123,7 @@ via: http://linoxide.com/linux-command/pocket-guide-linux-ssh-command/ 作者:[Bobbin Zachariah][a] 译者:[henryfour](https://github.com/henryfour) -校对:[校对者ID](https://github.com/校对者ID) +校对:[Caroline](https://github.com/carolinewuyan) 本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 diff --git a/published/20140819 KDE Plasma 5--For those Linux users undecided on the kernel' s future.md b/published/201410/20140819 KDE Plasma 5--For those Linux users undecided on the kernel' s future.md similarity index 100% rename from published/20140819 KDE Plasma 5--For those Linux users undecided on the kernel' s future.md rename to published/201410/20140819 KDE Plasma 5--For those Linux users undecided on the kernel' s future.md diff --git a/published/20140819 Linux Systemd--Start or Stop or Restart Services in RHEL or CentOS 7.md b/published/201410/20140819 Linux Systemd--Start or Stop or Restart Services in RHEL or CentOS 7.md similarity index 100% rename from published/20140819 Linux Systemd--Start or Stop or Restart Services in RHEL or CentOS 7.md rename to published/201410/20140819 Linux Systemd--Start or Stop or Restart Services in RHEL or CentOS 7.md diff --git a/published/201410/20140822 15 Practical Examples of 'cd' Command in Linux.md b/published/201410/20140822 15 Practical Examples of 'cd' Command in Linux.md new file mode 100644 index 0000000000..f48815397b --- /dev/null +++ b/published/201410/20140822 15 Practical Examples of 'cd' Command in Linux.md @@ -0,0 +1,155 @@ +15个关于Linux的‘cd’命令的练习例子 +=========================== + +在Linux中,**‘cd‘(改变目录)**命令,是对新手和系统管理员来说,最重要最常用的命令。对管理无图形界面的服务器的管理员,‘**cd**‘是进入目录,检查日志,执行程序/应用软件/脚本和其余每个任务的唯一方法。对新手来说,是他们必须自己动手学习的最初始命令 + +![15 cd command examples in linux](http://www.tecmint.com/wp-content/uploads/2014/08/cd-command-in-linux.png) + +*Linux中15个cd命令举例* + +所以,请用心学习,我们在这会带给你**15**个基础的‘**cd**‘命令,它们富有技巧和捷径,学会使用这些了解到的技巧,会大大减少你在终端上花费的努力和时间 + +### 课程细节 ### + +- 命令名称:cd +- 代表:切换目录 +- 使用平台:所有Linux发行版本 +- 执行方式:命令行 +- 权限:访问自己的目录或者其余指定目录 +- 级别:基础/初学者 + +1. 从当前目录切换到/usr/local + + avi@tecmint:~$ cd /usr/local + avi@tecmint:/usr/local$ + +2. 使用绝对路径,从当前目录切换到/usr/local/lib + + avi@tecmint:/usr/local$ cd /usr/local/lib + avi@tecmint:/usr/local/lib$ + +3. 使用相对路径,从当前路径切换到/usr/local/lib + + avi@tecmint:/usr/local$ cd lib + avi@tecmint:/usr/local/lib$ + +4. **(a)**切换当前目录到上级目录 + + avi@tecmint:/usr/local/lib$ cd - + /usr/local + avi@tecmint:/usr/local$ + + **(b)**切换当前目录到上级目录 + + avi@tecmint:/usr/local/lib$ cd .. + avi@tecmint:/usr/local$ + +5. 显示我们最后一个离开的工作目录(使用‘-’选项) + + avi@tecmint:/usr/local$ cd -- + /home/avi + +6. 从当前目录向上级返回两层 + + avi@tecmint:/usr/local$ cd ../../ + avi@tecmint:/$ + +7. 从任何目录返回到用户home目录 + + avi@tecmint:/usr/local$ cd ~ + avi@tecmint:~$ + + 或 + + avi@tecmint:/usr/local$ cd + avi@tecmint:~$ + +8. 切换工作目录到当前工作目录(LCTT:这有什么意义嘛?!) + + avi@tecmint:~/Downloads$ cd . + avi@tecmint:~/Downloads$ + + 或 + + avi@tecmint:~/Downloads$ cd ./ + avi@tecmint:~/Downloads$ + +9. 你当前目录是“/usr/local/lib/python3.4/dist-packages”,现在要切换到“/home/avi/Desktop/”,要求:一行命令,通过向上一直切换直到‘/’,然后使用绝对路径 + + avi@tecmint:/usr/local/lib/python3.4/dist-packages$ cd ../../../../../home/avi/Desktop/ + avi@tecmint:~/Desktop$ + +10. 从当前工作目录切换到/var/www/html,要求:不要将命令打完整,使用TAB + + avi@tecmint:/var/www$ cd /v/w/h + avi@tecmint:/var/www/html$ + +11. 从当前目录切换到/etc/v__ _,啊呀,你竟然忘了目录的名字,但是你又不想用TAB + + avi@tecmint:~$ cd /etc/v* + avi@tecmint:/etc/vbox$ + + **请注意:**如果只有一个目录以‘**v**‘开头,这将会移动到‘**vbox**‘。如果有很多目录以‘**v**‘开头,而且命令行中没有提供更多的标准,这将会移动到第一个以‘**v**‘开头的目录(按照他们在标准字典里字母存在的顺序) + +12. 你想切换到用户‘**av**‘(不确定是avi还是avt)目录,不用**TAB** + + avi@tecmint:/etc$ cd /home/av? + avi@tecmint:~$ + +13. Linux下的pushed和poped + + Pushed和poped是Linux bash命令,也是其他几个能够保存当前工作目录位置至内存,并且从内存读取目录作为当前目录的脚本,这些脚本也可以切换目录 + + avi@tecmint:~$ pushd /var/www/html + /var/www/html ~ + avi@tecmint:/var/www/html$ + + 上面的命令保存当前目录到内存,然后切换到要求的目录。一旦poped被执行,它会从内存取出保存的目录位置,作为当前目录 + + avi@tecmint:/var/www/html$ popd + ~ + avi@tecmint:~$ + +14. 切换到名字带有空格的目录 + + avi@tecmint:~$ cd test\ tecmint/ + avi@tecmint:~/test tecmint$ + + 或 + + avi@tecmint:~$ cd 'test tecmint' + avi@tecmint:~/test tecmint$ + + 或 + + avi@tecmint:~$ cd "test tecmint"/ + avi@tecmint:~/test tecmint$ + +15. 从当前目录切换到下载目录,然后列出它所包含的内容(使用一行命令) + + avi@tecmint:/usr$ cd ~/Downloads && ls + ... + . + service_locator_in.xls + sources.list + teamviewer_linux_x64.deb + tor-browser-linux64-3.6.3_en-US.tar.xz + . + ... + +我们尝试使用最少的词句和一如既往的友好,来让你了解Linux的工作和执行 + +这就是所有内容。我很快会带着另一个有趣的主题回来的。 + +--- + +via: http://www.tecmint.com/cd-command-in-linux/ + +作者:[Avishek Kumar][a] +译者:[su-kaiyao](https://github.com/su-kaiyao) +校对:[wxy](https://github.com/wxy) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://www.tecmint.com/author/avishek/ + diff --git a/published/201410/20140825 China Will Change The Way All Software Is Bought And Sold.md b/published/201410/20140825 China Will Change The Way All Software Is Bought And Sold.md new file mode 100644 index 0000000000..dfb76eaa6d --- /dev/null +++ b/published/201410/20140825 China Will Change The Way All Software Is Bought And Sold.md @@ -0,0 +1,67 @@ +中国将要改变软件购买和销售的方式 +================================================================================ +![](http://a5.files.readwrite.com/image/upload/c_fill,h_900,q_70,w_1600/MTE5NDg0MDYyMzQ4MzE0MTI3.jpg) + +> 这一切都是关于“开源”. + +**中国并不需要你,也不需要你的软件。具体说来,中国市场并不需要你的工程师日以继夜的工作,也不需要你提供的任何东西。 + +中国每年会产生超过100000名新软件工程师。这些工程师会写出一大批令人惊叹的奇妙软件。如果有中国市场上尚未出现的软件,中国的工程师们就会从国外“借鉴”。在2012年,这样的软件掠夺达到了77%之多。对于那些已经面对着开源和云服务的挑战的西方软件卖家来说,中国无疑让他们的日子更苦难了。 + +不止是更困难,简直是举步维艰。 + +中国正在挑战西方公司在中国及其他地区的赚钱模式。对于那些已经明白如何在中国运营的公司来说,他们的未来看起来一片光明。 + +### 抵制中国模式 ### + +当然,并非每家公司都会坐以待毙。以微软为例,微软已经通过[行使美国的国家司法权力来禁止中国公司做生意][1]——除非他们向微软购买许可证。这是一种很聪明的做法,而且它可能会为微软创造数十亿美元的价值,但是最终这一做法看起来与中国市场格格不入。 + +原因很简单,中国与微软对待知识产权的态度十分不同。 + +正如 [我所提到的][2],“与同在亚洲的印度十分相似,中国的企业更倾向于购买复杂的、面向企业的软件。因为这种软件比服务大众的公司开发出来的更为先进。”但这种形势不会持续太久,因为中国的软件产业正在以一种惊人的速度前进,并毫无颓势。中国将会坚持向西方国家“借鉴”代码,直到有一天有足够的能力可以创造出创新性的软件。 + +但即使到那时候,中国的软件公司与美国软件的运营模式还是有所不同,美国的软件大多都已经捆绑在设备、架构在云端或者公司只靠提供软件支持而盈利。而这些运营模式都是无法克隆的。 + +不出所料,接下来的问题将是,这些公司将如何通过“开源”来盈利。 + +### 开源化中国 ### + +正如CCID的分析师在 [J. Aaron Farr 的关于中国开源化报告][3] 中指出的,中国的开源社区规模很小而且没什么影响力。开源社区中缺少大项目、参与者稀少而且资金匮乏。 + +这真是个坏消息。 + +而好消息是,华为等公司将开源视为一种战略前景。具体而言,当[华为的开源项目网页][4]过时或疲软之时,就间接显示出了技术大步伐的前进方向。在与参与了开源项目的华为公司内部顾问的谈话中,虽然华为对如何参与到开源社区还处于摸索阶段,但他们总是对华为的开源项目赞不绝口。 + +这看起来并不容易坚持长久。 + +从一件事就可以看出端倪。中国最大的互联网公司们都纷纷以积极地姿态拥抱开源,这意味着中国开源时代的到来。你若是和任意一位在百度、阿里巴巴、微博的员工谈话,你会发现他们的软件项目都是彻底开源的。这些开源的软件都是运行在这些公司自己研发的硬件上而不是西方的硬件上。 + +换句话说,这样的模式已经和美国及西欧的运营模式如出一辙了。 + +抬头看看 [现金软件行业内最炙手可热的新公司][5], 你就会知道中国的互联网公司未来的主流趋势,正如发生在西方世界的一样。不出意料的,许多都是关于“开源”。 + +### 销售给中国 ### + +所有的一切都表明中国的软件行业不会像美国的软件行业发展历史一般发展。中国不会产生在柜台上卖卖软件就赚上亿美元的公司。因为西方对于知识产权的观念无法简单适用于中国的科技经济。 + +所以,商家们需要售卖比软件更丰富的产品。云服务是一大前景。硬件设施看起来也是前途璀璨。软件支持和咨询服务(虽然有一些非主流)也很被公司门看好。总而言之,中国的软件行业将会充满开源味道,而不能靠着简单的售卖专柜软件的形式赚钱。 + +图片由 [hackNY.org][6] 提供。 + +-------------------------------------------------------------------------------- + +原文: http://readwrite.com/2014/08/12/china-opensource-software-ip-programmers-united-states + +作者:[Matt Asay][a] +译者:[chi1shi2](https://github.com/chi1shi2) +校对:[reinoir](https://github.com/reinoir) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://readwrite.com/author/matt-asay +[1]:http://readwrite.com/2014/03/17/microsoft-anti-piracy-strategy-china +[2]:http://readwrite.com/2014/04/11/india-starts-paying-for-software-china-it +[3]:http://cdn.oreillystatic.com/en/assets/1/event/12/Open%20Source%20in%20China%20Presentation%201.pdf +[4]:http://huawei.com/en/about-huawei/Partner/openathuawei/index.htm +[5]:http://codingvc.com/which-technologies-do-startups-use-an-exploration-of-angellist-data +[6]:https://www.flickr.com/photos/hackny/8675057448/ \ No newline at end of file diff --git a/translated/tech/20140825 Linux FAQs with Answers--How to enable Nux Dextop repository on CentOS or RHEL.md b/published/201410/20140825 Linux FAQs with Answers--How to enable Nux Dextop repository on CentOS or RHEL.md similarity index 82% rename from translated/tech/20140825 Linux FAQs with Answers--How to enable Nux Dextop repository on CentOS or RHEL.md rename to published/201410/20140825 Linux FAQs with Answers--How to enable Nux Dextop repository on CentOS or RHEL.md index 3a7ddec920..5b8dc539ea 100644 --- a/translated/tech/20140825 Linux FAQs with Answers--How to enable Nux Dextop repository on CentOS or RHEL.md +++ b/published/201410/20140825 Linux FAQs with Answers--How to enable Nux Dextop repository on CentOS or RHEL.md @@ -1,4 +1,4 @@ -Linux FAQ -- 如何在CentOS或者RHEL上启用Nux Dextop仓库 +Linux有问必答:如何在CentOS或者RHEL上启用Nux Dextop仓库 ================================================================================ > **问题**: 我想要安装一个在Nux Dextop仓库的RPM包。我该如何在CentOS或者RHEL上设置Nux Dextop仓库? @@ -6,7 +6,7 @@ Linux FAQ -- 如何在CentOS或者RHEL上启用Nux Dextop仓库 要在CentOS或者RHEL上启用Nux Dextop,遵循下面的步骤。 -首先,要理解Nux Dextop被设计与EPEL仓库共存。因此,你需要使用Nux Dexyop仓库前先[启用 EPEL][2]。 +首先,要知道Nux Dextop被设计与EPEL仓库共存。因此,你需要在使用Nux Dexyop仓库前先[启用 EPEL][2]。 启用EPEL后,用下面的命令安装Nux Dextop仓库。 @@ -26,13 +26,13 @@ Linux FAQ -- 如何在CentOS或者RHEL上启用Nux Dextop仓库 ### 对于 Repoforge/RPMforge 用户 ### -据作者所说,Nux Dextop目前所知会与其他第三方库比如Repoforge和ATrpms相冲突。因此,如果你启用了除了EPEL的其他第三方库,强烈建议你将Nux Dextop仓库设置成“default off”(默认关闭)状态。就是用文本编辑器打开/etc/yum.repos.d/nux-dextop.repo,并且在nux-desktop下面将"enabled=1" 改成 "enabled=0"。 +据作者所说,目前已知Nux Dextop会与其他第三方库比如Repoforge和ATrpms相冲突。因此,如果你启用了除了EPEL的其他第三方库,强烈建议你将Nux Dextop仓库设置成“default off”(默认关闭)状态。就是用文本编辑器打开/etc/yum.repos.d/nux-dextop.repo,并且在nux-desktop下面将"enabled=1" 改成 "enabled=0"。 -$ sudo vi /etc/yum.repos.d/nux-dextop.repo + $ sudo vi /etc/yum.repos.d/nux-dextop.repo ![](https://farm6.staticflickr.com/5560/14789955930_f8711b3581_z.jpg) -当你无论何时从Nux Dextop仓库安装包时,显式地用下面的命令启用仓库。 +无论何时当你从Nux Dextop仓库安装包时,显式地用下面的命令启用仓库。 $ sudo yum --enablerepo=nux-dextop install @@ -41,7 +41,7 @@ $ sudo vi /etc/yum.repos.d/nux-dextop.repo via: http://ask.xmodulo.com/enable-nux-dextop-repository-centos-rhel.html 译者:[geekpi](https://github.com/geekpi) -校对:[校对者ID](https://github.com/校对者ID) +校对:[ wxy](https://github.com/wxy) 本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 diff --git a/translated/tech/20140825 Linux FAQs with Answers--How to fix 'failed to run aclocal--No such file or directory'.md b/published/201410/20140825 Linux FAQs with Answers--How to fix 'failed to run aclocal--No such file or directory'.md similarity index 90% rename from translated/tech/20140825 Linux FAQs with Answers--How to fix 'failed to run aclocal--No such file or directory'.md rename to published/201410/20140825 Linux FAQs with Answers--How to fix 'failed to run aclocal--No such file or directory'.md index f995f2203f..63ce6a4862 100644 --- a/translated/tech/20140825 Linux FAQs with Answers--How to fix 'failed to run aclocal--No such file or directory'.md +++ b/published/201410/20140825 Linux FAQs with Answers--How to fix 'failed to run aclocal--No such file or directory'.md @@ -1,4 +1,4 @@ -Linux有问必答——如何修复“运行aclocal失败:没有该文件或目录” +Linux有问必答:如何修复“运行aclocal失败:没有该文件或目录” ================================================================================ > **问题**:我试着在Linux上构建一个程序,该程序的开发版本是使用“autogen.sh”脚本进行的。当我运行它来创建配置脚本时,却发生了下面的错误: > @@ -24,7 +24,7 @@ Linux有问必答——如何修复“运行aclocal失败:没有该文件或 via: http://ask.xmodulo.com/fix-failed-to-run-aclocal.html 译者:[GOLinux](https://github.com/GOLinux) -校对:[校对者ID](https://github.com/校对者ID) +校对:[wxy](https://github.com/wxy) 本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 diff --git a/published/20140825 Linux Terminal--speedtest_cli checks your real bandwidth speed.md b/published/201410/20140825 Linux Terminal--speedtest_cli checks your real bandwidth speed.md similarity index 100% rename from published/20140825 Linux Terminal--speedtest_cli checks your real bandwidth speed.md rename to published/201410/20140825 Linux Terminal--speedtest_cli checks your real bandwidth speed.md diff --git a/published/20140826 Linus Torvalds is my hero, says 13 year old Zachary DuPont.md b/published/201410/20140826 Linus Torvalds is my hero, says 13 year old Zachary DuPont.md similarity index 100% rename from published/20140826 Linus Torvalds is my hero, says 13 year old Zachary DuPont.md rename to published/201410/20140826 Linus Torvalds is my hero, says 13 year old Zachary DuPont.md diff --git a/published/20140828 GIMP 2.8.12 Released--Here' s How to Install it on Ubuntu.md b/published/201410/20140828 GIMP 2.8.12 Released--Here' s How to Install it on Ubuntu.md similarity index 100% rename from published/20140828 GIMP 2.8.12 Released--Here' s How to Install it on Ubuntu.md rename to published/201410/20140828 GIMP 2.8.12 Released--Here' s How to Install it on Ubuntu.md diff --git a/published/201410/20140829 Linux Doesn't Need to Own the Desktop.md b/published/201410/20140829 Linux Doesn't Need to Own the Desktop.md new file mode 100644 index 0000000000..4011fefb74 --- /dev/null +++ b/published/201410/20140829 Linux Doesn't Need to Own the Desktop.md @@ -0,0 +1,32 @@ +Linux 应当放弃桌面 +================================================================================ +Linus Torvalds 前不久发布了 Linux 3.17 rc-2,这[偏离了他正常的发布时间表][1],因为8月25日是 Linux 的第23个生日。“Hello 大家好,你还在使用minix吗?”,23年前的8月25日,Torvalds 在 Linux 的第一次发布中这样写道。 + +与此同时,最近 PCMag.com 网站声称[Linux 的时间已经不多了][2]。但是你们不觉得这样没玩没了地讨论 Linux 在桌面端是否成功其实是毫无意义的吗?Linux 已经广泛应用于超级计算机和车载系统,它构建了 Android 的基础,同时还是最流行的云整合(例如 OpenStack)的运行平台 —— 以上这些还只是 Linux 的一部分成就。桌面并不是 Linux 唯一的战场。 + +Jon Buys 在他[最近的文章][3]中谈到了 Linux 专业化以及与桌面有关的内容: + +> “最近,IT业在追问‘[Linus 是否还在执著于 Linux 桌面?][4]’,来自 Teck Republic 的 Matt Asay 也在说‘[拜托不要再讨论 Linux 桌面了行吗?][5]’。这两篇文章都对 Linux 在个人计算机方面的发展空间持怀疑态度,还拿 Android 的成功故事来说事…… 但是它们都忽略了,Linux的灵活性以及它开源许可证的开放性,也许这两者正是拯救 Linux 桌面的关键。” + +也许这是事实,但是 Linux 对于如此众多的桌面用户来说,还是太多余了。Linux 分享庞大市场的最佳机会已经来也匆匆去也匆匆了。 + +事实其实很简单,Linux已经改变了世界,获得了无与伦比的成功 —— 除了桌面系统,这毋庸置疑。Android已经不仅仅是一个基于Linux的平台,它已经成为了一个伟大的标志。Linux在服务器端和嵌入式技术领域占有巨大的份额,同时也为平台整合方面不断提供创新动力。Ubuntu已经成为部署搭建 OpenStack 最流行的平台。全世界的超级计算机都运行着 Linux,Chrome OS 也是基于 Linux。 + +因此,Linux 正在不断推动着整个世界的巨变,批评家们是时候停下来执著于 Linux 在桌面端的状态了。 + +-------------------------------------------------------------------------------- + +via: http://ostatic.com/blog/linux-doesnt-need-to-own-the-desktop + +作者:[Sam Dean][a] +译者:[Mr小眼儿](http://blog.csdn.net/tinyeyeser) +校对:[wxy](https://github.com/wxy) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://ostatic.com/member/samdean +[1]:http://www.theregister.co.uk/2014/08/26/linux_turns_23_and_linus_torvalds_celebrates_as_only_he_can/ +[2]:http://www.pcmag.com/article2/0,2817,2465125,00.asp +[3]:http://ostatic.com/blog/specialization-and-the-linux-desktop +[4]:http://www.itworld.com/open-source/432816/does-it-still-make-sense-linus-want-desktop-linux +[5]:http://www.techrepublic.com/article/can-we-please-stop-talking-about-the-linux-desktop/ \ No newline at end of file diff --git a/published/20140901 Awesome systemd Commands to Manage Linux System.md b/published/201410/20140901 Awesome systemd Commands to Manage Linux System.md similarity index 100% rename from published/20140901 Awesome systemd Commands to Manage Linux System.md rename to published/201410/20140901 Awesome systemd Commands to Manage Linux System.md diff --git a/published/20140901 Remarkable--A New MarkDown Editor For Linux.md b/published/201410/20140901 Remarkable--A New MarkDown Editor For Linux.md similarity index 100% rename from published/20140901 Remarkable--A New MarkDown Editor For Linux.md rename to published/201410/20140901 Remarkable--A New MarkDown Editor For Linux.md diff --git a/published/20140901 Ubuntu Wallpaper Contest Closes, These Are Our 8 Faves.md b/published/201410/20140901 Ubuntu Wallpaper Contest Closes, These Are Our 8 Faves.md similarity index 100% rename from published/20140901 Ubuntu Wallpaper Contest Closes, These Are Our 8 Faves.md rename to published/201410/20140901 Ubuntu Wallpaper Contest Closes, These Are Our 8 Faves.md diff --git a/published/201410/20140902 Happy Birthday Email.md b/published/201410/20140902 Happy Birthday Email.md new file mode 100644 index 0000000000..6d8256419a --- /dev/null +++ b/published/201410/20140902 Happy Birthday Email.md @@ -0,0 +1,25 @@ +他发明了 Email ? +================================================================================ +[编者按:本文所述的 Email 发明人的观点存在很大的争议,请读者留意,以我的观点来看,其更应该被称作为某个 Email 应用系统的发明人,其所发明的一些功能和特性,至今沿用。——wxy] + +**一个印度裔美国人用他天才的头脑发明了电子邮件,而从此以后我们没有哪一天可以离开电子邮件。** + +![](http://1-ps.googleusercontent.com/h/www.efytimes.com/admin/useradmin/photo/150x150xDbOx104130AM8312014.jpg.pagespeed.ic.QJJxt_P8uE.jpg) + +8月30日,电子邮件满32岁了。现在让我们一起熟悉一下这个快捷迅速的信息传递方式是怎么诞生的。这要感谢以为印度裔美国人,Shiva Ayyadurai。Shiva开发了一个全功能的办公室间邮件系统软件并命名为email。 + +在1982年8月30日,他被美国政府正式承认作为这个电脑程序的发明者。Shiva生于孟买的一个泰米尔家庭,发明email系统的时候只有14岁。当时他还在新泽西的利文斯顿高中学习,并开始为新泽西牙科和医科大学开发这个系统。email系统被授予版权,因为当时还没有其他方式被用来保护软件发明。 + +Ayyadurai从日常办公室之间的内部邮件往来方式里找到email系统的点子。他尝试复制普遍用来传送办公室之间邮件的‘气动管道系统’。这个系统使用了一个物理的管道网络来传送打印好的邮件给秘书。每一位秘书都有收件箱,发件箱,草稿箱,复写纸,文件夹,地址本,别针,或是附件等等。所有这些都用作建立和处理接收和发送邮件。 + +Shiva也记下了一些常用的模板,像“发给”,“来自”,“主题”,“日期”,“正文”,“抄送”,“密送”等等。所有这些模版也都被纳入电子邮件的版本中。电子邮件系统是用FORTRAN编程语言写的,Shiva发明了一个同样系统的电子版本。因为这件非凡的作品,Shiva获得了无数嘉奖,也赢得了1981年度高中毕业生的西屋科学天才奖。如今,由史密森学会美国历史国家博物馆持有“Email”的正式美国版权。但是,也有争论说不是Ayyadurai而是其他什么人发明了email。 + +-------------------------------------------------------------------------------- + +via: http://www.efytimes.com/e1/fullnews.asp?edid=147170 + +作者:Sanchari Banerjee +译者:[zpl1025](https://github.com/zpl1025) +校对:[wxy](https://github.com/wxy) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 diff --git a/published/201410/20140902 How to share on linux the output of your shell commands.md b/published/201410/20140902 How to share on linux the output of your shell commands.md new file mode 100644 index 0000000000..f077f36895 --- /dev/null +++ b/published/201410/20140902 How to share on linux the output of your shell commands.md @@ -0,0 +1,111 @@ +如何在linux上分享你shell命令的输出 +================================================================================ +前段时间我发布了一篇关于[shelr.tv][1]这个网站的文章,它提供一个服务允许你从网站上直接分享你的[终端][2]记录。 + +现在shelr.tv这个网站似乎关闭了,然后我四处寻找是否有类似的网站,于是我发现了[commands.com][3]。 + +从它的主页上来看,它的服务和其他网站提供的服务是类似的,因此让我们来测试它。 + +### 步骤 1 – 在网站上注册 ### + +只需要[注册][4]一个新的 用户名/密码,或者直接使用你的github账户快速登录。 + +### 步骤 2 – 下载安装monitor程序 ### + +[Monitor][5]是一个命令行工具,它能捕获命令行的输入输出并且发送到commands.com网站上,这个程序是开源的,并托管在github上。 + +Monitor使得仓库的设置/安装变得更简单。通过它,你能方便地向人们展示最常见的错误与命令的输出。 + +简而言之,你能方便地和世界分享你的命令及其输出。 + +通过如下简单几步来安装它: + +1) 克隆github上的这个项目的仓库,这样你能获得最新的源代码。 + +要完成这步,你需要在系统中已经安装了git命令,如果你得到关于这个命令的报错信息,你可以使用包管理工具来安装它,例如: + +基于Debian的发布版: + + apt-get install git + +Redhat/Centos/Fedora发布版: + + yum install git + +现在从终端克隆这个仓库: + + git clone https://github.com/dtannen/monitor.git + +2) 安装readline和curl,这些库是通过源码构建程序的先决条件: + +基于Debian的发布版: + + apt-get install libreadline-dev libcurl4-openssl-dev + +Redhat/Centos/Fedora发布版: + + yum install readline-devel curl-devel + +3) 构建程序: + +要完成这步,你必须进入刚刚用git克隆的目录,然后编译这个c程序: + + cd monitor + make + sudo make install + +默认安装将把二进制文件放入/usr/local/bin目录下。 + +![](http://cdn.linuxaria.com/wp-content/uploads/2014/08/commands.png) + +### 步骤 3 – 使用monitor命令### + +monitor命令特别简单易用: + + monitor {-d} {-h} {-u } + + -d : 不删除/tmp下的文件 + -h : 帮助 + -u : commands.com用户名 + +要退出monitor程序,需要按ctrl-c。 + +对我来说这仅仅意味着打开一个终端然后执行这些命令: + + riccio@mint-desktop ~ $ monitor -u ricciocri + Password: + + Successfully logged in... + AuthKey saved to /tmp/.riccio.commands.com. Delete file to return to Anonymous posting. + monitor$ cd /tmp + ... + +想知道在这之后我使用过的哪个命令吗?我已经把这个会话公开(默认是私有),因此你可以去这个url查看:[https://commands.com/JTNSHRLQJA][6] + +在这里,你能看我已经使用过的命令以及它们的输出,一个有趣的选项是“fold/expand”你可以折叠(fold)所有的命令的输出或者仅仅展开(expand)你喜欢的那个命令的输出。 + +### 总结 ### + +这只是一个简单的安装指南,在这个网站上你能参加更多“社会化”的活动,比如评论脚本/shell会话,派生它们或者选择你的最爱。 + +和github一样,你能派生任何一个公开的脚本/命令并能直接在网站上改变它,然后你也能得到一个公开(或私有)的url。你可以直接运行你脚本,就像这样: + + curl commands.io/JTNSHRLQJA | sh + +在网络上储存一些你在电脑/服务器上经常使用到的脚本,这是极好的,通常不要放置任何密码或敏感信息,这样你的信息才足够安全。 + +-------------------------------------------------------------------------------- + +via: http://linuxaria.com/article/how-to-share-on-linux-the-output-of-your-shell-commands + +译者:[guodongxiaren](https://github.com/guodongxiaren) +校对:[Caroline](https://github.com/carolinewuyan) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[1]:http://linuxaria.com/recensioni/shelr-broadcast-your-linux-shell-on-the-net +[2]:http://linuxaria.com/tag/shell +[3]:https://commands.com/ +[4]:https://commands.com/Register/Index +[5]:https://github.com/dtannen/monitor +[6]:https://commands.com/JTNSHRLQJA diff --git a/published/20140902 Use SearchMonkey To Search Text In All Files Within A Directory In Ubuntu.md b/published/201410/20140902 Use SearchMonkey To Search Text In All Files Within A Directory In Ubuntu.md similarity index 100% rename from published/20140902 Use SearchMonkey To Search Text In All Files Within A Directory In Ubuntu.md rename to published/201410/20140902 Use SearchMonkey To Search Text In All Files Within A Directory In Ubuntu.md diff --git a/published/201410/20140904 The Masked Avengers.md b/published/201410/20140904 The Masked Avengers.md new file mode 100644 index 0000000000..8d81cf3188 --- /dev/null +++ b/published/201410/20140904 The Masked Avengers.md @@ -0,0 +1,377 @@ +

戴着面具的复仇者 —— 揭秘:激进黑客组织“匿名者”

+ +
从“突尼斯政变”到“弗格森枪击事件”,“匿名者”组织是如何煽动起网络示威活动的。
+ +
+ +
通过入会声明,任何人都能轻易加入“匿名者”组织。某人类学家称,组织成员会“根据影响程度对重大事件保持着不同关注,特别是那些能挑起强烈争端的事件”。
+ +纸雕作品:Jeff Nishinaka / 摄影:Scott Dunbar + +

1

+ +

上世纪七十年代中期,当 Christopher Doyon 还是一个生活在缅因州乡村的孩童时,就终日泡在 CB radio 上与各种陌生人聊天。他的昵称是“Big red”(大红),因为他有一头红色的头发。Christopher Doyon 把发射机挂在了卧室的墙壁上,并且说服了父亲在自家屋顶安装了两根天线。CB radio 主要用于卡车司机间的联络,但 Doyon 和一些人却将之用于不久后出现在 Internet 上的虚拟社交——自定义昵称、成员间才懂的笑话,以及施行变革的强烈愿望。

+ +

Doyon 很小的时候母亲就去世了,兄妹二人由父亲抚养长大,他俩都说受到过父亲的虐待。由此 Doyon 在 CB radio 社区中找到了慰藉和目标感。他和他的朋友们轮流监听当地紧急事件频道。其中一个朋友的父亲买了一个气泡灯并安装在了他的车顶上;每当这个孩子收听到来自孤立无援的乘车人的求助后,都会开车载着所有人到求助者所在的公路旁。除了拨打 911 外他们基本没有什么可做的,但这足以让他们感觉自己成为了英雄。

+ +

短小精悍的 Doyon 有着一口浓厚的新英格兰口音,并且非常喜欢《星际迷航》和阿西莫夫的小说。当他在《大众机械》上看到一则“组装你的专属个人计算机”构件广告时,就央求祖父给他买一套,接下来 Doyon 花了数月的时间把计算机组装起来并连接到 Internet 上去。与鲜为人知的 CB 电波相比,在线聊天室确实不可同日而语。“我只需要点一下按钮,再选中某个家伙的名字,然后我就可以和他聊天了,” Doyon 在最近回忆时说道,“这真的很惊人。”

+ +

十四岁那年,Doyon 离家出走,两年后他搬到了马萨诸塞州的剑桥,那里是一个新出现的计算机反主流文化的中心。同一时间,早在 34 年前就已由麻省理工学院的铁路狂热爱好者们创立的铁路模型技术俱乐部,已经演变成了“黑客”——也是推广该词的第一个组织。Richard Stallman,在那时还是一名任职于麻省理工学院人工智能实验室的计算机科学家,指出早期黑客们比起引发技术战争更乐于讨论“哥德尔、艾舍尔、巴赫”之类的话题。“我们没有任何约束”,Stallman 说,“这不是一项运动,而是一种可以让人们相互留下深刻印象的行为。”其中有些“行为”很有趣(制作电子游戏);有些非常实用(提高计算机处理速度);还有些则属于发生在真实世界里的恶作剧(在校园内放置模拟街道标识)。Michael Patton,在七十年代里管理着铁路模型技术俱乐部的人,谈起初代黑客间不成文的规定,说第一条就是“不要搞破坏”。

+ +

在剑桥,Doyon 以打零工和乞讨为生,他宁愿为了自由而睡在公园的长椅上,也不愿被单调的固定工作所束缚。1985 年,他和其他六个活跃分子共同组建了一支电子“义勇军”。模仿“动物解放阵线”,他们称呼自己为“人民解放阵线”(Peoples Liberation Front,PLF)。所有人都使用化名:如组织的创建者,声称自己是老兵的一位高大中年男子,自称“Commander Adama”;Doyon 则选择了“Commander X”这个称呼。受 “Merry Pranksters” 启示,他们在 Grateful Dead 的演唱会上出售 LSD(lysergic acid diethylamide,麦角酸酰二乙胺,一种迷幻药),并用收入的一部分购置了一辆二手校车,以及扩音器、相机,还有电源充电器。同时在剑桥租了一间地下公寓,Doyon 偶尔会在那里歇息。

+ +

Doyon 深深地沉溺于计算机中,虽然他并不是一位专业的程序员。在过去一年的几次谈话中,他告诉我他将自己视为激进主义分子,继承了 Abbie Hoffman 和 Eldridge Cleaver 的激进传统;技术不过是他抗议的工具。八十年代,哈佛大学和麻省理工学院的学生们举行集会,强烈抗议他们的学校从南非撤资。为了帮助抗议者通过安全渠道进行交流,PLF 制作了无线电套装:移动调频发射器、伸缩式天线,还有麦克风,所有部件都内置于背包内。Willard Johnson,麻省理工学院的一位激进分子和政治学家,表示黑客们出席集会并不意味着一次变革。“我们的大部分工作仍然是通过扩音器来完成的,”他解释道。

+ +

1992 年,在印第安纳的一场 Grateful Dead 的演唱会上,Doyon 秘密地向一位瘾君子出售了 300 粒药。由此他被判决在印第安纳州立监狱服役十二年,后来改为五年。服役期间,他对宗教和哲学产生了浓厚的兴趣,并于鲍尔州立大学学习了相应课程。

+ +

1994 年,第一款商业 Web 浏览器 Netscape Navigator(网景领航员)正式发布,同一年 Doyon 被捕入狱。当他出狱并再次回到剑桥后,PLF 依然活跃着,并且他们的工具有了实质性的飞跃。Doyon 回忆起他和入狱之前对比的变化,“非常巨大——好比是‘烽火狼烟’跟‘电报传信’之间那么大的差距。”黑客们入侵了一个印度的军事网站,并修改其首页文字为“拯救克什米尔”。在塞尔维亚,黑客们攻陷了一个阿尔巴尼亚网站。Stefan Wray,一位早期网络激进主义分子,为一次纽约“反哥伦布日”集会上的黑客行径辩护。“我们视之为电子形式的公众抗议,”他告诉大家。

+ +

1999 年,美国唱片业协会因为版权侵犯问题起诉了 Napster,一款文件共享服务。最终,Napster 于 2001 年关闭。Doyon 与其他黑客使用分布式拒绝服务(Distributed Denial of Service,DDoS,使大量数据涌入网站导致其响应速度减缓直至奔溃)的手段,攻击了美国唱片业协会的网站,使之停运时间长达一星期之久。Doyon为自己的行为进行了辩解,并高度赞扬了其他的“黑客主义者”。“我们很快意识到保卫 Napster 的战争象征着保卫 Internet 自由的战争,”他在后来写道。

+ +

2008 年的一天,Doyon 和 “Commander Adama” 在剑桥的 PLE 地下公寓相遇。Adama 当着 Doyon 的面点击了癫痫基金会的一个链接,与意料中将要打开的论坛不同,出现的是一连串闪烁的彩光。有些癫痫病患者对闪光灯非常敏感——这完全是出于恶意,有人想要在无辜群众中诱发癫痫病。已经出现了至少一名受害者。

+ +

Doyon 愤怒了。他质问 Adama 什么样的人才会做出这样的事来。

+ +

“你听说过‘匿名者’组织吗?” Adama 问。

+ +

2

+ +

2003 年,一位来自纽约的已经患病 15 年的失眠症患者 Christopher Poole,推出了 4chan 讨论社区,在这里用户们可以随意发布照片或者尖锐评论。随后其关注点迅速从动漫延伸到许多 Internet 的早期文化基因,如:LOLcats、Chocolate Rain、RickRolls。当用户没有按照屏幕上的要求输入昵称时,将会得到系统默认的“匿名者”(Anonymous)称呼。

+ +
+ +
“我得谈谈我的感受。”
+ +

Poole 希望匿名这一举措可以延续社区的尖锐性因素。“我们无意参与理智的涉外事件讨论,”他在网站上写道。4chan 社区里最具价值的事之一便是寻求“挑起强烈的争端”(lulz),这个词源自缩写 LOL。Lulz 经常是通过分享幼稚的笑话或图片来实现的,其中大部分不是色情的就是下流的。其中最令人震惊的部分被贴在了网站的“/b/”版块上,这里的用户们称呼自己为“/b/tards”。Doyon 知道 4chan 这个社区,但他认为它的用户是“一群愚昧无知的顽童”。2004 年前后,/b/ 上的部分用户开始把“匿名者”视为一个独立的实体。

+ +

这是一个全新的黑客团体。“这不是一个传统意义上的组织,”一位领导计算机安全工作的研究员 Mikko Hypponen 告诉我——倒不如,视之为一个非传统的亚文化群体。Barrett Brown,德克萨斯州的一名记者,同时也是众所周知的“匿名者”高层领导,把“匿名者”描述为“一连串前仆后继的伟大友谊”。无需任何会费或者入会仪式。任何想要加入“匿名者”组织,成为一名匿名者(Anon)的人,都可以通过简短的象征性的宣誓加入。

+ +

尽管 4chan 的关注焦点是一些琐碎的话题,但许多匿名者认为自己就是“正义的十字军”。如果网上有不良迹象出现,他们就会发起具有针对性的治安维护行动。不止一次,他们以未成年少女的身份使恋童癖陷入圈套,然后把他们的个人信息交给警察局。其他匿名者则是政治的厌恶者,为了挑起争端想方设法散布混乱的信息。他们中的一些人在 /b/ 上发布看着像是雷管炸弹的图片;另一些则叫嚣着要炸毁足球场并因此被联邦调查局逮捕。2007 年,一家洛杉矶当地的新闻联盟机构称呼“匿名者”组织为“互联网负能量制造机”。

+ +

2008 年 1 月,Gawker Media 上传了一段关于汤姆克鲁斯大力吹捧山达基优点的视频。这段视频是受版权保护的,山达基教会致信 Gawker,勒令其删除这段视频。“匿名者”组织认为教会企图控制网络信息。“是时候让 /b/ 来干票大的了,”有人在 4chan 上写道。“我说的是‘入侵’或者‘攻陷’山达基官方网站。”一位匿名者使用 YouTube 放出一段“新闻稿”,其中包括暴雨云视频和经过计算机处理的语音。“我们要立刻把你们从 Internet 上赶出去,并且在现有规模上逐渐瓦解山达基教会,”那个声音说,“你们无处可躲。”不到一个星期,这段 YouTube 视频的点击率就超过了两百万次。

+ +

“匿名者”组织已经不仅限于 4chan 社区。黑客们在专用的互联网中继聊天(Internet Relay Chat channels,IRC 聊天室)频道内进行交流,协商策略。通过 DDoS 攻击手段,他们使山达基的主网站间歇性崩溃了好几天。匿名者们制造了“谷歌炸弹”,由此导致 “dangerous cult” 的搜索结果中的第一条结果就是山达基主网站。其余的匿名者向山达基的欧洲总部寄送了数以百计的披萨,并用大量全黑的传真单耗干了洛杉矶教会总部的传真机墨盒。山达基教会,据报道是一个拥有超过十亿美元资产的组织,当然能经得起墨盒耗尽的考验。但山达基教会的高层可不这么认为,他们还收到了死亡恐吓,由此他们不得不向 FBI 申请调查“匿名者”组织的成员。

+ +

2008 年 3 月 15 日,在从伦敦到悉尼的一百多个城市里,数以千计匿名者们游行示威山达基教会。为了切合“匿名”这个主题,组织者下令所有的抗议者都应该佩戴相同的面具。深思熟虑过蝙蝠侠后,他们选定了 2005 年上映的反乌托邦电影《 V 字仇杀队》中 Guy Fawkes 的面具。“在每个大城市里都能以很便宜的价格大量购买,”广为人知的匿名者、游行组织者之一 Gregg Housh 告诉我说道。漫画式的面具上是一个的脸颊红润的男人,八字胡,有着灿烂的笑容。

+ +

匿名者们并未“瓦解”山达基教会。并且汤姆克鲁斯的那段视频任然保留在网络上。匿名者们证明了自己的顽强。组织选择了一个相当浮夸的口号:“我们是军团。绝不宽恕。永不遗忘。等待我们。”(We are Legion. We do not forgive. We do not forget. Expect us.)

+ +

3

+ +

2010 年,Doyon 搬到了加利福尼亚州的圣克鲁斯,并加入了当地的“和平阵营”组织。利用从木材堆置场偷来的木头,他在山上盖起了一间简陋的小屋,“借用”附近住宅的 WiFi,使用太阳能电池板发电,并通过贩卖种植的大麻换取现金。

+ +

与此同时,“和平阵营”维权者们每天晚上开始在公共场所休息,以此抗议圣克鲁斯政府此前颁布的“流浪者管理法案”,他们认为这项法案严重侵犯了流浪者的生存权。Doyon 出席了“和平阵营”的会议,并在网上发起了抗议活动。他留着蓬乱的红色山羊胡,戴一顶米黄色软呢帽,类似军服的服装。因此维权者们送给了他“罪恶制裁克里斯”的称呼。

+ +

“和平阵营”的成员之一 Kelley Landaker 曾几次和 Doyong 讨论入侵事宜。Doyon 有时会吹嘘自己的技术是多么的厉害,但作为一名资深程序员的 Landaker 却不为所动。“他说得很棒,但却不是行动派,”Landaker 告诉我。不过在那种场合下,的确更需要一位富有激情的领导者,而不是埋头苦干的技术员。“他非常热情并且坦率,”另一位成员 Robert Norse 如是对我说。“他创造出了大量的能够吸引媒体眼球的话题。我从事这行已经二十年了,在这一点上他比我见过的任何人都要厉害。”

+ +

Doyon 在 PLF 的上司,Commander Adama 仍然住在剑桥,并且通过电子邮件和 Doyon 保持着联络,他下令让 Doyon 监视“匿名者”组织,以此获知其运作方式,并伺机为 PLF 招募新成员。因为癫痫基金会网站入侵事件的那段不愉快回忆,Doyon 拒绝了 Adama。Adama 给 Doyon 解释说,在“匿名者”组织里不怀好意的黑客只占极少数,与此相反,这个组织经常会有一些的轰动世界举动。Doyon 对这点表示怀疑。“4chan 怎么可能会有轰动世界的大举动?”他质问道。但出于对 PLF 的忠诚,他还是答应了 Adama 的请求。

+ +

Doyon 经常带着一台宏基笔记本电脑出入于圣克鲁斯的一家名为 Coffee Roasting Company 的咖啡厅。“匿名者”组织的 IRC 聊天室主频道无需密码就能进入。Doyon 使用 PLF 的昵称进行登录并加入了聊天室。一段时间后,他发现了组织内大量的专用匿名者行动聊天频道,这些频道的规模更小,更多专门的组内匿名者间对话相互重复。要想参与行动,你必须知道行动的专用聊天频道名称,并且聊天频道随时会因为陌生的闯入者而进行变更。这套交流系统并不具备较高的安全系数,但它的确很凑效。“这些专用行动聊天频道确保了行动机密的高度集中”麦吉尔大学的人类学家 Gabriella Coleman 告诉我。

+ +

有些匿名者提议了一项行动,名为“反击行动”。如同新闻记者 Parmy Olson 于 2012 年在书中写道的,“我们是匿名者,” 这项行动是以又一次支持文件共享的网站而创立,如同 Napster 的后继者海盗湾(Pirate Bay),但随后其目标却扩展到了政治领域。2010 年末,在美国国务院的要求下,包括万事达、Visa、PayPal 在内的几家公司终止了对维基解密的捐助,维基解密是一家公布了成百上千份外交文件的自发性组织。在一段在线视频中,“匿名者”组织扬言要进行报复,发誓会对那些阻碍维基解密发展的公司进行惩罚。Doyon 被这种抗议企业的精神所吸引,决定参加这次行动。

+ +
+ +
潘多拉的魔盒
+ +

在十二月初的“反击行动”中,“匿名者”组织指导那些新成员,或者说新兵,去看标题为“如何加入那个【哔~】的Hive”,参与者被要求“首先配置他们【哔~】的网络,这【哔~】的很重要。”同时他们被要求下载“低轨道离子炮”,一款易于使用的开源软件。Doyon 下载了软件并在聊天室内等待着下一步指示。当开始的指令发出后,数千名匿名者将同时发动进攻。Doyon 进入了目标网址——www.visa.com——同时,在软件的右上角有个按钮,上面写着“IMMA CHARGIN MAH LAZER.”(“反击行动”同时也发动了大量的复杂精密的入侵进攻。)几天后,“反击行动”攻陷了万事达、Visa、PayPal 公司的主页。在法院的控告单上,PayPal 称这次攻击给公司造成了 550 万美元的损失。

+ +

但对 Doyon 来说,这是切实的激进主义体现。在剑桥反对种族隔离的行动中,他不能即可见效;而现在,只需指尖轻轻一点,就可以在攻陷大公司网站的行动中做出自己的贡献。隔天,赫芬顿邮报上出现了“万事达沦陷”的醒目标题。一位得意洋洋的匿名者发推特道:“有些事情维基解密是无能为力的。但这些事情却可以由‘反击行动’来完成。”

+ +

4

+ +

2010 年的秋天,“和平阵营”的抗议活动终止,政府只做出了略微让步,“流浪者管理法案”仍然有效。Doyon 希望通过借助“匿名者”组织的方略扭转局势。他回忆当时自己的想法,“也许我可以发动‘匿名者’组织来教训这种看似不堪一击的市政府网站,它们绝对会【哔~】地沦陷。最终我们使得市政府永久性废除‘流浪者管理法案’。”

+ +

Joshua Covelli 是一位 25 岁的匿名者,他的昵称是“Absolem”,他非常钦佩 Doyon 的果敢。“过去我们的组织完全是各种混乱的一盘散沙,”Covelli 告诉我。在“Commander X”加入之后,“组织似乎开始变得有模有样了。”Covelli 的工作是俄亥俄州费尔伯恩的一所大学接待员,他从不了解任何有关圣克鲁斯的政治。但是当 Doyon 提及帮助“和平阵营”抗击活动的计划后,Covelli 立即回复了一封表示赞同的电子邮件:“我期待参加这样的行动已经很久了。”

+ +

Doyon 使用 PLF 的昵称邀请 Covelli 在 IRC 聊天室进行了一次秘密谈话:

+ +
Absolem:抱歉,有个比较冒犯的问题...请问 PLF 是组织的一部分还是分开的?
+ +
Absolem:我会这么问,是因为看你们聊天,觉得你们都是非常有组织的。
+ +
PLF:不不不,你的问题一点也不冒犯。很高兴遇到你。PLF 是一个来自波士顿的黑客组织,已经成立 22 年了。我在 1981 年就开始了我的黑客生涯,但那时我并没有使用计算机,而是使用的 PBX(Private Branch Exchange,电话交换机)。
+ +
PLF:我们组织内所有成员的年龄都超过了 40 岁。我们当中有退伍士兵和学者。并且我们的成员“Commander Adama”,正在躲避一大帮警察还有间谍的追捕。
+ +
Absolem:听起来很棒!我对这次行动很感兴趣,不过“匿名者”组织看起来太混乱无序,不知道我是否可以提供一些帮助。我的电脑技术还不错,但我在入侵技术上还完全是一个新手。我有一些小工具,但不知道怎么去使用它们。
+ +

庄重的入会仪式后,Doyon 正式接纳 Covelli 加入 PLF:

+ +
PLF:把所有可能使你受牵连的敏感文件加密。
+ +
PLF:还有,想要联系任何一位 PLF 成员的话,给我发消息就行。从现在起,请叫我... Commander X。
+ +

2012 年,美联社称“匿名者”组织为“一帮专家级的黑客”;Quinn Norton 在《连线》杂志上发文称“‘匿名者’组织可以入侵任何坚不可摧的网站”,并在文末赞扬他们为“一群卓越的民间黑客”。事实上,有些匿名者的确是很有天赋的程序员,但绝大部分成员根本不懂任何技术。人类学家 Coleman 告诉我只有大约五分之一的匿名者是真正的黑客——其他匿名者则是“极客与抗议者”。

+ +

2010 年 12 月 16 日,Doyon 以 Commander X 的身份向几名记者发送了电子邮件。“明天当地时间 12:00 的时候,‘人民解放阵线’组织与‘匿名者’组织将从互联网中删除圣克鲁斯政府网站”,他在邮件中写道,“12:30 之后我们将恢复网站的正常运行。”

+ +

圣克鲁斯数据中心的工作人员收到了警告,匆忙地准备应对攻击。他们在服务器上运行起安全扫描软件,并向当地的互联网供应商 AT & T 求助,后者建议他们向 FBI 报警。

+ +

第二天,Doyon 走进了一家星巴克并启动了笔记本电脑。即便是在这样一个小镇上,Doyon 也显得格外醒目:一个疲惫的流浪汉疯狂地敲击着键盘。随后,Covelli 和他在一间秘密聊天室碰头。

+ +
PLF:去社区,登录——检查一下右上角的“聊天”菜单栏,上面有今天的具体方案。感谢你对我们的支持。
+ +
Absolem:一切为了 PLF,长官。
+ +

他们都打开了 DDoS 软件。尽管只有少数人参加了这次“和平阵营”的行动,但 Doyon 好似统率千军万马般下令:

+ +
PLF:注意:每一位支持 PLF 或者站在我们这边的朋友——还有那些对抗邪恶保卫正义的勇士们:‘和平阵营’行动进行中,战斗的号角已经响起!目标:www.co.santa-cruz.ca.us。随意开火。重复指令:开火!
+ +
Absolem:收到,长官。
+ +

数据中心的工作人员紧张地盯着服务器,上面反馈出一连串拒绝服务的请求。尽管他们尽了最大的努力,网站还是崩溃了。25 分钟后,Doyon 决定遵守承诺。他下令“停止攻击”,政府网站开始恢复了正常运行。(这次攻击后,“流浪者管理法案”依旧没有废除。)

+ +

Doyon 没有时间去庆祝胜利,他显得焦躁不安。“我得走了,”他告诉 Covelli。他飞一般得逃回了山中小屋。Doyon 的感觉是正确的:一位 FBI 的探员早就在 IRC 上盯住了他。这位 FBI 的探员已经获许搜查 Doyon 的笔记本电脑。

+ +

几周后,Doyon 的食物吃完了,他不得不下山进行采购。当 Doyon在 Coffee Roasting Company 咖啡厅逗留的时候,两位联邦探员走了进来将他拘捕。Doyon 给“和平阵营”的创建者,同时也是一名律师的 Ed Frey 打了一个电话,Ed Frey 来到了警察局。Doyon 告诉了 Frey 他的另一个身份“Commander X”的事。

+ +

随后 Doyon 被释放,但 FBI 没收了他的笔记本电脑,里面满是犯罪证据。Frey 一个几乎不了解网络世界的维权律师,把 Doyon 载回了他的山边露营。“接着你要怎么办?”Frey 问道。

+ +
+ +
“Zach 很聪明... 并且... 是一个天才... 但.. 你们... 不在一个班。”
+ +

Doyon 引用了一句电影台词。“拼命地跑,”他说。“我会躲起来,尽可能保持我的行动自由,用尽全力和这帮混蛋们作斗争。”Frey 给了他两张 20 美元的钞票并祝他好运。

+ +

5

+ +

Doyon 搭着便车来到了旧金山,并在这里呆了三个月。他经常混迹于 Haight 大街 Ashbury 区的一家杂乱的咖啡馆里,在计算机前一坐就是几个小时,只有在抽烟时他才会起身走到室外活动。

+ +

2011 年 1 月,Doyon 联系了新闻记者兼匿名者的 Barrett Brown。“我们的下一步计划是什么?”Doyon 问道。

+ +

“突尼斯,” Brown 答道。

+ +

“我知道,那是中东地区的一个国家,” Doyon 继续问,“具体任务是什么呢?”

+ +

“我们准备打倒那里的独裁者,” Brown 再次答道。

+ +

“啊?!那里有一位独裁者吗?” Doyon 有点惊讶。

+ +

几天后,“突尼斯行动”正式展开。Doyon 作为参与者向突尼斯政府域名下的电子邮箱发送了大量的垃圾邮件,以此阻塞其服务器。“我会提前写好关于那次行动邮件,接着一次又一次地把它们发送出去,” Doyon 说,“有时候实在没有时间,我就只简短的写上一句‘问候对方母亲’的话,然后发送出去。”短短一天时间里,匿名者们就攻陷了包括突尼斯证券交易所、工业部、总统办公室、总统办公室在内的多个网站。他们把总统办公室网站的首页替换成了一艘海盗船的图片,并配以文字“恶有恶报,不是吗?”

+ +

Doyon 不时会谈起他的网上“战斗”经历,似乎他刚从弹坑里爬出来一样。“伙计,自从干了这行我就变黑了,”他向我诉苦道。“你看我的脸,全是抽烟的时候熏的——而且可能已经粘在我的脸上了。我仔细地照过镜子,毫不夸张地说我简直就是一头棕熊。”很多个夜晚,Doyon 都是在 Golden Gate 公园里露营过夜的。“我就那样干了四天,我看了看镜子里的‘我’,感觉还可以——但其实我觉得‘我’也许应该去吃点东西、洗个澡了。”

+ +

“匿名者”组织接着又在 YouTube 上声明了将要进行的一系列行动:“利比亚行动”、“巴林行动”、“摩洛哥行动”。作为解放广场事件的抗议者,Doyon 参与了“埃及行动”。在 Facebook 针对这次行动的宣传专页中,有一个为当地示威者准备的“行动套装”链接。“行动套装”通过文件共享网站 Megaupload 进行分发,其中含有一份加密软件以及应对瓦斯袭击的保护措施。在埃及政府关闭了埃及的所有互联网及子网络的时候不久后,“匿名者”组织继续向当地抗议者们提供连接网络的方法。

+ +

2011 年夏季,Doyon 接替 Adama 成为 PLF 的最高指挥官。Doyon 招募了六个新成员,并力图发展 PLF 成为“匿名者”组织的中坚力量。Covelli 成为了他的其中一位技术顾问。另一名黑客 Crypt0nymous 负责在 YouTube 上发布视频;其余的人负责研究以及组装电子设备。与松散的“匿名者”组织不同,PLF 内部有一套极其严格的管理体系。“Commander X 事必躬亲,”Covelli 说。“这是他的行事风格,要么不做,要么做好。”一位创立了 AnonInsiders 博客的黑客通过加密聊天告诉我,他认为 Doyon 总是一意孤行——这在“匿名者”组织中是很罕见的现象。“当我们策划发起一项行动时,他并不在乎其他人是否同意,”这位黑客补充道,“他会一个人列出行动方案,确定攻击目标,登录 IRC 聊天室,接着告诉所有人在哪里‘碰头’,然后发起 DDoS 攻击。”

+ +

一些匿名者把 PLF 视为“面子项目”,认为 Doyon 的所作所为完全是个笑柄。“他是因为吹牛出名的,”另一名昵称为 Tflow 的匿名者 Mustafa Al-Bassam 告诉我。不过,即使是那些极度反感 Doyon 的狂妄自大的人,也不得不承认他在“匿名者”组织发展过程中的重要性。“他所倡导的强硬路线有时很凑效,有时则是碍事,” Gregg Housh 说,并且补充道自己和其他优秀的匿名者都曾遇到过相同的问题。

+ +

“匿名者”组织对外坚持声称自己是不分层次的平等组织。在由 Brian Knappenberger 制作的一部纪录片,《我们是军团》中,一名成员使用“一群鸟”来比喻组织,它们轮流领飞带动整个组织不断前行。Gabriella Coleman 告诉我,这个比喻不太切合实际,“匿名者”组织内实际上早就出现了一个非正式的领导阶层。“领导者非常重要,”她说。“有四五个人可以看做是我们的领头羊。”她把 Doyon 也算在了其中。但是匿名者们仍然倾向于反抗这种体制结构。在一本即将出版的关于“匿名者”组织的书,《黑客、骗子、告密者、间谍》中,Coleman 这么写道,在匿名者中,“成员个体以及那些特立独行的人依然在一些重大事件上保持着服从的态度,优先考虑集体——特别是那些能引发强烈争端的事件。”

+ +

匿名者们谑称那些特立独行的成员为“自尊心超强的疯子”和“想让自己出名的疯子”。(不过许多匿名者已经不会再随便给他人取那种具有冒犯性的称号了。)“但还是有令人惊讶的极少数成员违反规则”打破传统上的看法,Coleman 说。“这么做的人,像 Commander X 这样的,都会在组织里受到排斥。”去年,在一家网络论坛上,有人写道,“当他开始把自己比作‘蝙蝠侠’的时候我就不想理他了。”

+ +

Peter Fein,是一位以 n0pants 为昵称而出名的网络激进分子,也是众多反对 Doyon 的浮夸行为的众多匿名者之一。Fein 浏览了 PLF 的网站,其封面上有一个徽章,还有关于组织的宣言——“为了解放众多人类的灵魂而不断战斗”。Fein 沮丧的发现 Doyon 早就使用真名为这家网站注册过了,使他这种,以及其他想要找事的匿名者们无机可乘。“如果有人要对我的网站进行 DDoS 攻击,那完全可以,” Fein 回想起通过私密聊天告诉 Doyon 时的情景,“但如果你要这么做了的话,我会揍扁你的屁股。”

+ +

2011 年 2 月 5 日,《金融时报》报道了在一家名为 HBGary Federal 的网络安全公司,首席执行官 HBGary Federal 已经得到了“匿名者”组织骨干成员名单的消息。Barr 的调查结果表明,三位最高领导人其中之一就是‘ Commander X’,是一位潜伏在加利福尼亚州的黑客而且有能力“策划一些大型网络攻击事件”。Barr 联系了 FBI 并提交了自己的调查结果。

+ +

和 Fein 一样,Barr 也发现了 PLF 网站的注册法人名为 Christopher Doyon,地址是 Haight 大街。基于 Facebook 和 IRC 聊天室的调查,Barr 断定‘ Commander X’的真实身份是一名家庭住址在 Haight 大街附近的网络激进分子 Benjamin Spock de Vries。Barr 通过 Facebook 和 de Vries 取得了联系。“请告诉我组织里的其他人,我并不是来抓你们的,” Barr 留言道,“只是想让‘领导阶层’知晓我的意图。”

+ +

“‘领导阶层’? 2333,笑死我了,” de Vries 回复道。

+ +

《金融时报》发布报道的第二天,“匿名者”组织就进行了反击。HBGary Federal 的网站被进行了恶意篡改。Barr 的私人 Twitter 账户被盗取,他的上千封电子邮件被泄漏到了网上,同时匿名者们还公布了他的住址以及其他私人信息——这就是“冲动的惩罚”。不到一个月后,Barr 就从 HBGary Federal 辞职了。

+ +

6

+ +

2011 年 4 月,Doyon 离开了旧金山搭便车向西部前行,过着夜晚露宿公园、白天混迹于星巴克的生活。他的背包里只有一台笔记本电脑、Guy Fawkes 面具,还有在 Pall 超市里购买的一些东西。

+ +
+ +
“这是我在 TED 夏令营里学到的东西。”
+ +

他时刻关注着“匿名者”组织的内部消息。那年春季,在 Barr 调查报告中提到的六位匿名者精锐成员,组建了“LulzSec 安全”组织(Lulz Security),简称 LulzSec。这个组织正如其名,这些成员认为“匿名者”组织已经变得太过严肃;他们的目标是重新引发起那些“能挑起强烈争端”的事件。当“匿名者”组织还在继续支持“阿拉伯之春”的抗议者时,LulzSec 入侵了公共电视网(Public Broadcasting Service,PBS)网站,并发布了一则虚假声明称已故说唱歌手 Tupac Shakur 仍然生活在新西兰。

+ +

匿名者之间会通过 Pastebin.com 网站来共享文本。在这个网站上,LulzSec 发表了一则声明,称“很不幸,我们注意到北约和我们的好朋友巴拉克奥萨马——来自24世纪的奥巴马 已经提升了关于黑客的筹码,他们把黑客入侵行为视作一种战争的表现。”目标越高远,挑起的纷争就越大。6 月 15 日,LulzSec 表示对 CIA 网站受到的袭击行为负责,他们发表了一条推特,上面写道“目标击毙(Tango down,亦即target down)—— cia.gov ——这是起挑衅行为。”

+ +

2011 年 6 月 20 日,LulzSec 的一名十九岁的成员 Ryan Cleary 因为对 CIA 的网站进行了 DDoS 攻击而被捕。7 月,FBI 探员逮捕了七个月前对 PayPal 进行 DDoS 攻击的其他十四名黑客。这十四名黑客,每人都面临着 15 年的牢狱之灾以及 50 万美元的罚款。他们因为图谋不轨以及故意破坏互联网而被控违反了计算机欺诈与滥用法案。(Computer Fraud and Abuse Act,该法案允许检察官拥有宽泛的起诉裁量权,并在去年网络激进分子 Aaron Swartz 因为被判处 35 年牢狱之灾而自杀身亡之后,受到了广泛的质疑和批评。)

+ +

LulzSec 的成员之一 Jake (Topiary) Davis 因为付不起法律诉讼费,给组织的成员们写了一封请求帮助的信件。Doyon 进入了 IRC 聊天室把 Davis 需要帮助的消息进行了扩散:

+ +
CommanderX:那么请大家阅读信件并给予 Topiary 帮助...
+ +
Toad:你真是为了抓人眼球什么都做啊!
+ +
Toad:这么说你得到 Topiary 的消息了?
+ +
CommanderX:Toad 你这个混蛋!
+ +
Katanon:唉...
+ +

Doyon 越来越大胆。在佛罗里达州当局逮捕了支持流浪者的激进分子后,他就攻击 了奥兰多商务部商会网站。他使用个人笔记本电脑通过公用无线网络实施了攻击,并且没有花费太多精力来隐藏自己的网络行踪。“这种做法很勇敢,但也很愚蠢,”一位自称 Kalli 的 PLF 的资深成员告诉我。“他看起来并不在乎是否会被抓。他完全是一名自杀式黑客。”

+ +

两个月后,Doyon 参与了针对旧金山湾区快速交通系统(Bay Area Rapid Transit)的 DDoS 攻击,以此抗议一名 BART 的警官杀害一名叫做 Charles Hill 的流浪者的事件。随后 Doyon 现身“CBS 晚间新闻”为这次行动辩护,当然,他处理了自己的声音,用印花大手帕盖住了脸。他把 DDoS 攻击比作为公民的抗议行为。“与占用 Woolworth 午餐柜台的座位相比,这真的没什么不同,真的,”他说道。CBS 的主播 Bob Schieffer 笑称:“就我所见,它并不完全是一项民权运动。”

+ +

2011 年 9 月 22 日,在加利福尼亚州的一家名为 Mountain View 的咖啡店里,Doyon 被捕,同时面临着“使用互联网非法破坏受保护的计算机”的罪名指控。他被拘留了一个星期的时间,接着在签署协议之后获得假释。两天后,他不顾律师的反对,宣布将在圣克鲁斯郡法院召开会议。他梳起了马尾辫,戴着一副墨镜、一顶黑色海盗帽,同时还在脖子上围了一条五彩手帕。

+ +

Doyon 通过非常夸大的方式揭露了自己的身份。“我就是 Commander X,”他告诉蜂拥的记者。他举起了拳头。“作为‘匿名者’组织的一员,作为一名核心成员,我感到非常的骄傲。”他在接受一名记者的采访时说,“想要成为一名顶尖黑客的话,你只需要准备一台电脑以及一副墨镜。任何一台电脑都行。”

+ +

Kalli 非常担心 Doyon 会不小心泄露组织机密或者其他匿名者的信息。“这是所有环节中最薄弱的地方,如果这里出问题了,那么组织就完了,”他告诉我。曾在“和平阵营行动”中给予 Doyon 大力帮助的匿名者 Josh Covelli 告诉我,当他在网上看见 Doyon 的新闻发布会视频的时候,他感觉瞬间“下巴掉地上了”。“他的所作所为变得越来越不可捉摸,” Covelli 评价道。

+ +

三个月后,Doyon 的指定律师 Jay Leiderman 出席了圣荷西联邦法庭的辩护。Leiderman 已经好几个星期没有得到 Doyon 的消息了。“我需要得知被告无法出席的具体原因,”法官说。Leiderman 无法回答。Doyon 再次缺席了两星期后的另一场听证会。检控方表示:“很明显,看来被告已经逃跑了。”

+ +

7

+ +

“Xport 行动”是“匿名者”组织进行的所有同类行动中的第一个行动。这次行动的目标是协助如今已经背负两项罪名的通缉犯 Doyon 潜逃出国。负责调度的人是 Kalli 以及另一位曾在八十年代剑桥的迷幻药派对上和 Doyon 见过面的匿名者老兵。这位老兵是一位已经退休的软件主管,在组织内部威望很高。

+ +

Doyon 的目的地是这位软件主管家,位于加拿大的偏远乡村。2011 年 12 月,他搭便车前往旧金山,并辗转来到了市区组织大本营。他找到了他的指定联系人,后者带领他到达了奥克兰的一家披萨店。凌晨 2 点,Doyon 通过披萨店的无线网络,接收了一条加密聊天消息。

+ +

“你现在靠近窗户吗?”那条消息问道。

+ +

“是的,” Doyon 回复道。

+ +

“往大街对面看。看见一个绿色的邮箱了吗?十五分钟后,你去站到那个邮箱旁边,把你的背包取下来,然后把你的面具放在上面。”

+ +

一连几个星期的时间,Doyon 穿梭于海湾地区的安全屋之间,按照加密聊天那头的指示不断行动。最后,他搭上了前往西雅图的长途公交车,软件主管的一个朋友在那里接待了他。这个朋友是一名非常富有的退休人员,他花费了几小时的时间通过谷歌地球来帮助 Doyon 规划前往加拿大的路线。他们共同前往了一家野外用品供应商店,这位朋友为 Doyon 购置了价值 1500 美元的商品,包括登山鞋以及一个全新的背包。接着他又开车载着 Doyon 北上,两小时后到达距离国界只有几百英里的偏僻地区。随后 Doyon 见到了 Amber Lyon。

+ +

几个月前,广播新闻记者 Lyon 曾在 CNN 的关于“匿名者”组织的节目里采访过 Doyon。Doyon 很欣赏她的报道,他们一直保持着联络。Lyon 要求加入 Doyon 的逃亡行程,为一部可能会发行的纪录片拍摄素材。软件主管认为这样太过冒险,但 Doyon 还是接受了她的请求。“我觉得他是想让自己出名,” Lyon 告诉我。四天的时间里,她用影像记录下了 Doyon 徒步北上,在林间露宿的行程。“那一切看起来不太像是仔细规划过的,” Lyon 回忆说。“他实在是无家可归了,所以他才会想要逃到国外去。”

+ +
+ +
“这里是我们存放各种情感的仓库。如果你产生了某种情感,把它带到这里然后锁起来。”
+ +

2012 年 2 月 11 日,Pastebin 上出现了一条消息。“PLF 很高兴的宣布‘ Commander X’,也就是 Christopher Mark Doyon,已经离开了美国的司法管辖区,抵达了加拿大一个比较安全的地方,”上面写着,“PLF 呼吁美国政府,希望政府能够醒悟过来并停止无谓的骚扰与监视行为——不要仅仅逮捕‘匿名者’组织的成员,对所有的激进组织应该一视同仁。”

+ +

8

+ +Doyon 和软件主管在加拿大的小木屋里呆了几天。在一次同 Barrett Brown 的聊天中,Doyon 难掩内心的喜悦之情。 + +
BarrettBrown:你现在足够多安全的藏身之处等等吧?
+ +
CommanderX:是的,我现在很安全,现在加拿大既不缺钱也不缺藏身的地方。
+ +
CommanderX:Amber Lyon 想要你的一张照片。
+ +
CommanderX:去你【哔~】的怪人,Barrett,相信你会喜欢我的回复。我一直爱你,永远爱你。
+ +
CommanderX::-)
+ +
CommanderX:我告诉她你是一个英雄。
+ +
BarrettBrown:你才是真正的英雄...
+ +
BarrettBrown:很高兴你现在安全了
+ +
BarrettBrown:如果你还需要什么,告诉我一声就可以了
+ +
CommanderX:我会的,如果这种方式的确很凑效的话,可以让其他被通缉的人也这样逃出来....
+ +
BarrettBrown:当然,估计我们不久后也得这样了
+ +

在 Doyon 出逃十天后,《华尔街日报》上刊登了关于不久后升职为美国国家安全局及网络指挥部主任的 Keith Alexander 的报道,他在白宫以及其他场合举行的秘密会晤,表达了对“匿名者”组织的高度关注。Alexander 发出警告,两年内,该组织必将会是国家电网改造的大患。参谋长联席会议的主席 General Martin Dempsey 告诉记者,这群人是国家的敌人。“他们有能力把这些使用恶意软件造成破坏的技术扩散到其他的边缘组织去,”随后又补充道,“我们必须防范这种情况发生。”

+ +

3 月 8 日,国会议员们在国会大厦附近的一个敏感信息隔离设施附近举行了关于网络安全的会议。包括 Alexander、Dempsey、美国联邦调查局局长 Robert Mueller,以及美国国土安全部部长 Janet Napolitano 在内的多名美国安全方面的高级官员出席了这次会议。会议上,通过计算机向与会者模拟了东部沿海地区电力设施可能会遭受到的网络攻击时的情境。“匿名者”组织目前应该还不具备发动此种规模攻击的能力,但安全方面的官员担心他们会联合其他更加危险的组织来共同发动攻击。“在我们着手于不断增加的网络风险事故时,政府仍在就具体的处理细节进行不断协商讨论,” Napolitano 告诉我。当谈及潜在的网络安全隐患时,她补充道,“我们通常会把‘匿名者’组织的行动当做 A 级威胁来应对。”

+ +

“匿名者”也许是当今世界上最强大的无政府主义黑客组织。即使如此,它却从未表现出过任何的会对公共基础设施造成破坏的迹象或意愿。一些网络安全专家称,那些关于“匿名者”组织的谣传太过危言耸听。“在奥兰多发布战前宣言和实际发动 Stuxnet 蠕虫病毒攻击之间是有很大的差距的,” Internet 研究与战略中心的一位职员 James Andrew Lewis 告诉我,这和 2007 年美国与以色列对伊朗原子能网站发动的黑客袭击有关。哈佛大学法学院的教授 Yochai Benkler 告诉我,“我们所看见的只是以主要防御为理由而进行的开销,否则,将很难自圆其说。”

+ +

Keith Alexander 最近刚从政府部门退休,他拒绝就此事发表评论,因为他并不能代表国家安全局、联邦调查局、中央情报局以及国土安全部。尽管匿名者们从未真正盯上过政府部门的计算机网络,但他们对于那些激怒他们的人有着强烈的报复心理。前国土安全部国家网络安全部门负责人 Andy Purdy 告诉我他们“害怕被报复,”无论机构还是个人,都不同意政府公然反对“匿名者”组织。“每个人都容易成为被攻击对象,”他说。

+ +

9

+ +

2012 年 3 月 6 日,Hector Xavier Monsegur,昵称为 Sabu 的 LulzSec 骨干成员,被发现是 FBI 派来的卧底。为了换取减刑,Monsegur 花费了数月的时间卧底,协助搜集其他 LulzSec 成员的罪证。同一天,五位匿名者领导被捕,同时面临着包括“计算机某犯罪”在内的多项罪名指控。联邦调查局的一名官员在接受福克斯新闻记者采访时说道,“这对那个组织是一个毁灭性的打击。我们的行动如同砍掉了 LulzSec 组织的头。”接下来的十个月里, Barrett Brown 收到了 17 项联邦罪名的指控,其中的大部分后来被撤销了。(他将在十月被宣判最终结果。)

+ +

Doyon 感到很烦躁,但他还是继续扮演着一名黑客——以此吸引关注。他在多伦多上映的纪录片上以戴着面具的匿名者形象出现。在接受《National Post》的采访时,他向记者大肆吹嘘未经证实的消息,“我们已经入侵了美国政府的所有机密数据库。现在的问题是我们该何时泄露这些机密数据,而不是我们是否会泄露。”

+ +

2013 年 1 月,在另一名匿名者介入俄亥俄州斯托本维尔未成年少女强奸案,发起抗议行动之后,Doyon 重新启用了他两年前创办的网站 LocalLeaks,作为那起强奸事件的信息汇总处理中心。如同许多其他“匿名者”组织的所作所为一样,LocalLeaks 网站非常具有影响力,但却也不承担任何责任。LocalLeaks 网站是第一家公布 12 分钟斯托本维尔高中毕业生猥亵视频的网站,这激起了众多当事人的愤怒。LocalLeaks 网站上同时披露了几份未被法庭收录的关于案件的材料,并且由此不小心透漏出了案件受害人的名字。Doyon向我承认他公开这些未经证实的信息的策略是存在争议的,但他同时回忆起自己当时的想法,“我们可以选择销毁这些斯托本维尔案件的材料...也可以选择公开所有我们搜集的信息,基本上,给公众以提醒,不过,前提是你们得相信我们。”

+ +

2013 年 3 月,一个名为 Rustle League 的组织入侵了 Doyon 的 Twitter 账户,该组织此前经常挑衅“匿名者”组织。Rustle League 的领导者之一 Shm00p 告诉我,“我们的本意并不是伤害那些家伙,只不过,哦,那些家伙说的话你就当是在放屁好了——我会这么做只是因为我感到很好笑。” Rustle League 组织使用 Doyon 的账户发布了含有如 www.jewsdid911.org 链接这样的,种族主义和反犹太主义的信息。

+ +

2013 年 8 月 27 日,Doyon 发布了一则退出“匿名者”组织的声明。“我的一生都用在了追求正义和自由上,”他写道,“也许‘ Commander X’是无敌的,但我在这种高节奏的全球网络斗争中已经感到很累了,感觉自己好像病了。”各界对此反应不一,有同情的(“你是该休息了”),也有嘲讽的(“可怜的疯狂小老头。也许他现在有时间洗澡了”)。 Covelli 告诉我,“‘匿名者’的身份对他产生了较大的影响,他已经不能再应付了。”

+ + + +
1998 年 8 月 17 日 “我们还有‘巴黎’吗?仔细想想,我等会儿去检查一下。”
+ +

10

+ +

2013 年 11 月 5 日举行了第一次“百万面具游行”活动。在全世界四百五十个城市里,发起了数千人的支持“匿名者”组织的游行。伦敦的一名抗议者摘下了盖伊·福克斯面具后,露出了演员罗素·布兰德的脸。这种的迹象表明,“匿名者”组织已经深入到了流行文化中。

+ +

我参加了华盛顿的集会,Doyon 则呆在了加拿大观看现场直播。通过移动电话,我和 Doyon 不断交换着电子邮件。“只能坐在这里看直播而不能亲自去现场真的很令人沮丧——尤其是当这里面包含有你努力的结果的时候,”他在邮件里写道。“不过至少一切都已有所改变。”

+ +

我们约定了一次面谈。Doyon 坚持让我通过加密聊天把面谈的详细情况提前告诉他。我坐了几个小时的飞机,租车来到了加拿大的一个偏远小镇,并且禁用了我的电话。

+ +

最后,我在一个狭小安静的住宅区公寓里见到了 Doyon。他穿了一件绿色的军人夹克衫以及印有“匿名者”组织 logo 的 T 恤衫:一个脸被问号所替代的黑衣人形象。公寓里基本上没有什么家具,充满了一股烟味。他谈论起了美国政治(“我基本没怎么在众多的选举中投票——它们不过是暗箱操作的游戏罢了”),好战的伊斯兰教(“我相信,尼日利亚政府的人不过是相互勾结,以创建一个名为‘博科圣地’的基地组织的下属机构罢了”),以及他对“匿名者”组织的小小看法(“那些自称为怪人的人是真的是烂透了,其实是邪恶的人”)。

+ +

Doyon 剃去了他的胡须,但他却显得更加憔悴了。他说那是因为他病了的原因,他几乎很少出去。很小的写字台上有两台笔记本电脑、一摞关于佛教的书,还有一个堆满烟灰的烟灰缸。另一面裸露的泛黄墙壁上挂着盖伊·福克斯面具。他告诉我,“所谓‘Commander X’不过是一个处于极度痛苦中的小老头罢了。”

+ +

在刚过去的圣诞节里,匿名者的新网站 AnonInsiders 的创建者拜访了 Doyon,并给他带来了馅饼和香烟。Doyon 询问来访的朋友是否可以接替自己成为 PLF 的最高指挥官,同时希望能够递交出自己手里的“王国钥匙”——手里的所有密码,以及几份关于“匿名者”组织的机密文件。这位朋友委婉的拒绝了。“我有自己的生活,”他告诉了我拒绝的理由。

+ +

11

+ +

2014 年 8 月 9 日,当地时间下午 5 时 09 分,来自密苏里州圣路易斯郊区德尔伍德的一位说唱歌手同时也是激进分子的 Kareem (Tef Poe) Jackson,在 Twitter 上谈起了邻近城镇的一系列令人担忧的举措。“基本可以断定弗格森已经实施了戒严,任何人都无法出入,”他在 Twitter 上写道。“国内外的朋友们请帮助我们!!!”五个小时前,弗格森,一位十八岁的手无寸铁的非裔美国人 Michael Brown,被一位白人警察射杀。射杀警察声称自己这么做的原因是 Brown 意图伸手抢夺自己的枪支。而事发当时和 Brown 在一起的朋友 Dorian Johnson 却说,Brown 唯一做得不对的地方在于他当时拒绝离开街道中间。

+ +

不到两小时,Jackson 就收到了一位名为 CommanderXanon 的 Twitter 用户的回复。“你完全可以相信我们,”回复信息里写道。“你是否可以给我们详细描述一下现场情况,那样会对我们很有帮助。”近几周的时间里,仍然呆在加拿大的 Doyon 复出了。六月,他在还有两个月满 50 岁的时候,成功戒烟(“#戒瘾成功 #电子香烟功不可没 #老了,”他在戒烟成功后在 Twitter 上写道)。七月,在加沙地带爆发武装对抗之后,Doyon 发表 Twiter 支持“匿名者”组织的“拯救加沙行动”,并发动了一系列针对以色列网站的 DDoS 攻击。Doyon 认为弗格森枪击事件更加令人关注。抛开他本人的个性,他有能力在事件发展到引人注目之前,就迅速注意该事件。

+ +

“正在网上搜索关于那名警察以及当地政府的信息,” Doyon 发 Twitter 道。不到十分钟,他就为此专门在 IRC 聊天室里创建了一个频道。“‘匿名者’组织‘弗格森’行动正式启动,”他又发了一条 Twitter。但只有两个人转推了此消息。

+ +

次日早晨,Doyon 发布了一条链接,链接指向的是一个初具雏形的网站,网站首页有一条致弗格森市民的信息——“你们并不孤单,我们将尽一切努力支持你们”——以及致当地警察的警告:“如果你们对弗格森的抗议者们滥用职权、骚扰,或者伤害了他们,我们绝对会让你们所有政府部门的网站瘫痪。这不是威胁,这是承诺。”同时 Doyon 呼吁有 130 万粉丝的“匿名者”组织的 Twitter 账号 YourAnonNews 给与支持。“请支持‘弗格森’行动”,他发送了消息。一分钟后,YourAnonNews 回复表示同意。当天,包含话题 #OpFerguson 的 Twitter 被转发了超过六千次。

+ +

这个事件迅速成为头条新闻,同时匿名者们在弗格森周围进行了大集会。与“阿拉伯之春行动”类似,“匿名者”组织向抗议者们发送了电子关怀包,包括抗暴指导(“把瓦斯弹捡起来回丢给警察”)与可打印的盖伊·福克斯面具。Jackson 和其他示威者在弗格森进行示威游行时,警察企图通过橡皮子弹和催泪瓦斯来驱散他们。“当时的情景真像是布鲁斯·威利斯的电影里的情节,” Jackson 后来告诉我。“不过巴拉克·奥巴马应该并不会支持‘匿名者’组织传授给我们的这些知识,”他说道。“知道有人在你的背后支持你,真是感觉欣慰。”

+ +

有个网址是 www.opferguson.com 的网站,后来发现不过是一个骗局——一个用来收集访问者 ip 地址的陷阱,随后这些地址会被移交给执法机构。有些人怀疑 Commander X 是政府的线人。在 IRC 聊天室 #OpFerguson 频道,一个名叫 Sherlock 写道,“现在频道里每个人说的已经让我害怕去点击任何陌生的链接了。除非是一个我非常熟悉的网址,否则我绝对不会去点击。”

+ +

弗格森的抗议者要求当局公布射杀 Brown 的警察的名字。几天后,匿名者们附和了抗议者们的请求。有人在 Twitter 上写道,“弗格森警察局最好公布肇事警察的名字,否则‘匿名者’组织将会替他们公布。”8 月 12 的新闻发布会上,圣路易斯警察局的局长 Jon Belmar 拒绝了这个请求。“我们不会这样做,除非他们被某个罪名所指控,”他说道。

+ +

作为报复,一名黑客使用名为 TheAnonMessage 的 Twitter 账户公布了一条链接,该链接指向一段来自警察的无线电设备所记录的音频文件,文件记录时间是 Brown 被枪杀的两小时左右。TheAnonMessage 同时也把矛头指向了 Belmar,在 Twitter 上公布了这位警察局长的家庭住址、电话号码以及他的家庭照片——一张是他的儿子在长椅上睡觉,另一张则是 Belmar 和他的妻子的合影。“不错的照片,Jon,” TheAnonMessage 在 Twitter 上写道。“你的妻子在她这个年龄算是一个美人了。你已经爱她爱得不耐烦了吗?”一个小时后,TheAnonMessage 又以 Belmar 的女儿为把柄进行了恐吓。

+ +

Richard Stallman,来自 MIT 的初代黑客,告诉我虽然他在很多地方赞同“匿名者”组织的行为,但他认为这些泄露私人信息的攻击行为是要受到谴责的。即使是组织内部,TheAnonMessage 的行为也受到了谴责。“为何要泄露无辜的人的信息到网上?”一位匿名者通过 IRC 发问,并且表示威胁 Belmar 的家人实在是“相当愚蠢的行为”。但是 TheAnonMessage 和其他的一些匿名者仍然进行着不断搜寻,并企图在将来再次进行泄露信息的攻击。在互联网上可以得到所有弗格森警察局警员的名字,匿名者们不断地搜索着信息,企图找出具体是哪一个警察找出杀害了 Brown。

+ +
+ +
1999 年 4 月 12 日 “我应该把镜头对向谁?”
+ +

8 月 14 日清晨,几位匿名者基于 Facebook 上的照片还有其他的证据,确定了射杀 Brown 的凶手是一位名叫 Bryan Willman 的 32 岁男子。根据一份 IRC 聊天记录,一位匿名者贴出了 Willman 的肿胀面孔的照片;另一位匿名者提醒道,“凶手声称自己的脸没有被任何人看到。”另一位昵称为 Anonymous|11057 的匿名者承认他对 Willman 的怀疑确实是“跳跃性的可能错误的逻辑过程推导出来的。”不过他还是写道,“我只是无法动摇自己的想法。虽然我没有任何证据,但我非常非常地确信就是他。”

+ +

TheAnonMessage 看起来被这次对话逗乐了,写道,“#愿逝者安息,凶手是 BryanWillman。”另一位匿名者发出了强烈警告。“请务必确认,” Anonymous|2252 写道。“这不仅仅关乎到一个人的性命,我们可以不负责任地向公众公布我们的结果,但却很可能有无辜的人会因此受到不应受到的对待。”

+ +

争论超过了一个小时。一些匿名者指出没有证据表明 Willman 曾经在弗格森警察局任过职。

+ +
Anonymous|3549:@gs 我们依旧没有证据能够证明 Bryan 曾在警局呆过
+ +
Intangir:现在的形势已经够紧张的了,一旦我们把这个消息公布出去,可能就会有人因此去杀了他
+ +
Anonymous|11057:唯一的证明方法是犯罪现场目击者报告。否则我们的结果只是一个谣言
+ +
Anonymous|11057:最快的排除嫌疑的方法是称他为嫌疑犯...我们都害怕犯下不公正的错误,但这种方法恰好可以避免这些...
+ +

大部分匿名者都反对在网上泄露他人信息。但是早晨七点左右匿名者们进行了一次投票。聊天记录显示,当时聊天室里有 80 人左右,只有不到十人参与了投票表决。因此他们决定在互联网上公布 Willman 的私人信息。

+ +
Anonymous|2252:还在 Twitter 上公布?
+ +
anondepp:lol
+ +
Anonymous|2252:用 @theanonmessage 公布?
+ +
TheAnonMessage:当然
+ +
TheAnonMessage:去发吧
+ +
anondepp:搞定了
+ +
Anonymous|2252:我去
+ +
TheAnonMessage:上帝保佑...
+ +
Anonymous|3549:...请拯救我们的灵魂
+ +
anondepp:lol
+ +

早晨 9 时 45 分,圣路易斯警察局对 TheAnonMessage 进行了答复。“Bryan Willman 从来没有在 警察局或者圣路易斯警察局任过职,” 他们在 Twitter 上写道。“请不要再公布这位无辜市民的信息了。”(随后 FBI 对弗格森警察的电脑遭黑客入侵的事情展开了调查。)Twitter 管理员迅速封禁了 TheAnonMessage 的账户,但 Willman 的名字和家庭住址仍然被广泛传开。

+ +

实际上,Willman 是弗格森西郊圣安区的警察外勤负责人。当圣路易斯警察局的情报处打电话告诉 Willman,他已经被“确认”为凶手时,他告诉我,“我以为不过是个奇怪的笑话。”几小时后,他的社交账号上就收到了成百上千条死亡恐吓。他在警察的保护下,独自一人在家里呆了将近一个星期。“我只希望这一切都尽快过去,”他告诉我他的感受。他认为“匿名者”组织已经不可挽回地损害了他的名誉。“我不知道他们怎么会以为自己可以被再次信任的,”他说。

+ +

“我们并不完美,” OpFerguson 在 Twitter 上说道。“‘匿名者’组织确实犯错了,过去的几天我们制造一些混乱。为此,我们道歉。”尽管 Doyon 并不应该为这次错误的信息泄露攻击负责,但其他的匿名者却因为他发起了一次无法控制的行动,而归咎他。YourAnonNews 在 Pastebin 上发表了一则消息,上面写道,“你们也许注意到了组织不同的 Twitter 账户发表的话题 #Ferguson 和 #OpFerguson,这两个话题下的 Twitter 与信息是相互矛盾的。为什么会在这些关键话题上出现分歧,部分原因是因为 CommanderX 是一个‘想让自己出名的疯子/想让公众认识自己的疯子’——这种人喜欢,或者至少不回避媒体的宣传——并且显而易见的,组织内大部分成员并不喜欢这样。”

+ +

在个人 Twitter 上,Doyon 否认了所有关于“弗格森行动”的职责,他写道,“我讨厌这样。我不希望这样的情况发生,我也不希望和我认为是朋友的人战斗。”沉寂了几天后,他又再度获吹响了战斗的号角。他最近在 Twitter 上写道,“你们称他们是暴民,我们却称他们是压迫下的反抗之声”以及“解放西藏”。

+ +

Doyon 仍然处于藏匿状态。甚至连他的律师 Jay Leiderman 也不知道他在哪里。Leiderman 表示,除了在圣克鲁斯受到的指控,Doyon 很有可能因为攻击了 PayPal 和奥兰多而面临新的指控。一旦他被捕,所有的刑期加起来,他的余生就要在监狱里度过了。借鉴 Edward Snowden 的先例,他希望申请去俄罗斯避难。我们谈话时,他用一支点燃的香烟在他的公寓里比划着。“这里比【哔~】的牢房强多了吧?我绝对不会出去,”他愤愤道。“我不会再联系我的家人了....这是相当高的代价,但我必须这么做,我会尽我的努力让所有人活得自由、明白。”

+ + + +

via: http://www.newyorker.com/magazine/2014/09/08/masked-avengers

+ +

作者:David Kushner

+

译者:SteveArcher

+

校对:Caroline

+ +

本文由 LCTT 原创翻译,Linux中国荣誉推出

diff --git a/published/201410/20140905 Ubuntu Touch Now Has a Torrent Client in the Ubuntu Store.md b/published/201410/20140905 Ubuntu Touch Now Has a Torrent Client in the Ubuntu Store.md new file mode 100644 index 0000000000..7c845fbb91 --- /dev/null +++ b/published/201410/20140905 Ubuntu Touch Now Has a Torrent Client in the Ubuntu Store.md @@ -0,0 +1,26 @@ +Ubuntu商城有了一款 Ubuntu Touch 的 BT 客户端了 +================================================================================ +![DowNow](http://i1-news.softpedia-static.com/images/news2/Ubuntu-Touch-Now-Has-a-Torrent-Clinent-in-the-Ubuntu-Store-457538-2.jpg) + +**Ubuntu触屏平台已经拥有许多有趣应用程序,甚至看起来很多开发者已经开始实现许多超乎期望的软件,像BT客户端就是个很好的例子。** + +Ubuntu触屏设备的应用商店在过去几个月一直平稳增长并增添了许多有趣的应用程序。其中大多数都已经满足操作系统的基本需求,但也有不少远远超出普通用户的需求。 + +你会发现在大多数手机中BT客户端并不是必备的东西。Android和Windows手机已经已经有这类的应用程序,看起来Ubuntu也将是支持的平台之一。Ubuntu开发者[Alan Pope][1]公布了一张正在为Ubuntu平台开发的应用程序的截图,该程序命名为DowNow。 + +这是一个相对较新的应用程序,而且仍然在开发中,你可以在Launchpad点击DowNow 0.3安装包,如果你想要获得更多详情,你也可以从Ubuntu软件中心下载。 + +目前,只有Nexus4和Nexus7设备支持,如果你想要在更多手机上尝试Ubuntu,也许还要等待几个月。 + +-------------------------------------------------------------------------------- + +via: http://news.softpedia.com/news/Ubuntu-Touch-Now-Has-a-Torrent-Clinent-in-the-Ubuntu-Store-457538.shtml + +作者:[Silviu Stahie][a] +译者:[disylee](https://github.com/disylee) +校对:[wxy](https://github.com/wxy) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://news.softpedia.com/editors/browse/silviu-stahie +[1]:https://plus.google.com/u/0/+AlanPope/posts/Ej3vKVxBum8 \ No newline at end of file diff --git a/published/20140910 Colourful systemd vs sysVinit Linux Cheatsheet.md b/published/201410/20140910 Colourful systemd vs sysVinit Linux Cheatsheet.md similarity index 100% rename from published/20140910 Colourful systemd vs sysVinit Linux Cheatsheet.md rename to published/201410/20140910 Colourful systemd vs sysVinit Linux Cheatsheet.md diff --git a/published/201410/20140910 Jelly Conky Adds Simple, Stylish Stats To Your Linux Desktop.md b/published/201410/20140910 Jelly Conky Adds Simple, Stylish Stats To Your Linux Desktop.md new file mode 100644 index 0000000000..e4b0814c2b --- /dev/null +++ b/published/201410/20140910 Jelly Conky Adds Simple, Stylish Stats To Your Linux Desktop.md @@ -0,0 +1,37 @@ +Jelly Conky为你的Linux桌面带来简约、时尚的状态信息 +================================================================================ +**我把Conky当成壁纸一样使用:我会找出一个我喜欢的样式,下一周当我厌烦了想要一点小改变时我就更换另外一个样式。** + +不断更换样式的部分原因是由于日益增多的样式目录。我最近最喜欢的样式是Jelly Conky。 + +![](http://www.omgubuntu.co.uk/wp-content/uploads/2014/09/jelly-conky.png) + +Jelly Conky遵循了许多我们推荐的Conky风格采用的最小设计原则。它并不想成为一个大杂烩。它不会被那些喜欢一眼就能看到他们硬盘温度和IP地址的人所青睐。 + +它配备了三种不同的模式,它们都可以添加个性的或者静态背景图像: + +- 时钟 +- 时钟加日期 +- 时钟加日期和天气 + +一些人不理解为什么要在桌面上拥有重复的时钟。这是很好理解的。对于我而言,这不仅仅是功能(虽然,个人而言,Conky的时钟比挤在上部面板上那渺小的数字要更容易看清)。 + +我想如果你的Android主屏幕有一个时间小部件的话,你不会介意在你的桌面上也有这么一个的,对吧? + +你可以从下述链接下载Jelly Conky,zip 包里面有一个说明如何安装的 readme 文件。如果希望看到完整的教程,可以[参考我们的前一篇文章][3]。 +- [从Deviant Art上下载 Jelly Conky][2] + +-------------------------------------------------------------------------------- + +via: http://www.omgubuntu.co.uk/2014/09/jelly-conky-for-linux-desktop + +作者:[Joey-Elijah Sneddon][a] +译者:[geekpi](https://github.com/geekpi) +校对:[wxy](https://github.com/wxy) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:https://plus.google.com/117485690627814051450/?rel=author +[1]:http://www.omgubuntu.co.uk/2014/07/conky-circle-theme-nod-lg-quick-cover +[2]:http://zagortenay333.deviantart.com/art/Jelly-Conky-442559003 +[3]:http://www.omgubuntu.co.uk/2014/07/conky-circle-theme-nod-lg-quick-cover \ No newline at end of file diff --git a/published/20140910 Meet the 12 Ubuntu 14.10 Wallpaper Contest Winners (So Far).md b/published/201410/20140910 Meet the 12 Ubuntu 14.10 Wallpaper Contest Winners (So Far).md similarity index 100% rename from published/20140910 Meet the 12 Ubuntu 14.10 Wallpaper Contest Winners (So Far).md rename to published/201410/20140910 Meet the 12 Ubuntu 14.10 Wallpaper Contest Winners (So Far).md diff --git a/translated/tech/20140910 [Quick Tip] How To List All Installed Packages On Linux Distributions.md b/published/201410/20140910 [Quick Tip] How To List All Installed Packages On Linux Distributions.md similarity index 87% rename from translated/tech/20140910 [Quick Tip] How To List All Installed Packages On Linux Distributions.md rename to published/201410/20140910 [Quick Tip] How To List All Installed Packages On Linux Distributions.md index ff15cd3b9b..213e1cf279 100644 --- a/translated/tech/20140910 [Quick Tip] How To List All Installed Packages On Linux Distributions.md +++ b/published/201410/20140910 [Quick Tip] How To List All Installed Packages On Linux Distributions.md @@ -1,5 +1,4 @@ -2q1w2007翻译中 -[小贴士] 怎么在Linux发行版下列出所有安装了的包 +怎么在Linux发行版下列出所有安装了的包 ================================================================================ ![](http://180016988.r.cdn77.net/wp-content/uploads/2014/09/linux-790x536.png) @@ -39,7 +38,7 @@ dpkg -l -祝你有好的一天。 +祝你一天好心情。 -------------------------------------------------------------------------------- @@ -47,7 +46,7 @@ via: http://www.unixmen.com/quick-tip-list-installed-packages-linux-distribution 作者:[Enock Seth Nyamador][a] 译者:[2q1w2007](https://github.com/2q1w2007) -校对:[校对者ID](https://github.com/校对者ID) +校对:[wxy](https://github.com/wxy) 本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 diff --git a/published/201410/20140911 Install UberWriter Markdown Editor In Ubuntu 14.04.md b/published/201410/20140911 Install UberWriter Markdown Editor In Ubuntu 14.04.md new file mode 100644 index 0000000000..2b903e3c00 --- /dev/null +++ b/published/201410/20140911 Install UberWriter Markdown Editor In Ubuntu 14.04.md @@ -0,0 +1,59 @@ +在Ubuntu14.04上安装UberWriterMarkdown编辑器 +================================================================================ +这是一篇快速教程指导我们如何通过官方的PPA源在Ubuntu14.04上安装UberWriter编辑器。 + +[UberWriter][1]是一款Ubuntu下的Markdown编辑器,它简洁的界面能让我们更致力于编辑文字。UberWriter利用了[pandoc][3](一个格式转换器)。但由于UberWriter的UI是基于GTK3的,因此不能完全兼容Unity桌面系统。以下是对UberWriter功能的列举: + +- 简洁的界面 +- 使用pandoc转换markdown +- 可预览 +- 免打扰模式 +- 拼写检查 +- 语法高亮,能在html和pdf中出现数学公式 +- 支持导出到PDF,HTML,ODT等 + +### 在Ubuntu14.04上安装UberWriter ### + +UberWriter可以在[Ubuntu软件中心][4]中找到但是安装需要支付5刀。如果你真的喜欢这款编辑器并想为开发者提供一些资金支持的话,我很建议你购买它。 + +除此之外,UberWriter也能通过官方的PPA源来免费安装。通过如下命令: + + sudo add-apt-repository ppa:w-vollprecht/ppa + sudo apt-get update + sudo apt-get install uberwriter + +安装完毕之后,你可以通过Unity的Dash运行使用。如你所见,它支持markdown的语法高亮: + +![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/09/UberWriter_Ubuntu.jpeg) + +你可以使用预览功能来查看你的文档: + +![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/09/UberWriter_Ubuntu_1.jpeg) + +我尝试导出到PDF的时候被提示安装texlive。 + +![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/09/UberWriter_Ubuntu_PDF_Export.png) + +虽然导出到HTML和ODT格式是好的。 + +在Linux下还有一些其他的markdown编辑器。[Remarkable][5]是一款能够实时预览的编辑器,UberWriter却不能,不过总的来说它是一款很不错的应用。如果你在寻找文本编辑器的话,你可以试试[Texmaker LaTeX editor][6]。 + +系统这个教程能够帮你在Ubuntu14.04上成功安装UberWriter。我猜想UberWriter在Ubuntu12.04,Linux Mint 17,Elementary OS和其他在Ubuntu的基础上的Linux发行版上也能成功安装。 + +-------------------------------------------------------------------------------- + +via: http://itsfoss.com/install-uberwriter-markdown-editor-ubuntu-1404/ + +作者:[Abhishek][a] +译者:[John](https://github.com/johnhoow) +校对:[Caroline](https://github.com/carolinewuyan) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://itsfoss.com/author/Abhishek/ +[1]:http://uberwriter.wolfvollprecht.de/ +[2]:http://en.wikipedia.org/wiki/Markdown +[3]:http://johnmacfarlane.net/pandoc/ +[4]:apt://uberwriter +[5]:http://itsfoss.com/remarkable-markdown-editor-linux/ +[6]:http://itsfoss.com/install-latex-ubuntu-1404/ diff --git a/published/201410/20140912 How to Go Hands On With the Utopic Unicorn--Literally.md b/published/201410/20140912 How to Go Hands On With the Utopic Unicorn--Literally.md new file mode 100644 index 0000000000..b0c57b8273 --- /dev/null +++ b/published/201410/20140912 How to Go Hands On With the Utopic Unicorn--Literally.md @@ -0,0 +1,38 @@ +如何“上手”体验乌托邦独角兽! +================================================================================ +**想要知道如何在正式发布前上手体验乌托邦独角兽(Utopic Unicorn)?现在你就可以做到!—— 真的是[“上手”][1]体验哦~!** + +显然是为了庆祝即将发布的同名Ubuntu,Canonical上线了一款“手把手教你独角兽折纸指南”。这一活动作为该公司[2014 Deconstruct][2] 大会的一部分出现,大会于九月上旬在英国Brighton举办。 + +![Image: Alejandra Obregon](http://www.omgubuntu.co.uk/wp-content/uploads/2014/09/ubuntu-unicorns-750x745.jpg) + +供图: Alejandra Obregon + +大会为期一天,为富有创造力的专家以及数字文化狂热者们提供了一个理想的交流场所,Canonical将展示一个正在开发中版本的 Ubuntu Phone,内容包括具体的设计以及用户交互界面,用以满足与会观众。 + +人们对这一折纸活动的反响很积极。折纸独角兽作品最棒的人,将会获得一部全新的 Ubuntu 手机,这大大激发了人们的积极性。 + +### 下载折纸独角兽 ### + +其余没有获奖的朋友,也不要气馁,下载折纸独角兽还是会有惊喜哦~ + +如果你有五分钟的休息时间,为什么不玩玩这个折纸娱乐一下呢?如果你认为自己折出来的独角兽非常非常出(la)色(ji),请在[Twitter][3] 或 [Google+][4]上给我们发照片~(译者表示不爽!这是诚心不给我们天朝百姓获奖的机会吗?) + +- [下载 ‘Make a Unicorn’ 手工折纸][5] + +-------------------------------------------------------------------------------- + +via: http://www.omgubuntu.co.uk/2014/09/unicorn-origami-download-pdf-ubuntu-utopic + +作者:[Joey-Elijah Sneddon][a] +译者:[Mr小眼儿](http://blog.csdn.net/tinyeyeser) +校对:[wxy](https://github.com/wxy) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:https://plus.google.com/117485690627814051450/?rel=author +[1]:http://design.canonical.com/2014/09/canonical-and-ubuntu-at-dconstruct/ +[2]:http://2014.dconstruct.org/ +[3]:http://twitter.com/omgubuntu +[4]:http://plus.google.com/+omgubuntu +[5]:http://design.canonical.com/wp-content/uploads/042_CAN_dConstruct_instructions.pdf diff --git a/translated/tech/20140912 QuiteRSS--RSS Reader For Desktop Linux.md b/published/201410/20140912 QuiteRSS--RSS Reader For Desktop Linux.md similarity index 50% rename from translated/tech/20140912 QuiteRSS--RSS Reader For Desktop Linux.md rename to published/201410/20140912 QuiteRSS--RSS Reader For Desktop Linux.md index a69844dc1b..c7da331e4c 100644 --- a/translated/tech/20140912 QuiteRSS--RSS Reader For Desktop Linux.md +++ b/published/201410/20140912 QuiteRSS--RSS Reader For Desktop Linux.md @@ -1,47 +1,46 @@ -2q1w2007翻译中 QuiteRSS: Linux桌面的RSS阅读器 ================================================================================ -[QuiteRSS][1]是一个自由而[开源][2]的RSS/Atome阅读器。它可以运行在Windows , Linux和Mac上运行。它用C++/QT编写,所以它会有更好的未来。 +[QuiteRSS][1]是一个免费的[开源][2]RSS/Atome阅读器。它可以在Windows、Linux和Mac上运行。它用C++/QT编写。它有许多的特色功能。 -QuiteRSS的界面让我想起Lotus Notes mail,会有很多RSS信息排列在大小合适的方块上,你可以通过标签分组。需要查找东西时,只需在下面板上打开RSS信息。 +QuiteRSS的界面让我想起Lotus Notes mail,会有很多RSS信息排列在右侧面板上,你可以通过标签分组。点击一个 RSS 条目时,会在下方的面板里面显示该信息。 ![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/09/QuiteRSS_Ubuntu.jpeg) -除了上述功能,它还有一个广告屏蔽器,一个报纸输出视图,通过URL特性导入RSS等众多功能。你可以在[这里][3]查找到完整的功能列表。 +除了上述功能,它还有一个广告屏蔽器,一个报纸视图,通过URL导入RSS源等众多功能。你可以在[这里][3]查找到完整的功能列表。 ### 在 Ubuntu 和 Linux Mint 上安装 QuiteRSS ### -QuiteRSS在Ubuntu 14.04 和 Linux Mint 17中可用。你可以很简单的通过以下命令行安装: +QuiteRSS在Ubuntu 14.04 和 Linux Mint 17中可用。你可以通过以下命令行轻松安装: sudo apt-get install quiterss -如果你想安装最新的稳定版本,你可以用官方的[QuiteRSS PPA][4]: +如果你想安装最新的稳定版本,你可以使用官方的[QuiteRSS PPA][4]: sudo add-apt-repository ppa:quiterss/quiterss sudo apt-get update sudo apt-get install quiterss -上面的命令在所有基于Ubuntu的发行版像 Linux Mint, Elementary OS, Linux Lite, Pinguy OS 都应该好用。在其他Linux发行版和平台上,你可以从 [下载页][5]获得源码来安装. +上面的命令支持所有基于Ubuntu的发行版,比如Linux Mint, Elementary OS, Linux Lite, Pinguy OS等等。对于其他Linux发行版和平台上,你可以从 [下载页][5]获得源码来安装。 ### 卸载 QuiteRSS ### -用下方命令卸载 QuiteRSS: +用下列命令卸载 QuiteRSS: sudo apt-get remove quiterss -如果你用了PPA,你还需要从源列表中把仓库删除: +如果你使用了PPA,你还也应该从源列表中把仓库删除: sudo add-apt-repository --remove ppa:quiterss/quiterss -QuiteRSS是一个不错的开源RSS阅读器,尽管我更喜欢[Feedly][6]。尽管现在 Feedly 还没有Linux桌面程序,但是你依然可以在网页浏览器中使用。我希望你会认为QuiteRSS值得一试。 +QuiteRSS是一个不错的开源RSS阅读器,尽管我更喜欢[Feedly][6]。不过现在 Feedly 还没有Linux桌面程序,但是你依然可以在网页浏览器中使用。希望你会觉得QuiteRSS值得在桌面Linux一试。 -------------------------------------------------------------------------------- via: http://itsfoss.com/quiterss-rss-reader-desktop-linux/ - + 作者:[Abhishek][a] -译者:[2q1w2007(https://github.com/2q1w2007) -校对:[校对者ID](https://github.com/校对者ID) +译者:[2q1w2007](https://github.com/2q1w2007) +校对:[Caroline](https://github.com/carolinewuyan) 本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 @@ -51,4 +50,4 @@ via: http://itsfoss.com/quiterss-rss-reader-desktop-linux/ [3]:http://quiterss.org/en/about [4]:https://launchpad.net/~quiterss/+archive/ubuntu/quiterss/ [5]:http://quiterss.org/en/download -[6]:http://feedly.com/ \ No newline at end of file +[6]:http://feedly.com/ diff --git a/published/201410/20140915 How To Uninstall Ubuntu Linux From Windows 8 Dual Boot.md b/published/201410/20140915 How To Uninstall Ubuntu Linux From Windows 8 Dual Boot.md new file mode 100644 index 0000000000..247b4d1577 --- /dev/null +++ b/published/201410/20140915 How To Uninstall Ubuntu Linux From Windows 8 Dual Boot.md @@ -0,0 +1,127 @@ +从Windows双启动中卸载Ubuntu Linux +================================================================================ +![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/09/Guide_Uninstall_Ubuntu_Windows_dual_Boot.jpeg) + +我在过去已经多次涉及到[在UEFI模式下安装Ubuntu 14.04与Windows 8/8.1双启动][1]的话题。 但是要怎么从**Windows双启动中卸载Ubuntu呢**?下面我们将看到的教程适用于任意的Linux操作系统,如Ubuntu,Linux Mint,Elementary OS或其它任意Linux发行版。 + +如果你认为[在双启动模式下安装Ubuntu与Windows 8共存][2]是件难事,而从Windows双启动中移除Ubuntu将是很简单的,你的想法并不是完全错误的。如果你有个Windows安装介质的话,从Windows双启动中卸载Linux将是轻而易举的。 + +这个教程将教你如何在有**Windows 8/8.1安装介质**的情况下将Linux从Windows 8或Windows 8.1双启动中完全移除。 + +### 将Ubuntu从Windows 8双启动中安全卸载 ### + +你有没有Windows 8安装介质以及是否已经安装了Windows 8.1在你系统上这都不重要。它同样工作得很好。但是我不能说在Windows 7上也一样。如果你身边有Windows安装盘,让我们开始从Windows双启动中移除Ubuntu的进程吧。 + +从双启动中删除Linux分为两部分。第一部分是删除Linux安装的所在分区。第二部分是修复Windows启动引导,因为简单地将Linux分区删除会引起[“Grub rescue”错误][3]。 + +### 第一部分:在Windows下删除Linux分区 ### + +**第一步:** + +登录Windows。按下 **Windows+R** 然后在其中运行 diskmgmt.msc 命令。它将会打开Windows磁盘管理工具。 + +![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/09/Disk_Mgmt.jpg) + +**第二步:** + +在你安装了Linux之后,就能很容易地从大小上分辨出Linux分区。另一个分辨Linux分区的提示是找没有文件系统以及驱动器卷标的分区。Windows分区通常用卷标进行标记,比如C,D,E等等,而且通常是NTFS或FAT文件系统。 + +就像你所能看到的,我在这里有三个Linux分区,因为我在安装Ubuntu时单独地创建了根分区(root),交换分区(swap)和家目录(home)。 + +![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/09/Uninstall_Linux_From_WIndows_Dual_Boot.jpg) + +**Step 3:** +**第三步:** + +选择Linux分区,右键点击并选择 **删除卷** 选项。 + +![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/09/Uninstall_Linux_From_WIndows_Dual_Boot_1.jpg) + +如果出现了警告,在这里选择是即可。 + +![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/09/Uninstall_Linux_From_WIndows_Dual_Boot_2.jpg) + +**Step 4:** +**第四步:** + +被删除的分区会变成一块可用的空闲空间。你可以用它来扩展已有的卷或创建一个新的Windows分区。我会建议你创建一个新的驱动器(或是卷或者分区,随便你怎么叫),因为这样子万一你将来又想将Linux和Winodws双启动时会简单一点。 + +![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/09/Uninstall_Linux_From_WIndows_Dual_Boot_3.jpg) + +#### 第二部分:修复Windows启动引导 #### + +一旦你删除了Linux分区,就是时候修复Windows启动引导了。这里的图片看起来可能不是很清楚,因为相对于Windows来说[在Ubuntu下对登录画面进行截图][4]要简单的多。我用手机相机拍下了这些照片。 + +**第一步:** + +**插入Windows 8安装介质并重启**你的电脑。在启动的时候按下F10或F12进入BIOS/UEFI,选择**从可移除介质启动(boot from removable disk)**。 + +![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/09/Uninstall_Linux_Windows_Dualboot_1.jpg) + +**第二步:** + +选择修复你的计算机(repair your computer): + +![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/09/Uninstall_Linux_Windows_Dualboot_3.jpg) + +**第三步:** + +在这里选择疑难解答(Troubleshoot): + +![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/09/Uninstall_Linux_Windows_Dualboot_2.jpg) + +**第四步:** + +在疑难解答页面,选择高级选项(Advanced options): + +![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/09/Uninstall_Linux_Windows_Dualboot_4.jpg) + +**第五步:** + +找到这里的命令提示符(command prompt): + +![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/09/Uninstall_Linux_Windows_Dualboot_6.jpg) + +**第六步:** + +在命令行中输入下列命令来修复Windows启动引导: + + bootrec.exe /fixmbr + +正常情况下,它是立即生效的,你甚至都不用等。 + +![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/09/Uninstall_Linux_Windows_Dualboot_5.jpg) + +**第七步:** + +一旦完成了这一步,重启你的电脑,这次从硬盘正常启动。你应该能够启动进入Windows。如果你仍然看到Grub rescue错误,试试下面的步骤。 + +**第八步:如果第六步中的方法不起作用** + +如果第六步中的命令不起作用,试试高级疑难解答中的自动修复选项。 + +![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/09/Uninstall_Linux_Windows_Dualboot_8.jpg) + +它会花点时间查找问题然后修复它。 + +![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/09/Uninstall_Linux_Windows_Dualboot_7.jpg) + +现在如果你重启的话,你应该能够正常进入Windows,不再看到任何的Grub rescue错误提示。 + +我希望这个指南能够帮助你**将Ubuntu从Windows 8双启动中完全移除**。欢迎提出任何问题与建议。 + +-------------------------------------------------------------------------------- + +via: http://itsfoss.com/uninstall-ubuntu-linux-windows-dual-boot/ + +作者:[Abhishek][a] +译者:[alim0x](https://github.com/alim0x) +校对:[Caroline](https://github.com/carolinewuyan) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://itsfoss.com/author/Abhishek/ +[1]:http://linux.cn/article-3178-1.html +[2]:http://itsfoss.com/install-ubuntu-dual-boot-mode-windows/ +[3]:http://itsfoss.com/solve-error-partition-grub-rescue-ubuntu-linux/ +[4]:http://itsfoss.com/screenshot-login-screen-ubuntu-linux/ diff --git a/published/201410/20140915 Linux FAQs with Answers--How to find and remove obsolete PPA repositories on Ubuntu.md b/published/201410/20140915 Linux FAQs with Answers--How to find and remove obsolete PPA repositories on Ubuntu.md new file mode 100644 index 0000000000..5df96720b1 --- /dev/null +++ b/published/201410/20140915 Linux FAQs with Answers--How to find and remove obsolete PPA repositories on Ubuntu.md @@ -0,0 +1,44 @@ +Linux有问必答——如何查找并移除Ubuntu上陈旧的PPA仓库 +================================================================================ +> **问题**:我试着通过运行apt-get update命令来再次同步包索引文件,但是却出现了“404 无法找到”的错误,看起来似乎是我不能从先前添加的第三方PPA仓库中获取最新的索引。我怎样才能清除这些破损而且陈旧的PPA仓库呢? + + Err http://ppa.launchpad.net trusty/main amd64 Packages + 404 Not Found + Err http://ppa.launchpad.net trusty/main i386 Packages + 404 Not Found + W: Failed to fetch http://ppa.launchpad.net/finalterm/daily/ubuntu/dists/trusty/main/binary-amd64/Packages 404 Not Found + + W: Failed to fetch http://ppa.launchpad.net/finalterm/daily/ubuntu/dists/trusty/main/binary-i386/Packages 404 Not Found + + E: Some index files failed to download. They have been ignored, or old ones used instead. + +当你试着更新APT包索引时,“404 无法找到”错误总是会在版本更新之后发生。就是说,在你升级你的Ubuntu发行版后,你在旧的版本上添加的一些第三方PPA仓库就不再受新版本的支持。在此种情况下,你可以像下面这样来**鉴别并清除那些破损的PPA仓库**。 + +首先,找出那些引起“404 无法找到”错误的PPA。 + + $ sudo apt-get update | grep "Failed" + +![](https://farm6.staticflickr.com/5580/14972354938_0e1e1f3db6_z.jpg) + +在本例中,Ubuntu Trusty不再支持的PPA仓库是“ppa:finalterm/daily”。 + +去[移除PPA仓库][1]吧。 + + $ sudo add-apt-repository --remove ppa:finalterm/daily + +你得去重复重复再重复,把上面找到的所有过时的PPA仓库一个一个地移除。 + +![](https://farm4.staticflickr.com/3844/15158541642_1fc8f92c77_z.jpg) + +在移除所有过时的PPA仓库后,重新运行“apt-get update”命令来检查它们是否都被成功移除。 + +-------------------------------------------------------------------------------- + +via: http://ask.xmodulo.com/find-remove-obsolete-ppa-repositories-ubuntu.html + +译者:[GOLinux](https://github.com/GOLinux) +校对:[Caroline](https://github.com/carolinewuyan) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[1]:http://ask.xmodulo.com/how-to-remove-ppa-repository-from-command-line-on-ubuntu.html diff --git a/published/201410/20140915 One of the Smallest Distros in the World, Tiny Core, Gets a Fresh Update.md b/published/201410/20140915 One of the Smallest Distros in the World, Tiny Core, Gets a Fresh Update.md new file mode 100644 index 0000000000..eac233ac21 --- /dev/null +++ b/published/201410/20140915 One of the Smallest Distros in the World, Tiny Core, Gets a Fresh Update.md @@ -0,0 +1,39 @@ +世界上最小的发行版之一Tiny Core有了更新 +================================================================================ +![Tiny Core desktop](http://i1-news.softpedia-static.com/images/news2/One-of-the-Smallest-Distros-in-the-World-Tiny-Core-Gets-a-Fresh-Update-458785-2.jpg) + +Tiny Core + +**Robert Shingledecker 宣布了最终版本的Tiny Core 5.4 Linux操作系统已经可以即刻下载,这也使它成为世界上最小的发行版之一。** + +发行版的名字说明了一切,但是开发者依然集成了一些有意思的包和一个轻量的桌面来与它相匹配。这次最新的迭代只有一个候选版本,而且它也是迄今为止最安静的版本之一。 + +官网上的开发者说"Tiny Core是一个简单的范例来说明核心项目可以提供什么。它提供了一个12MB的FLTK/FLWM桌面。用户对提供的程序和外加的硬件有完整的控制权。你可以把它用在桌面、笔记本或者服务器上,这可以由用户从在线库中安装附加程序时选择,或者用提供的工具编译大多数你需要的。" + +根据更新日志,NFS的入口被添加,'Done'将在新的一行里显示,udev也升级到174来修复竞态条件问题。 + +关于修改和升级的完整内容可以在官方的[声明][1]里找到。 + +你可以点击以下链接下载Tiny Core Linux 5.4. + +- [Tiny Core Linux 5.4 (ISO)][2][iso] [14 MB] +- [Tiny Core Plus 5.4 (ISO)][3][iso] [72 MB] +- [Core 5.4 (ISO)][4][iso] [8.90 MB] + +这些发行版都有Live,你可以在安装之前试用。 + +-------------------------------------------------------------------------------- + +via: http://news.softpedia.com/news/One-of-the-Smallest-Distros-in-the-World-Tiny-Core-Gets-a-Fresh-Update-458785.shtml + +作者:[Silviu Stahie][a] +译者:[2q1w2007](https://github.com/2q1w2007) +校对:[Caroline](https://github.com/carolinewuyan) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://news.softpedia.com/editors/browse/silviu-stahie +[1]:http://forum.tinycorelinux.net/index.php/topic,17487.0.html +[2]:http://distro.ibiblio.org/pub/linux/distributions/tinycorelinux/5.x/x86/release/TinyCore-5.4.iso +[3]:http://repo.tinycorelinux.net/5.x/x86/release/CorePlus-5.4.iso +[4]:http://distro.ibiblio.org/tinycorelinux/5.x/x86/release/Core-current.iso diff --git a/published/201410/20140915 Potenza Icon Themes 2.0 Available For Download.md b/published/201410/20140915 Potenza Icon Themes 2.0 Available For Download.md new file mode 100644 index 0000000000..992c8bfd91 --- /dev/null +++ b/published/201410/20140915 Potenza Icon Themes 2.0 Available For Download.md @@ -0,0 +1,44 @@ +Potenza 图标主题2.0已可下载 +================================================= +![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/09/Potenza_Icons.jpeg) + +[Potenza][1]图标主题版本2.0已经发布。Potenza 图标的灵感来自[faenza][2],faenza是我们在[Ubuntu 13.10的最佳图标][3]的列出的一款漂亮的图标主题。 + +Potenza 的开发者 Alessandro Bompadre说,他曾试图建立一个适用于Linux的完整图标集,它应该适合各种桌面环境,包括如Unity,Gnome,Cinnamon,KDE等。 + +###下载 Potenza 图标### + +Potenza 图标可在 Ubuntu,Linux Mint、Elementary OS、Linux Lite 等环境中通过Noobslab的PPA来安装。只有一点需要提醒你,因为要为所有主要类型的桌面环境提供了大量的图标,所以总下载字节大概是400 MB。 + +打开一个终端,使用下面的命令: + + sudo add-apt-repository ppa:noobslab/potenza + sudo apt-get update + sudo apt-get install potenza-2 + +如果你不想使用PPA,您也可以从下面的链接安装该图标主题: + +- [下载 Potenza 图标主题][4] + +解压文件到 ~/.icons 目录。在Ubuntu的Unity环境中,你可以[使用Unity Tweak Tool把当前的图标主题切换][5] 为 Potenza 。 + +希望你喜欢Potenza,您也可以试试[Dalisha图标主题][6]或看看我们的[Ubuntu 14.04的最佳图标主题列表][7]。 + +-------------------------------------------------- ------------------------------ + +via: http://itsfoss.com/potenza-icon-themes-20-download/ + +作者:[Abhishek][a] +译者:[fbigun](https://github.com/fbigun) +校对:[wxy](https://github.com/wxy) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://itsfoss.com/author/Abhishek/ +[1]:https://github.com/AlessandroBompadre/Potenza/ +[2]:http://tiheum.deviantart.com/art/Faenza-Icons-173323228 +[3]:http://itsfoss.com/best-icon-themes-ubuntu-1310/ +[4]:http://gnome-look.org/content/show.php/Potenza+2.0?content=166853 +[5]:http://itsfoss.com/best-icon-themes-ubuntu-1404/ +[6]:http://itsfoss.com/dalisha-icon-ubuntu-linux/ +[7]:http://itsfoss.com/best-icon-themes-ubuntu-1404/ diff --git a/published/201410/20140917 GNOME Control Center 3.14 RC1 Corrects Lots of Potential Crashes.md b/published/201410/20140917 GNOME Control Center 3.14 RC1 Corrects Lots of Potential Crashes.md new file mode 100644 index 0000000000..aef8750f6b --- /dev/null +++ b/published/201410/20140917 GNOME Control Center 3.14 RC1 Corrects Lots of Potential Crashes.md @@ -0,0 +1,41 @@ +GNOME控制中心3.14 RC1修复了大量潜在崩溃问题 +================================================================================ +![GNOME Control Center in Arch Linux](http://i1-news.softpedia-static.com/images/news2/GNOME-Control-Center-3-14-RC1-Correct-Lots-of-Potential-Crashes-458986-2.jpg) + +Arch Linux下的GNOME控制中心 + +**GNOME控制中心,可以在GNOME中更改你的桌面各个方面设置的主界面,已经升级至3.14 RC1,伴随而来的是大量来自GNOME stack的包。** + +GNOME控制中心是在GNOME生态系统中十分重要的软件之一,尽管不是所有的用户意识到了它的存在。GNOME控制中心是管理由GNOME驱动的操作系统中所有设置的部分,就像你从截图里看到的那样。 + +GNOME控制中心不是很经常被宣传,它实际上是GNOME stack中为数不多的源代码包和安装后的应用名称不同的软件包。源代码包的名字为GNOME控制中心,但用户经常看到的应用名称是“设置”或“系统设置”,取决于开发者的选择。 + +### GNOME控制中心 3.14 RC1 带来哪些新东西 ### + +通过更新日志可以得知,升级了libgd以修复GdNotification主题,切换视图时背景选择对话框不再重新调整大小,选择对话框由三个不同视图组合而成,修复Flickr支持中的一个内存泄漏,在“日期和时间”中不再使用硬编码的字体大小,修复改换窗口管理器(或重启)时引起的崩溃,更改无线网络启用时可能引起的崩溃也已被修复,以及纠正了更多可能的WWAN潜在崩溃因素。 + +此外,现在热点仅在设备活动时运行,所有虚拟桥接现在是隐藏的,不再显示VPN连接的底层设备,默认不显示空文件夹列表,解决了几个UI填充问题,输入焦点现在重新回到了账户对话框,将年份设置为0时导致的崩溃已修复,“Wi-Fi热点”属性居中,修复了打开启用热点时弹出警告的问题,以及现在打开热点失败时将弹出错误信息。 + +完整的变动,更新以及bug修复,参见官方[更新日志][1]。 + +你可以下载GNOME控制中心 3.14 RC1: + +- [tar.xz (3.12.1 稳定版)][2][sources] [6.50 MB] +- [tar.xz (3.14 RC1 开发版)][3][sources] [6.60 MB] + +这里提供的仅仅是源代码包,你必须自己编译以测试GNOME控制中心。除非你真的知道自己在做什么,否则你应该等到完整的GNOME stack在源中可用时再使用。 + +-------------------------------------------------------------------------------- + +via: http://news.softpedia.com/news/GNOME-Control-Center-3-14-RC1-Correct-Lots-of-Potential-Crashes-458986.shtml + +作者:[Silviu Stahie][a] +译者:[alim0x](https://github.com/alim0x) +校对:[wxy](https://github.com/wxy) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://news.softpedia.com/editors/browse/silviu-stahie +[1]:http://ftp.acc.umu.se/pub/GNOME/sources/gnome-control-center/3.13/gnome-control-center-3.13.92.news +[2]:http://ftp.acc.umu.se/pub/GNOME/sources/gnome-control-center/3.12/gnome-control-center-3.12.1.tar.xz +[3]:http://ftp.acc.umu.se/pub/GNOME/sources/gnome-control-center/3.13/gnome-control-center-3.13.92.tar.xz diff --git a/published/201410/20140919 Another Italian City Says Goodbye To Microsoft Office, Will Switch To OpenOffice Soon.md b/published/201410/20140919 Another Italian City Says Goodbye To Microsoft Office, Will Switch To OpenOffice Soon.md new file mode 100644 index 0000000000..1fd4d81ec7 --- /dev/null +++ b/published/201410/20140919 Another Italian City Says Goodbye To Microsoft Office, Will Switch To OpenOffice Soon.md @@ -0,0 +1,36 @@ +欧洲现在很流行拥抱开源 +================================================================================ +![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/08/Turin_Open_Source.jpg) + +看来拥抱[开源][1]最近在欧洲的国家很流行。上个月我们我只听说[都灵成为意大利首个官方接受开源产品的城市][2]。另一个意大利西北部城市,[乌迪内][3],已经宣布他们正在抛弃微软Office转而迁移到[OpenOffice][4]。 + +乌迪内有100,000的人口并且行政部门有大约900台电脑,它们都运行着微软Windows以及它的默认产品套装。根据[预算文档][5],迁移将在大约12月份时进行,从80台新电脑开始。接着将会是旧电脑迁移到OpenOffice。 + +迁移估计会节省一笔授权费用,不然将会每台电脑花费大约400欧元,总计360,000欧元。但是节约成本并不是迁移的唯一目的,获得常规的软件升级也是其中一个因素。 + +当然从微软的Office到OpenOfifice不会太顺利。不过,全市的培训计划是先让少数员工使用安装了OpenOffice的电脑。 + +如我先前说明的,这似乎在欧洲是一个趋势。在今年早些时候在[西班牙的加那利群岛][7]之后[法国城市图卢兹也使用了LibreOffice中从而节省了100万欧元][6]。相邻的法国城市[日内瓦也有开源方面的迹象][8]。在世界的另一边,政府机构[泰米尔纳德邦][9]和印度喀拉拉邦省也抛弃了微软而使用开源软件。 + +伴随着经济的萧条,我觉得Windows XP的死亡一直是开源的福音。无论是什么原因,我很高兴看到这份名单越来越大。你看呢? + +-------------------------------------------------------------------------------- + +via: http://itsfoss.com/udine-open-source/ + +作者:[Abhishek][a] +译者:[geekpi](https://github.com/geekpi) +校对:[wxy](https://github.com/wxy) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://itsfoss.com/author/Abhishek/ +[1]:http://itsfoss.com/category/open-source-software/ +[2]:http://linux.cn/article-3602-1.html +[3]:http://en.wikipedia.org/wiki/Udine +[4]:https://www.openoffice.org/ +[5]:http://www.comune.udine.it/opencms/opencms/release/ComuneUdine/comune/Rendicontazione/PEG/PEG_2014/index.html?lang=it&style=1&expfolder=???+NavText+??? +[6]:http://linux.cn/article-3575-1.html +[7]:http://itsfoss.com/canary-islands-saves-700000-euro-open-source/ +[8]:http://itsfoss.com/170-primary-public-schools-geneva-switch-ubuntu/ +[9]:http://linux.cn/article-2744-1.html \ No newline at end of file diff --git a/published/201410/20140919 Mir and Unity 8 Status Update Arrives from Ubuntu Devs.md b/published/201410/20140919 Mir and Unity 8 Status Update Arrives from Ubuntu Devs.md new file mode 100644 index 0000000000..97698ad575 --- /dev/null +++ b/published/201410/20140919 Mir and Unity 8 Status Update Arrives from Ubuntu Devs.md @@ -0,0 +1,35 @@ +来自Ubuntu开发团队关于Mir和Unity 8的状态更新 +================================================================================ +> 目前Unity 8和Mir的开发进度很慢,但是仍在进行中 + +![](http://i1-news.softpedia-static.com/images/news2/Mir-and-Unity-8-Update-Arrive-from-Ubuntu-Devs-459263-2.jpg) + +**和其他项目一样,Canonical也在开发Unity桌面环境与Mir显示服务。开发团队刚刚发布了一个小的更新,据此我们可以知道都有些什么进展** + +Ubuntu开发者可能刚刚集中精力在一些重要的发布上,就像接下来的Ubuntu 14.10(Utopic Unicorn) 或者是新的面向移动设备的Ubuntu Touch,但是他们同样也涉及像Mir以及Unity 8这样的项目。 + +目前这代Ubuntu系统使用的是Unity 7桌面环境,但是新一代已经酝酿了很长一段时间。它与新的显示服务一起,已经在Ubuntu的移动版中了,但最终也要将它带到桌面上。 + +这两个项目的领导Kevin Gunn经常发布一些来自开发者的进度信息以及这周以来的一些改变,虽然这些都很粗略。 + +根据 [开发团队][1]的消息, 一些关于触摸/触发角的问题已经修正了,也修复了几个翻译问题,一些Dash UI相关的问题已经修复了,目前 团队在开发Mir 0.8,Mir 0.7.2将被升级,同时一些高优先级的bug处理也在进行中。 + +你可以[下载 Ubuntu Next][7]来体验新的Unity 8以及Mir的特性,但是还不够稳定。要等到成熟还需要一些时间。 + +-------------------------------------------------------------------------------- + +via: http://news.softpedia.com/news/Mir-and-Unity-8-Update-Arrive-from-Ubuntu-Devs-459263.shtml + +作者:[Silviu Stahie][a] +译者:[geekpi](https://github.com/geekpi) +校对:[wxy](https://github.com/wxy) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://news.softpedia.com/editors/browse/silviu-stahie +[1]:https://lists.launchpad.net/ubuntu-phone/msg09875.html +[2]:http://cdimage.ubuntu.com/daily-live/current/utopic-desktop-amd64.iso +[3]:http://cdimage.ubuntu.com/daily-live/current/utopic-desktop-i386.iso +[4]:http://cdimage.ubuntu.com/daily-live/current/utopic-desktop-amd64+mac.iso +[5]:http://cdimage.ubuntu.com/ubuntu-desktop-next/daily-live/current/utopic-desktop-amd64.iso +[6]:http://cdimage.ubuntu.com/ubuntu-desktop-next/daily-live/current/utopic-desktop-i386.iso \ No newline at end of file diff --git a/published/201410/20140919 Netflix Offers to Work with Ubuntu to Bring Native Playback to All.md b/published/201410/20140919 Netflix Offers to Work with Ubuntu to Bring Native Playback to All.md new file mode 100644 index 0000000000..e8b1dc8bfd --- /dev/null +++ b/published/201410/20140919 Netflix Offers to Work with Ubuntu to Bring Native Playback to All.md @@ -0,0 +1,48 @@ +Netflix支持 Ubuntu 上原生回放 +================================================================================ +![](http://www.omgubuntu.co.uk/wp-content/uploads/2014/08/netflix-ubuntu.jpg) + +**我们[上个月说的Netflix 的原生Linux支持很接近了][1],现在终于有了,我们只需几个简单的步骤就可以在Ubuntu桌面上启用HTML 5视频流了。 + +现在Netflix更近一步提供了支持。它希望给Ubuntu带来真正的开箱即用的Netflix回放。现在只需要更新**网络安全(Network Security Services,NSS)**服务库就行。 + +### 原生Netflix? Neato. ### + +在一封发给Ubuntu开发者邮件列表的[邮件中][2],Netflix的Paul Adolph解释了现在的情况: + +> “如果NSS的版本是3.16.2或者更高的话,Netflix可以在Ubuntu 14.04的稳定版Chrome中播放。如果版本超过了14.04,Netflix会作出一些调整,以避免用户必须对浏览器的 User-Agent 参数进行一些修改才能播放。” + +[LCTT 译注:此处原文是“14.02”,疑是笔误,应该是指Ubuntu 14.04。] + +很快要发布的Ubuntu 14.10提供了更新的[NSS v3.17][3], 而目前大多数用户使用的版本 Ubuntu 14.04 LTS 提供的是 v3.15.x。 + +NSS是一系列支持多种安全功能的客户端和服务端应用的库,包括SSL,TLS,PKCS和其他安全标准。为了让Ubuntu LTS用户可以尽快用上原生的HTML5 Netflix, Paul 问道: + +>”让一个新的NSS版本进入更新流的过程是什么?或者有人可以给我提供正确的联系方式么?“ + +Netflix今年早期时在Windows 8.1和OSX Yosemite上提供了HTML5视频回放,而不需要任何额外的下载或者插件。现在可以通过[加密媒体扩展][4]特性来使用。 + +虽然我们等待这讨论取得进展(并且希望可以完全解决),但是你仍可以在Ubuntu上[下面的指导来][5]修改HTML5 Netflix。 + +更新:9/19 + +本文发表后,Canonical 已经确认所需版本的NSS 库会按计划在下个“安全更新”中更新,预计 Ubuntu 14.04 LTS 将在两周内得到更新。 + +这个新闻让 Netflix 的Paul Adolph 很高兴,作为回应,他说当软件包更新后,他将“去掉 Chrome 中回放 Netflix HTML5 视频时的User-Agent 过滤,不再需要修改UA 了”。 + +-------------------------------------------------------------------------------- + +via: http://www.omgubuntu.co.uk/2014/09/netflix-linux-html5-nss-change-request + +作者:[Joey-Elijah Sneddon][a] +译者:[geekpi](https://github.com/geekpi) +校对:[wxy](https://github.com/wxy) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:https://plus.google.com/117485690627814051450/?rel=author +[1]:http://www.omgubuntu.co.uk/2014/08/netflix-linux-html5-support-plugins +[2]:https://lists.ubuntu.com/archives/ubuntu-devel-discuss/2014-September/015048.html +[3]:https://developer.mozilla.org/en-US/docs/Mozilla/Projects/NSS/NSS_3.17_release_notes +[4]:http://en.wikipedia.org/wiki/Encrypted_Media_Extensions +[5]:http://www.omgubuntu.co.uk/2014/08/netflix-linux-html5-support-plugins \ No newline at end of file diff --git a/published/201410/20140919 Red Hat Acquires FeedHenry for $82 Million to Advance Mobile Development.md b/published/201410/20140919 Red Hat Acquires FeedHenry for $82 Million to Advance Mobile Development.md new file mode 100644 index 0000000000..45f7718d45 --- /dev/null +++ b/published/201410/20140919 Red Hat Acquires FeedHenry for $82 Million to Advance Mobile Development.md @@ -0,0 +1,37 @@ +Red Hat公司8200万美元收购FeedHenry来推动移动开发 +================================================================================ +> 这是Red Hat公司进入移动开发领域的一次关键收获。 + +Red Hat公司的JBoss开发者工具事业部一直注重于企业开发,而忽略了移动方面。而如今这一切将随着Red Hat公司宣布用8200万美元收购移动开发供应商 [FeedHenry][1] 开始发生改变。这笔交易将在Red Hat公司2015财年的第三季度结束。 + +Red Hat公司的中间件总经理Mike Piech说当交易结束后FeedHenry公司的员工将会变成Red Hat公司的员工。 + +FeedHenry公司的开发平台能让应用开发者快速地开发出Android、IOS、Windows Phone以及黑莓的移动应用。FeedHenry的平台Node.js的编程结构有着深远影响,而那不是过去JBoss所涉及的领域。 + +"这次对FeedHenry公司的收购显著地提高了我们对于Node.js的支持与衔接。" Piech说。 + +Red Hat公司的平台即服务(PaaS)技术OpenShift已经有了一个Node.js的cartridge组件。此外,Red Hat公司的企业版Linux把Node.js的技术预览来作为Red Hat公司软件包的一部分。 + +尽管Node.js本身就是开源的,但不是所有FeedHenry公司的技术能在近期符合开源许可证的要求。作为Red Hat纵贯历史的政策, 现在也是致力于让FeedHenry开源的时候了。 + +"我们完成了收购,那么开源我们所收购的技术就是公司的首要任务,并且我们没有理由因Feedhenry而例外。"Piech说。 + +Red Hat公司最后一次主要的非开源性公司的收购是在2012年用104万美元收购 [ManageIQ][2] 公司。在今年的5月份,Red Hat公司成立了ManageIQ公司的开源项目,开放之前闭源的云管理技术代码。 + +从整合的角度来看,Red Hat公司还尚未精确地提供FeedHenry公司如何融入它的完整信息。 + +"我们已经确定了一些FeedHenry公司和我们已经存在的技术和产品能很好地相互融合和集成的范围," Piech说,"我们会在接下来的90天内分享更多我们发展蓝图的细节。" + +-------------------------------------------------------------------------------- + +via: http://www.datamation.com/mobile-wireless/red-hat-acquires-feedhenry-for-82-million-to-advance-mobile-development.html + +作者:[Sean Michael Kerner][a] +译者:[ZTinoZ](https://github.com/ZTinoZ) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://www.datamation.com/author/Sean-Michael-Kerner-4807810.html +[1]:http://www.feedhenry.com/ +[2]:http://www.datamation.com/cloud-computing/red-hat-makes-104-million-cloud-management-bid-with-manageiq-acquisition.html diff --git a/published/201410/20140922 Ten Blogs Every Ubuntu User Must Follow.md b/published/201410/20140922 Ten Blogs Every Ubuntu User Must Follow.md new file mode 100644 index 0000000000..0bc0290e0f --- /dev/null +++ b/published/201410/20140922 Ten Blogs Every Ubuntu User Must Follow.md @@ -0,0 +1,103 @@ +10个 Ubuntu 用户一定要知道的博客 +================================================================================ +![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/09/Best_Ubuntu_Blogs.jpg) + +**想要了解更多关于 ubuntu 的资讯,我们应该追哪些网站呢?** + +这是初学者经常会问的一个问题,在这里,我会告诉你们10个我最喜欢的博客,这些博客可以帮助我们解决问题,能让我们及时了解所有 Ubuntu 版本的更新消息。不,我谈论的不是通常的 Linux 和 shell 脚本一类的东东。我是在说一个流畅的 Linux 桌面系统和一个普通的用户所要的关于 Ubuntu 的经验。 + +这些网站帮助你解决你正遇到的问题,提醒你关注各种应用和提供给你来自 Ubuntu 世界的最新消息。这个网站可以让你对 Ubuntu 更了解,所以,下面列出的是10个我最喜欢的博客,它们包括了 Ubuntu 的方方面面。 + +###10个Ubutun用户一定要知道的博客### + +从我开始在 itsfoss 网站上写作开始,我特意把它排除在外,没有列入名单。我也并没有把[Planet Ubuntu][1]列入名单,因为它不适合初学者。废话不多说,让我们一起来看下**最好的乌邦图(ubuntu)博客**(排名不分先后): + +### [OMG! Ubuntu!][2] ### + +这是一个只针对 ubuntu 爱好者的网站。无论多小,只要是和乌邦图有关系的,OMG!Ubuntu 都会收入站内!博客主要包括新闻和应用。你也可以再这里找到一些关于 Ubuntu 的教程,但不是很多。 + +这个博客会让你知道 Ubuntu 世界发生的各种事情。 + +### [Web Upd8][3] ### + +Web Upd8 是我最喜欢的博客。除了涵盖新闻,它有很多容易理解的教程。Web Upd8 还维护了几个PPAs。博主[Andrei][4]有时会在评论里回答你的问题,这对你来说也会是很有帮助的。 + +这是一个你可以了解新闻资讯,学习教程的网站。 + +### [Noobs Lab][5] ### + +和Web Upd8一样,Noobs Lab上也有很多教程,新闻,并且它可能是PPA里最大的主题和图标集。 + +如果你是个新手,去Noobs Lab看看吧。 + +### [Linux Scoop][6] ### + +大多数的博客都是“文字博客”。你通过看说明和截图来学习教程。而 Linux Scoop 上有很多录像来帮助初学者来学习,完全是一个视频博客。 + +比起阅读来,如果你更喜欢视频,Linux Scoop应该是最适合你的。 + +### [Ubuntu Geek][7] ### + +这是一个相对比较老的博客。覆盖面很广,并且有很多快速安装的教程和说明。虽然,有时我发现其中的一些教程文章缺乏深度,当然这也许只是我个人的观点。 + +想要快速小贴士,去Ubuntu Geek。 + +### [Tech Drive-in][8] ### + +这个网站的更新频率好像没有以前那么快了,可能是 Manuel 在忙于他的工作,但是仍然给我们提供了很多的东西。新闻,教程,应用评论是这个博客的亮点。 + +博客经常被收入到[Ubuntu的新闻邀请邮件中][9],Tech Drive-in肯定是一个很值得你去学习的网站。 + +### [UbuntuHandbook][10] ### + +快速小贴士,新闻和教程是UbuntuHandbook的USP。[Ji m][11]最近也在参与维护一些PPAS。我必须很认真的说,这个博客的页面其实可以做得更好看点,纯属个人观点。 + +UbuntuHandbook 真的很方便。 + +### [Unixmen][12] ### + +这个网站是由很多人一起维护的,而且并不仅仅局限于Ubuntu,它也覆盖了很多的其他的Linux发行版。它有自己的论坛来帮助用户。 + +紧跟着 Unixmen 的步伐。。 + +### [The Mukt][13] ### + +The Mukt是Muktware新的代表。Muktware是一个逐渐消亡的Linux组织,并以Mukt重生。Muktware是一个很严谨的Linux开源的博客,The Mukt涉及很多广泛的主题,包括,科技新闻,极客新闻,有时还有娱乐新闻(听起来是否有一种混搭风的感觉?)The Mukt也包括很多你感兴趣的Ubuntu新闻。 + +The Mukt 不仅仅是一个博客,它是一种文化潮流。 + +### [LinuxG][14] ### + +LinuxG是一个你可以找到所有关于“怎样安装”类型文章的站点。几乎所有的文章都开始于一句话“你好,Linux geeksters,正如你所知道的……”,博客可以在不同的主题上做得更好。我经常发现有些是文章缺乏深度,并且是急急忙忙写出来的,但是它仍然是一个关注应用最新版本的好地方。 + +这是个快速浏览新的应用和它们最新的版本好地方。 + +### 你还有什么好的站点吗? ### + +这些就是我平时经常浏览的 Ubuntu 博客。我知道还有很多我不知道的站点,可能会比我列出来的这些更好。所以,欢迎把你最喜爱的 Ubuntu 博客写在下面评论区。 + +-------------------------------------------------------------------------------- + +via: http://itsfoss.com/ten-blogs-every-ubuntu-user-must-follow/ + +作者:[Abhishek][a] +译者:[barney-ro](https://github.com/barney-ro) +校对:[Caroline](https://github.com/carolinewuyan) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://itsfoss.com/author/Abhishek/ +[1]:http://planet.ubuntu.com/ +[2]:http://www.omgubuntu.co.uk/ +[3]:http://www.webupd8.org/ +[4]:https://plus.google.com/+AlinAndrei +[5]:http://www.noobslab.com/ +[6]:http://linuxscoop.com/ +[7]:http://www.ubuntugeek.com/ +[8]:http://www.techdrivein.com/ +[9]:https://lists.ubuntu.com/mailman/listinfo/ubuntu-news +[10]:http://ubuntuhandbook.org/ +[11]:https://plus.google.com/u/0/+JimUbuntuHandbook +[12]:http://www.unixmen.com/ +[13]:http://www.themukt.com/ +[14]:http://linuxg.net/ diff --git a/published/201410/20140924 Canonical Closes nginx Exploit in Ubuntu 14.04 LTS.md b/published/201410/20140924 Canonical Closes nginx Exploit in Ubuntu 14.04 LTS.md new file mode 100644 index 0000000000..5b87861224 --- /dev/null +++ b/published/201410/20140924 Canonical Closes nginx Exploit in Ubuntu 14.04 LTS.md @@ -0,0 +1,37 @@ +Canonical解决了一个Ubuntu 14.04 LTS中的nginx漏洞 +================================================================================ +> 用户应该更新他们的系统来修复这个漏洞! + +
![Ubuntu 14.04 LTS](http://i1-news.softpedia-static.com/images/news2/Canonical-Closes-Nginx-Exploit-in-Ubuntu-14-04-LTS-459677-2.jpg)
+ +
*Ubuntu 14.04 LTS*
+ +**Canonical已经在安全公告中公布了这个影响到Ubuntu 14.04 LTS (Trusty Tahr)的nginx漏洞的细节。这个问题已经被确定并被修复了** + +Ubuntu的开发者已经修复了nginx的一个小漏洞。他们解释nginx可能已经被利用来暴露网络上的敏感信息。 + +根据安全公告,“Antoine Delignat-Lavaud和Karthikeyan Bhargavan发现nginx错误地重复使用了缓存的SSL会话。攻击者可能利用此问题,在特定的配置下,可以从不同的虚拟主机获得信息“。 + +对于这些问题的更详细的描述,可以看到Canonical的安全[公告][1]。用户应该升级自己的Linux发行版以解决此问题。 + +这个问题可以通过在系统升级到最新nginx包(和依赖v包)进行修复。要应用该补丁,你可以直接运行升级管理程序。 + +如果你不想使用软件更新器,您可以打开终端,输入以下命令(需要root权限): + + sudo apt-get update + sudo apt-get dist-upgrade + +在一般情况下,一个标准的系统更新将会进行必要的更改。要应用此修补程序您不必重新启动计算机。 + +-------------------------------------------------------------------------------- + +via: http://news.softpedia.com/news/Canonical-Closes-Nginx-Exploit-in-Ubuntu-14-04-LTS-459677.shtml + +作者:[Silviu Stahie][a] +译者:[geekpi](https://github.com/geekpi) +校对:[wxy](https://github.com/wxy) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://news.softpedia.com/editors/browse/silviu-stahie +[1]:http://www.ubuntu.com/usn/usn-2351-1/ \ No newline at end of file diff --git a/published/201410/20140924 Debian 8 Jessie to Have GNOME as the Default Desktop.md b/published/201410/20140924 Debian 8 Jessie to Have GNOME as the Default Desktop.md new file mode 100644 index 0000000000..1a7f03e7fd --- /dev/null +++ b/published/201410/20140924 Debian 8 Jessie to Have GNOME as the Default Desktop.md @@ -0,0 +1,42 @@ +Debian 8 "Jessie" 将把GNOME作为默认桌面环境 +================================================================================ +> Debian的GNOME团队已经取得了实质进展 + +
![The GNOME 3.14 desktop](http://i1-news.softpedia-static.com/images/news2/Debian-8-quot-Jessie-quot-to-Have-GNOME-as-the-Default-Desktop-459665-2.jpg)
+ +
*GNOME 3.14桌面*
+ +**Debian项目开发者花了很长一段时间来决定将Xfce,GNOME或一些其他桌面环境中的哪个作为默认环境,不过目前看起来像是GNOME赢了。** + +[我们两天前提到了][1],GNOME 3.14的软件包被上传到 Debian Testing(Debian 8 “Jessie”)的软件仓库中,这是一个令人惊喜的事情。通常情况下,GNOME的维护者对任何类型的软件包都不会这么快地决定添加,更别说桌面环境。 + +事实证明,关于即将到来的Debian 8的发行版中所用的默认桌面的争论已经尘埃落定,尽管这个词可能有点过于武断。无论什么情况下,总是有些开发者想要Xfce,另外一些则是喜欢 GNOME,看起来 MATE 也是不少人的备选。 + +### 最有可能的是,GNOME将Debian 8“Jessie” 的默认桌面环境### + +我们之所以说“最有可能”是因为协议尚未达成一致,但它看起来GNOME已经遥遥领先了。Debian的维护者和开发者乔伊·赫斯解释了为什么会这样。 + +“根据从 https://wiki.debian.org/DebianDesktop/Requalification/Jessie 初步结果看,一些所需数据尚不可用,但在这一点上,我百分之八十地确定GNOME已经领先了。特别是,由于“辅助功能”和某些“systemd”整合的进度。在辅助功能方面:Gnome和Mate都领先了一大截。其他一些桌面的辅助功能改善了在Debian上的支持,部分原因是这一过程推动的,但仍需要上游大力支持。“ + +“Systemd /etc 整合方面:Xfce,Mate等尽力追赶在这一领域正在发生的变化,当技术团队停止了修改之后,希望有时间能在冻结期间解决这些问题。所以这并不是完全否决这些桌面,但要从目前的状态看,GNOME是未来的选择,“乔伊·赫斯[补充说][2]。 + +开发者在邮件中表示,在Debian的GNOME团队对他们所维护的项目[充满了激情][3],而Debian的Xfce的团队是决定默认桌面的实际阻碍。 + +无论如何,Debian 8“Jessie”没有一个具体发布时间,并没有迹象显示何时可能会被发布。在另一方面,GNOME 3.14已经发布了(也许你已经看到新闻了),它将很快应对好进行Debian的测试。 + +我们也应该感谢Jordi Mallach,在Debian中的GNOME包的维护者之一,他为我们指引了正确的讯息。 + +-------------------------------------------------------------------------------- + +via: http://news.softpedia.com/news/Debian-8-quot-Jessie-quot-to-Have-GNOME-as-the-Default-Desktop-459665.shtml + +作者:[Silviu Stahie][a] +译者:[fbigun](https://github.com/fbigun) +校对:[wxy](https://github.com/wxy) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://news.softpedia.com/editors/browse/silviu-stahie +[1]:http://news.softpedia.com/news/Debian-8-quot-Jessie-quot-to-Get-GNOME-3-14-459470.shtml +[2]:http://anonscm.debian.org/cgit/tasksel/tasksel.git/commit/?id=dce99f5f8d84e4c885e6beb4cc1bb5bb1d9ee6d7 +[3]:http://news.softpedia.com/news/Debian-Maintainer-Says-that-Xfce-on-Debian-Will-Not-Meet-Quality-Standards-GNOME-Is-Needed-454962.shtml diff --git a/published/201410/20140924 End of the Line for Red Hat Enterprise Linux 5.md b/published/201410/20140924 End of the Line for Red Hat Enterprise Linux 5.md new file mode 100644 index 0000000000..c1a680ecdd --- /dev/null +++ b/published/201410/20140924 End of the Line for Red Hat Enterprise Linux 5.md @@ -0,0 +1,29 @@ +Red Hat Enterprise Linux 5产品线终结 +================================================================================ +2007年3月,红帽公司首次宣布它的[Red Hat Enterprise Linux 5][1](RHEL)平台。虽然如今看来很普通,RHEL 5特别显著的一点是它是红帽公司第一个强调虚拟化的主要发行版本,而这点是如今现代发行版所广泛接受的特性。 + +最初的计划是为RHEL 5提供七年的寿命,但在2012年该计划改变了,红帽为RHEL 5[扩展][2]至10年的标准支持。 + +刚刚过去的这个星期,Red Hat发布的RHEL 5.11是RHEL 5.X系列的最后的、次要里程碑版本。红帽现在进入了将持续三年的名为“production 3”的支持周期。在这阶段将没有新的功能被添加到平台中,并且红帽公司将只提供有重大影响的安全修复程序和紧急优先级的bug修复。 + +平台事业部副总裁兼总经理Jim Totton在红帽公司在一份声明中说:“红帽公司致力于建立一个长期,稳定的产品生命周期,这将给那些依赖Red Hat Enterprise Linux为他们的关键应用服务的企业客户提供关键的益处。虽然RHEL 5.11是RHEL 5平台的最终次要版本,但它提供了安全性和可靠性方面的增强功能,以保持该平台接下来几年的活力。” + +新的增强功能包括安全性和稳定性更新,包括改进了红帽帮助用户调试系统的方式。 + +还有一些新的存储的驱动程序,以支持新的存储适配器和改进在VMware ESXi上运行RHEL的支持。 + +在安全方面的巨大改进是OpenSCAP更新到版本1.0.8。红帽在2011年五月的[RHEL5.7的里程碑更新][3]中第一次支持了OpenSCAP。 OpenSCAP是安全内容自动化协议(SCAP)框架的开源实现,用于创建一个标准化方法来维护安全系统。 + +-------------------------------------------------------------------------------- + +via: http://www.linuxplanet.com/news/end-of-the-line-for-red-hat-enterprise-linux-5.html + +作者:Sean Michael Kerner +译者:[geekpi](https://github.com/geekpi) +校对:[wxy](https://github.com/wxy) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[1]:http://www.internetnews.com/ent-news/article.php/3665641 +[2]:http://www.serverwatch.com/server-news/red-hat-extends-linux-support.html +[3]:http://www.internetnews.com/skerner/2011/05/red-hat-enterprise-linux-57-ad.html \ No newline at end of file diff --git a/published/201410/20140924 Second Bugfix Release for KDE Plasma 5 Arrives with Lots of Changes.md b/published/201410/20140924 Second Bugfix Release for KDE Plasma 5 Arrives with Lots of Changes.md new file mode 100644 index 0000000000..243a2c5027 --- /dev/null +++ b/published/201410/20140924 Second Bugfix Release for KDE Plasma 5 Arrives with Lots of Changes.md @@ -0,0 +1,39 @@ +KDE Plasma 5的第二个bug修复版本发布,带来了很多的改变 +================================================================================ +> 新的Plasma 5发布了,带来了新的外观 + + 
![KDE Plasma 5](http://i1-news.softpedia-static.com/images/news2/Second-Bugfix-Release-for-KDE-Plasma-5-Arrives-with-Lots-of-Changes-459688-2.jpg)
+ +
*KDE Plasma 5*
+ +### Plasma 5的第二个bug修复版本发布,已可下载### + +KDE Plasma 5的bug修复版本不断来到,它新的桌面体验将会是KDE的生态系统的一个组成部分。 + +[公告][1]称:“plasma-5.0.2这个版本,新增了一个月以来来自KDE的贡献者新的翻译和修订。Bug修复通常是很小但是很重要,如修正未翻译的文字,使用正确的图标和修正KDELibs 4软件的文件重复现象。它还增加了一个月以来辛勤的翻译成果,使其支持其他更多的语言” + +这个桌面还没有在任何Linux发行版中默认安装,这将持续一段时间,直到我们测试完成。 + +开发者还解释说,更新的软件包可以在Kubuntu Plasma 5的开发版本中进行审查。 + +如果你个人需要它们,你也可以下载源码包。 + +- [KDE Plasma Packages][2] +- [KDE Plasma Sources][3] + +如果你决定去编译它,你必须需要知道 KDE Plasma 5.0.2是一组复杂的软件,可能你需要解决不少问题。 + +-------------------------------------------------------------------------------- + +via: http://news.softpedia.com/news/Second-Bugfix-Release-for-KDE-Plasma-5-Arrives-with-Lots-of-Changes-459688.shtml + +作者:[Silviu Stahie][a] +译者:[geekpi](https://github.com/geekpi) +校对:[wxy](https://github.com/wxy) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://news.softpedia.com/editors/browse/silviu-stahie +[1]:http://kde.org/announcements/plasma-5.0.2.php +[2]:https://community.kde.org/Plasma/Packages +[3]:http://kde.org/info/plasma-5.0.2.php \ No newline at end of file diff --git a/published/201410/20140924 Wal Commander GitHub Edition 0.17 released.md b/published/201410/20140924 Wal Commander GitHub Edition 0.17 released.md new file mode 100644 index 0000000000..98ab4c8567 --- /dev/null +++ b/published/201410/20140924 Wal Commander GitHub Edition 0.17 released.md @@ -0,0 +1,43 @@ +文件管理器 Wal Commander Github 0.17版发布了 +================================================================================ +![](http://wcm.linderdaum.com/wp-content/uploads/2014/09/wc21.png) + +> ### 描述 ### +> +> Wal Commander GitHub 版是一款多平台的开源文件管理器。适用于Windows、Linux、FreeBSD、和OSX。 +> +> 这个从项目的目的是创建一个模仿Far管理器外观和感觉的便携式文件管理器。 + +Wal Commander 的下一个Github稳定版本0.17 已经出来了。主要功能包括: + +- 使用命令历史自动补全; +- 文件关联绑定自定义命令对文件的各种操作; +- 和用XQuartz实验性地支持OS X。 + +很多新的快捷键添加在此版本中。预编译二进制文件适用于Windows64、Linux,FreeBSD和OS X版本,这些可以直接从[GitHub中的源代码][1]编译。 + +### 主要特性 ### + +- 命令行自动补全 (使用Del键删除一条命令) +- 文件关联 (主菜单 -> 命令 -> 文件关联) +- XQuartz上实验性地支持OS X ([https://github.com/corporateshark/WalCommander/issues/5][2]) + +### 下载 ### + +下载:[http://wcm.linderdaum.com/downloads/][3] +源代码: [https://github.com/corporateshark/WalCommander][4] + + +-------------------------------------------------------------------------------- + +via: http://wcm.linderdaum.com/release-0-17-0/ + +译者:[geekpi](https://github.com/geekpi) +校对:[wxy](https://github.com/wxy) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[1]:https://github.com/corporateshark/WalCommander/releases +[2]:https://github.com/corporateshark/WalCommander/issues/5 +[3]:http://wcm.linderdaum.com/downloads/ +[4]:https://github.com/corporateshark/WalCommander \ No newline at end of file diff --git a/published/How to listen to Internet radio from the command line on Linux.md b/published/201410/How to listen to Internet radio from the command line on Linux.md similarity index 100% rename from published/How to listen to Internet radio from the command line on Linux.md rename to published/201410/How to listen to Internet radio from the command line on Linux.md diff --git a/published/201410/The Open Source Witch Hunts Have Returned.md b/published/201410/The Open Source Witch Hunts Have Returned.md new file mode 100644 index 0000000000..a3c4d47878 --- /dev/null +++ b/published/201410/The Open Source Witch Hunts Have Returned.md @@ -0,0 +1,62 @@ +开源女巫狩猎归来! +================================================================================ +![](http://readwrite.com/files/styles/1400_0/public/fields/shutterstock-open-gate.jpg) + +> 开源软件社区已经做出了改变,就像之前的美好时光。 + +开源已经变的温和了,之前我们有过各种不同的思潮,但是最近我们对分享代码和创新却有种奇怪的迷恋。 + +幸运的是,这一系列的使用主义注定要结束了。在过去的一段时间里,我们团结在Mozilla身边支持DRM版权保护以及嘲笑Red Hat和OpenStack之间的竞争。开源社区那些年仅有的几个开源软件明星和[Open Core 这种商业模式][1]产生了冲突而被反噬了。 + +噢,怎么变成这样了! + + +### Red Hat 退回到2003年 ### + +Red Hat,开源软件理想主义的典范,在几周前拒绝支持它的竞争对手。Jodi Mardesich[出色的][2]揭露了真相,而Red Hat在努力辩护,这个真相就是: + +Red Hat不想支持它的竞争对手,它的OpenStack的竞争对手也不想这样做。 + +在另外世界上这算是新闻吗? + +### Mozilla变成了麻瓜 ### + +Red Hat作为开源软件理想主义的典范代表很容易成为各种带颜色攻击的目标,Mozilla其实是更大的一个目标。 + +Mozilla致力于为用户服务,它最近进行了一场自我牺牲似的CEO 下台,同意加入DRM的技术,即纯Firefox浏览器源码可以使用户观看视频。 + +人们想看视频,Mozilla倾向于在它的浏览器中观看。 + +总是找到别人的思想滑坡的问题,开源软件组织[批评了][3] Mozilla,深切表达了自己对于Mozilla的失望,因为这种“为减轻市场份额的流失而妥协重要原则的决定”令人担忧。 + +但是,Mozilla为什么要做这样的傻事呢,为了用户,你懂的。 + +抛开道德说教的部分不说,[电子前沿基金会哀叹][4],“开放网络最后的抗争已经失败了”。它对Mozilla投降的做法争论道:“接受DRM会改变这个行业”!DRM的倡导者一再妥协,一个公司又一个公司(PC行业)演变成一个行业,它通过锁定装置,监视器,接受每一个人的管理建立自己的利益关系。 + +[Mitchell Bake解释道][5],Mozilla可能并没有投降:“Firefox用户会需要使用另外的浏览器来观看他们自己想看的视频,这会让人怀疑Firfox做一一个产品是否真的有用”。 + +嗯,好吧。 + +### 回到我们的思想源头 ### + +我们或许希望其它人都按照我们的想法来,但事实上他们却有着不同的考虑。免费的软件让步给更加务实的开源软件,认为只有“不二法门”的想法也逐渐消亡了。 + +这种意识在目前还是有用的,但它并不总是方便和舒服。我崇尚开源软件的实用主义和Apache软件基金会,这样有很大的好处提醒GPL组织在意识形态上的危机感。软件自由真的很重要。 + +这么多悲观的言论,我自己也感到了恐惧,希望回到一个不断会自我鞭策的免费的开软软件的组织。这使开源软件协作变少而且更难驾驭,但是会变得更有力而且关乎未来。 + +(译者注:本文来源于一篇国外的杂文,译者和校对在翻译时感觉颇为吃力,因此肯定有大量谬误和不足,敬请大家谅解,或提出指正。虽然这篇文章说的事情已经过去了一段时间了,但是其反映的问题和潜伏的暗流也许影响更为深远。) + +-------------------------------------------------------------------------------- + +via: http://readwrite.com/2014/05/21/open-source-witch-hunt-mozilla-openstack-redhat#feed=/hack&awesm=~oEYDhxfP0Qv5hE + +译者:[jiajia9linuxer](https://github.com/jiajia9linuxer) 校对:[wxy](https://github.com/wxy) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[1]:http://en.m.wikipedia.org/wiki/Open_core +[2]:http://readwrite.com/2014/05/16/red-hat-openstack-mirantis-rhel-support +[3]:http://www.fsf.org/news/fsf-condemns-partnership-between-mozilla-and-adobe-to-support-digital-restrictions-management +[4]:https://www.eff.org/deeplinks/2014/05/mozilla-and-drm +[5]:https://blog.mozilla.org/blog/2014/05/14/drm-and-the-challenge-of-serving-users/ diff --git a/sources/news/20140821 Microsoft Lobby Denies the State of Chile Access to Free Software.md b/sources/news/20140821 Microsoft Lobby Denies the State of Chile Access to Free Software.md deleted file mode 100644 index d321e0b961..0000000000 --- a/sources/news/20140821 Microsoft Lobby Denies the State of Chile Access to Free Software.md +++ /dev/null @@ -1,37 +0,0 @@ -Microsoft Lobby Denies the State of Chile Access to Free Software -================================================================================ -![Fuerza Chile](http://i1-news.softpedia-static.com/images/news2/Microsoft-Lobby-Denies-the-State-of-Chile-Access-to-Free-Software-455598-3.jpg) -Fuerza Chile - -Fresh on the heels of the entire Munich and Linux debacle, another story involving Microsoft and free software has popped up across the world, in Chile. A prolific magazine from the South American country says that the powerful Microsoft lobby managed to turn around a law that would allow the authorities to use free software. - -The story broke out from a magazine called El Sábado de El Mercurio, which explains in great detail how the Microsoft lobby works and how it can overturn a law that may harm its financial interests. - -An independent member of the Chilean Parliament, Vlado Mirosevic, pushed a bill that would allow the state to consider free software when the authorities needed to purchase or renew licenses. The state of Chile pays $2.7 billion (€2 billion) on licenses from various companies, including Microsoft. - -According to [ubuntizando.com][1], Microsoft representatives met with Vlado Mirosevic shortly after he announced his intentions, but the bill passed the vote, with 64 votes in favor, 12 abstentions, and one vote against it. That one vote was cast by Daniel Farcas, a member of a Chilean party. - -A while later, the same member of the Parliament, Daniel Farcas, proposed another bill that actually nullified the effects of the previous one that had just been adopted. To make things even more interesting, some of the people who voted in favor of the first law also voted in favor of the second one. - -The new bill is even more egregious, because it aggressively pushes for the adoption of proprietary software. Companies that choose to use proprietary software will receive certain tax breaks, which makes it very hard for free software to get adopted. - -Microsoft has been in the news in the last few days because the [German city of Munich that adopted Linux][2] and dropped Windows system from its administration was considering, supposedly, returning to proprietary software. - -This new situation in Chile give us a sample of the kind of pull a company like Microsoft has and it shows us just how fragile laws really are. This is not the first time a company tries to bend the laws in a country to maximize the profits, but the advent of free software and the clear financial advantages that it offers are really making a dent. - -Five years ago, few people or governments would have considered adopting free software, but the quality of that software has risen dramatically and it has become a real competition [for the likes of Microsoft][3]. - --------------------------------------------------------------------------------- - -via: http://news.softpedia.com/news/Microsoft-Lobby-Denies-the-State-of-Chile-Access-to-Free-Software-455598.shtml - -作者:[Silviu Stahie][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://news.softpedia.com/editors/browse/silviu-stahie -[1]:http://www.ubuntizando.com/2014/08/20/microsoft-chile-y-el-poder-del-lobby/ -[2]:http://news.softpedia.com/news/Munich-Disappointed-with-Linux-Plans-to-Switch-Back-to-Windows-455405.shtml -[3]:http://news.softpedia.com/news/Munich-Switching-to-Windows-from-Linux-Is-Proof-that-Microsoft-Is-Still-an-Evil-Company-455510.shtml \ No newline at end of file diff --git a/sources/news/20140821 Transport Tycoon Deluxe Remake OpenTTD 1.4.2 Is an Almost Perfect Sim.md b/sources/news/20140821 Transport Tycoon Deluxe Remake OpenTTD 1.4.2 Is an Almost Perfect Sim.md deleted file mode 100644 index 7ef1024938..0000000000 --- a/sources/news/20140821 Transport Tycoon Deluxe Remake OpenTTD 1.4.2 Is an Almost Perfect Sim.md +++ /dev/null @@ -1,40 +0,0 @@ -Transport Tycoon Deluxe Remake OpenTTD 1.4.2 Is an Almost Perfect Sim -================================================================================ -![Transport Tycoon](http://i1-news.softpedia-static.com/images/news2/Transport-Tycoon-Deluxe-Remake-OpenTTD-1-4-2-Is-an-Almost-Perfect-Sim-455715-2.jpg) -Transport Tycoon - -**OpenTTD 1.4.2, an open source simulation game based on the popular Microprose title Transport Tycoon written by Chris Sawyer, has been officially released.** - -Transport Tycoon is a very old game that was originally launched back in 1995, but it made such a huge impact on the gaming community that, even almost 20 years later, it still has a powerful fan base. - -In fact, Transport Tycoon Deluxe had such an impact on the gaming industry that it managed to spawn an entire generation of similar games and it has yet to be surpassed by any new title, even though many have tried. - -Despite the aging graphics, the developers of OpenTTD have tried to provide new challenges for the fans of the original games. To put things into perspective, the original game is already two decades old. That means that someone who was 20 years old back then is now in his forties and he is the main audience for OpenTTD. - -"OpenTTD is modelled after the original Transport Tycoon game by Chris Sawyer and enhances the game experience dramatically. Many features were inspired by TTDPatch while others are original," reads the official announcement. - -OpenTTD features bigger maps (up to 64 times in size), stable multiplayer mode for up to 255 players in 15 companies, a dedicated server mode and an in-game console for administration, IPv6 and IPv4 support for all communication of the client and server, new pathfinding algorithms that makes vehicles go where you want them to, different configurable models for acceleration of vehicles, and much more. - -According to the changelog, awk is now used instead of trying to convince cpp to preprocess nfo files, CMD_CLEAR_ORDER_BACKUP is no longer suppressed by pause modes, the Wrong breakdown sound is no longer played for ships, integer overflow in the acceleration code is no longer causing either too low acceleration or too high acceleration, incorrectly saved order backups are now discarded when clients join, and the game no longer crashes when trying to show an error about vehicle in a NewGRF and the NewGRF was not loaded at all. - -Also, the Slovak language no longer uses space as group separator in numbers, the parameter bound checks are now tighter on GSCargoMonitor functions, the days in dates are not represented by ordinal numbers in all languages, and the incorrect usage of string commands in the base language has been fixed. - -Check out the [changelog][1] for a complete list of updates and fixes. - -Download OpenTTD 1.4.2: - -- [http://www.openttd.org/en/download-stable][2] - --------------------------------------------------------------------------------- - -via: http://news.softpedia.com/news/Transport-Tycoon-Deluxe-Remake-OpenTTD-1-4-2-Is-an-Almost-Perfect-Sim-455715.shtml - -作者:[Silviu Stahie][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://news.softpedia.com/editors/browse/silviu-stahie -[1]:http://ftp.snt.utwente.nl/pub/games/openttd/binaries/releases/1.4.2/changelog.txt -[2]:http://www.openttd.org/en/download-stable \ No newline at end of file diff --git a/sources/news/20140826 Munich Council--LiMux Demise Has Been Greatly Exaggerated.md b/sources/news/20140826 Munich Council--LiMux Demise Has Been Greatly Exaggerated.md deleted file mode 100644 index f6bbe4cefd..0000000000 --- a/sources/news/20140826 Munich Council--LiMux Demise Has Been Greatly Exaggerated.md +++ /dev/null @@ -1,41 +0,0 @@ -[sailing] -Munich Council: LiMux Demise Has Been Greatly Exaggerated -================================================================================ -![LiMux – Munich City Council’s Official OS](http://www.omgubuntu.co.uk/wp-content/uploads/2014/07/limux-4-kde-desktop.jpg) -LiMux – Munich City Council’s Official OS - -A Munich city council spokesman has attempted to clarify the reasons behind its [plan to re-examine the role of open-source][1] software in local government IT systems. - -The response comes after numerous German media outlets revealed that the city’s incoming mayor has asked for a report into the use of LiMux, the open-source Linux distribution used by more than 80% of municipalities. - -Reports quoted an unnamed city official, who claimed employees were ‘suffering’ from having to use open-source software. Others called it an ‘expensive failure’, with the deputy mayor, Josef Schmid, saying the move was ‘driven by ideology’, not financial prudence. - -With Munich often viewed as the poster child for large Linux migrations, news of the potential renege quickly went viral. Now council spokesman Stefan Hauf has attempted to bring clarity to the situation. - -### ‘Plans for the future’ ### - -Hauf confirms that the city’s new mayor has requested a review of the city’s IT systems, including its choice of operating systems. But the report is not, as implied in earlier reports, solely tasked with deciding whether to return to using Microsoft Windows. - -**“It’s about the organisation, the costs, performance and the usability and satisfaction of the users,”** [Techrepublic][2] quote him as saying. - -**“[It's about gathering the] facts so we can decide and make a proposal for the city council how to proceed in future.”** - -Hauf also confirms that council staff have, and do, complain about LiMux, but that the majority of issues stem from compatibility issues in OpenOffice, something a potential switch to LibreOffice could solve. - -So is Munich about to switch back to Windows? As we said in our original coverage: it’s just too early to say, but it’s not being ruled out. - -No final date for the report’s recommendations is yet set, and any binding decision on Munich’s IT infrastructure will need to be made by its elected members, the majority of whom are said to ‘support’ the LiMux initiative. - --------------------------------------------------------------------------------- - -via: http://www.omgubuntu.co.uk/2014/08/munich-council-say-talk-limux-demise-greatly-exaggerated - -作者:[Joey-Elijah Sneddon][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:https://plus.google.com/117485690627814051450/?rel=author -[1]:http://www.omgubuntu.co.uk/2014/08/munich-city-linux-switching-back-windows -[2]:http://www.techrepublic.com/article/no-munich-isnt-about-to-ditch-free-software-and-move-back-to-windows/ diff --git a/sources/news/20140829 Red Hat Shake-up, Desktop Users, and Outta Time.md b/sources/news/20140829 Red Hat Shake-up, Desktop Users, and Outta Time.md deleted file mode 100644 index 1e37246514..0000000000 --- a/sources/news/20140829 Red Hat Shake-up, Desktop Users, and Outta Time.md +++ /dev/null @@ -1,31 +0,0 @@ -Red Hat Shake-up, Desktop Users, and Outta Time -================================================================================ -![](https://farm4.staticflickr.com/3839/15058131052_b5e86dce3e_t.jpg) - -Our top story tonight is the seemingly sudden resignation of Red Hat CTO Brian Stevens. In other news, John C. Dvorak says "Linux has run out of time" and Infoworld.com says there may be problems with Red Hat Enterprise 7. OpenSource.com has a couple of interesting interviews and Nick Heath has five big names that use Linux on the desktop. - -**In a late afternoon** [press release][1], Red Hat announced the resignation of long-time CTO Brian Stevens. Paul Cormier will be handling CTO duties until Stevens' replacement is named. No reason for the sudden resignation was given although CEO Whitehurst said, "We want to thank Brian for his years of service and numerous contributions to Red Hat’s business. We wish him well in his future endeavors." However, Steven J. Vaughan-Nichols says some rumors are flying. One says friction between Stevens and Cormier caused the resignation and others say Stevens had higher ambitions than Red Hat could provide. He'd been with Red Hat since 2001 and had been CTO at Mission Critical Linux before that [according to Vaughan-Nichols][2] who also said Stevens' Red Hat page was gone within seconds of the announcement. - -**Speaking of Red Hat**, InfoWorld.com has a review of RHEL 7 available to the general public today. Reviewer Paul Venezia runs down the new features, but soon mentions systemd as one of the many new features "certain to cause consternation." After offering his opinion on several other key features and even throwing in a tip or two, [Venezia concludes][3], "RHEL 7 is a fairly significant departure from the expected full-revision release from Red Hat. This is not merely a reskinning of the previous release with updated packages, a more modern kernel, and some new toolkits and widgets. This is a very different release than RHEL 6 in any form, mostly due to the move to Systemd." - -**Our own Sam Dean** [today said][4] that Linux doesn't need to own the desktop because of its success in many other key areas. While that may be true, Nick Heath today listed "five big names that use Linux on the desktop." He said besides Munich, there's Google for one and they even have their own Ubuntu derivative. He lists a couple of US government agencies and then mentions CERN and others. See that [full story][5] for more. - -Despite that feel-good report, John C. Dvorak said he's tired of waiting for someone to develop that one "killer app" that would bring in the masses or satisfy his needs. [He says][6] he has to make podcasts and "photographic art" and he just can't do that with Linux. Our native applications "do not cut it in the end." - --------------------------------------------------------------------------------- - -via: http://ostatic.com/blog/red-hat-shake-up-desktop-users-and-outta-time - -作者:[Susan Linton][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://ostatic.com/member/susan-linton -[1]:http://www.businesswire.com/news/home/20140827006134/en/Brian-Stevens-Step-CTO-Red-Hat#.U_5AlvFdX0p -[2]:http://www.zdnet.com/red-hat-chief-technology-officer-resigns-7000033058/ -[3]:http://www.infoworld.com/d/data-center/review-rhel-7-lands-jolt-249219 -[4]:http://ostatic.com/blog/linux-doesnt-need-to-own-the-desktop -[5]:http://www.techrepublic.com/article/five-big-names-that-use-linux-on-the-desktop/ -[6]:http://www.pcmag.com/article2/0,2817,2465125,00.asp \ No newline at end of file diff --git a/sources/news/20140901 LibreOffice 4.3.1 Has More than 100 Fixes and DOCX Embedded Objects Support.md b/sources/news/20140901 LibreOffice 4.3.1 Has More than 100 Fixes and DOCX Embedded Objects Support.md deleted file mode 100644 index e592d4c9f3..0000000000 --- a/sources/news/20140901 LibreOffice 4.3.1 Has More than 100 Fixes and DOCX Embedded Objects Support.md +++ /dev/null @@ -1,37 +0,0 @@ -LibreOffice 4.3.1 Has More than 100 Fixes and DOCX Embedded Objects Support -================================================================================ -![LibreOffice selection menu](http://i1-news.softpedia-static.com/images/news2/LibreOffice-4-3-1-Has-More-Than-100-Fixes-and-DOCX-Embedded-Objects-Support-456916-2.jpg) -LibreOffice selection menu - -**The Document Foundation announces that the stable version of LibreOffice 4.3.1 has been released and is now available for download.** - -The developers from The Document Foundation have released a new update for the 4.3 branch of LibreOffice and they have implemented quite a few fixes and other various changes. The development cycle for this latest update has been rather short and the devs managed to repair most of the issues that have been found. - -LibreOffice 4.3.1 is just maintenance release, which means that the focus has been about the bugs found so far. Don't expect to find anything extraordinary, but you should upgrade the software nonetheless. - -"The Document Foundation announces LibreOffice 4.3.1, the first minor release of LibreOffice 4.3 'fresh' family, with over 100 fixes (including patches for two CVEs, backported to LibreOffice 4.2.6-secfix, which is also available for download now)." - -"All LibreOffice users are invited to update their installation as soon as possible to avoid security issues. This includes users who are running LibreOffice 4.2.6 as originally released on August, 5th 2014. LibreOffice 4.3.1 and LibreOffice 4.2.6 will be shown on stage at the LibreOffice Conference in Bern, from September 3 to September 5, with a large number of sessions about development, community, marketing and migrations," reads the announcement made by The Linux Foundation. - -According to the changelog, editing the text search with expanded fields is now working properly, the static value array for OOXML chart is now handled correctly, bullets now have the color as the following text by default, ww8import no longer creates a pagedesc if a continuous section changes margins, the 0 font height is now handled just like outdev, it's now possible to import OLE objects in the header with background wrapping, the XLSX export of revisions has been fixed in order to get it to work in Excel, and borders around data labels are now supported. - -Also, the table style for lastRow is now correctly applied, the rulers now have app-background by default, the graphics are now swapped in on DrawingML::WriteImage, the redundant 'Preferences' label has been removed in order to save some space, page breaks in tables are now ignored during the RTF import, some of the style hierarchy has been reworked, Data Statistics no longer crashes with any entry, DOCX embedded objects are now supported, and numerous other improvements have been made. - -More details about this release can be found in the official [announcement][1]. - -- [Download LibreOffice 4.3.1 for Linux][2] - - --------------------------------------------------------------------------------- - -via: http://news.softpedia.com/news/LibreOffice-4-3-1-Has-More-Than-100-Fixes-and-DOCX-Embedded-Objects-Support-456916.shtml - -作者:[Silviu Stahie][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://news.softpedia.com/editors/browse/silviu-stahie -[1]:http://blog.documentfoundation.org/2014/08/28/libreoffice-4-3-1-fresh-announced/ -[2]:http://www.libreoffice.org/download/libreoffice-fresh/ \ No newline at end of file diff --git a/sources/news/20140905 Ubuntu Touch Now Has a Torrent Client in the Ubuntu Store.md b/sources/news/20140905 Ubuntu Touch Now Has a Torrent Client in the Ubuntu Store.md deleted file mode 100644 index 4b0f23c5c6..0000000000 --- a/sources/news/20140905 Ubuntu Touch Now Has a Torrent Client in the Ubuntu Store.md +++ /dev/null @@ -1,27 +0,0 @@ -disylee占个坑!来翻译了! -Ubuntu Touch Now Has a Torrent Client in the Ubuntu Store -================================================================================ -![DowNow](http://i1-news.softpedia-static.com/images/news2/Ubuntu-Touch-Now-Has-a-Torrent-Clinent-in-the-Ubuntu-Store-457538-2.jpg) - -**The Ubuntu Touch platform is already the host of many interesting applications, and it looks like the developers have started to implement software that goes beyond what you might expect, like a torrent client for example.** - -The app store for Ubuntu Touch has been growing steadily over the past few months and interesting applications are added all the time. Most of them are covering some of the basic needs of the operating system, but there are quite a few that go well beyond regular users’ needs. - -A torrent client is not something that you will find on most phones. Android and Windows Phone already have this kind of apps and it looks like Ubuntu is now one of those platforms. Ubuntu developer [Alan Pope][1] posted a screenshot with a new application that's being developed for the Ubuntu platforms called DowNow. - -This is a relatively new application and it's still under development. You can find the click package for DowNow 0.3 in Launchpad, if you want to take a closer look, or you can download from Ubuntu Software Center. - -For now, the only supported devices are Nexus 4 and Nexus 7, if you want to test Ubuntu for phones, but that might change in the coming months. - --------------------------------------------------------------------------------- - -via: http://news.softpedia.com/news/Ubuntu-Touch-Now-Has-a-Torrent-Clinent-in-the-Ubuntu-Store-457538.shtml - -作者:[Silviu Stahie][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://news.softpedia.com/editors/browse/silviu-stahie -[1]:https://plus.google.com/u/0/+AlanPope/posts/Ej3vKVxBum8 diff --git a/sources/news/20140910 Jelly Conky Adds Simple, Stylish Stats To Your Linux Desktop.md b/sources/news/20140910 Jelly Conky Adds Simple, Stylish Stats To Your Linux Desktop.md deleted file mode 100644 index 6f78db6067..0000000000 --- a/sources/news/20140910 Jelly Conky Adds Simple, Stylish Stats To Your Linux Desktop.md +++ /dev/null @@ -1,37 +0,0 @@ -Jelly Conky Adds Simple, Stylish Stats To Your Linux Desktop -================================================================================ -**I treat Conky setups a bit like wallpapers: I’ll find one I love, only to change it the next week because I’m bored of it and want a change.** - -Part of the impatience is fuelled by the ever-growing catalog of designs available. One of my most recent favourites is Jelly Conky. - -![](http://www.omgubuntu.co.uk/wp-content/uploads/2014/09/jelly-conky.png) - -Jelly Conky sports the minimal design many of the Conky’s we’ve highlighted recently have followed. It’s not trying to be a kitchen sink. It won’t win favour with those who need constant at-a-glance data on their HDD temperatures and IP addresses. - -It comes with three distinct modes that can all add personality to an otherwise static background image: - -- Clock -- Clock plus date -- Clock plus date and weather - -Some people don’t understand the point of having a duplicate clock on show on the desktop. That’s understandable. For me, it’s more about form than function (though, personally, I find Conky clocks easier to see than the minuscule digits nestled in my upper panel). - -Chances are if you have a home screen widget on Android with the time, you won’t mind having one on your desktop, either! - -You can download Jelly Conky from the link below. The .zip archive contains a readme with instructions on how to install. For a guided walkthrough, [revisit one of our previous articles][1]. - -- [Download Jelly Conky on Deviant Art][2] - --------------------------------------------------------------------------------- - -via: http://www.omgubuntu.co.uk/2014/09/jelly-conky-for-linux-desktop - -作者:[Joey-Elijah Sneddon][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:https://plus.google.com/117485690627814051450/?rel=author -[1]:http://www.omgubuntu.co.uk/2014/07/conky-circle-theme-nod-lg-quick-cover -[2]:http://zagortenay333.deviantart.com/art/Jelly-Conky-442559003 \ No newline at end of file diff --git a/sources/news/20140912 How to Go Hands On With the Utopic Unicorn--Literally.md b/sources/news/20140912 How to Go Hands On With the Utopic Unicorn--Literally.md deleted file mode 100644 index 45c365193e..0000000000 --- a/sources/news/20140912 How to Go Hands On With the Utopic Unicorn--Literally.md +++ /dev/null @@ -1,38 +0,0 @@ -How to Go Hands On With the Utopic Unicorn – Literally! -================================================================================ -**Looking to go hands-on with the Utopic Unicorn ahead of its release? Now you can — [literally][1]!** - -A step-by-step guide to making your own paper Unicorn (to celebrate the upcoming release of the same name, obviously) has been posted online by Canonical. The instructions were offered as part of the company’s presence at the 2014 [deconstruct][2] event held in Brighton, UK in early September. - -![Image: Alejandra Obregon](http://www.omgubuntu.co.uk/wp-content/uploads/2014/09/ubuntu-unicorns-750x745.jpg) - -Image: Alejandra Obregon - -The one-day conference for creative professionals and digital culture enthusiasts served as an ideal place for Canonical to showcase an in-progress version of the upcoming Ubuntu Phone, its design and the user interaction benefits they believe it offers. - -Reaction was positive, they say. That will have made the prize of a brand new Ubuntu phone to the maker of the best origami unicorn all the more tempting! - -### Download Origami Unicorn ### - -No prizes are on offer to the rest of us attempting to fold our way to frustration, but a download of the how-to is. - -If you have a spare five hours minutes, why not make one for fun? If you make particularly epic success/fail of it be sure to send us a pic on [Twitter][3] or [Google+][4]. - -- [Download ‘Make a Unicorn’ Instructions][5] - --------------------------------------------------------------------------------- - -via: http://www.omgubuntu.co.uk/2014/09/unicorn-origami-download-pdf-ubuntu-utopic - -作者:[Joey-Elijah Sneddon][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:https://plus.google.com/117485690627814051450/?rel=author -[1]:http://design.canonical.com/2014/09/canonical-and-ubuntu-at-dconstruct/ -[2]:http://2014.dconstruct.org/ -[3]:http://twitter.com/omgubuntu -[4]:http://plus.google.com/+omgubuntu -[5]:http://design.canonical.com/wp-content/uploads/042_CAN_dConstruct_instructions.pdf \ No newline at end of file diff --git a/sources/talk/20140610 How does the cloud affect the everyday linux user.md b/sources/talk/20140610 How does the cloud affect the everyday linux user.md deleted file mode 100644 index 6bc787729d..0000000000 --- a/sources/talk/20140610 How does the cloud affect the everyday linux user.md +++ /dev/null @@ -1,197 +0,0 @@ -barney-ro translating - -How does the cloud affect the everyday linux user? -================================================================================ -### Introduction ### - -Cloud computing is one of those terms you hear about and see all the time whether it is in the national newspapers, online news websites, podcasts, technical blogs, technical news sites or on radio and television. - -It is a fairly woolly term that encompasses so many things but what exactly is it? - -> **Cloud computing** is a term used to refer to a model of network computing where a program or application runs on a connected server or servers rather than on a local computing device such as a PC, tablet or smartphone. Like the traditional client-server model or older mainframe computing,[1] a user connects with a server to perform a task. The difference with cloud computing is that the computing process may run on one or many connected computers at the same time, utilizing the concept of virtualization. With virtualization, one or more physical servers can be configured and partitioned into multiple independent “virtual” servers, all functioning independently and appearing to the user to be a single physical device. Such virtual servers are in essence disassociated from their physical server, and with this added flexibility, they can be moved around and scaled up or down on the fly without affecting the end user. The computing resources have become “granular”, which provides end user and operator benefits including on-demand self-service, broad access across multiple devices, resource pooling, rapid elasticity and service metering capability.[2] - -The above quote was obviously taken from Wikipedia. - -In the past we either used dumb terminals to connect to a mainframe or more recently desktop computers connected to applications on in-house servers which in turn connected to databases also kept on site. - -The management of the desktops, applications and servers were all local and all had to be supported by the company who owned them. - -Whilst this might be great for software houses it isn’t good business for other companies such as banks, insurance companies and oil companies. Information Technology is not a banking function in the same way catering isn’t a function of drilling oil out of the ground. - -Large companies have long since outsourced many functions to dedicated companies. For example outside catering companies provide the staff canteen and we all know about the offshore call centres handling customer calls for the banks. - -IT has also become an offshore function with a number of support and development functions shipped out to China, India, Malaysia and Eastern Europe. - -Cloud computing is different to the typical model in that it is all about virtualisation. It is about putting applications on virtual servers which could all be in one location or could be thousands of miles apart but the point is it doesn’t matter because it is somebody else’s job to make sure they work. - -> In common usage the term “the cloud” has become a shorthand way to refer to cloud computing infrastructure.[4] The term came from the cloud symbol that network engineers used on network diagrams to represent the unknown (to them) segments of a network.[5] Marketers have further popularized the phrase “in the cloud” to refer to software, platforms and infrastructure that are sold “as a service”, i.e. remotely through the Internet. - -This article is therefore all about the cloud and what it means for the everyday linux user and what it can do for you and what, if any, pitfalls are there. - -From an end user and home user point of view, cloud computing has basically come to mean any service that is hosted online. - -So here goes, which cloud services are useful for an everyday linux user? - -### Email ### - -I would be very surprised if you are reading this and you don’t have an email account. - -PC Advisor magazine analysed the top 6 emails services back in March, 2014 consisting of Outlook, GMail, Yahoo, iCloud, AOL and GMX. - -### Office Suites ### - -As well as an email client one of the most commonly used tools required by everyone is an office suite. - -In the past people would toddle off down to PC World, buy a computer and come home with a great big machine and half a dozen CDs containing 5 programs you definitely won’t use and Microsoft Works which was a cheap and virtually useless cut down version of Microsoft Office. - -Now you don’t even need an office suite on your computer even though there are some great free choices out there including LibreOffice and Kingsoft. - -The obvious choices are of course Google Docs and Office 365. Does Office 365 work for Linux? Well this article from PC Pro in 2012 seems to suggest that it does. - -![](http://www.linuxnews.pro/wp-content/uploads/2014/06/office365_1.png) - -I don’t believe everything I read though so I signed up to Office 365 to see what would happen. - -Signing up was free for a month and I was presented with a list of online applications that I could use which included Word, Excel and Outlook. - -![](http://www.linuxnews.pro/wp-content/uploads/2014/06/office365_2.png) - -All looked to be going well. I started Microsoft Word, chose a template to use and then of course it didn’t work at all. - -Office 365 isn’t yet supported on Linux and to be honest you don’t need it. Move on. - -![](http://www.linuxnews.pro/wp-content/uploads/2014/06/office365_3.png) - -Google Docs works and for home use it is perfect. There are hundreds of templates for the word processing and presentation tools and the spreadsheet application does most things although it doesn’t really replace Excel because you haven’t got hundreds of wannabe developers creating naff macros and VBA scripts everywhere. - -![](http://www.linuxnews.pro/wp-content/uploads/2014/06/zoho_1.png) - -Another alternative to Office 365 is Zoho. - -Similar to Google Docs, Zoho includes a word processor, spreadsheet tool, presentation tool and mail. - -There are finance and CRM tools as well. - -![](http://www.linuxnews.pro/wp-content/uploads/2014/06/zoho_2.png) - -The interface for the tools is actually very nice and clean. - -Services such as Google Docs and Zoho also give you the power of collaboration. - -Documents can be shared and worked on by different people in different locations. - -This site provides a good list of alternative choices to Google Docs and Zoho. - -### Online File Storage ### - -Another good service provided by Google Docs and Zoho is the ability to store the documents and files you create online. - -There are other services however such as Dropbox that are used to exclusively store your documents in the cloud. - -The benefit of storing files with services like Dropbox is that if your house is burgled or catches fire then you have an offshore backup that remains intact. You can also access your files anywhere. - -Dropbox is free for up to 2 gigabytes of use. If you have a lot more data, and most of us do nowadays, then there is a $ 9.99 monthly plan that is available allowing for 100 gigabytes. There is also a business version available from $ 15 a month. - -There are of course alternatives to Dropbox and this site provides a list of the best online backup solutions. - -### Photos ### - -Since the introduction of digital cameras and more recently smart phones, more and more of us have memory cards full of photos. - -I bet that at some point or other that you have lost photos because your phone died and the photos were on the phone and not the memory card or you lost your phone losing pictures of your child’s sports day or another important occasion. - -Losing a phone is never a good thing. If you are clever you will have set up some sort of security because most people have their phones synchronised with their email accounts, Facebook, Twitter and even online banking. - -All it takes to fix a lost phone is to change the passwords to all of the above accounts but lost photos are just not possible to recover and are a little bit more upsetting when lost. - -One solution of course is to backup to your computer. This is of course a good first step but occasionally laptops break as well and you are back to square one. - -Online photo storage sites are great resources because not only do they keep your photos safe you can also share them with whoever you choose to, eliminating the need to get 5 copies of the same photo developed to send to mum, nan, sister, aunty and mother-in-law. - -The solution I like to use is Google’s Picasa but many of you will have heard of services like Flickr as well. - -Lifehacker has a list of the five best photo sharing services. - -Remember though that just because they are called photo sharing services doesn’t mean you have to share them. You can keep them just to yourself. - -### Music ### - -The first record that I was ever given was a 12 inch vinyl version of “Kings of the wild frontier” by “Adam and the Ants” back in the early 1980s. - -As the 1980s progressed the long play records were replaced by cassettes and just as I had accumulated a decent number of cassettes the compact disc became the thing to have. - -Hundreds of compact discs later and MP3 file sharing became the norm and it even became the legal way of doing things. - -Nothing sits still with technology and the future is now with audio streaming services such as Spotify. - -Spotify is free to use but is supported with the inclusion of adverts. In this regard it is like having your own personal radio station where you choose the playlist. Of course you can pay a monthly fee and have the adverts removed altogether. - -There are dozens of similar services including Grooveshark and last.fm. - -Techradar has a list of 7 alternatives to Spotify. - -### Film ### - -The first film I ever watched in the Cinema was Dumbo. The first video I ever watched was “Krull” which contained a young Dulph Lundgren. The format of the video was on Beta Max. (My next door neighbour had one). - -My dad came home one day with a video recorder from Radio Rentals and my sister and I used to take it in turns to pick a video to hire from the video store. I remember my first choice being “The Black Hole”. - -As with music time moves on. Just as you get large units full of movies, some genius comes along and develops DVDs and then they come out with Bluerays. - -Now of course video streaming is the order of the day especially if you have a decent enough internet connection. - -The most commonly known services are Netflix and Lovefilm. - -This website has a list of good alternatives to Netflix. Not all of these services (including Netflix) work seamlessly on Linux. - -### Gaming ### - -Music, films and now gaming have moved to the online arena. - -Gaming is of course more difficult. Music is relatively low cost in terms of bandwidth and although films require a little more, the stream just needs to remain steady to get a clear picture. - -Games need to run at a consistently high frame rate to be playable and unless you have a decent connection it probably isn’t even worth trying. - -Current services offering a cloud gaming service include OnLive and StreamMyGame. - -This site contains a list of 6 online gaming services to rival OnLive. - -### Pitfalls ### - -Cloud computing isn’t free from issues. - -There is the obvious problem of hacking. If someone gets access to your online banking or your email then you have a real problem. - -What about online file storage? There is currently the high profile case of Megaupload.com. - -Megaupload.com was essentially a file storage site for storing large files. The problem is that a lot of people used the service to share copyright material and the US authorities came down like a ton of bricks and the service was shut down. - -Now a lot of people losing files would perhaps be expecting the inevitable but what about people who genuinely did nothing wrong. Their data has been lost. The US authorities refusing to give it back. - -Finally there is the subject of service maintenance. If your email went down for a day could you cope? What about 3 days? What about a month? You are at the mercy of the service provider. - -A lot has been made about large companies losing data and there has also been a lot of noise regarding heartbleed which is a vulnerability found in SSL left unpatched for years. - -If you have services hosted for you online then you are relying on technical support staff to do their job properly and if they don’t you could be at the mercy of hackers, hardware failures and poor backup and recovery maintenance. - -### Summary ### - -Cloud computing has really become the buzz term for any online service. Your web browser is a client connecting to a server or clusters of servers hosted anywhere in the world. The point is that you don’t care. You don’t need to know. - -Generally speaking I have barely touched the surface. We all use the cloud everyday and most of us don’t even think about it. - -How does the cloud affect the everyday linux user? It turns out quite a bit. - -Is the cloud a good or bad thing? Neither. Each service has to be judged on it’s own merits. - -The term “The Cloud” is just something marketing people and the technical press get excited about. Anyone remember when they kept using the term “Web 2.0″? - -Thankyou for reading. - --------------------------------------------------------------------------------- - -via: http://www.linuxnews.pro/how-does-the-cloud-affect-the-everyday-linux-user/ - -译者:[译者ID](https://github.com/译者ID) 校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 \ No newline at end of file diff --git a/sources/talk/20140611 Red Hat's CEO Sees Open Source Cloud Domination.md b/sources/talk/20140611 Red Hat's CEO Sees Open Source Cloud Domination.md deleted file mode 100644 index 9e57a2533a..0000000000 --- a/sources/talk/20140611 Red Hat's CEO Sees Open Source Cloud Domination.md +++ /dev/null @@ -1,33 +0,0 @@ -Red Hat's CEO Sees Open Source Cloud Domination -================================================================================ -Red Hat CEO Jim Whitehurst sees the business opportunity of a generation in what he calls a computing paradigm shift from client server to cloud architectures. “In those paradigm shifts, generally new winners emerge,” says Whitehurst and he intends to make sure Red Hat is one of those winners. His logic is sound and simple: disruptive technologies like the cloud that arise every couple decades level the playing field between large, established firms and smaller, innovative challengers since everyone, from corporate behemoth to a couple guys in a garage, starts from the same spot and must play by the same unfamiliar and changeable rules. With the cloud “there’s less of an installed based and an opportunity for new winners to be chosen,” Whitehurst adds. His mission is “to see that open source is the default choice for next generation architecture” and that Red Hat is the preferred choice, particularly for enterprise IT, of open source providers. - -The case for open source dominating the cloud rests on the fact that it’s already the foundation for many popular cloud services and enterprise applications. Whitehurst aptly notes that outside of Microsoft Azure, the underlying infrastructure of all the major public cloud services is built upon open source software. Furthermore, software like Linux, Apache, MySQL, WordPress and many others are already widely used and trusted by most enterprises. “In many cases [open source] already is the default choice for next generation architectures, but it hasn’t fully driven itself through the traditional enterprise data center,” he says. Cloud software is the next and most important software category up for open source disruption. - -![](http://blogs-images.forbes.com/kurtmarko/files/2014/06/redhat-logo.jpg) - -Yet open source is still saddled with a reputation for widely variable software quality and support, something the recent OpenSSL Heartbleed bug only reinforced. However Whitehurst contends that strong enterprise adoption of Red Hat’s Linux distribution and it’s training and skills certification programs lends credibility to a similar plan for the cloud: [Red Hat’s Cloud Partner Program][1]. He believes such insurance policies alleviate enterprise IT’s fears of adopting open source software for both internal, private clouds and external public cloud services. Red Hat wants its imprimatur to be the Good Housekeeping seal of approval for open source in general and cloud software in specific, namely IT’s assurance that their applications will work and the service is trustworthy and reliable. - -Red Hat’s strategy to make open source clouds safe for the enterprise is mirrors that used to break into the market for enterprise server software. There, “Job one for Red Hat is making sure our operating system and layers above that work well on anyone’s infrastructure underneath,” says Whitehurst. Red Hat is applying this same model of polishing, integrating and supporting open source software to cloud stacks. “One of the most important parts about cloud, public, private or hybrid, is a sense that you can confidently run your applications,” says Whitehurst and he believes Red Hat’s track record on Linux and other open source products will carry over to make Red Hat “the enterprise choice” for cloud architectures. - -### Cloud isn’t just virtualization 2.0 ### - -One of the conundrums for OpenStack advocates like Whitehurst is the entrenchment of Microsoft and VMware in the enterprise market. Although virtual servers are a prerequisite for clouds, they’re sufficient. Countering the notion that enterprise clouds are just a natural extension of virtualized servers and storage, Whitehurst argues that by setting new rules for infrastructure and application design, cloud infrastructure is more than just the natural evolution of server virtualization. - -![](http://blogs-images.forbes.com/kurtmarko/files/2014/06/RH_NEXT_HS-JIM-W-01.jpg) - -Whitehurst draws an important distinction between traditional client-server and cloud-optimized applications. “One of the big questions will be how much of this [cloud adoption] is moving traditional Windows workloads, which frankly were written as stateful apps in the first place. [Instead] are we talking about a new generation of applications that are actually built with elasticity and scalability in mind.” Whitehurst clearly believes cloud infrastructure is much more appropriate for the latter and that in such Greenfield scenarios, OpenStack and other open source software have established themselves as the preferred platform. Contrasting OpenStack, based on the Linux KVM hypervisor and VMware or Microsoft using their proprietary virtual machine platforms, Whitehurst says, “Longer term, nobody really cares what the hypervisor is, you just expect it to work and bluntly, as long as Red Hat supports you on it, why do you have to care,” adding “more and more, you’ll see the hypervisor mattering less and less.” Of course, VMware and Microsoft probably agree, both having moved their energies to building more sophisticated management platforms and making the hypervisor a baseline feature. - -But in Whitehurst’s view of the world, traditional virtualization platforms like VMware or Microsoft Hyper-V are legacy infrastructure designed for yesterday’s client-server software, not the sort of distributed, rapidly relocatable, elastically scalable applications that define the era of big data, SaaS and social software. “I’m not sure what good you get out of putting Exchange on a cloud,” he quips. Instead, he says this new generation of cloud-optimized applications are the sweet spot for OpenStack. According to Whitehurst, “If you look at where most new applications are getting built, and therefore where so much of the innovation around languages, frameworks and management paradigms are happening, it’s around an open infrastructure.” But there’s obviously some selection bias in Whitehurst’s account, as he lives in an open source world where it’s easy to be unaware, overlook or ignore the innovation happening on proprietary cloud platforms like Azure, AWS and vCloud. - -In sum, Whitehurst hopes and expects OpenStack to do to VMware what Linux did to Windows: to become the first choice of cloud-savvy startups and if not the default choice, at least an accepted and respectable alternative within the enterprise. In my next column I’ll explain that even for an open source champion like Whitehurst, OpenStack versus VMware vCloud or Microsoft Azure isn’t an either/or choice and how he sees the fundamental notion of cloud computing as based on virtual machines as an design model likely to change. - --------------------------------------------------------------------------------- - -via: http://www.forbes.com/sites/kurtmarko/2014/06/08/red-hat-ceo-open-source-clouds/ - -译者:[译者ID](https://github.com/译者ID) 校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[1]:http://www.redhat.com/partners/become/cloud/ \ No newline at end of file diff --git a/sources/talk/20140612 Linux hiring frenzy--Why open source devs are being bombarded with offers to jump ship.md b/sources/talk/20140612 Linux hiring frenzy--Why open source devs are being bombarded with offers to jump ship.md deleted file mode 100644 index 4115b21b64..0000000000 --- a/sources/talk/20140612 Linux hiring frenzy--Why open source devs are being bombarded with offers to jump ship.md +++ /dev/null @@ -1,27 +0,0 @@ -Linux hiring frenzy: Why open source devs are being bombarded with offers to jump ship -================================================================================ -> Summary: Figures from the Linux Foundation suggest skills shortages across disciplines and throughout Europe. - -Nine out of ten (87 percent) of hiring managers in Europe have "hiring Linux talent" on their list of priorities and almost half (48 percent) say they are looking to hire people with Linux skills within the next six months. - -But while they either need or want to hire more people with Linux skills, the data from the Linux Foundation suggests that this is easier said than done. Almost all — 93 percent — of the managers surveyed said they were having difficulty finding IT professionals with the Linux skills required and a quarter (25 percent) said they have "delayed projects as a result". - -All of this makes it a good time to be a Linux expert. - -Seven out of 10 Europe-based Linux professionals have received calls where they were pitched new positions in the past six months, and a third said they had received more calls than in the previous six months. One in three are looking to move anyway, and over half of them said it would be fairly or very easy. Salary is the biggest reason to move jobs, followed by work-life balance and the chance to gain additional skills. - -Employers are trying harder to keep hold of staff too: In the past six months, 29 percent of Linux professionals say they have been offered a higher salary from their current employers, while a quarter said they’ve been offered a flexible work schedule and one in five have been extended additional training opportunities or certification. - -The Linux Foundation, a non-profit organisation which supports the growth of Linux, and Dice Holdings, which provides career sites for technology professionals, produced the research which covers Europe and the US. - -In terms of the specific skills organisations are looking for people with the developer (69 percent) and enterprise management (51 percent) skills. These are followed by 32 percent of respondents who are looking for people with a combination of development and operations skills (DevOps), and 19 percent who are in management/IT management. - -The Linux Job Report has been produced for the last three years by the Linux Foundation and Dice but this is the first time that a specific report on European skills has been separated out of the worldwide report. Some 893 Linux professionals responded to the survey across Europe. - --------------------------------------------------------------------------------- - -via: http://www.zdnet.com/linux-hiring-frenzy-why-open-source-devs-are-being-bombarded-with-offers-to-jump-ship-7000030418/ - -译者:[译者ID](https://github.com/译者ID) 校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 \ No newline at end of file diff --git a/sources/talk/20140612 The Companies That Support Linux--Rackspace.md b/sources/talk/20140612 The Companies That Support Linux--Rackspace.md deleted file mode 100644 index 20b5f7964b..0000000000 --- a/sources/talk/20140612 The Companies That Support Linux--Rackspace.md +++ /dev/null @@ -1,61 +0,0 @@ -The Companies That Support Linux: Rackspace -================================================================================ -[![](http://www.linux.com/images/stories/41373/Paul-Voccio-Rackspace.jpg)][1] - -[Rackspace][1] has lately been in the news for its stock market gains and a [potential acquisition][2]. But over the past 16 years the company has become well known, first as a web hosting provider built on Linux and open source, and later as a [pioneer of the open source cloud][3] and founder of the OpenStack cloud platform. - -In May, Rackspace became a [Xen Project][4] member and was one of [three companies to join the Linux Foundation][5] as a corporate member, along with CoreOS and Cumulus Networks. - -“Many of the applications and infrastructure that we need to run for internal use or for customers run best on Linux,” said Paul Voccio, Senior Director of Software Development at Rackspace, via email. “This includes all the popular language frameworks and open virtualization platforms such as Xen, LXC, KVM, Docker, etc.” - -In this Q&A, Voccio discusses the role of Rackspace in the cloud, how the company uses Linux, why they joined the Linux Foundation, as well as current trends and future technologies in the data center. - -### Linux.com: What is Rackspace? ### - -Paul Voccio: Rackspace is the managed cloud specialist and founder of OpenStack, the open-source operating system for the cloud. Hundreds of thousands of customers look to Rackspace to deliver the best-fit hybrid cloud solutions for their IT needs, leveraging a product and services portfolio that allows workloads to run where they perform best – whether on the public cloud, private cloud, dedicated servers, or a combination of platforms. - -As a managed cloud pioneer, we give our customers 24x7 access to cloud engineers for everything from planning and architecting to building and operating clouds through our award-winning Fanatical Support®. We help customers successfully architect, deploy and run their most critical applications. Or, more plainly put, we’re cloud specialists so you don’t have to be. We are headquartered in San Antonio, Texas, and operate a global support and engineering organization with data centers on four continents. - -### How and why do you use Linux? ### - -Rackspace uses Linux because it provides a stable and flexible platform for our customers' workloads. Our customers trust us to support their mission-critical applications and we need reliable infrastructure – including software and hardware – to meet their expectations. If you look under the hood in our dedicated environments or in our expansive cloud infrastructure, you'll find Linux running there. - -Many of the applications and infrastructure that we need to run for internal use or for customers run best on Linux. This includes all the popular language frameworks and open virtualization platforms such as Xen, LXC, KVM, Docker, etc. Running combinations of these platforms give us the stability and performance we demand for the Rackspace Cloud. Our Cloud Servers product runs OpenStack services that manage tens of thousands of hypervisors – all running Linux. - -Using Linux also allows us to tap into a community of experts to solve problems. When we have an issue, we're comfortable asking questions. When we have a solution, we enjoy sharing it with the community. At Rackspace, we understand how to work and contribute in an open community and Linux has many opportunities to build relationships with other groups that have similar goals. - -### Why did you join the Linux Foundation? ### - -Joining the Linux Foundation allows us to show our support and engage the Linux community in new ways. We've learned plenty from running Linux in highly demanding environments at a large scale and we're eager to share those experiences. Other members of the community have probably run into different challenges than we have and this gives us a greater opportunity to learn from them as well. - -### What interesting or innovative trends are you witnessing in the data center and what role does Linux play in them? ### - -Virtualization and automation have changed how companies deploy hardware and software. Linux gives us several virtualization options and these allow us to automate more of our infrastructure deployments and maintenance tasks. Automation and configuration management frameworks allow us to reduce our costs, improve our testing capabilities, and bring products to market faster. The majority of these open source automation frameworks run best on Linux servers. - -### How is Rackspace participating in that innovation? ### - -We leverage several open-source Linux-based tools and projects to deliver great customer outcomes. One of our largest efforts in this area is with OpenStack. It's the software that runs our public and private clouds and we're actively engaged with the community to improve it. We're using Linux to find new ways to scale our large virtualization platform and deliver infrastructure to customers quickly. - -The open-source nature of Linux inspires us to share the majority of these discoveries with the community. Our customers can improve OpenStack and those improvements will eventually make it into our product offering. We make contributions to a countless number of open source projects either as a company or as individual Rackers (our employees are called "Rackers") and many of these projects are designed to run on Linux. - -### What other future technologies or industries do you think Linux and open source will increasingly become important in and why? ### - -The move to software-defined infrastructure is a big shift. Customers already have access to virtualization platforms like Xen that allow them to define their infrastructure with software. Software-defined networking is quickly becoming more mature and scalable. However, customers want the ability to have a software defined datacenter at their fingertips. This may involve physical servers, virtual servers, and virtual networks that need high performance with flexible configurations. Many of the current technologies are designed to run on Linux due to technology already available in the kernel or userland frameworks provided by the community. - -### Are you hiring? ### - -From hacking on kernels to supporting thousands of virtual machines – we are always looking for talented admins, developers and engineers. You can find more information at Rackertalent.com. - --------------------------------------------------------------------------------- - -via: http://www.linux.com/news/featured-blogs/200-libby-clark/775890-the-companies-that-support-linux-rackspace/ - -译者:[译者ID](https://github.com/译者ID) 校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[1]:http://www.rackspace.com/ -[2]:http://www.bloomberg.com/news/2014-05-15/rackspace-hires-morgan-stanley-to-evaluate-options.html -[3]:http://www.informationweek.com/cloud/infrastructure-as-a-service/9-more-cloud-computing-pioneers/d/d-id/1109120 -[4]:http://www.xenproject.org/ -[5]:http://www.linuxfoundation.org/news-media/announcements/2014/05/new-linux-foundation-members-advance-massively-scalable-secure \ No newline at end of file diff --git a/sources/talk/20140619 Fire Phone Dynamic Perspective tracks eyes for 3D UI.md b/sources/talk/20140619 Fire Phone Dynamic Perspective tracks eyes for 3D UI.md deleted file mode 100644 index 65b0e250d1..0000000000 --- a/sources/talk/20140619 Fire Phone Dynamic Perspective tracks eyes for 3D UI.md +++ /dev/null @@ -1,79 +0,0 @@ -Fire Phone Dynamic Perspective tracks eyes for 3D UI -================================================================================ -![](http://cdn.slashgear.com/wp-content/uploads/2014/06/fire-phone-dynamic-perspective-1-820x420.jpg) - -3D on phones is back, and it's Amazon giving it a try this time with Dynamic Perspective on the new [Fire Phone][1]. Eschewing a "true" 3D display as we've seen before, the Fire Phone's system instead uses four front-facing cameras to track the user's eyes, and adjusts the on-screen UI so that the various layers shift around to give the impression of 3D. - -A combination of physically tilting the phone and moving your head as you hold it can be used to navigate through the interface and apps. So, tilting the Fire Phone can scroll through the browser, rather than having to swipe around with a fingertip. - -youtube视频链接地址:[http://www.youtube.com/embed/iB75HJe8eiI][2] - -Similarly, with a carousel of items in Amazon's store on the phone, tilting the handset left and right pans through the products. - -youtube视频链接地址:[http://www.youtube.com/embed/lwj0hlE8CJc][3] - -In ebooks, the Kindle app can scroll through according to how you're holding it. The settings can be switched between adjusting speed depending on how extreme the tilt angle is, or locking it to a fixed rate if you'd rather have things be predictable. - -### This is the Amazon Fire Phone ### - -Maps, too, get Dynamic Perspective support. Moving the Fire Phone around can show what's "hiding" behind 3D buildings or on different layers. Tilting can also be used to open up menus, in games for motion control, and even to navigate between the now-playing and lyrics UIs in the Prime Music app. - -![](http://cdn.slashgear.com/wp-content/uploads/2014/06/P1010143-XL-600x337.jpg) - -All that 3D didn't come easy, though. Based on the fact that every face is different, with variations in hair color, shape, whether they wear glasses, and other factors, Amazon had to put Dynamic Perspective through some serious testing. - -![](http://cdn.slashgear.com/wp-content/uploads/2014/06/P1010006-XL-600x337.jpg) - -In the companies labs, that involved a somewhat nightmarish rubber head on a stick, but then Amazon expanded that to use real-world data from thousands of photos of people. The use of four cameras means that, no matter what may be blocking the screen, the Fire Phone should be able to spot the user properly. - -youtube视频链接地址:[http://www.youtube.com/embed/X-wPOq27iXk][5] - -Whether it'll all work as Bezos says, or be something owners quickly turn off, remains to be seen. We'll know more when we spend some hands-on time with the Fire Phone soon. - -![](http://cdn.slashgear.com/wp-content/uploads/2014/06/fire-phone-dynamic-perspective-1.jpg) - -![](http://cdn.slashgear.com/wp-content/uploads/2014/06/P1010143-XL.jpg) - -![](http://cdn.slashgear.com/wp-content/uploads/2014/06/P1010012-XL1.jpg) - -![](http://cdn.slashgear.com/wp-content/uploads/2014/06/P1010010-XL.jpg) - -![](http://cdn.slashgear.com/wp-content/uploads/2014/06/P1010007-XL.jpg) - -![](http://cdn.slashgear.com/wp-content/uploads/2014/06/P1010003-XL.jpg) - -![](http://cdn.slashgear.com/wp-content/uploads/2014/06/P1010153-XL.jpg) - -![](http://cdn.slashgear.com/wp-content/uploads/2014/06/P1010145-XL.jpg) - -![](http://cdn.slashgear.com/wp-content/uploads/2014/06/P1010019-XL.jpg) - -![](http://cdn.slashgear.com/wp-content/uploads/2014/06/P1010030-XL.jpg) - -![](http://cdn.slashgear.com/wp-content/uploads/2014/06/P1010022-XL.jpg) - -![](http://cdn.slashgear.com/wp-content/uploads/2014/06/P1010004-XL.jpg) - -![](http://cdn.slashgear.com/wp-content/uploads/2014/06/P1010010-XL-1.jpg) - -![](http://cdn.slashgear.com/wp-content/uploads/2014/06/P1010015-XL.jpg) - -![](http://cdn.slashgear.com/wp-content/uploads/2014/06/P1010014-XL.jpg) - -![](http://cdn.slashgear.com/wp-content/uploads/2014/06/P1010008-XL1.jpg) - -![](http://cdn.slashgear.com/wp-content/uploads/2014/06/P1010006-XL.jpg) - --------------------------------------------------------------------------------- - -via: http://www.slashgear.com/fire-phone-dynamic-perspective-tracks-eyes-for-3d-ui-18334229/ - -译者:[译者ID](https://github.com/译者ID) 校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[1]:http://www.slashgear.com/tags/fire-phone -[2]:http://www.youtube.com/embed/iB75HJe8eiI -[3]:http://www.youtube.com/embed/lwj0hlE8CJc -[4]:http://www.slashgear.com/this-is-the-amazon-fire-phone-18334195/ -[5]:http://www.youtube.com/embed/X-wPOq27iXk \ No newline at end of file diff --git a/sources/talk/20140624 Staying free--should GCC allow non-free plug ins.md b/sources/talk/20140624 Staying free--should GCC allow non-free plug ins.md deleted file mode 100644 index 6d6dcdfe81..0000000000 --- a/sources/talk/20140624 Staying free--should GCC allow non-free plug ins.md +++ /dev/null @@ -1,39 +0,0 @@ -CNprober translating.. - -Staying free – should GCC allow non-free plug ins? -================================================================================ -> Arguments in favour of the use of non-free plug-ins in GCC have again been raised on GCC mailing-lists, but are trumped by the arguments for GCC as a vehicle for free software development - -Once again, Gcc and its lack of modularity has been raised as an issue and contrasted with LLVm, the new compiler on the block. GCC is huge and venerable: 5 million lines, 30 years, and growing. LLVM, in contrast, is relatively youthful and modular and allows free and proprietary languages to be added as modules. - -The core of LLVM is ‘open source’. GCC is copyleft and unreservedly free software and doesn’t allow plug-ins or other means to add proprietary extensions to the GCC code. The argument, as delivered by Eric Raymond, is that “FSF can no longer prevent proprietary vendors from plugging into a free compiler to improve their tools. That horse has left the barn; the strategic goal of the anti-plug-in policy has been definitively busted.” - -LLVM has been sponsored by Apple as a replacement for GCC on OS X and Apple hardware and has grown in popularity, especially among users of the BSDs. Advocates of LLVM see it as a putative replacement for GCC in the wider market for applications developers and mobile devices. The argument against GCC is that its complexity, and the commitment of its developers to copyleft licensing, constrains the possibilities for proprietary developers, who do not want to release their language or architectural specifications under a copyleft licence. Apple, of course, has a long history of antipathy to free software, and doesn’t allow applications licensed under copyleft licences to be distributed through its App Store. - -To this extent, the argument between LLVM and GCC is a retread of the historic differences between GNU/Linux and the BSDs, between ‘open source’ and free software. Open source developers allow the code to be reused in any context, free or proprietary. Free software is restrictive in that it insists that the code, and any modifications to the code, must remain free in perpetuity. Advocates of free software would argue that the integrity of copyleft licensing has been instrumental in the spread of GCC, and has taken Linux and free software into places it would not otherwise have reached, and that free software cannot be bought or corrupted by commercial or corporate interests. Open source advocates argue that open source is more free because the user has no restrictions and can do what he or she likes, including developing closed source versions of the code. - -Since the beginning, the GNU Compiler Collection (GCC) was vital to the spread of free software. Compilers were a rare and expensive commodity and the compilers of the proprietary software companies were rife with ‘features’ that were non-compliant with ANSI programming standards. Porting software between different machines and operating systems was an unnecessarily complicated task. GCC, the first truly free cross-platform compiler, commoditised this process. - -GCC was a breakthrough product for applications developers and mobile device developers – not just those who were committed to the idea of free software. Not only was GCC free and portable, its ubiquity and commonality across different architectures made it easier to port software between machines and to expect robust and consistent results – as the likes of John Gilmore, Michael Tiemann and David Henkel- Wallace were to discover when they made GCC and its development the key selling point of Cygnus Solutions, the first company to make money by selling free software. - -The primary technical difference between LLVM and GCC emerges in the separation between the modules that form the ‘front ends’, ‘middle end’ and ‘back ends’ of both GCC and LLVM. ‘Front ends’ are used to interpret the code specific to the translation of a particular language. The ‘middle end’ optimises the translated code. The ‘back ends’ take the optimised code and apply the results to a specific target architecture. LLVM separates these modules into distinct entities, but for semantic and historical reasons, GCC obfuscates the separation between the modules. - -Perhaps untypically for a free software project, it is a difficult process to add a new language or architecture to GCC and the adding of proprietary plug-ins is not allowed. There is little clear separation between the modules, and the path of least resistance is to add any feature under a free software licence. The early ports of C++ and Objective C (via Apple) are cited as examples where the original developers might have preferred to keep the code in-house and proprietary, and instead released the code as free software. - -In contrast, LLVM has allowed, or perhaps even encouraged, the addition and development of proprietary languages and architectures – one example being Nvidia’s NVCC for GPU computing, based on Clang and LLVM. The source code of NVCC is inaccessible to free software or ‘open source’ developers. - -Richard Stallman’s [take on this][1] is characteristically resolute: “In the free software movement, we campaign for the freedom of the users of computing. The values of free software are fundamentally different from the values of open source, which make‘bettercode’theultimategoal. IfGCCwere to change from a free compiler into a platform for non-free compilers, it would no longer serve the goal of freedom very well. - -“The Clang and LLVM developers reach different conclusions from ours because they do not share our values and goals. They object to the measures we have taken to defend freedom because they see the inconvenience of them and do not recognise (or don’t care about) the need for them. I would guess they describe their work as ‘open source’ and do not talk about freedom.” - -The GCC developers are unlikely to compromise on the licensing terms. While LLVM is fashionable among certain sectors of industry, because it is young and new and has been quicker to jump on developing trands in programming languages, the prevailing wind is towards greater openness, and GCC’s resolve to be incorruptible and free from commercial interests, may be the greater asset in the long term. The Unix companies learnt something from the Unix wars of the Eighties and Nineties. Languages and operating systems are tools, and are better open and shared. GCC is free software and belongs to nobody. - --------------------------------------------------------------------------------- - -via: http://www.linuxuser.co.uk/features/staying-free-should-gcc-allow-non-free-plug-ins - -译者:[译者ID](https://github.com/译者ID) 校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[1]:http://lwn.net/articles/582241 \ No newline at end of file diff --git a/sources/talk/20140801 $2400 Valued Introduction To Linux Course Is Available For Free On edX.md b/sources/talk/20140801 $2400 Valued Introduction To Linux Course Is Available For Free On edX.md deleted file mode 100644 index 3eafcb4fe0..0000000000 --- a/sources/talk/20140801 $2400 Valued Introduction To Linux Course Is Available For Free On edX.md +++ /dev/null @@ -1,37 +0,0 @@ -$2400 Valued Introduction To Linux Course Is Available For Free On edX -================================================================================ -![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/07/Introduction_Linux_edX.jpg) - -Probably you have already heard it. [Linux Foundation][1] has tied up with [edX][2] (a major online learning platform founded by MIT and Harvard University) to provide its Introduction to Linux course, which usually costs $2400, for free. - -edX has over 200 courses from over 50 elite universities, corporations and organizations worldwide. Over 2.5 million users attend these online courses across the globe. - -**Introduction to Linux course is starting from 1st August**. There are three ways one can take this course (or most other edX courses): - -- **Audit the course**: Simple register for **free** and get access to study material. Participate in course as per your own pace. There is no compulsion or penalty if you cannot complete the course. -- **Honor code certificate**: It certifies that you have successfully completed the course, however, it doesn’t verify your identity. This too is for free. -- **Verified certificate of achievement**: This certificates validates your identity and costs $250 for **Introduction to Linux** course. - -Introduction to Linux requires a working knowledge of computers and common software. Program aims to provide experienced computer users, who may or may not have previous Linux experience, a good working knowledge of Linux, from both a graphical and command line perspective. It consists a course work of 40 to 60 hours and is designed by Dr. Jerry Cooperstein, who manages training content at Linux Foundation. - -If you are planning to attend Introduction to Linux, it is advised to have Linux installed on your computer beforehand. Linux Foundation has [prepared a guide to set up the computer][3] to help users out. - -What are you waiting for? If you ever wanted to learn Linux, this is the time and best of all, it’s FREE! Sign up to the course with the link below: - -- [Introduction to Linux course at edX][4] - --------------------------------------------------------------------------------- - -via: http://itsfoss.com/introduction-linux-free-edx/ - -作者:[Abhishek][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://itsfoss.com/author/Abhishek/ -[1]:http://www.linuxfoundation.org/ -[2]:https://www.edx.org/ -[3]:https://training.linuxfoundation.org/images/pdfs/Preparing_Your_Computer_for_LFS101x.pdf -[4]:https://www.edx.org/course/linuxfoundationx/linuxfoundationx-lfs101x-introduction-1621#.U9gJ5nWSyb8 \ No newline at end of file diff --git a/sources/talk/20140804 Microsoft's Raspberry Pi Will Cost $300.md b/sources/talk/20140804 Microsoft's Raspberry Pi Will Cost $300.md deleted file mode 100644 index 3192f039a4..0000000000 --- a/sources/talk/20140804 Microsoft's Raspberry Pi Will Cost $300.md +++ /dev/null @@ -1,28 +0,0 @@ -Microsoft’s Raspberry Pi Will Cost $300 -================================================================================ -![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/08/Sharks_Cove_Microsoft.jpg) - -I presume that you have heard of [Raspberry Pi][1]. A $35 microcomputer that has revolutionized the low cost computing and has cult following among hardware hobbyist and do-it-yourself enthusiasts. Several other followed in the footsteps of Raspberry Pi to provide low cost micro computers, [Arduino][2] is one of the successful examples. - -Microsoft has decided to enter the world of “System on Chip” and to come up with its “own Raspberry Pi”. Teamed up with Intel and [CircuitCo][3], [Microsoft will be launching a micro computer named “Sharks Cove“][4]. - -Sharks Cove boasts of Intel Atom Z3735G, a quad-core chip with speeds up to 1.83GHz, 1GB of RAM, 16GB of flash storage and a MicroSD slot among many other things. You can read the full specifications [here][5]. The main aim of Shark Cove is to provide a platform to develop hardware and drivers for Windows and Android. - -Everything sounds fine till it comes to price. Sharks Cove will cost $299 with a Windows 8.1 license. While Arduino costs around $55 and Raspberry Pi $35, I don’t think there will be many buyers for such a high price in a domain which is dominated by low cost Linux based devices. What do you think? - --------------------------------------------------------------------------------- - -via: http://itsfoss.com/microsofts-raspberry-pi/ - -作者:[Abhishek][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://itsfoss.com/author/Abhishek/ -[1]:http://www.raspberrypi.org/ -[2]:http://www.arduino.cc/ -[3]:http://www.circuitco.com/ -[4]:http://blogs.msdn.com/b/windows_hardware_and_driver_developer_blog/archive/2014/07/26/the-sharks-cove-is-now-available-for-pre-order.aspx -[5]:http://www.sharkscove.org/docs/ \ No newline at end of file diff --git a/sources/talk/20140804 Nostalgic Gaming On Linux With Good Old Games.md b/sources/talk/20140804 Nostalgic Gaming On Linux With Good Old Games.md deleted file mode 100644 index afc461446d..0000000000 --- a/sources/talk/20140804 Nostalgic Gaming On Linux With Good Old Games.md +++ /dev/null @@ -1,94 +0,0 @@ -Nostalgic Gaming On Linux With Good Old Games -================================================================================ -![](http://thelinuxrain.com/content/01-articles/70-nostalgic-gaming-on-linux-with-good-old-games/headimage.jpg) - -**Thanks to the recent Linux support provided by DRM-free classic games provider, GOG.com, getting that nostalgic kick on Linux has never been easier. In this article I'll also detail a few of my favourite classic games that are now available to play in Linux.** - -It's not all nostalgia, though. Some of the classic games you might think of are genuinely classic, amazing games no matter their age. Others, you might need to imagine you're back in, say, 1995 and look at the game from that point of view to appreciate how good it must have seemed at that time. Whatever the case though, there's no shortage of these old games out there to enjoy and thankfully it's recently gotten even easier with [GOG.com][1] recently announcing Linux support. - -A lot of these old classic games actually run in [DOSBox][2], so a seasoned Linux gamer who has experience with such games may bring up the point that you could play a lot of these games provided by services such as GOG.com for years already, well before that recent announcement. Which is correct, I've done the same thing myself, but it does involve a bit of fiddling with files, so at the very least we now have a "turn-key" solution even with the DOSBox powered games - you download them, you launch them, they should just work. If you just want to purchase a game and play it right away, that's no bad thing. - -Then there's the non-DOS games. A lot of old Windows 95/98 games do often work fine in WINE, but not always, or perhaps need workarounds to be manually applied or even a special version of WINE itself. Some old games just won't work at all no matter what you try, even on modern versions of Windows itself! So again, having an alternative available that is designed to work out-of-the-box (and DRM-free, no less) is a nice thing. - -GOG.com initially provided 50 Linux compatible games on their penguin-friendly launch, but that number is and will keep growing. In coming months they say they hope to reach 100 games, and who knows how many thereafter, but it should grow to be a fairly considerable library. - -Here are a few of my favourites so far, that are available right now: - -### Rise Of The Triads Dark War (1994) ### - -![](http://thelinuxrain.com/content/01-articles/70-nostalgic-gaming-on-linux-with-good-old-games/rott.png) - -If you crave some 90's style shoot-em-up action where you get to blow the hell out of, well, everything and everyone, Rise Of The Triads (ROTT) is one of the best choices and a favourite to many. - -If you know these kinds of shooters, you probably know what to expect. There is a storyline, but really it's about blowing everything up and/or riddling enemies full of bullet holes. As a member of an elite group of operatives you are sent to a remote island to stop a mad cult leader, where typically everything goes pear-shaped and you have to kill everything and successfully navigate levels to save the day and get out alive in the process. - -True to the arcade-style shooter of this vintage, weapons are all about being big, high-tech and fun. You might be in an elite operations group, but you ain't stuck with peashooters and standard rifles - no there's duel pistols all the way to heat seeking missiles and the Flamewall cannon and many more. It's all about genuine fun and doesn't take itself too seriously. - -*Verdict: A blast (literally)* - -### Realms Of The Haunting (1996) ### - -![](http://thelinuxrain.com/content/01-articles/70-nostalgic-gaming-on-linux-with-good-old-games/roth.png) - -This one is actually fairly new to me and isn't a game I remember from years back. Which is my loss really, as I can imagine this game must have seemed pretty incredible all the way back in 1996. - -Realms Of The Haunting is something of a first-person shooter/point-and-click adventure combination. The controls at first seem a bit strange because of this (keyboard to control movement and attack etc. Mouse to move the context indicator/cursor around the screen and interact with objects) but you soon get used to it. The storyline, although I have not experienced all of it yet myself, is apparently very good and certainly my impressions of it have been good. This is also one of those classic games that uses good old FMV (Full Motion Video) for cutscenes. - -![](http://thelinuxrain.com/content/01-articles/70-nostalgic-gaming-on-linux-with-good-old-games/roth1.png) - -Basically you play as a young man who receives a suitably vague letter from your recently deceased father about a strange deserted mansion and it's curious happenings inside. Naturally, said young man decides to visit the mansion and discovers his father's spirit being held captive by the forces of evil and then sets out to try free him. That sounds like a pretty standard storyline at first but the difference lays in the execution and how it progresses. - -From the moment the main character picks up a lantern and gazes around the dark, creepy surroundings of the mansion, it actually reminds me a bit of Amnesia: The Dark Descent. Sure, the gameplay and amount of actual combat means the comparison somewhat ends after that, but ROTH does also have it's fair share of exploration and puzzles. Despite a very dated looking graphics engine (it is based on the DOOM engine after all!) it strikes me how much attention to detail the game creators managed to pack into the environment, which further adds to the atmosphere and immersion despite the constant pixel party happening on screen. - -All in all, Realms Of The Haunting is a creepy but very intriguing old game that is very much worth checking out. And if you love games that feature old-school FMV, there is heaps on offer here too. - -*Verdict: Ahead of it's time?* - -### Sid Meier's Colonization (1994) ### - -![](http://thelinuxrain.com/content/01-articles/70-nostalgic-gaming-on-linux-with-good-old-games/colonization.jpg) - -Think Civilization, but with a colonial twist. Instead of building a nation from a mound of dirt in the middle of nowhere, Colonization tasks you with controlling either the forces of England, France, Spain or The Netherlands as you set about managing expansion across the Atlantic for your nation of choice. The aim of the game, as far as winning goes, is to achieve independence from your mother country and defeat the angry Royal Expeditionary Force that comes your way. - -If big chunky pixels, even in text, is something that hurts your eyes you may want to avoid this one but the simple old graphics belie the actual gameplay and depth available here. If you have experience with the more modern Sid Meier turn-based strategy games like the Civilization series, you may be surprised just how much familiar elements and gameplay there is in this old game. - -It may appear ancient and a little clunky, but like most of the classic Sid Meier games, you can sink hours upon hours into this game. Which considering it's price nowadays, no more than a piece of cake and a coffee, is fantastic value that is hard to beat. Do try it. - -*Verdict: Superb turn-based strategy, all the way from 1994* - -### Sword Of The Samurai (1989) ### - -![](http://thelinuxrain.com/content/01-articles/70-nostalgic-gaming-on-linux-with-good-old-games/sots.png) - -This one is a little more obscure and may surprise. For me, and this will sound a little cliché given the Japanese theme and setting, but there is something rather Zen about Sword Of The Samurai. A product in the year 1989, the graphics are obviously simple and have a very limited colour palette. Yet, I think even today the graphics work for this particular game and add to its charm and, again, the Zen. - -Describing SOTS is difficult though. It's sort of... a strategy, war, dating, stealth, melee, dueling, diplomacy, choose-your-own adventure Samurai sim. - -Seriously. - -Somehow this old game, which weighs in less than 20 megabytes, fits in an incredible amount of different gameplay (and surprisingly smart artificial intelligence) and approaches you can take to achieve your goal. The core goal is get a very important thing called Honor. In the world of feudal Japan, Honor is a big, big thing and you must get more Honor any way you can in order to achieve the goal of unifying Japan under your rule, as Shogun. - -While you can of course be the "good guy" and do everything you think is right to get Honor, the game is inherently deep and clever enough to allow you to achieve Honor even with, shall we say, more underhanded tactics. - -It's difficult to truly describe all the ways you can play this game but my advice is to simply do so - play it, let it wash over you and soak in the Japanese culture and atmosphere that the game exudes in a really classy way, without being over-the-top. And yes, the game can also be educational! You can't beat that. - -*Verdict: An under-appreciated masterpiece* - -### Get your game on ### - -So there we have it, there's some of my favourites that I've been (re)playing recently, on my Fedora 20 system no less. Some of these games may be older than Linux (the kernel) itself, but thanks to the likes of GOG.com and especially emulators like DOSBox, you can still enjoy the classic titles you remember from years gone by. - -What are some of your favourite classic games? Are you also playing them now in your favourite Linux distro? Let us know in the comments! - --------------------------------------------------------------------------------- - -via: http://thelinuxrain.com/articles/nostalgic-gaming-on-linux-with-good-old-games - -作者:Andrew Powell -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[1]:http://gog.com/ -[2]:http://www.dosbox.com/ \ No newline at end of file diff --git a/sources/talk/20140807 Five Awesome GOG.com Linux Games Everyone Should Play Once.md b/sources/talk/20140807 Five Awesome GOG.com Linux Games Everyone Should Play Once.md deleted file mode 100644 index 2bc6c0e247..0000000000 --- a/sources/talk/20140807 Five Awesome GOG.com Linux Games Everyone Should Play Once.md +++ /dev/null @@ -1,132 +0,0 @@ -Five Awesome GOG.com Linux Games Everyone Should Play Once -================================================================================ -![GOG AKA ILU TUX NAO](http://www.omgubuntu.co.uk/wp-content/uploads/2014/07/gog-com-tile.jpg) -GOG AKA ILU TUX NAO - -**Ardent Linux gamers will have seen last week as a good one, as rising game distribution service [GOG.com brought a batch of more than 50 classic PC and indie titles to the platform][1], many for the very first time.** - -Against the 775 DRM-free offerings offered to Windows users, not to mention the 600 strong Linux catalog on Steam, it might not sound like much. But the company says this is only the first wave and that another 50 games are set to land later in the year. - -Last week [we asked][2] our Facebook fans which five games being sold by GOG they consider ‘must have’ titles. - -After pruning the titles often found warming the shelves of the Humble Bundle (*e.g., Uplink: Hacker Elite, Darwinia, Don’t Starve and Anomaly Warzone Earth*), and throwing in a free title for good measure, we came up with the following list. - -It’s not comprehensive, it’s not definitive and it’s certainly not going to be the five you’d pick. But for those either too young to have experienced some of these games for the first time, or old enough to level up nostalgia, it’s a great jumping in point. - -Because we know it matters to some of you, we’ve listed the ‘port’ type for each entry, so you can avoid Wine or DOSBox where needed. - -Finally (though it really should go without saying) if you’re looking for full HD immersive 3D worlds with GPU melting graphics requirements, this is not the list for you. - -Now to hark back to rainy days spent cooped up inside, eyes firmly fixed on a CRT monitor… - -### FlatOut ### - -![](http://www.omgubuntu.co.uk/wp-content/uploads/2014/08/flatout.jpeg) - -**Year**: 2005. **Genre**: Racing. **Port**: Wine. **Price**: $5.99 (inc. extras). - -Unbuckle up and prepare for one bad-ass and throughly bumpy ride. - -Trying to condense why FlatOut is a classic demolition rally game into just a few short sentences is traumatic. Almost as traumatic as being a driver in it must be. - -Its premise — carnage, destruction, more carnage — reads fairly standard these days. Virtually every racing game (at least those worth their tread) implements an element of off-road mayhem. But FlatOut was one of the first, and even today remains one of the best. - -With 36 course littered with more than 3000 items to crash and smash, plus 16 upgradeable vehicles, each made up of 40 “deformable pieces” for ultimate on-screen obliteration, FlatOut is flat out one of the best raucous racing games available on Linux. - -*Also check out Flat Out 2, released in 2011 and costing $9.99.* - -- [Buy “FlatOut” on GOG][3] - -### Duke Nukem 3D: Atomic Edition ### - -![](http://www.omgubuntu.co.uk/wp-content/uploads/2014/08/duke-3d.jpeg) - -**Year**: 1995. **Genre**: First-Person Shooter. **Port**: DOSBox. **Price**: $5.99 (inc. extras). - -Politically incorrect, full of female objectification, and featuring more cheesy one-liners than the script of a straight-to-VHS Jean-Claude Van Damme action film. Yep, it’s Duke Nukem. - -But c’mon; no list of retro PC classics would be complete without a least one Duke Nukem entry, right? They are bona fide classics. Along with Doom and Quake, it kickstarted the gory corridor crawling shooter genre. - -Most of its strengths are in the pastiche; it is camp, cheesy and kaleidoscopically brash, and takes itself about as seriously as a Sega MegaCD video cutscene from Night Trap. - -The environments are varied and rich. The gameplay mechanics easy to get to grips with. And while the less than subtle humour laced throughout may rile the easily offended, those of a certain age won’t be able to resist smirking at the pop-culture satire. - -- [Buy “Duke Nukem: Atomic Edition” on GOG][4] - -### The Last Federation ### - -Youtobe 视频地址: -https://www.youtube.com/embed/5RKXWpyf1i4?feature=oembed - -**Year**: 2014. **Genre**: Strategy. **Port**: Native. Price: $19.99. - -The Last Federation is the most expensive title on this list and also the most modern, having debuted this year. - -It’s a turn-based tactical combat set in space that burdens you with the task of ‘forging a lasting federation of planets and usher in an era of peace and prosperity to the solar system.’ - -But to forge a lasting truce you must indulge your inner machiavellian monsters. - -*“Remember, when helping civilizations evolve, sometimes they evolve faster when a large multi-headed monster is glaring menacingly at them,” reads the game’s synopsis.* - -Pricey, but one of the standout strategy games of 2014. - -- [Buy “The Last Federation” on GOG][5] - -### StarGunner ### - -![](http://www.omgubuntu.co.uk/wp-content/uploads/2014/08/stargunner.jpeg) - -**Year**: 1996. **Genre**: Arcade. **Port**: DOSBox. Price: Free. - -StarGunner is one of two Linux games available for free on GOG. It’s a space-based side scrolling shoot ‘em up, similar to thousands of mid-nineties arcade games now resting in a land fill somewhere. - -That’s not to say it’s not any good; it’s great fun but just a little familiar. - -Gameplay is fast, battlefields switch between space, ground and water often enough to maintain interest, and with more than 75 different enemy crafts (plus over 30 super adaptive bosses) things never get visually tired, either. - -Look out for weapons and other power-ups littered through levels. - -- [Download “StarGunner” for free on GOG][6] - -### Blocks That Matter ### - -![](http://www.omgubuntu.co.uk/wp-content/uploads/2014/08/blocks-that-matter.jpeg) - -**Year**: 2011. **Price**: $2.99. **Genre**: Platformer. **Port**: Wine, 32-bit only. - -Take some blocks, drop them into an isometrical world, add bit of jumping and a whole lot of puzzle solving. Finally, coat it all in a layer of cuteness. Aside from an needlessly drawn out introduction, you should end up with **Blocks That Matter**. And boy do these blocks matter. - -Playing as a robot called Tetrobot, your sole aim is to waddle about each level drilling blocks of various materials (sand, ice, etc.) one by one. Blocks can be collected and inserted into the game to help you complete levels, but depending on the material this can often be a hindrance rather than a help. - -An innovative 2D platform-puzzler, it offers up 40 levels in standard Adventure Mode with another 20 waiting to be unlocked. It’s cute, clever and cheap. - -- [Buy “Blocks that Matter” on GOG][7] - -### Honourable Mentions ### - -####DarkLands#### - -**Year**: 1992. **Genre**: RPG. **Port**: DOSBox. **Price**: $5.99 (inc. extras). - -#### Sid Meier’s Covert Action #### - -**Year**: 1990. **Genre**: Action/Strategy. **Port**: DOSBox. **Price**: $5.99 (inc. extras). - --------------------------------------------------------------------------------- - -via: http://www.omgubuntu.co.uk/2014/08/five-best-linux-gog-com-games-available-now - -作者:[Joey-Elijah Sneddon][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:https://plus.google.com/117485690627814051450/?rel=author -[1]:http://www.omgubuntu.co.uk/2014/07/50-classic-pc-games-now-available-linux-gog -[2]:https://www.facebook.com/omgubuntu/posts/830930706919468 -[3]:http://www.gog.com/game/flatout -[4]:http://www.gog.com/game/duke_nukem_3d_atomic_edition -[5]:http://www.gog.com/game/last_federation_the -[6]:http://www.gog.com/game/stargunner -[7]:http://www.gog.com/game/blocks_that_matter \ No newline at end of file diff --git a/sources/talk/20140818 Where And How To Code--Choosing The Best Free Code Editor.md b/sources/talk/20140818 Where And How To Code--Choosing The Best Free Code Editor.md deleted file mode 100644 index dd1461328e..0000000000 --- a/sources/talk/20140818 Where And How To Code--Choosing The Best Free Code Editor.md +++ /dev/null @@ -1,105 +0,0 @@ -zpl1025 -Where And How To Code: Choosing The Best Free Code Editor -================================================================================ -A close look at Cloud9, Koding and Nitrous.IO. - -![](http://a2.files.readwrite.com/image/upload/c_fill,h_900,q_70,w_1600/MTIzMDQ5NjYzODM4NDU1MzA4.jpg) - -**Ready to start your first coding project? Great! Just configure** Terminal or Command Prompt, learn to use it and then install all the languages, add-on libraries and APIs you’ll need. When you're finally through with all that, you can get started with installing [Visual Studio][1] so you can preview your work. - -At least that's how you used to have to do it. - -No wonder beginning coders are increasingly turning to online integrated development environments (IDEs). An IDE is a code editor that comes ready to work with languages and all their dependencies, saving you the hassle of installing them on your computer. - -I wanted to learn more about what constitutes the typical IDE, so I took a look at the free tier for three of the most popular integrated development environments out there: [Cloud9][2], [Koding][3], and [Nitrous.IO][4]. In the process, I learned a lot about the cases in which programmers would and would not want to use IDEs. - -### Why Use An IDE? ### - -If a text editor is like Microsoft Word, think of an IDE as Google Drive. You get similar functionality, but it's accessible from any computer and ready to share. As the Internet becomes an increasingly influential part of project workflow, IDEs make life easier. - -I used Nitrous.IO for my last ReadWrite tutorial, the Python app in [Create Your Own Obnoxiously Simple Messaging App Just Like Yo][5]. When you use an IDE, you select the language you want to work in so you can test and preview how it looks on the IDE’s Virtual Machine (VM) designed to run programs written specifically in that language. - -If you read the tutorial, you'll see there are only two API libraries that my app depended on—messaging service Twilio and Python microframework Flask. That would have been easy to build using a text editor and Terminal on my computer, but I chose an IDE for yet another convenience: when everyone is using the same developer environment, it’s easier to follow along with a tutorial. - -### What An IDE Is Not ### - -Still, an IDE is not a long term hosting solution. - -When you’re working on an IDE, you’re able to build, test and preview your app in the cloud. You’re even able to share the final draft via link. - -But you can’t use an IDE to store your project permanently. You wouldn't ditch your blog in favor of hosting your posts as Google Drive documents. Like Google Drive, IDEs allow you to link and share content, but neither are equipped to replace real hosting. - -What's more, IDEs aren't designed for wide-spread sharing. Despite the increased functionality IDEs add to the preview capability of most text editors, stick with showing off your app preview to friends and coworkers, not with, say, the front page of Hacker News. In that case, your IDE would probably shut you down for excessive traffic. - -Think of it this way: an IDE is a place to build and test your app; a host is a place for it to live. So once you’ve finalized your app, you’ll want to deploy it on a cloud-based service that lets you host apps long term, preferably one with a free hosting option like [Heroku][6]. - -### Choosing An IDE ### - -![](http://a2.files.readwrite.com/image/upload/c_fit,w_630/MTIzNjEzMTg5MjA2NDc2MzAy.png) - -As IDEs become more popular, more are popping up all the time. In my opinion, there’s no perfect IDE. However, some IDEs are better for certain work process priorities than others. - -I took a look at the free tier for three of the most popular integrated development environments out there: Cloud9, Koding, and Nitrous.IO. Each has its benefits, depending on what you're working on. Here's what I found. - -### Cloud9: Ready To Collaborate ### - -When I signed up for Cloud9, one of the first things it prompted me to do was integrate my GitHub and BitBucket accounts. Instantly, all my GitHub projects, solo and collaborative, were ready to clone and work on in Cloud9’s development tool. Other IDEs have nowhere near this level of GitHub integration. - -Out of the three IDEs I looked at, Cloud9 seemed most intent on ensuring an environment where I could work seamlessly with co-coders. Here, it’s not just a chat function in the corner. In fact, said CEO Ruben Daniels, Cloud9 collaborators can see each others coding in real time, just like co-authors are able to on Google Drive. - -“Most services’ collaborative features only work on a single file,” said Daniels. “Ours work on multiples throughout the project. Collaboration is fully integrated within the IDE.” - -### Koding: Help When You Need It ### - -IDEs give you the tools you need to build and test applications in the gamut of open source languages. For a beginner, that can be a little bit intimidating. For example, if I’m working on a project with both Python and Ruby components, which VM do I use for testing? - -The answer is both, though on a free account, you can only turn on one VM for testing at a time. I was able to find that out right on my Koding dashboard, which doubles as a place for users to give and get advice on their Koding projects. Of the three, it’s the most transparent when it comes to where you can ask for assistance and hear back in minutes. - -“We have an active community built into the application,” said Nitin Gupta, Chief Business Officer at Koding. “We wanted to create an environment that is extremely attractive to people who need help and who want to help.” - -### Nitrous.IO: An IDE Wherever You Want ### - -The ultimate advantage of using an IDE over your own desktop environment is that it’s self-contained. You don’t have to install anything to use it. On the other hand, the ultimate advantage of using your own desktop environment is that you can work locally, even without Internet. - -Nitrous.IO gives you the best of both worlds. You can use the IDE on the Web, or you can download it to your own computer, said cofounder AJ Solimine. The advantage is that you can merge the integrations of Nitrous with the familiarity of your preferred text editor. - -“You can access Nitrous.IO from any modern web browser via our online Web IDE, but we also have handy desktop applications for Windows and Mac that let you edit with your favorite editor,” he said. - -### The Bottom Line ### - -The most surprising thing I learned from a week of [using][7] three different IDEs? How similar they are. [When it comes to the basics of coding][8], they’re all equally helpful. - -Cloud9, Koding, [and Nitrous.IO all support][9] every major open source language, from Ruby to Python to PHP to HTML5. You can choose from any of those VMs. - -Both Cloud9 and Nitrous.IO have built-in one-click GitHub integration. For Koding there are a [couple more steps][10], but it can be done. - -Each integrated easily with the APIs I needed. Each let me install my preferred package installers, too (and Koding made me do it as a superuser). They all have a built in Terminal for easily testing and deploying projects. All three allow you to easily preview your project. And of course, they all hosted my project in the cloud so I could work on it anywhere. - -On the downside, they all had the same negatives, which is reasonable when you consider they're free. You can only run one VM at a time to test a program written in a particular language. When you’re not using your VM for a while, the IDE preserves bandwidth by putting it into hibernation and you have to wait for it to reload next time you use it (and Cloud9 was especially laborious). None of them make a good permanent host for your finished projects. - -So to answer those who ask me if there’s a perfect free IDE out there, probably not. But depending on your priorities, there might be one that’s perfect for your project. - -Lead image courtesy of [Shutterstock][11] - --------------------------------------------------------------------------------- - -via: http://readwrite.com/2014/08/14/cloud9-koding-nitrousio-integrated-development-environment-ide-coding - -作者:[Lauren Orsini][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://readwrite.com/author/lauren-orsini -[1]:http://www.visualstudio.com/ -[2]:http://c9.io/ -[3]:https://koding.com/ -[4]:http://nitrous.io/ -[5]:http://readwrite.com/2014/07/11/one-click-messaging-app -[6]:http://heroku.com/ -[7]:http://help.nitrous.io/ide-general/ -[8]:https://www.nitrous.io/desktop -[9]:https://www.nitrous.io/desktop -[10]:https://koding.com/Activity/steps-clone-projects-github-koding-1-create-account-github-2-open-your-terminal-3 -[11]:http://www.shutterstock.com/ diff --git a/sources/talk/20140818 Why Your Company Needs To Write More Open Source Software.md b/sources/talk/20140818 Why Your Company Needs To Write More Open Source Software.md deleted file mode 100644 index 04aa33c138..0000000000 --- a/sources/talk/20140818 Why Your Company Needs To Write More Open Source Software.md +++ /dev/null @@ -1,68 +0,0 @@ -Why Your Company Needs To Write More Open Source Software - ReadWrite -================================================================================ -> Real innovation doesn't happen behind closed doors. - -![](http://a5.files.readwrite.com/image/upload/c_fill,h_900,q_70,w_1600/MTE5NDg0MDYxMTkxMzQxNTgz.jpg) - -**The Wall Street Journal [thinks][1] it's news that Zulily is developing** "more software in-house." It's not. At all. As [Eric Raymond wrote][2] years ago, 95% of the world's software is written for use, not for sale. The reasons are many, but one stands out: as Zulily CIO Luke Friang declares, it's "nearly impossible for a [off the shelf] solution to keep up with our pace." - -True now, just as it was true 20 years ago. - -But one thing is different, and it's something the WSJ completely missed. Historically software developed in-house was zealously kept proprietary because, the reasoning went, it was the source of a firm's competitive advantage. Today, however, companies increasingly realize the opposite: there is far more to be gained by open sourcing in-house software than keeping it closed. - -Which is why your company needs to contribute more open-source code. Much more. - -We've gone through an anomalous time these past 20 years. While most software continued to be written for internal use, most of the attention has been focused on vendors like SAP and Microsoft that build solutions that apply to a wide range of companies. - -That's the theory, anyway. - -In practice, buyers spent a small fortune on license fees, then a 5X multiple on top of that to make the software fit their requirements. For example, a company may spend $100,000 on an ERP system, but they're going to spend another $500,000 making it work. - -One of the reasons open source took off, even in applications, was that companies could get a less functional product for free (or a relatively inexpensive fee) and then spend their implementation dollars tuning it to their needs. Either way, customization was necessary, but the open source approach was less costly and arguably more likely to result in a more tailored result. - -Meanwhile, technology vendors doubled-down on "sameness," as Redmonk analyst [Stephen O'Grady describes][3]: - -> The mainstream technology industry has, in recent years, eschewed specialization. Virtual appliances, each running a version of the operating system customized for an application or purpose, have entirely failed to dent the sales of general purpose alternatives such as RHEL or Windows. For better than twenty years, the answer to any application data persistence requirement has meant one thing: a relational database. If you were talking about enterprise application development, you were talking about Java. And so on. - -Along the way, however, companies discovered that vendors weren't really meeting their needs, even for well-understood product categories like Content Management Systems. They needed different, not same. - -So the customers went rogue. They became vendors. Sort of. - -As is often the case, [O'Grady nails][4] this point. Writing in 2010, O'Grady uncovers an interesting trend: "Software vendors are facing a powerful new market competitor: their customers." - -Think about the most visible technologies today. Most are open source, and nearly all of them were originally written for some company's internal use, or some developer's hobby. Linux, Git, Hadoop, Cassandra, MongoDB, Android, etc. None of these technologies were originally written to be sold as products. - -Instead, they were developed by companies—usually Web companies—building software to "[scratch their own itches][5]," to use the open source phrase. And unlike previous generations of in-house software developed at banks, hospitals and other organizations, they open sourced the code. - -While [some companies eschew developing custom software][6] because they don't want to maintain it, open source (somewhat) mitigates this by letting a community grow up to extend and maintain a project, thereby amortizing the costs of development for the code originators. Yahoo! started Hadoop, but its biggest contributors today are Cloudera and Hortonworks. Facebook kickstarted Cassandra, but DataStax primarily maintains it today. And so on. - -Today real software innovation doesn't happen behind closed doors. Or, if it does, it doesn't stay there. It's open source, and it's upending decades of established software orthodoxy. - -Not that it's for the faint of heart. - -The best open-source projects [innovate very fast][7]. Which is not the same as saying anyone will care about your open-source code. There are [significant pros and cons to open sourcing your code][8]. But one massive "pro" is that the best developers want to work on open code: if you need to hire quality developers, you need to give them an open source outlet for their work. (Just [ask Netflix][9].) - -But that's no excuse to sit on the sidelines. It's time to get involved, and not for the good of some ill-defined "community." No, the primary beneficiary of open-source software development is you and your company. Better get started. - -Lead image courtesy of Shutterstock. - --------------------------------------------------------------------------------- - -via: http://readwrite.com/2014/08/16/open-source-software-business-zulily-erp-wall-street-journal - -作者:[Matt Asay][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://readwrite.com/author/matt-asay -[1]:http://blogs.wsj.com/cio/2014/08/08/zulily-calls-in-house-software-a-differentiator-for-competitive-advantage/ -[2]:http://oreilly.com/catalog/cathbazpaper/chapter/ch05.html -[3]:http://redmonk.com/sogrady/2010/01/12/roll-your-own/#ixzz3ATBuZsef -[4]:http://redmonk.com/sogrady/2010/01/12/roll-your-own/ -[5]:http://en.wikipedia.org/wiki/The_Cathedral_and_the_Bazaar -[6]:http://www.abajournal.com/magazine/article/roll_your_own_software_hidden_dangers_on_the_road_less_traveled/ -[7]:http://readwrite.com/2013/12/12/open-source-innovation -[8]:http://readwrite.com/2014/07/07/open-source-software-pros-cons -[9]:http://techblog.netflix.com/2012/07/open-source-at-netflix-by-ruslan.html \ No newline at end of file diff --git a/sources/talk/20140826 Linus Torvalds Promotes Linux for Desktops, Embedded Computing.md b/sources/talk/20140826 Linus Torvalds Promotes Linux for Desktops, Embedded Computing.md deleted file mode 100644 index 0d6322820b..0000000000 --- a/sources/talk/20140826 Linus Torvalds Promotes Linux for Desktops, Embedded Computing.md +++ /dev/null @@ -1,31 +0,0 @@ -Linus Torvalds Promotes Linux for Desktops, Embedded Computing -================================================================================ -> Linux kernel developer and open source leader Linus Torvalds spoke recently about the future of desktop Linux and Linux for embedded devices. - -![](http://thevarguy.com/site-files/thevarguy.com/files/imagecache/medium_img/uploads/2014/08/linus-torvalds-1.jpg) - -What's the future of Linux for desktop computers and embedded devices? That's a question up for debate, but Linux founder and open source superstar Linus Torvalds provided some intriguing viewpoints in a discussion at the [Linux Foundation's][1] recent LinuxCon event. - -As the guy who wrote the first Linux kernel code and shared it publicly over the Internet back in 1991, Torvalds is without doubt among the most famous developers of open source software—or any software, really—alive today. And while Torvalds is only one individual among many thousands of people and organizations guiding the development of Linux, his opinions tend to be influential with the open source community, and his role as a lead kernel developer places him in a powerful position for deciding which features and code make it into the operating system. - -So it's worth paying attention when Torvalds says, "I still want the desktop," as he [did last week][2] at LinuxCon. It's a sign that he still sees a future for Linux as an operating system for powering personal PCs, even though desktop Linux market share has remained minuscule and relatively flat for more than a decade, and most of the commercial activity around Linux these days involves servers or Android-powered mobile hardware. - -But, Torvalds added, ensuring a strong future for desktop Linux means solving an "infrastructure problem" that stems, he seems to believe, from the broader open source software ecosystem and the hardware world. It's not the core Linux code itself that's at issue, and making the channel friendly for desktop Linux is a feat Torvalds and his fellow kernel developers probably have little power to achieve on their own. That's up to app developers, hardware manufacturers and other parties who have the power to deliver computing platforms based on Linux that people will readily use. - -On the other hand, Torvalds also mentioned a hope that kernel developers might streamline the Linux code for embedded devices—a task that might be at odds in some ways with making the kernel more desktop-friendly. But that's not necessarily the case, and at any rate, given that Linux is designed to be so modular, there's no reason a single kernel code base can't meet the needs of desktop users and embedded developers equally well, depending on which chunks they choose to use. - -As a longtime desktop Linux user who would also like to see more Linux-powered embedded devices, I'm hoping Torvalds's aspirations in both regards will be realized, and that I will one day be able to do everything I need using only Linux, whether it's on a desktop computer, a mobile phone, the car or anywhere else. - --------------------------------------------------------------------------------- - -via: http://thevarguy.com/open-source-application-software-companies/082514/linus-torvalds-promotes-linux-desktops-and-embedded-compu - -作者:[Christopher Tozzi][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://thevarguy.com/author/christopher-tozzi -[1]:http://linuxfoundation.org/ -[2]:http://www.eweek.com/enterprise-apps/linux-founder-linus-torvalds-still-wants-the-desktop.html \ No newline at end of file diff --git a/sources/talk/20140828 Interesting facts about Linux.md b/sources/talk/20140828 Interesting facts about Linux.md deleted file mode 100644 index d257f4f2fe..0000000000 --- a/sources/talk/20140828 Interesting facts about Linux.md +++ /dev/null @@ -1,85 +0,0 @@ -Interesting facts about Linux -================================================================================ -Today, August, 25th, is the 23rd birthday of Linux. The modest [Usenet post][1] made by a 21 year old student at the University of Helsinki on August 25th, 1991, marks the birth of the venerable Linux as we know it today. - -Fast forward 23 years, and now Linux is everywhere, not only installed on end user desktops, [smartphones][2] and embedded systems, but also fulfilling the needs of [leading enterprises][3] and powering mission-critical systems such as [US Navy's nuclear submarines][4] and [FAA's air traffic control][5]. Entering the era of ubiquitous cloud computing, Linux is continuing [its dominance][6] as by far the most popular platform for the cloud. - -Celebrating the 23rd birthday of Linux today, let me show you **some interesting facts and history you may not know about Linux**. If there is anything to add, feel free to share it in the comments. In this article, I will use the terms "Linux", "kernel" or "Linux kernel" interchangeably to mean the same thing. - -1. There is a never-ending debate on whether or not Linux is an operating system. Technically, the term "Linux" refers to the kernel, a core component of an operating system. Folks who argue that Linux is not an operating system are operating system purists who think that the kernel alone does not make the whole operating system, or free software ideologists who believe that the largest free operating system should be named "[GNU/Linux][7]" to give credit where credit is due (i.e., [GNU project][8]). On the other hand, some developers and programmers have a view that Linux qualifies as an operating system in a sense that it implements the [POSIX standard][9]. - -2. According to openhub.net, the majority (95%) of Linux is written in C language. The second popular language for Linux is assembly language (2.8%). The dominance of C lanaguage over C++ is no surprise given Linus's stance on C++. Here is the programming language breakdown for Linux. - -![](https://farm4.staticflickr.com/3845/15025332121_055cfe3a2c_z.jpg) - -3. Linux has been built by a total of [13,036 contributors][10] worldwide. The most prolific contributor is, of course, Linus Torvalds himself, who has committed code more than 20,000 times over the course of the lifetime of Linux. The following figures show the all-time top-10 contributors of Linux in terms of commit counts. - -![](https://farm4.staticflickr.com/3837/14841786838_7a50625f9d_b.jpg) - -4. The total source lines of code (SLOC) of Linux is over 17 million. The estimated cost for the entire code base is 5,526 person-years, or over 300M USD according to [basic COCOMO model][11]. - -5. Enterprises have not been simply consumers of Linux. Their employees have been [actively participated][12] in the development of Linux. The figure below shows the top-10 corporate sponsors of Linux kernel development, in terms of total commit counts from their employees, as of year 2013. They include commercial Linux distributors (Red Hat, SUSE), chip/embedded system makers (Intel, Texas Instruments, Wolfson), non-profits (Linaro), and other IT power houses (IBM, Samsung, Google). - -![](https://farm6.staticflickr.com/5573/14841856427_a5a1828245_o.png) - -6. The official mascot of Linux is "Tux", a friendly penguin character. The idea of using a cuddly penguin as a mascot/logo was in fact [first conceived and asserted][13] by Linus himself. Why penguin? Personally Linus is fond of penguins, despite the fact that he once was bitten by a ferocious penguin, causing him infected with a disease. - -7. A Linux "distribution" contains the Linux kernel, supporting GNU utilities/libraries, and other third-party applications. According to [distrowatch.com][14], there are a total of 286 actively maintained Linux distrutions. The oldest among them is [Slackware][15] whose very first release 1.0 became available in 1993. - -8. Kernel.org, which is the main repository of Linux source code, was [compromised][16] by an unknown attacker in August, 2011, who managed to tamper with several kernel.org's servers. In an effort to tighten up access policies of the Linux kernel, Linux foundation recently [turned on][17] two-factor authentication at the official Git repositories hosting the Linux kernel. - -9. The dominance of Linux on top 500 supercomputers [continues to rise][18]. As of June 2014, 97% of the world-fastest computers are powered by Linux. - -10. Spacewatch, a research group of Lunar and Planetary Laboratory at the University of Arizona, named several asteroids ([9793 Torvalds][19], [9882 Stallman][20], [9885 Linux][21] and [9965 GNU][22]) after GNU/Linux and their creators, in recognition of the free operating system which was instrumental in their asteroid survey activities. - -11. In the modern history of Linux kernel development, there was a big jump in kernel version: from 2.6 to 3.0. The [renumbering to version 3][23] actually did not signify any major restructuring in kernel code, but was simply to celebrate the 20 year milestone of the Linux kernel. - -12. In 2000, Steve Jobs at Apple Inc. [tried to hire][24] Linus Torvalds to have him drop Linux development and instead work on "Unix for the biggest user base," which was OS X back then. Linus declined the offer. - -13. The [reboot()][25] system call in the Linux kernel requires two magic numbers. The second magic number comes from the [birth dates][26] of Linus Torvalds and his three daughters. - -14. With so many fans of Linux around the world, there are [criticisms][27] on current Linux distributions (mainly desktops), such as limited hardware support, lack of standardization, instability due to short upgrade/release cycles, etc. During the [Linux kernel panel][28] at LinuxCon 2014, Linus was quoted as saying "I still want the desktop" when asked where he thinks Linux should go next. - -If you know any interesting facts about Linux, feel free to share them in the comments. - -Happy birthday, Linux! - --------------------------------------------------------------------------------- - -via: http://xmodulo.com/2014/08/interesting-facts-linux.html - -作者:[Dan Nanni][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://xmodulo.com/author/nanni -[1]:https://groups.google.com/forum/message/raw?msg=comp.os.minix/dlNtH7RRrGA/SwRavCzVE7gJ -[2]:http://developer.android.com/about/index.html -[3]:http://fortune.com/2013/05/06/how-linux-conquered-the-fortune-500/ -[4]:http://www.linuxjournal.com/article/7789 -[5]:http://fcw.com/Articles/2006/05/01/FAA-manages-air-traffic-with-Linux.aspx -[6]:http://thecloudmarket.com/stats -[7]:http://www.gnu.org/gnu/why-gnu-linux.html -[8]:http://www.gnu.org/gnu/gnu-history.html -[9]:http://en.wikipedia.org/wiki/POSIX -[10]:https://www.openhub.net/p/linux/contributors/summary -[11]:https://www.openhub.net/p/linux/estimated_cost -[12]:http://www.linuxfoundation.org/publications/linux-foundation/who-writes-linux-2013 -[13]:http://www.sjbaker.org/wiki/index.php?title=The_History_of_Tux_the_Linux_Penguin -[14]:http://distrowatch.com/search.php?ostype=All&category=All&origin=All&basedon=All¬basedon=None&desktop=All&architecture=All&status=Active -[15]:http://www.slackware.com/info/ -[16]:http://pastebin.com/BKcmMd47 -[17]:http://www.linux.com/news/featured-blogs/203-konstantin-ryabitsev/784544-linux-kernel-git-repositories-add-2-factor-authentication -[18]:http://www.top500.org/statistics/details/osfam/1 -[19]:http://ssd.jpl.nasa.gov/sbdb.cgi?sstr=9793 -[20]:http://ssd.jpl.nasa.gov/sbdb.cgi?sstr=9882 -[21]:http://ssd.jpl.nasa.gov/sbdb.cgi?sstr=9885 -[22]:http://ssd.jpl.nasa.gov/sbdb.cgi?sstr=9965 -[23]:https://lkml.org/lkml/2011/5/29/204 -[24]:http://www.wired.com/2012/03/mr-linux/2/ -[25]:http://lxr.free-electrons.com/source/kernel/reboot.c#L199 -[26]:http://www.nndb.com/people/444/000022378/ -[27]:http://linuxfonts.narod.ru/why.linux.is.not.ready.for.the.desktop.current.html -[28]:https://www.youtube.com/watch?v=8myENKt8bD0 \ No newline at end of file diff --git a/sources/talk/20140829 Linux Doesn't Need to Own the Desktop.md b/sources/talk/20140829 Linux Doesn't Need to Own the Desktop.md deleted file mode 100644 index ba28555b79..0000000000 --- a/sources/talk/20140829 Linux Doesn't Need to Own the Desktop.md +++ /dev/null @@ -1,32 +0,0 @@ -Linux Doesn't Need to Own the Desktop -================================================================================ -Linus Torvalds issued Linux 3.17 rc-2 on Monday of this week, and [he deviated from his normal schedule][1] in doing so, because August 25 happens to mark the 23rd anniversary of the original Linux announcement. "Hello everybody out there using minix," Torvalds wrote. - -Meanwhile, PCMag.com has proclaimed that [Linux has run out of time][2]. But isn't it true that the endless discussions of whether Linux is a success on the desktop are moot? Linux is in supercomputers and cars, it formed the basis for Android and is the most popular platform to run emerging cloud platforms like OpenStack on--just to name a few of its successes. The desktop is not the only battleground for Linux. - -Jon Buys took note of specialization and the Linux desktop [in a recent post][3], where he wrote: - -> "Recently, IT World asked “[Does it still make sense for Linus to want the desktop for Linux?][4]”, and Matt Asay from Tech Repubic asked “[Can we please stop talking about the Linux desktop?][5]”. Both publishers are critical of the claim that there is still room for Linux on Personal Computers, and point to Android as a Linux success story...What both articles miss though is that the flexibility of Linux, and the permissiveness of its open source license may be the things that save Linux on the desktop." - -That may be true, but Linux is so much to so many people beyond the desktop. Linux's opportunity for great market share on the desktop has come and gone. - -The simple fact is that Linux has changed the world and been a tremendous success outside the desktop, and there is nothing wrong with that. Android is hardly the only Linux-based platform that has made a big mark. Linux is huge on servers, in embedded technology, and is a constant prompt for innovation on emerging platforms. Ubuntu is the most popular platform for building OpenStack deployments on. Supercomputers all over the world run Linux, and Chrome OS is based on it. - -So Linux is making a huge difference globally, and it is time for detractors to stop focusing exclusively on its status on the desktop. - --------------------------------------------------------------------------------- - -via: http://ostatic.com/blog/linux-doesnt-need-to-own-the-desktop - -作者:[Sam Dean][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://ostatic.com/member/samdean -[1]:http://www.theregister.co.uk/2014/08/26/linux_turns_23_and_linus_torvalds_celebrates_as_only_he_can/ -[2]:http://www.pcmag.com/article2/0,2817,2465125,00.asp -[3]:http://ostatic.com/blog/specialization-and-the-linux-desktop -[4]:http://www.itworld.com/open-source/432816/does-it-still-make-sense-linus-want-desktop-linux -[5]:http://www.techrepublic.com/article/can-we-please-stop-talking-about-the-linux-desktop/ \ No newline at end of file diff --git a/sources/talk/20140902 Happy Birthday Email.md b/sources/talk/20140902 Happy Birthday Email.md deleted file mode 100644 index b5db299b33..0000000000 --- a/sources/talk/20140902 Happy Birthday Email.md +++ /dev/null @@ -1,23 +0,0 @@ -Happy Birthday Email -================================================================================ -**An Indian American had the brain to invent electronic mail without which we cannot figure out a single day in this era.** - -![](http://1-ps.googleusercontent.com/h/www.efytimes.com/admin/useradmin/photo/150x150xDbOx104130AM8312014.jpg.pagespeed.ic.QJJxt_P8uE.jpg) - -30 August, email turned 32. Now we wonder how this fast and quick method of message transfer came into existence. The credit goes to an Indian American, Shiva Ayyadurai. Shiva developed a full-scale software of the interoffice mail system and it was named email. - -He was officially acknowledged as the inventor of the computer programme on 30 August, 1982, by the US government. Born to Tamil family in Bombay, Shiva was just 14 years old when he invented the email system. He was studying at Livingston High School in New Jersey and he began working on this system for the University of Medicine and Dentistry of New Jersey. A copyright was given to the email system as no other way was known to protect software inventions at that time. - -Ayyadurai got the idea of the email system from the way mail was transported internally in offices. He tried to make a copy of ‘Pneumatic Tube System’ which was mostly used to send interoffice mails across offices. This system used a physical network of tubes which used to transport typed mails to secretaries. Each secretary used to have inbox, outbox, drafts, carbon copy paper, folders, address book, paper clips or attachments etc. All these were used to create and process incoming and outgoing mails. - -Shiva also took a note of the common templates like “To”, “From”, “Subject”, “Date”, “Body”, “CC”, “BCC” and so on. All these templates were incorporated in the version of the electronic mail too. Mail was written FORTRAN programming language and Shiva discovered an electronic version of the same. Shiva received many accolades for his extraordinary work and also won a Westinghouse Science Talent Search Award for high school seniors in 1981. Now Smithsonian Institution National Museum of American History (SINMAH) has the official US copyright for “Email”. But there is a controversy that not Ayyadurai but some other people have invented email. - --------------------------------------------------------------------------------- - -via: http://www.efytimes.com/e1/fullnews.asp?edid=147170 - -作者:Sanchari Banerjee -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 \ No newline at end of file diff --git a/sources/talk/20140904 Making MySQL Better at GitHub.md b/sources/talk/20140904 Making MySQL Better at GitHub.md deleted file mode 100644 index 1faf5d6e27..0000000000 --- a/sources/talk/20140904 Making MySQL Better at GitHub.md +++ /dev/null @@ -1,92 +0,0 @@ -Making MySQL Better at GitHub -================================================================================ -> At GitHub we say, "it's not fully shipped until it's fast." We've talked before about some of the ways we keep our [frontend experience speedy][1], but that's only part of the story. Our MySQL database infrastructure dramatically affects the performance of GitHub.com. Here's a look at how our infrastructure team seamlessly conducted a major MySQL improvement last August and made GitHub even faster. - -### The mission ### - -Last year we moved the bulk of GitHub.com's infrastructure into a new datacenter with world-class hardware and networking. Since MySQL forms the foundation of our backend systems, we expected database performance to benefit tremendously from an improved setup. But creating a brand-new cluster with brand-new hardware in a new datacenter is no small task, so we had to plan and test carefully to ensure a smooth transition. - -### Preparation ### - -A major infrastructure change like this requires measurement and metrics gathering every step of the way. After installing base operating systems on our new machines, it was time to test out our new setup with various configurations. To get a realistic test workload, we used tcpdump to extract SELECT queries from the old cluster that was serving production and replayed them onto the new cluster. - -MySQL tuning is very workload specific, and well-known configuration settings like innodb_buffer_pool_size often make the most difference in MySQL's performance. But on a major change like this, we wanted to make sure we covered everything, so we took a look at settings like innodb_thread_concurrency, innodb_io_capacity, and innodb_buffer_pool_instances, among others. - -We were careful to only make one test configuration change at a time, and to run tests for at least 12 hours. We looked for query response time changes, stalls in queries per second, and signs of reduced concurrency. We observed the output of SHOW ENGINE INNODB STATUS, particularly the SEMAPHORES section, which provides information on work load contention. - -Once we were relatively comfortable with configuration settings, we started migrating one of our largest tables onto an isolated cluster. This served as an early test of the process, gave us more space in the buffer pools of our core cluster and provided greater flexibility for failover and storage. This initial migration introduced an interesting application challenge, as we had to make sure we could maintain multiple connections and direct queries to the correct cluster. - -In addition to all our raw hardware improvements, we also made process and topology improvements: we added delayed replicas, faster and more frequent backups, and more read replica capacity. These were all built out and ready for go-live day. - -### Making a list; checking it twice ### - -With millions of people using GitHub.com on a daily basis, we did not want to take any chances with the actual switchover. We came up with a thorough [checklist][2] before the transition: - -![](https://cloud.githubusercontent.com/assets/1155781/4116929/13fc6f50-328b-11e4-837b-922aad3055a8.png) - -We also planned a maintenance window and [announced it on our blog][3] to give our users plenty of notice. - -### Migration day ### - -At 5am Pacific Time on a Saturday, the migration team assembled online in chat and the process began: - -![](https://cloud.githubusercontent.com/assets/1155781/4060850/39f52cd4-2df3-11e4-9aca-1f54a4870d24.png) - -We put the site in maintenance mode, made an announcement on Twitter, and set out to work through the list above: - -![](https://cloud.githubusercontent.com/assets/1155781/4060864/54ff6bac-2df3-11e4-95da-b059c0ec668f.png) - -**13 minutes** later, we were able to confirm operations of the new cluster: - -![](https://cloud.githubusercontent.com/assets/1155781/4060870/6a4c0060-2df3-11e4-8dab-654562fe628d.png) - -Then we flipped GitHub.com out of maintenance mode, and let the world know that we were in the clear. - -![](https://cloud.githubusercontent.com/assets/1155781/4060878/79b9884c-2df3-11e4-98ed-d11818c8915a.png) - -Lots of up front testing and preparation meant that we kept the work we needed on go-live day to a minimum. - -### Measuring the final results ### - -In the weeks following the migration, we closely monitored performance and response times on GitHub.com. We found that our cluster migration cut the average GitHub.com page load time by half and the 99th percentile by *two-thirds*: - -![](https://cloud.githubusercontent.com/assets/1155781/4060886/9106e54e-2df3-11e4-8fda-a4c64c229ba1.png) - -### What we learned ### - -#### Functional partitioning #### - -During this process we decided that moving larger tables that mostly store historic data to separate cluster was a good way to free up disk and buffer pool space. This allowed us to leave more resources for our "hot" data, splitting some connection logic to enable the application to query multiple clusters. This proved to be a big win for us and we are working to reuse this pattern. - -#### Always be testing #### - -You can never do too much acceptance and regression testing for your application. Replicating data from the old cluster to the new cluster while running acceptance tests and replaying queries were invaluable for tracing out issues and preventing surprises during the migration. - -#### The power of collaboration #### - -Large changes to infrastructure like this mean a lot of people need to be involved, so pull requests functioned as our primary point of coordination as a team. We had people all over the world jumping in to help. - -Deploy day team map: - - - -This created a workflow where we could open a pull request to try out changes, get real-time feedback, and see commits that fixed regressions or errors -- all without phone calls or face-to-face meetings. When everything has a URL that can provide context, it's easy to involve a diverse range of people and make it simple for them give feedback. - -### One year later.. ### - -A full year later, we are happy to call this migration a success — MySQL performance and reliability continue to meet our expectations. And as an added bonus, the new cluster enabled us to make further improvements towards greater availability and query response times. I'll be writing more about those improvements here soon. - --------------------------------------------------------------------------------- - -via: https://github.com/blog/1880-making-mysql-better-at-github - -作者:[samlambert][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:https://github.com/samlambert -[1]:https://github.com/blog/1756-optimizing-large-selector-sets -[2]:https://help.github.com/articles/writing-on-github#task-lists -[3]:https://github.com/blog/1603-site-maintenance-august-31st-2013 \ No newline at end of file diff --git a/sources/talk/20140904 The Masked Avengers.md b/sources/talk/20140904 The Masked Avengers.md deleted file mode 100644 index 0cb5cdaeed..0000000000 --- a/sources/talk/20140904 The Masked Avengers.md +++ /dev/null @@ -1,378 +0,0 @@ -[Translating by SteveArcher] -The Masked Avengers -================================================================================ -> How Anonymous incited online vigilantism from Tunisia to Ferguson. - -![](http://www.newyorker.com/wp-content/uploads/2014/09/140908_r25419-690.jpg) - -Anyone can join Anonymous simply by claiming affiliation. An anthropologist says that participants “remain subordinate to a focus on the epic win—and, especially, the lulz.” - -Paper Sculpture by Jeff Nishinaka / Photograph by Scott Dunbar - ----------- - -In the mid-nineteen-seventies, when Christopher Doyon was a child in rural Maine, he spent hours chatting with strangers on CB radio. His handle was Big Red, for his hair. Transmitters lined the walls of his bedroom, and he persuaded his father to attach two directional antennas to the roof of their house. CB radio was associated primarily with truck drivers, but Doyon and others used it to form the sort of virtual community that later appeared on the Internet, with self-selected nicknames, inside jokes, and an earnest desire to effect change. - -Doyon’s mother died when he was a child, and he and his younger sister were reared by their father, who they both say was physically abusive. Doyon found solace, and a sense of purpose, in the CB-radio community. He and his friends took turns monitoring the local emergency channel. One friend’s father bought a bubble light and affixed it to the roof of his car; when the boys heard a distress call from a stranded motorist, he’d drive them to the side of the highway. There wasn’t much they could do beyond offering to call 911, but the adventure made them feel heroic. - -Small and wiry, with a thick New England accent, Doyon was fascinated by “Star Trek” and Isaac Asimov novels. When he saw an ad in Popular Mechanics for a build-your-own personal-computer kit, he asked his grandmother to buy it for him, and he spent months figuring out how to put it together and hook it up to the Internet. Compared with the sparsely populated CB airwaves, online chat rooms were a revelation. “I just click a button, hit this guy’s name, and I’m talking to him,” Doyon recalled recently. “It was just breathtaking.” - -At the age of fourteen, he ran away from home, and two years later he moved to Cambridge, Massachusetts, a hub of the emerging computer counterculture. The Tech Model Railroad Club, which had been founded thirty-four years earlier by train hobbyists at M.I.T., had evolved into “hackers”—the first group to popularize the term. Richard Stallman, a computer scientist who worked in M.I.T.’s Artificial Intelligence Laboratory at the time, says that these early hackers were more likely to pass around copies of “Gödel, Escher, Bach” than to incite technological warfare. “We didn’t have tenets,” Stallman said. “It wasn’t a movement. It was just a thing that people did to impress each other.” Some of their “hacks” were fun (coding video games); others were functional (improving computer-processing speeds); and some were pranks that took place in the real world (placing mock street signs near campus). Michael Patton, who helped run the T.M.R.C. in the seventies, told me that the original hackers had unwritten rules and that the first one was “Do no damage.” - -In Cambridge, Doyon supported himself through odd jobs and panhandling, preferring the freedom of sleeping on park benches to the monotony of a regular job. In 1985, he and a half-dozen other activists formed an electronic “militia.” Echoing the Animal Liberation Front, they called themselves the Peoples Liberation Front. They adopted aliases: the founder, a towering middle-aged man who claimed to be a military veteran, called himself Commander Adama; Doyon went by Commander X. Inspired by the Merry Pranksters, they sold LSD at Grateful Dead shows and used some of the cash to outfit an old school bus with bullhorns, cameras, and battery chargers. They also rented a basement apartment in Cambridge, where Doyon occasionally slept. - -Doyon was drawn to computers, but he was not an expert coder. In a series of conversations over the past year, he told me that he saw himself as an activist, in the radical tradition of Abbie Hoffman and Eldridge Cleaver; technology was merely his medium of dissent. In the eighties, students at Harvard and M.I.T. held rallies urging their schools to divest from South Africa. To help the protesters communicate over a secure channel, the P.L.F. built radio kits: mobile FM transmitters, retractable antennas, and microphones, all stuffed inside backpacks. Willard Johnson, an activist and a political scientist at M.I.T., said that hackers were not a transformative presence at rallies. “Most of our work was still done using a bullhorn,” he said. - -In 1992, at a Grateful Dead concert in Indiana, Doyon sold three hundred hits of acid to an undercover narcotics agent. He was sentenced to twelve years in Pendleton Correctional Facility, of which he served five. While there, he developed an interest in religion and philosophy and took classes from Ball State University. - -Netscape Navigator, the first commercial Web browser, was released in 1994, while Doyon was incarcerated. When he returned to Cambridge, the P.L.F. was still active, and their tools had a much wider reach. The change, Doyon recalls, “was gigantic—it was the difference between sending up smoke signals and being able to telegraph someone.” Hackers defaced an Indian military Web site with the words “Save Kashmir.” In Serbia, hackers took down an Albanian site. Stefan Wray, an early online activist, defended such tactics at an “anti-Columbus Day” rally in New York. “We see this as a form of electronic civil disobedience,” he told the crowd. - -In 1999, the Recording Industry Association of America sued Napster, the file-sharing service, for copyright infringement. As a result, Napster was shut down in 2001. Doyon and other hackers disabled the R.I.A.A. site for a weekend, using a Distributed Denial of Service, or DDoS, attack, which floods a site with so much data that it slows down or crashes. Doyon defended his actions, employing the heightened rhetoric of other “hacktivists.” “We quickly came to understand that the battle to defend Napster was symbolic of the battle to preserve a free internet,” he later wrote. - -One day in 2008, Doyon and Commander Adama met at the P.L.F.’s basement apartment in Cambridge. Adama showed Doyon the Web site of the Epilepsy Foundation, on which a link, instead of leading to a discussion forum, triggered a series of flashing colored lights. Some epileptics are sensitive to strobes; out of sheer malice, someone was trying to induce seizures in innocent people. There had been at least one victim already. - -Doyon was incensed. He asked Adama who would do such a thing. - -“Ever hear of a group called Anonymous?” Adama said. - ----------- - -In 2003, Christopher Poole, a fifteen-year-old insomniac from New York City, launched 4chan, a discussion board where fans of anime could post photographs and snarky comments. The focus quickly widened to include many of the Internet’s earliest memes: LOLcats, Chocolate Rain, RickRolls. Users who did not enter a screen name were given the default handle Anonymous. - -![](http://www.newyorker.com/wp-content/uploads/2014/09/140908_a18505-600.jpg) - -“I need to talk about my inner life.” - -Poole hoped that anonymity would keep things irreverent. “We have no intention of partaking in intelligent discussions concerning foreign affairs,” he wrote on the site. One of the highest values within the 4chan community was the pursuit of “lulz,” a term derived from the acronym LOL. Lulz were often achieved by sharing puerile jokes or images, many of them pornographic or scatological. The most shocking of these were posted on a part of the site labelled /b/, whose users called themselves /b/tards. Doyon was aware of 4chan, but considered its users “a bunch of stupid little pranksters.” Around 2004, some people on /b/ started referring to “Anonymous” as an independent entity. - -It was a new kind of hacker collective. “It’s not a group,” Mikko Hypponen, a leading computer-security researcher, told me—rather, it could be thought of as a shape-shifting subculture. Barrett Brown, a Texas journalist and a well-known champion of Anonymous, has described it as “a series of relationships.” There was no membership fee or initiation. Anyone who wanted to be a part of Anonymous—an Anon—could simply claim allegiance. - -Despite 4chan’s focus on trivial topics, many Anons considered themselves crusaders for justice. They launched vigilante campaigns that were purposeful, if sometimes misguided. More than once, they posed as underage girls in order to entrap pedophiles, whose personal information they sent to the police. Other Anons were apolitical and sowed chaos for the lulz. One of them posted images on /b/ of what looked like pipe bombs; another threatened to blow up several football stadiums and was arrested by the F.B.I. In 2007, a local news affiliate in Los Angeles called Anonymous “an Internet hate machine.” - -In January, 2008, Gawker Media posted a video in which Tom Cruise enthusiastically touted the benefits of Scientology. The video was copyright-protected, and the Church of Scientology sent a cease-and-desist letter to Gawker, asking that the video be removed. Anonymous viewed the church’s demands as attempts at censorship. “I think it’s time for /b/ to do something big,” someone posted on 4chan. “I’m talking about ‘hacking’ or ‘taking down’ the official Scientology Web site.” An Anon used YouTube to issue a “press release,” which included stock footage of storm clouds and a computerized voice-over. “We shall proceed to expel you from the Internet and systematically dismantle the Church of Scientology in its present form,” the voice said. “You have nowhere to hide.” Within a few weeks, the YouTube video had been viewed more than two million times. - -Anonymous had outgrown 4chan. The hackers met in dedicated Internet Relay Chat channels, or I.R.C.s, to coördinate tactics. Using DDoS attacks, they caused the main Scientology Web site to crash intermittently for several days. Anons created a “Google bomb,” so that a search for “dangerous cult” would yield the main Scientology site at the top of the results page. Others sent hundreds of pizzas to Scientology centers in Europe, and overwhelmed the church’s Los Angeles headquarters with all-black faxes, draining the machines of ink. The Church of Scientology, an organization that reportedly has more than a billion dollars in assets, could withstand the depletion of its ink cartridges. But its leaders, who had also received death threats, contacted the F.B.I. to request an investigation into Anonymous. - -On March 15, 2008, several thousand Anons marched past Scientology churches in more than a hundred cities, from London to Sydney. In keeping with the theme of anonymity, the organizers decided that all the protesters should wear versions of the same mask. After considering Batman, they settled on the Guy Fawkes mask worn in “V for Vendetta,” a dystopian movie from 2005. “It was available in every major city, in large quantities, for cheap,” Gregg Housh, one of the organizers of the protests and a well-known Anon, told me. The mask was a caricature of a man with rosy cheeks, a handlebar mustache, and a wide grin. - -Anonymous did not “dismantle” the Church of Scientology. Still, the Tom Cruise video remained online. Anonymous had proved its tenacity. The collective adopted a bombastic slogan: “We are Legion. We do not forgive. We do not forget. Expect us.” - ----------- - -In 2010, Doyon moved to Santa Cruz, California, to join a local movement called Peace Camp. Using wood that he stole from a lumberyard, he built a shack in the mountains. He borrowed WiFi from a nearby mansion, drew power from salvaged solar panels, and harvested marijuana, which he sold for cash. - -At the time, the Peace Camp activists were sleeping on city property as a protest against a Santa Cruz anti-homelessness law that they considered extreme. Doyon appeared at Peace Camp meetings and offered to promote their cause online. He had an unkempt red beard and wore a floppy beige hat and quasi-military fatigues. Some of the activists called him Curbhugger Chris. - -Kelley Landaker, a member of Peace Camp, spoke with Doyon several times about hacking. Doyon sometimes bragged about his technical aptitude, but Landaker, an expert programmer, was unimpressed. “He was more of a spokesman than a hands-on-the-keyboard type of person,” Landaker told me. But the movement needed a passionate leader more than it needed a coder. “He was very enthusiastic and very outspoken,” Robert Norse, also a member of Peace Camp, told me. “He created more media attention for the issue than anyone I’ve seen, and I’ve been doing this for twenty years.” - -Commander Adama, Doyon’s superior in the P.L.F., who still lived in Cambridge and communicated with him via e-mail, had ordered Doyon to monitor Anonymous. Doyon’s brief was to observe their methods and to recruit members to the P.L.F. Recalling his revulsion at the Epilepsy Foundation hack, Doyon initially balked. Adama argued that the malicious hackers were a minority within Anonymous, and that the collective might inspire powerful new forms of activism. Doyon was skeptical. “The biggest movement in the world is going to come from 4chan?” he said. But, out of loyalty to the P.L.F., he obeyed Adama. - -Doyon spent much of his time at the Santa Cruz Coffee Roasting Company, a café downtown, hunched over an Acer laptop. The main Anonymous I.R.C. did not require a password. Doyon logged in using the name PLF and followed along. Over time, he discovered back channels where smaller, more dedicated groups of Anons had dozens of overlapping conversations. To participate, you had to know the names of the back channels, which could be changed to deflect intruders. It was not a highly secure system, but it was adaptable. “These simultaneous cabals keep centralization from happening,” Gabriella Coleman, an anthropologist at McGill University, told me. - -Some Anons proposed an action called Operation Payback. As the journalist Parmy Olson wrote in a 2012 book, “We Are Anonymous,” Operation Payback started as another campaign in support of file-sharing sites like the Pirate Bay, a successor to Napster, but the focus soon broadened to include political speech. In late 2010, at the behest of the State Department, several companies, including MasterCard, Visa, and PayPal, stopped facilitating donations to WikiLeaks, the vigilante organization that had released hundreds of thousands of diplomatic cables. In an online video, Anonymous called for revenge, promising to lash out at the companies that had impeded WikiLeaks. Doyon, attracted by the anti-corporate spirit of the project, decided to participate. - -![](http://www.newyorker.com/wp-content/uploads/2014/09/140908_a18473-600.jpg) - -During Operation Payback, in early December, Anonymous directed new recruits, or noobs, to a flyer headed “How to Join the Fucking Hive,” in which participants were instructed to “FIX YOUR GODDAMN INTERNET. THIS IS VERY FUCKING IMPORTANT.” They were also asked to download Low Orbit Ion Cannon, an easy-to-use tool that is publicly available. Doyon downloaded the software and watched the chat rooms, waiting for a cue. When the signal came, thousands of Anons fired at once. Doyon entered a target URL—say, www.visa.com—and, in the upper-right corner, clicked a button that said “IMMA CHARGIN MAH LAZER.” (The operation also relied on more sophisticated hacking.) Over several days, Operation Payback disabled the home pages of Visa, MasterCard, and PayPal. In court filings, PayPal claimed that the attack had cost the company five and a half million dollars. - -To Doyon, this was activism made tangible. In Cambridge, protesting against apartheid, he could not see immediate results; now, with the tap of a button, he could help sabotage a major corporation’s site. A banner headline on the Huffington Post read “MasterCard DOWN.” One gloating Anon tweeted, “There are some things WikiLeaks can’t do. For everything else, there’s Operation Payback.” - ----------- - -In the fall of 2010, the Peace Camp protests ended. With slight concessions, the anti-homelessness law remained in effect. Doyon hoped to use the tactics of Anonymous to reinvigorate the movement. He recalls thinking, “I could wield Anonymous against this tiny little city government and they would just be fucking wrecked. Plan was we were finally going to solve this homelessness problem, once and for all.” - -Joshua Covelli, a twenty-five-year-old Anon who went by the nickname Absolem, admired Doyon’s decisiveness. “Anonymous had been this clusterfuck of chaos,” Covelli told me. With Commander X, “there seemed to be a structure set up.” Covelli worked as a receptionist at a college in Fairborn, Ohio, and knew nothing about Santa Cruz politics. But when Doyon asked for help with Operation Peace Camp, Covelli e-mailed back immediately: “I’ve been waiting to join something like that my entire life.” - -Doyon, under the name PLF, invited Covelli into a private I.R.C.: - -> Absolem: Sorry to be so rude . . . Is PLF part of Anonymous or separate? -> -> Absolem: I was just asking because you all seem very organized in chat. -> -> PLF: You are not in the least rude. I am pleased to meet you. PLF is 22 year old hacker group originally from Boston. I started hacking in 81, not with computers but PBX (telephones). -> -> PLF: We are all older 40 or over. Some of us are former military or intelligence. One of us, Commander Adama is currently sought by an alphabet soup of cops and spooks and in hiding. -> -> Absolem: Wow that’s legit. I am really interested in helping this out in some way and Anonymous just seems too chaotic. I have some computer skills but very noob in hacking. I have some tools but no Idea how to use them. - -With ritual solemnity, Doyon accepted Covelli’s request to join the P.L.F.: - -> PLF: Encrypt the fuck out of all sensitive material that might incriminate you. -> -> PLF: Yep, work with any PLFer to get a message to me. Call me . . . Commander X for now. - -In 2012, the Associated Press called Anonymous “a group of expert hackers”; Quinn Norton, in Wired, wrote that “Anonymous had figured out how to infiltrate anything,” resulting in “a wild string of brilliant hacks.” In fact some Anons are gifted coders, but the vast majority possess little technical skill. Coleman, the anthropologist, told me that only a fifth of Anons are hackers—the rest are “geeks and protesters.” - -On December 16, 2010, Doyon, as Commander X, sent an e-mail to several reporters. “At exactly noon local time tomorrow, the Peoples Liberation Front and Anonymous will remove from the Internet the Web site of the Santa Cruz County government,” he wrote. “And exactly 30 minutes later, we will return it to normal function.” - -The data-center staff for Santa Cruz County saw the warning and scrambled to prepare for the attack. They ran security scans on the servers and contacted A.T. & T., the county’s Internet provider, which suggested that they alert the F.B.I. - -The next day, Doyon entered a Starbucks and booted up his laptop. Even for a surfing town, he was notably eccentric: a homeless-looking man wearing fatigues and typing furiously. Covelli met him in a private chat room. - -> PLF: Go to Forum, sign in—and look at top right menu bar “chat.” Thats Ops for today. Thank you for standing with us. -> -> Absolem: Anything for PLF, sir. - -They both opened DDoS software. Though only a handful of people were participating in Operation Peace Camp, Doyon gave orders as if he were addressing legions of troops: - -> PLF: ATTENTION: Everyone who supports the PLF or considers us their friend—or who cares about defeating evil and protecting the innocent: Operation Peace Camp is LIVE and an action is underway. TARGET: www.co.santa-cruz.ca.us. Fire At Will. Repeat: FIRE! -> -> Absolem: got it, sir. - -The data-center staff watched their servers, which showed a flurry of denial-of-service requests. Despite their best efforts, the site crashed. Twenty-five minutes later, Doyon decided that he had made his point. He typed “CEASE FIRE,” and the county’s site flickered back to life. (Despite the attack, the city’s anti-homelessness law did not change.) - -Doyon hardly had time to celebrate before he grew anxious. “I got to leave,” he typed to Covelli. He fled to his shack in the mountains. Doyon was right to be wary: an F.B.I. agent had been snooping in the I.R.C. The F.B.I. obtained a warrant to search Doyon’s laptop. - -A few weeks later, Doyon’s food ran out, and he returned to town. While he was at the Santa Cruz Coffee Roasting Company, two federal agents entered the shop. They brought him to the county police station. Doyon called Ed Frey, a lawyer and the founder of Peace Camp, who met him at the station. Doyon told Frey about his alter ego as Commander X. - -Doyon was released, but the F.B.I. kept his laptop, which was full of incriminating evidence. Frey, a civil-rights lawyer who knew little about cybersecurity, drove Doyon back to his hillside encampment. “What are you going to do?” Frey asked. - -![](http://www.newyorker.com/wp-content/uploads/2014/09/140908_a18447-600.jpg) - -“Zach is in the gifted-and-talented-and-you’re-not class.” - -He spoke in cinematic terms. “Run like hell,” he said. “I will go underground, try to stay free as long as I can, and keep fighting the bastards any way possible.” Frey gave him two twenty-dollar bills and wished him luck. - ----------- - -Doyon hitchhiked to San Francisco and stayed there for three months. He spent his days at Coffee to the People, a quirky café in the Haight-Ashbury district, where he would sit for hours in front of his computer, interrupted only by outdoor cigarette breaks. - -In January, 2011, Doyon contacted Barrett Brown, the journalist and Anon. “What are we going to do next?” Doyon asked. - -“Tunisia,” Brown said. - -“Yeah, it’s a country in the Middle East,” Doyon said. “What about it?” - -“We’re gonna take down its dictator,” Brown said. - -“Oh, they have a dictator?” Doyon said. - -A couple of days later, Operation Tunisia began. Doyon volunteered to spam Tunisian government e-mail addresses in an attempt to clog their servers. “I would take the text of the press release for that op and just keep sending it over and over again,” he said. “Sometimes, I was so busy that I would just put ‘fuck you’ and send it.” In one day, the Anons brought down the Web sites of the Tunisian Stock Exchange, the Ministry of Industry, the President, and the Prime Minister. They replaced the Web page of the President’s office with an image of a pirate ship and the message “Payback is a bitch, isn’t it?” - -Doyon often spoke of his online battles as if he had just crawled out of a foxhole. “Dude, I turned black from doing it,” he told me. “My face, from all the smoke—it would cling to me. I would look up and I would literally be like a raccoon.” Most nights, he camped out in Golden Gate Park. “I would look at myself in the mirror and I’d be like, O.K., it’s been four days—maybe I should eat, bathe.” - -Anonymous-affiliated operations continued to be announced on YouTube: Operation Libya, Operation Bahrain, Operation Morocco. As protesters filled Tahrir Square, Doyon participated in Operation Egypt. A Facebook page disseminated information, including links to a “care package” for protesters on the ground. The package, distributed through the file-sharing site Megaupload, contained encryption software and a primer on defending against tear gas. Later, when the Egyptian government disabled Internet and cellular networks within the country, Anonymous helped the protesters find alternative ways to get online. - -In the summer of 2011, Doyon succeeded Adama as Supreme Commander of the P.L.F. Doyon recruited roughly half a dozen new members and attempted to position the P.L.F. as an élite squad within Anonymous. Covelli became one of his technical advisers. Another hacker, Crypt0nymous, made YouTube videos; others did research or assembled electronic care packages. Unlike Anonymous, the P.L.F. had a strict command structure. “X always called the shots on everything,” Covelli said. “It was his way or no way.” A hacker who founded a blog called AnonInsiders told me over encrypted chat that Doyon was willing to act unilaterally—a rare thing within Anonymous. “When we wanted to start an op, he didn’t mind if anyone would agree or not,” he said. “He would just write the press release by himself, list all the targets, open the I.R.C. channel, tell everyone to go in there, and start the DDoSing.” - -Some Anons viewed the P.L.F. as a vanity project and Doyon as a laughingstock. “He’s known for his exaggeration,” Mustafa Al-Bassam, an Anon who went by Tflow, told me. Others, even those who disapproved of Doyon’s egotism, grudgingly acknowledged his importance to the Anonymous movement. “He walks that tough line of sometimes being effective and sometimes being in the way,” Gregg Housh said, adding that he and other prominent Anons had faced similar challenges. - -Publicly, Anonymous persists in claiming to be non-hierarchical. In “We Are Legion,” a 2012 documentary about Anonymous by Brian Knappenberger, one activist uses the metaphor of a flock of birds, with various individuals taking turns drifting toward the front. Gabriella Coleman told me that, despite such claims, something resembling an informal leadership class did emerge within Anonymous. “The organizer is really important,” she said. “There are four or five individuals who are really good at it.” She counted Doyon among them. Still, Anons tend to rebel against institutional structure. In a forthcoming book about Anonymous, “Hacker, Hoaxer, Whistleblower, Spy,” Coleman writes that, among Anons, “personal identity and the individual remain subordinate to a focus on the epic win—and, especially, the lulz.” - -Anons who seek individual attention are often dismissed as “egofags” or “namefags.” (Many Anons have yet to outgrow their penchant for offensive epithets.) “There are surprisingly few people who violate the rule” against attention-seeking, Coleman says. “Those who do, like X, are marginalized.” Last year, in an online discussion forum, a commenter wrote, “I stopped reading his BS when he started comparing himself to Batman.” - -Peter Fein, an online activist known by the nickname n0pants, was among the many Anons who were put off by Doyon’s self-aggrandizing rhetoric. Fein browsed the P.L.F. Web site, which featured a coat of arms and a manifesto about the group’s “epic battle for the very soul of humanity.” Fein was dismayed to find that Doyon had registered the site using his real name, leaving himself and possibly other Anons vulnerable to prosecution. “I’m basically okay with people DDoSing,” Fein recalls telling Doyon over private chat. “But if you’re going to do it, you’ve got to cover your ass.” - -On February 5, 2011, the Financial Times reported that Aaron Barr, the C.E.O. of a cybersecurity firm called HBGary Federal, had identified the “most senior” members of Anonymous. Barr’s research suggested that one of the top three was Commander X, a hacker based in California, who could “manage some significant firepower.” Barr contacted the F.B.I. and offered to share his work with them. - -Like Fein, Barr had seen that the P.L.F. site was registered to Christopher Doyon at an address on Haight Street. Based on Facebook and I.R.C. activity, Barr concluded that Commander X was Benjamin Spock de Vries, an online activist who had lived near the Haight Street address. Barr approached de Vries on Facebook. “Please tell the folks there that I am not out to get you guys,” Barr wrote. “Just want the ‘leadership’ to know what my intent is.” - -“ ‘Leadership’ lmao,” de Vries responded. - -Days after the Financial Times story appeared, Anonymous struck back. HBGary Federal’s Web site was defaced. Barr’s personal Twitter account was hijacked, thousands of his e-mails were leaked online, and Anons released his address and other personal information—a punishment known as doxing. Barr resigned from HBGary Federal within the month. - ----------- - -In April, 2011, Doyon left San Francisco and hitchhiked around the West, camping in parks at night and spending his days at Starbucks outlets. In his backpack he kept his laptop, his Guy Fawkes mask, and several packs of Pall Malls. - -![](http://www.newyorker.com/wp-content/uploads/2014/09/140908_a18563-600.jpg) - -“This is what I learned during my summer at TED camp.” - -He followed internal Anonymous news. That spring, six élite Anons, all of whom had been instrumental in deflecting Barr’s investigation, formed a group called Lulz Security, or LulzSec. As their name indicated, they felt that Anonymous had become too self-serious; they aimed to bring the lulz back. While Anonymous continued supporting Arab Spring protesters, LulzSec hacked the Web site of PBS and posted a fake story claiming that the late rapper Tupac Shakur was alive in New Zealand. - -Anons often share text through the Web site Pastebin.com. On the site, LulzSec issued a statement that read, “It has come to our unfortunate attention that NATO and our good friend Barrack Osama-Llama 24th-century Obama have recently upped the stakes with regard to hacking. They now treat hacking as an act of war.” The loftier the target, the greater the lulz. On June 15th, LulzSec took credit for crashing the C.I.A.’s Web site, tweeting, “Tango down—cia.gov—for the lulz.” - -On June 20, 2011, Ryan Cleary, a nineteen-year-old member of LulzSec, was arrested for the DDoS attacks on the C.I.A. site. The next month, F.B.I. agents arrested fourteen other hackers for DDoS attacks on PayPal seven months earlier. Each of the PayPal Fourteen, as they became known, faced fifteen years in prison and a five-hundred-thousand-dollar fine. They were charged with conspiracy and intentional damage to protected computers under the Computer Fraud and Abuse Act. (The law allows for wide prosecutorial discretion and was widely criticized after Aaron Swartz, an Internet activist who was facing thirty-five years in prison, committed suicide last year.) - -A petition was circulated on behalf of Jake (Topiary) Davis, a member of LulzSec, who needed help paying his legal fees. Doyon entered an I.R.C. to promote Davis’s cause: - -> CommanderX: Please sign the petition and help Topiary… -> -> toad: you are an attention whore -> -> toad: so you get attention -> -> CommanderX: Toad your an asshole. -> -> katanon: sigh - -Doyon had grown increasingly brazen. He DDoS’ed the Web site of the Chamber of Commerce of Orlando, Florida, after activists there were arrested for feeding the homeless. He launched the attacks from public WiFi networks, using his personal laptop, without making much effort to cover his tracks. “That’s brave but stupid,” a senior member of the P.L.F. who asked to be called Kalli told me. “He didn’t seem to care if he was caught. He was a suicide hacker.” - -Two months later, Doyon participated in a DDoS strike against San Francisco’s Bay Area Rapid Transit, protesting an incident in which a BART police officer had killed a homeless man named Charles Hill. Doyon appeared on the “CBS Evening News” to defend the action, his voice disguised and his face obscured by a bandanna. He compared DDoS attacks to civil disobedience. “It’s no different, really, than taking up seats at the Woolworth lunch counters,” he said. Bob Schieffer, the CBS anchor, snickered and said, “It’s not quite the civil-rights movement, as I see it.” - -On September 22, 2011, in a coffee shop in Mountain View, California, Doyon was arrested and charged with causing intentional damage to a protected computer. He was detained for a week and released on bond. Two days later, against his lawyer’s advice, he called a press conference on the steps of the Santa Cruz County Courthouse. His hair in a ponytail, he wore dark sunglasses, a black pirate hat, and a camouflage bandanna around his neck. - -In characteristically melodramatic fashion, Doyon revealed his identity. “I am Commander X,” he told reporters. He raised his fist. “I am immensely proud, and humbled to the core, to be a part of the idea called Anonymous.” He told a journalist, “All you need to be a world-class hacker is a computer and a cool pair of sunglasses. And the computer is optional.” - -Kalli worried that Doyon was placing his ego above the safety of other Anons. “It’s the weakest link in the chain that ends up taking everyone down,” he told me. Josh Covelli, the Anon who had been eager to help Doyon with Operation Peace Camp, told me that his “jaw dropped” when he saw a video of Doyon’s press conference online. “The way he presented himself and the way he acted had become more unhinged,” Covelli said. - -Three months later, Doyon’s pro-bono lawyer, Jay Leiderman, was in a federal court in San Jose. Leiderman had not heard from Doyon in a couple of weeks. “I’m inquiring as to whether there’s a reason for that,” the judge said. Leiderman had no answer. Doyon was absent from another hearing two weeks later. The prosecutor stated the obvious: “It appears as though the defendant has fled.” - ----------- - -Operation Xport was the first Anonymous operation of its kind. The goal was to smuggle Doyon, now a fugitive wanted for two felonies, out of the country. The coördinators were Kalli and a veteran Anon who had met Doyon at an acid party in Cambridge during the eighties. A retired software executive, he was widely respected within Anonymous. - -Doyon’s ultimate destination was the software executive’s house, deep in rural Canada. In December, 2011, he hitchhiked to San Francisco and made his way to an Occupy encampment downtown. He found his designated contact, who helped him get to a pizzeria in Oakland. At 2 A.M., Doyon, using the pizzeria’s WiFi, received a message on encrypted chat. - -“Are you near a window?” the message read. - -“Yeah,” Doyon typed. - -“Look across the street. Do you see the green mailbox? In exactly fifteen minutes, go and stand next to that mailbox and set your backpack down, and lay your mask on top of it.” - -For a few weeks, Doyon shuttled among safe houses in the Bay Area, following instructions through encrypted chat. Eventually, he took a Greyhound bus to Seattle, where he stayed with a friend of the software executive. The friend, a wealthy retiree, spent hours using Google Earth to help Doyon plot a route to Canada. They went to a camping-supplies store, and the friend spent fifteen hundred dollars on gear for Doyon, including hiking boots and a new backpack. Then he drove Doyon two hours north and dropped him off in a remote area, several hundred miles from the border, where Doyon met up with Amber Lyon. - -Months earlier, Lyon, a broadcast journalist, had interviewed Doyon for a CNN segment about Anonymous. He liked her report, and they stayed in touch. Lyon asked to join Doyon on his escape, to shoot footage for a possible documentary. The software executive thought that it was “nuts” to take the risk, but Doyon invited her anyway. “I think he wanted to make himself a face of the movement,” Lyon told me. For four days, she filmed him as he hiked north, camping in the woods. “It wasn’t very organized,” Lyon recalls. “He was functionally homeless, so he just kind of wandered out of the country.” - -![](http://www.newyorker.com/wp-content/uploads/2014/09/140908_a18506-600.jpg) - -“This is the barn where we keep our feelings. If a feeling comes to you, bring it out here and lock it up.” - -On February 11, 2012, a press release appeared on Pastebin. “The PLF is delighted to announce that Commander X, aka Christopher Mark Doyon, has fled the jurisdiction of the USA and entered the relative safety of the nation of Canada,” it read. “The PLF calls upon the government of the USA to come to its senses and cease the harassment, surveillance—and arrest of not only Anonymous, but all activists.” - ----------- - -In Canada, Doyon spent a few days with the software executive in a small house in the woods. In a chat with Barrett Brown, Doyon was effusive. - -> BarrettBrown: you have enough safe houses, etc? . . . -> -> CommanderX: Yes I am good here, money and houses a plenty in Canada. -> -> CommanderX: Amber Lyon asked me on camera about you. -> -> CommanderX: I think you will like my reply, and fuck the trolls Barrett. I have always loved you and always will. -> -> CommanderX: :-) -> -> CommanderX: I told her you were a hero. -> -> BarrettBrown: you’re a hero . . . -> -> BarrettBrown: glad you’re safe for now -> -> BarrettBrown: let me know if you need anything -> -> CommanderX: I am, and if this works we can get others out to . . . . -> -> BarrettBrown: good, we’re going to need that - -Ten days after Doyon’s escape, the Wall Street Journal reported that Keith Alexander, then the N.S.A. and U.S. Cyber Command director, had held classified meetings in the White House and elsewhere during which he expressed concern about Anonymous. Within two years, Alexander warned, the group might be capable of destabilizing national power grids. General Martin Dempsey, the chairman of the Joint Chiefs of Staff, told the Journal that an enemy of the U.S. “could give cyber malware capability to some fringe group,” adding, “We have to get after this.” - -On March 8th, a briefing on cybersecurity was held for members of Congress at a Sensitive Compartmented Information Facility near the Capitol Building. Many of the country’s top security officials attended the briefing, including Alexander, Dempsey, Robert Mueller, the head of the F.B.I., and Janet Napolitano, the Secretary of Homeland Security. Attendees were shown a computer simulation of what a cyberattack on the Eastern Seaboard’s electrical supply might look like. Anonymous was not yet capable of mounting an attack on this scale, but security officials worried that they might join forces with other, more sophisticated groups. “As we were dealing with this ever-increasing presence on the Net and ever-increasing risk, the government nuts and bolts were still being worked out,” Napolitano told me. When discussing potential cybersecurity threats, she added, “We often used Anonymous as Exhibit A.” - -Anonymous might be the most powerful nongovernmental hacking collective in the world. Even so, it has never demonstrated an ability or desire to damage any key elements of public infrastructure. To some cybersecurity experts, the dire warnings about Anonymous sounded like fearmongering. “There’s a big gap between declaring war on Orlando and pulling off a Stuxnet attack,” James Andrew Lewis, a senior fellow at the Center for Strategic and International Studies, told me, referring to the elaborate cyberstrike carried out by the U.S. and Israel against Iranian nuclear sites in 2007. Yochai Benkler, a professor at Harvard Law School, told me, “What we’ve seen is the use of drumbeating as justification for major defense spending of a form that would otherwise be hard to justify.” - -Keith Alexander, who recently retired from the government, declined to comment for this story, as did representatives from the N.S.A., the F.B.I., the C.I.A., and the D.H.S. Although Anons have never seriously compromised government computer networks, they have a record of seeking revenge against individuals who anger them. Andy Purdy, the former head of the national-cybersecurity division of the D.H.S., told me that “a fear of retaliation,” both institutional and personal, prevents government representatives from speaking out against Anonymous. “Everyone is vulnerable,” he said. - ----------- - -On March 6, 2012, Hector Xavier Monsegur, a key member of LulzSec with the screen name Sabu, was revealed to be an F.B.I. informant. In exchange for a reduced sentence, Monsegur had spent several months undercover, helping to gather evidence against other LulzSec members. The same day, five leading Anons were arrested and charged with several crimes, including computer conspiracy. An F.B.I. official told Fox News, “This is devastating to the organization. We’re chopping off the head of LulzSec.” Over the next ten months, Barrett Brown was indicted on seventeen federal charges, most of which were later dropped. (He will be sentenced in October.) - -Doyon was distraught, but he continued to hack—and to seek attention. He appeared, masked, at a Toronto screening of a documentary about Anonymous. He gave an interview to a reporter from the National Post and boasted, without substantiation, “We have access to every classified database in the U.S. government. It’s a matter of when we leak the contents of those databases, not if.” - -In January, 2013, after another Anon started an operation about the rape of a teen-age girl in Steubenville, Ohio, Doyon repurposed LocalLeaks, a site he had created two years earlier, as a clearinghouse for information about the rape. Like many Anonymous efforts, LocalLeaks was both influential and irresponsible. It was the first site to widely disseminate the twelve-minute video of a Steubenville High School graduate joking about the rape, which inflamed public outrage about the story. But the site also perpetuated several false rumors about the case and it failed to redact a court document, thus accidentally revealing the rape victim’s name. Doyon admitted to me that his strategy of releasing unexpurgated materials was controversial, but he recalled thinking, “We could either gut the Steubenville Files . . . or we could release everything we know, basically, with the caveat, Hey, you’ve got to trust us.” - -In May, 2013, the Rustle League, a group of online trolls who often provoke Anonymous, hacked Doyon’s Twitter account. Shm00p, one of the leaders of Rustle League, told me, “We’re not trying to cause harm to the guy, but, just, the shit he was saying—it was comical to me.” The Rustle League implanted racist and anti-Semitic messages into Doyon’s account, such as a link to www.jewsdid911.org. - -On August 27, 2013, Doyon posted a note announcing his retirement from Anonymous. “My entire life has been dedicated to fighting for justice and freedom,” he wrote. “ ‘Commander X’ may be invincible, but I am extremely ill from the exhaustion and stress of fighting in this epic global cyber war.” Reactions varied from compassion (“you deserve a rest”) to ridicule (“poor crazy old gnoll. Maybe he has some time for bathing now”). Covelli told me, “The persona has consumed him to the point where he can’t handle it anymore.” - -![](http://www.newyorker.com/wp-content/uploads/2014/09/140908_roberts-1998-08-17-600.jpg) - -August 17, 1998 “We still have Paris? Just thought I’d check.” - ----------- - -The first Million Mask March took place on November 5, 2013. Several thousand people marched in support of Anonymous, in four hundred and fifty cities around the world. In a sign of how deeply Anonymous had penetrated popular culture, one protester in London removed his Guy Fawkes mask to reveal that he was the actor Russell Brand. - -While I attended the rally in Washington, D.C., Doyon watched a livestream in Canada. I exchanged e-mails with him on my phone. “It is so surreal to sit here, sidelined and out of the game—and watch something that you helped create turn into this,” he wrote. “At least it all made a difference.” - -We arranged a face-to-face meeting. Doyon insisted that I submit to elaborate plans made over encrypted chat. I was to fly to an airport several hours away, rent a car, drive to a remote location in Canada, and disable my phone. - -I found him in a small, run-down apartment building in a quiet residential neighborhood. He wore a green Army-style jacket and a T-shirt featuring one of Anonymous’s logos: a black-suited man with a question mark instead of a face. The apartment was sparsely furnished and smelled of cigarette smoke. He discussed U.S. politics (“I have not voted in many elections—it’s all a rigged game”), militant Islam (“I believe that people in the Nigerian government essentially colluded to create a completely phony Al Qaeda affiliate called Boko Haram”), and his tenuous position within Anonymous (“These people who call themselves trolls are really just rotten, mean, evil people”). - -Doyon had shaved his beard, and he looked gaunt. He told me that he was ill and that he rarely went outside. On his small desk were two laptops, a stack of books about Buddhism, and an overflowing ashtray. A Guy Fawkes mask hung on an otherwise bare yellow wall. He told me, “Underneath the whole X persona is a little old man who is in absolute agony at times.” - -This past Christmas, the founder of the news site AnonInsiders visited him, bearing pie and cigarettes. Doyon asked the friend to succeed him as Supreme Commander of the P.L.F., offering “the keys to the kingdom”—all his passwords, as well as secret files relating to several Anonymous operations. The friend gently declined. “I have a life,” he told me. - ----------- - -On August 9, 2014, at 5:09 P.M. local time, Kareem (Tef Poe) Jackson, a rapper and activist from Dellwood, Missouri, a suburb of St. Louis, tweeted about a crisis unfolding in a neighboring town. “Basically martial law is taking place in Ferguson all perimeters blocked coming and going,” he wrote. “National and international friends Help!!!” Five hours earlier in Ferguson, an unarmed eighteen-year-old African-American, Michael Brown, had been shot to death by a white police officer. The police claimed that Brown had reached for the officer’s gun. Brown’s friend Dorian Johnson, who was with him at the time, said that Brown’s only offense was refusing to leave the middle of the street. - -Within two hours, Jackson received a reply from a Twitter account called CommanderXanon. “You can certainly expect us,” the message read. “See if you can get us some live streams going, that would be useful.” In recent weeks, Doyon, still in Canada, had come out of retirement. In June, two months before his fiftieth birthday, he quit smoking (“#hacktheaddiction #ecigaretteswork #old,” he later tweeted). The following month, after fighting broke out in Gaza, he tweeted in support of Anonymous’s Operation Save Gaza, a series of DDoS strikes against Israeli Web sites. Doyon found the events in Ferguson even more compelling. Despite his idiosyncrasies, he had a knack for being early to a cause. - -“Start collecting URLs for cops, city government,” Doyon tweeted. Within ten minutes, he had created an I.R.C. channel. “Anonymous Operation Ferguson is engaged,” he tweeted. Only two people retweeted the message. - -The next morning, Doyon posted a link to a rudimentary Web site, which included a message to the people of Ferguson—“You are not alone, we will support you in every way possible”—and an ultimatum to the police: “If you abuse, harass or harm in any way the protesters in Ferguson, we will take every Web based asset of your departments and governments off line. That is not a threat, it is a promise.” Doyon appealed to the most visible Anonymous Twitter account, YourAnonNews, which has 1.3 million followers. “Please support Operation Ferguson,” he wrote. A minute later, YourAnonNews complied. That day, the hashtag #OpFerguson was tweeted more than six thousand times. - -The crisis became a top news story, and Anons rallied around Operation Ferguson. As with the Arab Spring operations, Anonymous sent electronic care packages to protesters on the ground, including a riot guide (“Pick up the gas emitter and lob it back at the police”) and printable Guy Fawkes masks. As Jackson and other protesters marched through Ferguson, the police attempted to subdue them with rubber bullets and tear gas. “It looked like a scene from a Bruce Willis movie,” Jackson told me. “Barack Obama hasn’t supported us to the degree Anonymous has,” he said. “It’s comforting to know that someone out there has your back.” - -One site, www.opferguson.com, turned out to be a honeypot—a trap designed to collect the Internet Protocol addresses of visitors and turn them over to law-enforcement agencies. Some suspected Commander X of being a government informant. In the #OpFerguson I.R.C., someone named Sherlock wrote, “Everyone got me scared clicking links. Unless it’s from a name I’ve seen a lot, I just avoid them.” - -Protesters in Ferguson asked the police to reveal the name of the officer who had shot Brown. Several times, Anons echoed this demand. Someone tweeted, “Ferguson police better release the shooter’s name before Anonymous does the work for them.” In a community meeting on August 12th, Jon Belmar, the Chief of the St. Louis Police Department, refused. “We do not do that until they’re charged with an offense,” he said. - -In retaliation, a hacker with the handle TheAnonMessage tweeted a link to what he claimed was a two-hour audio file of a police radio scanner, recorded around the time of Brown’s death. TheAnonMessage also doxed Belmar, tweeting what he purported to be the police chief’s home address, phone number, and photographs of his family—one of his son sleeping on a couch, another of Belmar posing with his wife. “Nice photo, Jon,” TheAnonMessage tweeted. “Your wife actually looks good for her age. Have you had enough?” An hour later, TheAnonMessage threatened to dox Belmar’s daughter. - -Richard Stallman, the first-generation hacker from M.I.T., told me that though he supports many of Anonymous’s causes, he considered these dox attacks reprehensible. Even internally, TheAnonMessage’s actions were divisive. “Why bother doxing people who weren’t involved?” one Anon asked over I.R.C., adding that threatening Belmar’s family was “beyond stupid.” But TheAnonMessage and other Anons continued to seek information that could be used in future dox attacks. The names of Ferguson Police Department employees were available online, and Anons scoured the Internet, trying to suss out which of the officers had killed Brown. - -![](http://www.newyorker.com/wp-content/uploads/2014/09/140908_steig-1999-04-12-600.jpg) - -April 12, 1999“Which thing do I press?” - -In the early morning of August 14th, a few Anons became convinced, based on Facebook photos and other disparate clues, that Brown’s shooter was a thirty-two-year-old man named Bryan Willman. According to a transcript of an I.R.C., one Anon posted a photo of Willman with a swollen face; another noted, “The shooter claimed to have been hit in the face.” Another user, Anonymous|11057, acknowledged that his suspicion of Willman involved “a leap of probably bad logic.” Still, he wrote, “i just can’t shake it. i really truly honestly and without a shred of hard evidence think it’s him.” - -TheAnonMessage seemed amused by the conversation, writing, “#RIPBryanWillman.” Other Anons urged caution. “Please be sure,” Anonymous|2252 wrote. “It’s not just about a man’s life, Anon can easily be turned on by the public if something truly unjust comes of this.” - -The debate went on for more than an hour. Several Anons pointed out that there was no way to confirm that Willman had ever been a Ferguson police officer. - -> Anonymous|3549: @gs we still don’t have a confirmation that bry is even on PD -> -> Intangir: tensions are high enough right now where there is a slim chance someone might care enough to kill him -> -> Anonymous|11057: the only real way to get a confirmation would be an eyewitness report from the scene of the crime. otherwise it’s hearsay and shillery -> -> Anonymous|11057: the fastest way to eliminate a suspect is to call him a suspect . . . we are all terrified of being unjust, but the pegs keep fitting in the holes . . . - -Many Anons remained uncomfortable with the idea of a dox. But around 7 A.M. a vote was taken. According to chat logs, of the eighty or so people in the I.R.C., fewer than ten participated. They decided to release Willman’s personal information. - -> Anonymous|2252: is this going on twitter? -> -> anondepp: lol -> -> Anonymous|2252: via @theanonmessage ? -> -> TheAnonMessage: yup -> -> TheAnonMessage: just did -> -> anondepp: its up -> -> Anonymous|2252: shit -> -> TheAnonMessage: Lord in heaven… -> -> Anonymous|3549: . . .have mercy on our souls -> -> anondepp: lol - -At 9:45 A.M., the St. Louis Police Department responded to TheAnonMessage. “Bryan Willman is not even an officer with Ferguson or St. Louis County PD,” the tweet read. “Do not release more info on this random citizen.” (The F.B.I. later opened an investigation into the hacking of police computers in Ferguson.) Twitter quickly suspended TheAnonMessage, but Willman’s name and address had been reported widely. - -Willman is the head police dispatcher in St. Ann, a suburb west of Ferguson. When the St. Louis Police Department’s Intelligence Unit called to tell him that he had been named as the killer, Willman told me, “I thought it was the weirdest joke.” Within hours, he received hundreds of death threats on his social-media accounts. He stayed in his house for nearly a week, alone, under police protection. “I just want it all to go away,” he told me. He thinks that Anonymous has irreparably harmed his reputation. “I don’t see how they can ever think they can be trusted again,” he said. - -“We are not perfect,” OpFerguson tweeted. “Anonymous makes mistakes, and we’ve made a few in the chaos of the past few days. For those, we apologize.” Though Doyon was not responsible for the errant dox attack, other Anons took the opportunity to shame him for having launched an operation that spiralled out of control. A Pastebin message, distributed by YourAnonNews, read, “You may notice contradictory tweets and information about #Ferguson and #OpFerguson from various Anonymous twitter accounts. Part of why there is dissension about this particular #op is that CommanderX is considered a ‘namefag/facefag’—a known entity who enjoys or at least doesn’t shun publicity—which is considered by most Anonymous to be bad form, for some probably fairly obvious reasons.” - -On his personal Twitter account, Doyon denied any involvement with Op Ferguson and wrote, “I hate this shit. I don’t want drama and I don’t want to fight with people I thought were friends.” Within a couple of days, he was sounding hopeful again. He recently retweeted messages reading, “You call them rioters, we call them voices of the oppressed” and “Free Tibet.” - -Doyon is still in hiding. Even Jay Leiderman, his attorney, does not know where he is. Leiderman says that, in addition to the charges in Santa Cruz, Doyon may face indictment for his role in the PayPal and Orlando attacks. If he is arrested and convicted on all counts, he could spend the rest of his life in prison. Following the example of Edward Snowden, he hopes to apply for asylum with the Russians. When we spoke, he used a lit cigarette to gesture around his apartment. “How is this better than a fucking jail cell? I never go out,” he said. “I will never speak with my family again. . . . It’s an incredibly high price to pay to do everything you can to keep people alive and free and informed.” - --------------------------------------------------------------------------------- - -via: http://www.newyorker.com/magazine/2014/09/08/masked-avengers - -作者:[David Kushner][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://www.newyorker.com/contributors/david-kushner diff --git a/sources/talk/20140910 Drab Desktop Try These 4 Beautiful Linux Icon Themes.md b/sources/talk/20140910 Drab Desktop Try These 4 Beautiful Linux Icon Themes.md deleted file mode 100644 index 06cd6c4f82..0000000000 --- a/sources/talk/20140910 Drab Desktop Try These 4 Beautiful Linux Icon Themes.md +++ /dev/null @@ -1,89 +0,0 @@ -Drab Desktop? Try These 4 Beautiful Linux Icon Themes -================================================================================ -**Ubuntu’s default icon theme [hasn’t changed much][1] in almost 5 years, save for the [odd new icon here and there][2]. If you’re tired of how it looks we’re going to show you a handful of gorgeous alternatives that will easily freshen things up.** - -Do feel free to share links to your own favourite choices in the comments below. - -### Captiva ### - -![Captiva icons, elementary folders and Moka GTK](http://www.omgubuntu.co.uk/wp-content/uploads/2014/09/moka-and-captiva.jpg) - -Captiva icons, elementary folders and Moka GTK - -Captiva is a relatively new icon theme that even the least bling-prone user can appreicate. - -Made by DeviantArt user ~[bokehlicia][3], Captiva shuns the 2D flat look of many current icon themes for a softer, rounded look. The icons themselves have an almost material or textured look, with subtle drop shadows and a rich colour palette adding to the charm. - -It doesn’t yet include a set of its own folder icons, and will fallback to using elementary (if available) or stock Ubuntu icons. - -To install Captiva icons in Ubuntu 14.04 you can add the official PPA by opening a new Terminal window and enter the following commands: - - sudo add-apt-repository ppa:captiva/ppa - - sudo apt-get update && sudo apt-get install captiva-icon-theme - -Or, if you’re not into software source cruft, by downloading the icon pack direct from the DeviantArt page. To install, extract the archive and move the resulting folder to the ‘.icons‘ directory in Home. - -However you choose to install it, you’ll need to apply this (and every other theme on this list) using a utility like [Unity Tweak Tool][4]. - -- [Captiva Icon Theme on DeviantArt][5] - -### Square Beam ### - -![Square Beam icon set with Orchis GTK](http://www.omgubuntu.co.uk/wp-content/uploads/2014/09/squarebeam.jpg) - -Square Beam icon set with Orchis GTK - -After something a bit angular? Check out Square Beam. It offers a more imposing visual statement than other sets on this list, with electric colours, harsh gradients and stark iconography. It claims to have more than 30,000 different icons (!) included (you’ll forgive me for not counting) so you should find very few gaps in its coverage. - -- [Square Beam Icon Theme on GNOME-Look.org][6] - -### Moka & Faba ### - -![Moka/Faba Mono Icons with Orchis GTK](http://www.omgubuntu.co.uk/wp-content/uploads/2014/09/moka-faba.jpg) - -Moka/Faba Mono Icons with Orchis GTK - -The Moka icon suite needs little introduction. In fact, I’d wager a good number of you are already using it - -With pastel colours, soft edges and simple icon artwork, Moka is a truly standout and comprehensive set of application icons. It’s best used with its sibling, Faba, which Moka will inherit so as to fill in all the system icons, folders, panel icons, etc. The combined result is…well, you’ve got eyes! - -For full details on how to install on Ubuntu head over to the official project website, link below. - -- [Download Moka and Faba Icon Themes][7] - -### Compass ### - -![Compass Icon Theme with Numix Blue GTK](http://www.omgubuntu.co.uk/wp-content/uploads/2014/09/compass1.jpg) - -Compass Icon Theme with Numix Blue GTK - -Last on our list, but by no means least, is Compass. This is a true adherent to the ’2D, two-tone’ UI design right now. It may not be as visually diverse as others on this list, but that’s the point. It’s consistent and uniform and all the better for it — just check out those folder icons! - -It’s available to download and install manually through GNOME-Look (link below) or through the Nitrux Artwork PPA: - - sudo add-apt-repository ppa:nitrux/nitrux-artwork - - sudo apt-get update && sudo apt-get install compass-icon-theme - -- [Compass Icon Theme on GNOME-Look.org][8] - --------------------------------------------------------------------------------- - -via: http://www.omgubuntu.co.uk/2014/09/4-gorgeous-linux-icon-themes-download - -作者:[Joey-Elijah Sneddon][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:https://plus.google.com/117485690627814051450/?rel=author -[1]:http://www.omgubuntu.co.uk/2010/02/lucid-gets-new-icons-for-rhythmbox-ubuntuone-memenu-more -[2]:http://www.omgubuntu.co.uk/2012/08/new-icon-theme-lands-in-lubuntu-12-10 -[3]:http://bokehlicia.deviantart.com/ -[4]:http://www.omgubuntu.co.uk/2014/06/unity-tweak-tool-0-7-development-download -[5]:http://bokehlicia.deviantart.com/art/Captiva-Icon-Theme-479302805 -[6]:http://gnome-look.org/content/show.php/Square-Beam?content=165094 -[7]:http://mokaproject.com/moka-icon-theme/download/ubuntu/ -[8]:http://gnome-look.org/content/show.php/Compass?content=160629 \ No newline at end of file diff --git a/sources/talk/20140911 5 Reasons Why I Hate GNU or Linux--Do You Hate (Love) Linux.md b/sources/talk/20140911 5 Reasons Why I Hate GNU or Linux--Do You Hate (Love) Linux.md deleted file mode 100644 index 29017fad07..0000000000 --- a/sources/talk/20140911 5 Reasons Why I Hate GNU or Linux--Do You Hate (Love) Linux.md +++ /dev/null @@ -1,100 +0,0 @@ -5 Reasons Why I Hate GNU/Linux – Do You Hate (Love) Linux? -================================================================================ -This part of Linux, I don’t like to talk very often but sometimes I do really feel some of the aspects related to Linux is real pain. Here are the five points which I come across on a daily basis, almost. - -![5 Reasons Why I Hate Linux](http://www.tecmint.com/wp-content/uploads/2014/09/I-Hate-Linux.jpg) - -5 Reasons Why I Hate Linux - -### 1. Choose from Too Many Good Distros ### - -While reading several on-line forum (a part of my hobby), I very often come across a question like – Hi, I am new to Linux, just [switched over from Windows to Linux][1]. Which Linux Distribution, I should get my hands dirty with? Oh! forgot to mention, I am an Engineering Student. - -As soon as someone posted such question, there is a flood of comments. each distribution’s fan boy tries to make sense that the distro he is using leads all the rest, a few comments may look like: - -1. Get your hands upon Linux Mint or Ubuntu, they are easy to use specially for newbies like you. -1. Ubuntu is Sh** better go with Mint. -1. If you want something like windows, better stay there. -1. Nothing is better than Debian. It is easy to use and contains all the packages you may need. -1. Slackware, for the point, if you learn slack you learn Linux. - At this point, the student who asked question really gets confused and annoyed. -1. CentOS – Nothing like this, when comes to stability. -1. I will recommend Fedora, Bleeding edge technology implementation, you will get a lot to learn. -1. Puppy Linux, SUSE, BSD, Manjaro, Megia, Kali, RedHat Beta, etc,…… - -At the end of discussion, the discussion forum may be used as a paper for research based upon the facts and figure provided in the comments. - -Now think the same in Windows or Mac – One may say are you Insane? Still using Windows XP or Vista but no one will try to prove that windows 8 is better than XP and XP is more on a User Friendly side. You won’t get a fan boy in Mac as well, who is trying to jump into the discussion just to make his point sounds louder. - -You may frequently come across points like – Distros are like religion. These things makes the newbie puzzled. Anyone who have used Linux for a considerable time would be knowing that all the distros are same at the base. It is only the working interface and the way to perform task differs and that too rarely. You are using apt, yum, portage, emerge, spike or ABS who cares as far as the things are done and user is comfortable with it. - -Well the above scenario is not only true in forums and groups on-line, it is sometimes taken to the corporate world. - -I was recently being Interviewed by a company based in Mumbai (India). The person interviewing, asked me several questions and technologies, I have worked with. As per their requirements, I have worked with nearly half of the technologies they were looking for. A few of last conversation as mentioned below. - -**Interviewer**: Do you know kernel editing? (Then he talked to himself for a couple of seconds – no, no not kernel editing, it is a very different thing.) Do you know how to compile a kernel on a monolithic side? - -**Me**: Yes, we just need to make sure what we need to run in future. We need to select those options only that supports our need before compiling the kernel. - -**Interviewer**: How do you compile a kernel? - -**Me**: make menuconfig, fire it as………..(interrupted) - -**Interviewer**: When have you compiled the kernel lastly without any help? - -**Me**: Very recently on my Debian…..(Interrupted) - -**Interviewer**: Debian? Do you know what we does? Debian-Febian is not of our use. We use CentOS. Ok, I will tell the management the result. They will call you. - -**Not to Mention**: I didn’t get the call or job, but certainly the phrase **Debian-febian** forces me to think over and over again. He could have said we don’t use Debian, we use CentOS. The tone of him, was a bit racist, it is spread-ed all over. - -### 2. Some of the very important software has no support in Linux ### - -No! I am not talking about Photoshop. I understand Linux is not build to perform such task. But some backbone softwares required to connect your Android phone to PC for Updation – PC Suite certainly means a lot. I have been looking for a windows PC. - -I know Linux is more like a server side OS. Really? Is not it trying to make a point that, it has been used as a Desktop as well? If Yes! It should have other developed desktop features. For a desktop user security, stability, RAID, Kernel does not mean much. They should get their work done with little or no effort. - -Moreover the companies like Samsung, Sony, Micromax, etc are dealing with Android (Linux) Phones and they have no support to get their phone connected over a Linux PC. - -Don’t drag me in PC suite discussion. For Linux to be a Desktop OS, it still lacks several things, Little or no gaming support – I mean high end gaming. No professional Video and Photo Editing Tools, I Said Professional. And yeah I remember Titanic and Avatar Movies were maid using some kind of FOSS video editor, I am coming to that point. - -Agree or not, Linux still has to go a long way to be a distro for everyone. - -### 3. Linuxer have a habit of living in virtual world ### - -I am a Linux user, and I am superior than you. I can handle terminal much better than you. You know Linux is Everywhere in your wrist watch, mobile phones, remote control. You know what, Hacker’s use Linux. Are you aware as soon as you boot Linux you become hacker. You can do several things from Linux you can’t even think of using Windows and Mac. - -Let me tell you, Linux is now being used in International Space Station. The world’s most successful movies Avatar and Titanic were build using Linux. Last but not the least, world’s 90% supercomputers are using Linux. World’s Top 5 fastest computer are using Linux. Facebook, Linkedin, Google, Yahoo all have their server based on Linux. - -I don’t mean they are wrong. I only mean they keeps on talking about the thing they very little know about. - -### 4. The long hours of compilation and dependency resolution ### - -I am aware of automatic dependency resolution and the program getting smart day by day. Still think from corporate view, I was installing a program say ‘y‘, it had one dependency say ‘**x**‘ which was unable to be resolved automatically. While resolving ‘**x**‘ I came across 8 other dependency, a few of other were dependent on a few other libraries and program. Isn’t it painful? - -The rule of corporate is to have the work done efficiently with less man power and as much less time as possible. Who cares if your piece of codes are coming from Windows or Mac or Linux as far as the work is done. - -### 5. Too much manual work ### - -No matter which distro you choose, you have to manually do a lot a things time-to-time. Lets say you are installing proprietary Nvidia Driver. Now you need to kill **X** manually, may need to edit **Xorg.conf** manually and still may have a broken **X**. Furthermore, you have to make sure that the next time kernel updates, it still be in working condition. - -Think of same on Windows. You have nothing to do other than firing the executables and click** Next, Next, I Agree, Next, Forward, Finish, Reboot** and your system may very rarely have broken GUI. Though the demerit is a broken GUI is not possible to be repaired on Windows but easily on Linux. - -Hey don’t tell me its because of security implementation. If you are installing something using ‘**root**‘, and still needs a lot of things done manually that not security. Some may have a point that it gives you power to configure your system to any extent. My friend at least give him a working interface from where he can configure it to next best level. Why Installer laves him to re-invent the wheel every-time in the name of security and configurability. - -I myself is a Linux fan and have been working on this platform for nearly half a decades. I myself have used Distros of several kind and came to the above conclusion. You may have used a different distro’s and might you’ve came to a such conclusion, where you feel that Linux is not upto the mark. - -Please do share with us, why do you hate (Love) Linux? via our comment section below. - --------------------------------------------------------------------------------- - -via: http://www.tecmint.com/why-i-hate-linux/ - -作者:[Avishek Kumar][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://www.tecmint.com/author/avishek/ -[1]:http://www.tecmint.com/useful-linux-commands-for-newbies/ \ No newline at end of file diff --git a/sources/talk/20140912 What' s wrong with IPv4 and Why we are moving to IPv6.md b/sources/talk/20140912 What' s wrong with IPv4 and Why we are moving to IPv6.md deleted file mode 100644 index 1289613263..0000000000 --- a/sources/talk/20140912 What' s wrong with IPv4 and Why we are moving to IPv6.md +++ /dev/null @@ -1,86 +0,0 @@ -What’s wrong with IPv4 and Why we are moving to IPv6 -================================================================================ -For the past 10 years or so, this has been the year that IPv6 will become wide spread. It hasn’t happened yet. Consequently, there is little widespread knowledge of what IPv6 is, how to use it, or why it is inevitable. - -![IPv4 and IPv6 Comparison](http://www.tecmint.com/wp-content/uploads/2014/09/ipv4-ipv6.gif) - -IPv4 and IPv6 Comparison - -### What’s wrong with IPv4? ### - -We’ve been using **IPv4** ever since RFC 791 was published in 1981. At the time, computers were big, expensive, and rare. IPv4 had provision for **4 billion IP** addresses, which seemed like an enormous number compared to the number of computers. Unfortunately, IP addresses are not use consequently. There are gaps in the addressing. For example, a company might have an address space of **254 (2^8-2)** addresses, and only use 25 of them. The remaining 229 are reserved for future expansion. Those addresses cannot be used by anybody else, because of the way networks route traffic. Consequently, what seemed like a large number in 1981 is actually a small number in 2014. - -The Internet Engineering Task Force (**IETF**) recognized this problem in the early 1990s and came up with two solutions: Classless Internet Domain Router (**CIDR**) and private IP addresses. Prior to the invention of CIDR, you could get one of three network sizes: **24 bits** (16,777,214 addresses), **20 bits** (1,048,574 addresses) and **16 bits** (65,534 addresses). Once CIDR was invented, it was possible to split networks into subnetworks. - -So, for example, if you needed **5 IP** addresses, your ISP would give you a network with a size of 3 bits which would give you **6 IP** addresses. So that would allow your ISP to use addresses more efficiently. Private IP addresses allow you to create a network where each machine on the network can easily connect to another machine on the internet, but where it is very difficult for a machine on the internet to connect back to your machine. Your network is private, hidden. Your network could be very large, 16,777,214 addresses, and you could subnet your private network into smaller networks, so that you could manage your own addresses easily. - -You are probably using a private address right now. Check your own IP address: if it is in the range of **10.0.0.0 – 10.255.255.255** or **172.16.0.0 – 172.31.255.255** or **192.168.0.0 – 192.168.255.255**, then you are using a private IP address. These two solutions helped forestall disaster, but they were stopgap measures and now the time of reckoning is upon us. - -Another problem with **IPv4** is that the IPv4 header was variable length. That was acceptable when routing was done by software. But now routers are built with hardware, and processing the variable length headers in hardware is hard. The large routers that allow packets to go all over the world are having problems coping with the load. Clearly, a new scheme was needed with fixed length headers. - -Still another problem with **IPv4** is that, when the addresses were allocated, the internet was an American invention. IP addresses for the rest of the world are fragmented. A scheme was needed to allow addresses to be aggregated somewhat by geography so that the routing tables could be made smaller. - -Yet another problem with IPv4, and this may sound surprising, is that it is hard to configure, and hard to change. This might not be apparent to you, because your router takes care of all of these details for you. But the problems for your ISP drives them nuts. - -All of these problems went into the consideration of the next version of the Internet. - -### About IPv6 and its Features ### - -The **IETF** unveiled the next generation of IP in December 1995. The new version was called IPv6 because the number 5 had been allocated to something else by mistake. Some of the features of IPv6 included. - -- 128 bit addresses (3.402823669×10³⁸ addresses) -- A scheme for logically aggregating addresses -- Fixed length headers -- A protocol for automatically configuring and reconfiguring your network. - -Let’s look at these features one by one: - -#### Addresses #### - -The first thing everybody notices about **IPv6** is that the number of addresses is enormous. Why so many? The answer is that the designers were concerned about the inefficient organization of addresses, so there are so many available addresses that we could allocate inefficiently in order to achieve other goals. So, if you want to build your own IPv6 network, chances are that your ISP will give you a network of **64 bits** (1.844674407×10¹⁹ addresses) and let you subnet that space to your heart’s content. - -#### Aggregation #### - -With so many addresses to use, the address space can be allocated sparsely in order to route packets efficiently. So, your ISP gets a network space of **80 bits**. Of those 80 bits, 16 of them are for the ISPs subnetworks, and 64 bits are for the customer’s networks. So, the ISP can have 65,534 networks. - -However, that address allocation isn’t cast in stone, and if the ISP wants more smaller networks, it can do that (although probably the ISP would probably simply ask for another space of 80 bits). The upper 48 bits is further divided, so that ISPs that are “**close**” to one another have similar network addresses ranges, to allow the networks to be aggregated in the routing tables. - -#### Fixed length Headers #### - -An **IPv4** header has a variable length. An **IPv6** header always has a fixed length of 40 bytes. In IPv4, extra options caused the header to increase in size. In IPv6, if additional information is needed, that additional information is stored in extension headers, which follow the IPv6 header and are generally not processed by the routers, but rather by the software at the destination. - -One of the fields in the IPv6 header is the flow. A flow is a **20 bit** number which is created pseudo-randomly, and it makes it easier for the routers to route packets. If a packet has a flow, then the router can use that flow number as an index into a table, which is fast, rather than a table lookup, which is slow. This feature makes **IPv6** very easy to route. - -#### Automatic Configuration #### - -In **IPv6**, when a machine first starts up, it checks the local network to see if any other machine is using its address. If the address is unused, then the machine next looks for an IPv6 router on the local network. If it finds the router, then it asks the router for an IPv6 address to use. Now, the machine is set and ready to communicate on the internet – it has an IP address for itself and it has a default router. - -If the router should go down, then the machines on the network will detect the problem and repeat the process of looking for an IPv6 router, to find the backup router. That’s actually hard to do in IPv4. Similarly, if the router wants to change the addressing scheme on its network, it can. The machines will query the router from time to time and change their addresses automatically. The router will support both the old and new addresses until all of the machines have switched over to the new configuration. - -IPv6 automatic configuration is not a complete solution. There are some other things that a machine needs in order to use the internet effectively: the name servers, a time server, perhaps a file server. So there is **dhcp6** which does the same thing as dhcp, only because the machine boots in a routable state, one dhcp daemon can service a large number of networks. - -#### There’s one big problem #### - -So if IPv6 is so much better than IPv4, why hasn’t adoption been more widespread (as of **May 2014**, Google estimates that its IPv6 traffic is about **4%** of its total traffic)? The basic problem is which comes first, the **chicken or the egg**? Somebody running a server wants the server to be as widely available as possible, which means it must have an **IPv4** address. - -It could also have an IPv6 address, but few people would use it and you do have to change your software a little to accommodate IPv6. Furthermore, a lot of home networking routers do not support IPv6. A lot of ISPs do not support IPv6. I asked my ISP about it, and I was told that they will provide it when customers ask for it. So I asked how many customers had asked for it. One, including me. - -By way of contrast, all of the major operating systems, Windows, OS X, and Linux support IPv6 “**out of the box**” and have for years. The operating systems even have software that will allow IPv6 packets to “**tunnel**” within IPv4 to a point where the IPv6 packets can be removed from the surrounding IPv4 packet and sent on their way. - -#### Conclusion #### - -IPv4 has served us well for a long time. IPv4 has some limitations which are going to present insurmountable problems in the near future. IPv6 will solve those problems by changing the strategy for allocating addresses, making improvements to ease the routing of packets, and making it easier to configure a machine when it first joins the network. - -However, acceptance and usage of IPv6 has been slow, because change is hard and expensive. The good news is that all operating systems support IPv6, so when you are ready to make the change, your computer will need little effort to convert to the new scheme. - --------------------------------------------------------------------------------- - -via: http://www.tecmint.com/ipv4-and-ipv6-comparison/ - -作者:[Jeff Silverman][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://www.tecmint.com/author/jeffsilverm/ \ No newline at end of file diff --git a/sources/talk/20140915 10 Open Source Cloning Software For Linux Users.md b/sources/talk/20140915 10 Open Source Cloning Software For Linux Users.md new file mode 100644 index 0000000000..e96b5c37f5 --- /dev/null +++ b/sources/talk/20140915 10 Open Source Cloning Software For Linux Users.md @@ -0,0 +1,87 @@ +10 Open Source Cloning Software For Linux Users +================================================================================ +> These cloning software take all disk data, convert them into a single .img file and you can copy it to another hard drive. + +![](http://1-ps.googleusercontent.com/h/www.efytimes.com/admin/useradmin/photo/150x150x1Qn740810PM9112014.jpg.pagespeed.ic.Ch7q5vT9Yg.jpg) + +Disk cloning means copying data from a hard disk to another one and you can do this by simple copy & paste. But you cannot copy the hidden files and folders and not the in-use files too. That's when you need a cloning software which can also help you in saving a back-up image from your files and folders. The cloning software takes all disk data, convert them into a single .img file and you can copy it to another hard drive. Here we give you the best 10 Open Source Cloning software: + +### 1. [Clonezilla][1]: ### + +Clonezilla is a Live CD based on Ubuntu and Debian. It clones all your hard drive data and take a backup just like Norton Ghost on Windows but in a more effective way. Clonezilla support many filesystems like ext2, ext3, ext4, btrfs, xfs and others. It also supports BIOS, UEFI, MPR and GPT partitions. + +![](http://1-ps.googleusercontent.com/h/www.efytimes.com/admin/useradmin/rte/my_documents/my_pictures/600x450xZ34_clonezilla-600x450.png.pagespeed.ic.8Jq7pL2dwo.png) + +### 2. [Redo Backup][2]: ### + +Redo Bakcup is another Live CD tool which clones your drivers easily. It is free and Open Source Live System which has its licence under GPL 3. Its main features include easy GUI boots from CD, no installation, restoration of Linux and Windows systems, access to files with out any log-in, recovery of deleted files and more. + +![](http://1-ps.googleusercontent.com/h/www.efytimes.com/admin/useradmin/rte/my_documents/my_pictures/600x450x7D5_Redo-Backup-600x450.jpeg.pagespeed.ic.3QMikN07F5.jpg) + +### 3. [Mondo Rescue][3]: ### + +Mondo doesn't work like other software. It doesn’t convert your hard drivers into an .img file. It converts them into an .iso image and with Mondo you can also create a custom Live CD using “mindi” which is a special tool developed by Mondo Rescue to clone your data from the Live CD. It supports most Linux distributions, FreeBSD, and it is licensed under GPL. + +![](http://1-ps.googleusercontent.com/h/www.efytimes.com/admin/useradmin/rte/my_documents/my_pictures/620x387x3C4_MondoRescue-620x387.jpeg.pagespeed.ic.cqVh7nbMNt.jpg) + +### 4. [Partimage][4]: ### + +This is an open-source software backup, which works under Linux system, by default. It's also available to install from the package manager for most Linux distributions and if you don’t have a Linux system then you can use “SystemRescueCd”. It is a Live CD which includes Partimage by default to do the cloning process that you want. Partimage is very fast in cloning hard drivers. + +![](http://1-ps.googleusercontent.com/h/www.efytimes.com/admin/useradmin/rte/my_documents/my_pictures/620x424xBZF_partimage-620x424.png.pagespeed.ic.ygzrogRJgE.png) + +### 5. [FSArchiver][5]: ### + +FSArchiver is a follow-up to Partimage, and it is again a good tool to clone hard disks. It supports cloning Ext4 partitions and NTFS partitions, basic file attributes like owner, permissions, extended attributes like those used by SELinux, basic file system attributes for all Linux file systems and so on. + +### 6. [Partclone][6]: ### + +Partclone is a free tool which clones and restores partitions. Written in C it first appeared in 2007 and it supports many filesystems like ext2, ext3, ext4, xfs, nfs, reiserfs, reiser4, hfs+, btrfs. It is very simple to use and it's licensed under GPL. + +### 7. [doClone][7]: ### + +doClone is a free software project which is developed to clone Linux system partitions easily. It's written in C++ and it supports up to 12 different filesystems. It can preform Grub bootloader restoration and can also transform the clone image to another computer via LAN. It also provides support to live cloning which means you will eb able to clone from the system even if it's running. + +![](http://1-ps.googleusercontent.com/h/www.efytimes.com/admin/useradmin/rte/my_documents/my_pictures/620x396x2A6_doClone-620x396.jpeg.pagespeed.ic.qhimTILQPI.jpg) + +### 8. [Macrium Reflect Free Edition][8]: ### + +Macrium Reflect Free Edition is claimed to be one of the fastest disk cloning utilities which supports only Windows file systems. It is a fairly straightforward user interface. This software does disk imaging and disk cloning and also allows you to access images from the file manager. It allows you to create a Linux rescue CD and it is compatible with Windows Vista and 7. + +![](http://1-ps.googleusercontent.com/h/www.efytimes.com/admin/useradmin/rte/my_documents/my_pictures/620x464xD1E_open1.jpg.pagespeed.ic.RQ41AyMCFx.png) + +### 9. [DriveImage XML][9]: ### + +DriveImage XML uses Microsoft VSS for creation of images, quite reliably. With this software you can create "hot" images from a disk, which is still running. XML files store images, which means you can access them from any supporting third-party software. DriveImage XML also allows restoring an image to a machine without any reboot. This software is also compatible with Windows XP, Windows Server 2003, Vista, and 7. + +![](http://1-ps.googleusercontent.com/h/www.efytimes.com/admin/useradmin/rte/my_documents/my_pictures/620x475x357_open2.jpg.pagespeed.ic.50ipbFWsa2.jpg) + +### 10. [Paragon Backup & Recovery Free][10]: ### + +Paragon Backup & Recovery Free does a great job when it comes to managing scheduled imaging. This is a free software but it's for personal use only. + +![](http://1-ps.googleusercontent.com/h/www.efytimes.com/admin/useradmin/rte/my_documents/my_pictures/600x536x9Z9_open3.jpg.pagespeed.ic.9rDHp0keFw.png) + + + + +-------------------------------------------------------------------------------- + +via: http://www.efytimes.com/e1/fullnews.asp?edid=148039 + +作者:Sanchari Banerjee +译者:[译者ID](https://github.com/译者ID) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[1]:http://clonezilla.org/ +[2]:http://redobackup.org/ +[3]:http://www.mondorescue.org/ +[4]:http://www.partimage.org/Main_Page +[5]:http://www.fsarchiver.org/Main_Page +[6]:http://www.partclone.org/ +[7]:http://doclone.nongnu.org/ +[8]:http://www.macrium.com/reflectfree.aspx +[9]:http://www.runtime.org/driveimage-xml.htm +[10]:http://www.paragon-software.com/home/br-free/ \ No newline at end of file diff --git a/sources/talk/20140928 What is a good subtitle editor on Linux.md b/sources/talk/20140928 What is a good subtitle editor on Linux.md new file mode 100644 index 0000000000..85038a88fc --- /dev/null +++ b/sources/talk/20140928 What is a good subtitle editor on Linux.md @@ -0,0 +1,66 @@ +barney-ro translating + +What is a good subtitle editor on Linux +================================================================================ +If you watch foreign movies regularly, chances are you prefer having subtitles rather than the dub. Grown up in France, I know that most Disney movies during my childhood sounded weird because of the French dub. If now I have the chance to be able to watch them in their original version, I know that for a lot of people subtitles are still required. And I surprise myself sometimes making subtitles for my family. Hopefully for me, Linux is not devoid of fancy and open source subtitle editors. In short, this is the non-exhaustive list of open source subtitle editors for Linux. Share your opinion on what you think of the best subtitle editor. + +### 1. Gnome Subtitles ### + +![](https://farm6.staticflickr.com/5596/15323769611_59bc5fb4b7_z.jpg) + +[Gnome Subtitles][2] is a bit my go to when it comes to quickly editing some existing subtitles. You can load the video, load the subtitle text files and instantly get going. I appreciate its balance between ease of use and advanced features. It comes with a synchronization tool as well as a spell check. Finally, last but not least, the shortcuts are what makes it good in the end: when you edit a lot of lines, you prefer to keep your hands on the keyboard, and use the built in shortcuts to move around. + +### 2. Aegisub ### + +![](https://farm3.staticflickr.com/2944/15323964121_59e9b26ba5_z.jpg) + +[Aegisub][2] is already one level of complexity higher. Just the interface reflects a learning curve. But besides its intimidating aspect, Aegisub is very complete software, providing tools beyond anything I could have imagined before. Like Gnome Subtitles, Aegisub has a WYSIWYG approach, but to a whole new level: it is possible to drag and drop the subtitles on the screen, see the audio spectrum on the side, and do everything with shortcuts. In addition to that, it comes with a Kanji tool, a karaoke mode, and the possibility to import lua script to automate some tasks. I really invite you to go read the [manual page][3] before starting using it. + +### 3. Gaupol ### + +![](https://farm3.staticflickr.com/2942/15326817292_6702cc63fc_z.jpg) + +At the other end of the complexity spectrum is [Gaupol][4]. Unlike Aegisub, Gaupol is quick to pick up and adopts an interface very close to Gnome Subtitles. But behind this relative simplicity, it comes with all the necessary tools: shortcuts, third party extension, spell checking, and even speech recognition (courtesy of [CMU Sphinx][5]). As a downside, however, I did notice some slow-downs while testing it, nothing too serious, but just enough to make me prefer Gnome Subtitles still. + +### 4. Subtitle Editor ### + +![](https://farm4.staticflickr.com/3914/15323911521_8e33126610_z.jpg) + +[Subtitle Editor][6] is very close to Gaupol. However, the interface is a little bit less intuitive, and the features are slightly more advanced. I appreciate the possibility to define "key frames" and all the given synchronization options. However, maybe more icons and less text would enhance the interface. As a goodie, Subtitle Editor can simulate a "type writer" effect, while I am not sure if it is extremely useful. And last but not least, the possibility to redefine the shortcuts is always handy. + +### 5. Jubler ### + +![](https://farm4.staticflickr.com/3912/15323769701_3d94ca8884_z.jpg) + +Written in Java, [Jubler][7] is a multi-platform subtitle editor. I was actually very impressed by its interface. I definitely see the Java-ish aspect of it, but it remains well conceived and clear. Like Aegisub, you can drag and drop the subtitles on the image, making the experience far more pleasant than just typing. It is also possible to define a style for subtitles, play sound from another track, translate the subtitles, or use the spell checker. However, be careful as you will need MPlayer installed and correctly configured beforehand if you want to use Jubler fully. Oh and I give it a special credit for its easy installation process after downloading the script from the [official page][8]. + +### 6. Subtitle Composer ### + +![](https://farm6.staticflickr.com/5578/15323769711_6c6dfbe405_z.jpg) + +Defined as a "KDE subtitle composer," [Subtitle Composer][9] comes with most of the traditional features evoked previously, but with the KDE interface that we expect. This comes naturally with the option to redefine the shortcuts, which is very dear to me. But beyond all of this, what differentiates Subtitle Composer from all the previously mentioned programs is its ability to follow scripts written in JavaScript, Python, and even Ruby. A few examples are packaged with the software, and will definitely help you pick up the syntax and the usefulness of such feature. + +To conclude, whether you, like me, just edit a few subtitles for your family, re-synchronize the entire track, or write everything from scratch, Linux has the tools for you. For me in the end, the shortcuts and the ease-of-use make all the difference, but for any higher usage, scripting or speech recognition can become super handy. + +Which subtitle editor do you use and why? Or is there another one that you prefer not mentioned here? Let us know in the comments. + +-------------------------------------------------------------------------------- + +via: http://xmodulo.com/good-subtitle-editor-linux.html + +作者:[Adrien Brochard][a] +译者:[barney-ro](https://github.com/barney-ro) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://xmodulo.com/author/adrien +[1]:http://gnomesubtitles.org/ +[2]:http://www.aegisub.org/ +[3]:http://docs.aegisub.org/3.2/Main_Page/ +[4]:http://home.gna.org/gaupol/ +[5]:http://cmusphinx.sourceforge.net/ +[6]:http://home.gna.org/subtitleeditor/ +[7]:http://www.jubler.org/ +[8]:http://www.jubler.org/download.html +[9]:http://sourceforge.net/projects/subcomposer/ diff --git a/sources/talk/20140929 Shellshock--How to protect your Unix, Linux and Mac servers.md b/sources/talk/20140929 Shellshock--How to protect your Unix, Linux and Mac servers.md new file mode 100644 index 0000000000..94cc23fb5d --- /dev/null +++ b/sources/talk/20140929 Shellshock--How to protect your Unix, Linux and Mac servers.md @@ -0,0 +1,100 @@ +Shellshock: How to protect your Unix, Linux and Mac servers +================================================================================ +> **Summary**: The Unix/Linux Bash security hole can be deadly to your servers. Here's what you need to worry about, how to see if you can be attacked, and what to do if your shields are down. + +The only thing you have to fear with [Shellshock, the Unix/Linux Bash security hole][1], is fear itself. Yes, Shellshock can serve as a highway for worms and malware to hit your Unix, Linux, and Mac servers, but you can defend against it. + +![](http://cdn-static.zdnet.com/i/r/story/70/00/034072/cybersecurity-v1-620x464.jpg?hash=BQMxZJWuZG&upscale=1) + +If you don't patch and defend yourself against Shellshock today, you may have lost control of your servers by tomorrow. + +However, Shellshock is not as bad as [HeartBleed][2]. Not yet, anyway. + +While it's true that the [Bash shell][3] is the default command interpreter on most Unix and Linux systems and all Macs — the majority of Web servers — for an attacker to get to your system, there has to be a way for him or her to actually get to the shell remotely. So, if you're running a PC without [ssh][4], [rlogin][5], or another remote desktop program, you're probably safe enough. + +A more serious problem is faced by devices that use embedded Linux — such as routers, switches, and appliances. If you're running an older, no longer supported model, it may be close to impossible to patch it and will likely be vulnerable to attacks. If that's the case, you should replace as soon as possible. + +The real and present danger is for servers. According to the National Institute of Standards (NIST), [Shellshock scores a perfect 10][6] for potential impact and exploitability. [Red Hat][7] reports that the most common attack vectors are: + +- **httpd (Your Web server)**: CGI [Common-Gateway Interface] scripts are likely affected by this issue: when a CGI script is run by the web server, it uses environment variables to pass data to the script. These environment variables can be controlled by the attacker. If the CGI script calls Bash, the script could execute arbitrary code as the httpd user. mod_php, mod_perl, and mod_python do not use environment variables and we believe they are not affected. +- **Secure Shell (SSH)**: It is not uncommon to restrict remote commands that a user can run via SSH, such as rsync or git. In these instances, this issue can be used to execute any command, not just the restricted command. +- **dhclient**: The [Dynamic Host Configuration Protocol Client (dhclient)][8] is used to automatically obtain network configuration information via DHCP. This client uses various environment variables and runs Bash to configure the network interface. Connecting to a malicious DHCP server could allow an attacker to run arbitrary code on the client machine. +- **[CUPS][9] (Linux, Unix and Mac OS X's print server)**: It is believed that CUPS is affected by this issue. Various user-supplied values are stored in environment variables when cups filters are executed. +- **sudo**: Commands run via sudo are not affected by this issue. Sudo specifically looks for environment variables that are also functions. It could still be possible for the running command to set an environment variable that could cause a Bash child process to execute arbitrary code. +- **Firefox**: We do not believe Firefox can be forced to set an environment variable in a manner that would allow Bash to run arbitrary commands. It is still advisable to upgrade Bash as it is common to install various plug-ins and extensions that could allow this behavior. +- **Postfix**: The Postfix [mail] server will replace various characters with a ?. While the Postfix server does call Bash in a variety of ways, we do not believe an arbitrary environment variable can be set by the server. It is however possible that a filter could set environment variables. + +So much for Red Hat's thoughts. Of these, the Web servers and SSH are the ones that worry me the most. The DHCP client is also troublesome, especially if, as it the case with small businesses, your external router doubles as your Internet gateway and DHCP server. + +Of these, Web server attacks seem to be the most common by far. As Florian Weimer, a Red Hat security engineer, wrote: "[HTTP requests to CGI scripts][10] have been identified as the major attack vector." Attacks are being made against systems [running both Linux and Mac OS X][11]. + +Jaime Blasco, labs director at [AlienVault][12], a security management services company, ran a [honeypot][13] looking for attackers and found "[several machines trying to exploit the Bash vulnerability][14]. The majority of them are only probing to check if systems are vulnerable. On the other hand, we found two worms that are actively exploiting the vulnerability and installing a piece of malware on the system." + +Other security researchers have found that the malware is the usual sort. They typically try to plant distributed denial of service (DDoS) IRC bots and attempt to guess system logins and passwords using a list of poor passwords such as 'root', 'admin', 'user', 'login', and '123456.' + +So, how do you know if your servers can be attacked? First, you need to check to see if you're running a vulnerable version of Bash. To do that, run the following command from a Bash shell: + +env x='() { :;}; echo vulnerable' bash -c "echo this is a test" + +If you get the result: + +*vulnerable this is a test* + +Bad news, your version of Bash can be hacked. If you see: + +*bash: warning: x: ignoring function definition attempt bash: error importing function definition for `x' this is a test* + +You're good. Well, to be more exact, you're as protected as you can be at the moment. + +While all major Linux distributors have released patches that stop most attacks — [Apple has not released a patch yet][15] — it has been discovered that "[patches shipped for this issue are incomplete][16]. An attacker can provide specially-crafted environment variables containing arbitrary commands that will be executed on vulnerable systems under certain conditions." While it's unclear if these attacks can be used to hack into a system, it is clear that they can be used to crash them, thanks to a null-pointer exception. + +Patches to fill-in the [last of the Shellshock security hole][17] are being worked on now. In the meantime, you should update your servers as soon as possible with the available patches and keep an eye open for the next, fuller ones. + +In the meantime, if, as is likely, you're running the Apache Web server, there are some [Mod_Security][18] rules that can stop attempts to exploit Shellshock. These rules, created by Red Hat, are: + + Request Header values: + SecRule REQUEST_HEADERS "^\(\) {" "phase:1,deny,id:1000000,t:urlDecode,status:400,log,msg:'CVE-2014-6271 - Bash Attack'" + + SERVER_PROTOCOL values: + SecRule REQUEST_LINE "\(\) {" "phase:1,deny,id:1000001,status:400,log,msg:'CVE-2014-6271 - Bash Attack'" + + GET/POST names: + SecRule ARGS_NAMES "^\(\) {" "phase:2,deny,id:1000002,t:urlDecode,t:urlDecodeUni,status:400,log,msg:'CVE-2014-6271 - Bash Attack'" + + GET/POST values: + SecRule ARGS "^\(\) {" "phase:2,deny,id:1000003,t:urlDecode,t:urlDecodeUni,status:400,log,msg:'CVE-2014-6271 - Bash Attack'" + + File names for uploads: + SecRule FILES_NAMES "^\(\) {" "phase:2,deny,id:1000004,t:urlDecode,t:urlDecodeUni,status:400,log,msg:'CVE-2014-6271 - Bash Attack'" + +It is vital that you patch your servers as soon as possible, even with the current, incomplete ones, and to set up defenses around your Web servers. If you don't, you could come to work tomorrow to find your computers completely compromised. So get out there and start patching! + +-------------------------------------------------------------------------------- + +via: http://www.zdnet.com/shellshock-how-to-protect-your-unix-linux-and-mac-servers-7000034072/ + +作者:[Steven J. Vaughan-Nichols][a] +译者:[译者ID](https://github.com/译者ID) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://www.zdnet.com/meet-the-team/us/steven-j-vaughan-nichols/ +[1]:http://www.zdnet.com/unixlinux-bash-critical-security-hole-uncovered-7000034021/ +[2]:http://www.zdnet.com/heartbleed-serious-openssl-zero-day-vulnerability-revealed-7000028166 +[3]:http://www.gnu.org/software/bash/ +[4]:http://www.openbsd.org/cgi-bin/man.cgi?query=ssh&sektion=1 +[5]:http://unixhelp.ed.ac.uk/CGI/man-cgi?rlogin +[6]:http://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2014-7169 +[7]:http://www.redhat.com/ +[8]:http://www.isc.org/downloads/dhcp/ +[9]:https://www.cups.org/ +[10]:http://seclists.org/oss-sec/2014/q3/650 +[11]:http://www.zdnet.com/first-attacks-using-shellshock-bash-bug-discovered-7000034044/ +[12]:http://www.alienvault.com/ +[13]:http://www.sans.org/security-resources/idfaq/honeypot3.php +[14]:http://www.alienvault.com/open-threat-exchange/blog/attackers-exploiting-shell-shock-cve-2014-6721-in-the-wild +[15]:http://apple.stackexchange.com/questions/146849/how-do-i-recompile-bash-to-avoid-the-remote-exploit-cve-2014-6271-and-cve-2014-7 +[16]:https://bugzilla.redhat.com/show_bug.cgi?id=1141597#c27 +[17]:http://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2014-7169 +[18]:http://www.inmotionhosting.com/support/website/modsecurity/what-is-modsecurity-and-why-is-it-important \ No newline at end of file diff --git a/sources/talk/20140929 What Linux Users Should Know About Open Hardware.md b/sources/talk/20140929 What Linux Users Should Know About Open Hardware.md new file mode 100644 index 0000000000..2816764239 --- /dev/null +++ b/sources/talk/20140929 What Linux Users Should Know About Open Hardware.md @@ -0,0 +1,66 @@ +zpl1025 +What Linux Users Should Know About Open Hardware +================================================================================ +> What Linux users don't know about manufacturing open hardware can lead them to disappointment. + +Business and free software have been intertwined for years, but the two often misunderstand one another. That's not surprising -- what is just a business to one is way of life for the other. But the misunderstanding can be painful, which is why debunking it is a worth the effort. + +An increasingly common case in point: the growing attempts at open hardware, whether from Canonical, Jolla, MakePlayLive, or any of half a dozen others. Whether pundit or end-user, the average free software user reacts with exaggerated enthusiasm when a new piece of hardware is announced, then retreats into disillusionment as delay follows delay, often ending in the cancellation of the entire product. + +It's a cycle that does no one any good, and often breeds distrust – and all because the average Linux user has no idea what's happening behind the news. + +My own experience with bringing products to market is long behind me. However, nothing I have heard suggests that anything has changed. Bringing open hardware or any other product to market remains not just a brutal business, but one heavily stacked against newcomers. + +### Searching for Partners ### + +Both the manufacturing and distribution of digital products is controlled by a relatively small number of companies, whose time can sometimes be booked months in advance. Profit margins can be tight, so like movie studios that buy the rights to an ancient sit-com, the manufacturers usually hope to clone the success of the latest hot product. As Aaron Seigo told me when talking about his efforts to develop the Vivaldi tablet, the manufacturers would much rather prefer someone else take the risk of doing anything new. + +Not only that, but they would prefer to deal with someone with an existing sales record who is likely to bring repeat business. + +Besides, the average newcomer is looking at a product run of a few thousand units. A chip manufacturer would much rather deal with Apple or Samsung, whose order is more likely in the hundreds of thousands. + +Faced with this situation, the makers of open hardware are likely to find themselves cascading down into the list of manufacturers until they can find a second or third tier manufacturer that is willing to take a chance on a small run of something new. + +They might be reduced to buying off-the-shelf components and assembling units themselves, as Seigo tried with Vivaldi. Alternatively, they might do as Canonical did, and find established partners that encourage the industry to take a gamble. Even if they succeed, they have usually taken months longer than they expected in their initial naivety. + +### Staggering to Market ### + +However, finding a manufacturer is only the first obstacle. As Raspberry Pi found out, even if the open hardware producers want only free software in their product, the manufacturers will probably insist that firmware or drivers stay proprietary in the name of protecting trade secrets. + +This situation is guaranteed to set off criticism from potential users, but the open hardware producers have no choice except to compromise their vision. Looking for another manufacturer is not a solution, partly because to do so means more delays, but largely because completely free-licensed hardware does not exist. The industry giants like Samsung have no interest in free hardware, and, being new, the open hardware producers have no clout to demand any. + +Besides, even if free hardware was available, manufacturers could probably not guarantee that it would be used in the next production run. The producers might easily find themselves re-fighting the same battle every time they needed more units. + +As if all this is not enough, at this point the open hardware producer has probably spent 6-12 months haggling. The chances are, the industry standards have shifted, and they may have to start from the beginning again by upgrading specs. + +### A Short and Brutal Shelf Life ### + +Despite these obstacles, hardware with some degree of openness does sometimes get released. But remember the challenges of finding a manufacturer? They have to be repeated all over again with the distributors -- and not just once, but region by region. + +Typically, the distributors are just as conservative as the manufacturers, and just as cautious about dealing with newcomers and new ideas. Even if they agree to add a product to their catalog, the distributors can easily decide not to encourage their representatives to promote it, which means that in a few months they have effectively removed it from the shelves. + +Of course, online sales are a possibility. But meanwhile, the hardware has to be stored somewhere, adding to the cost. Production runs on demand are expensive even in the unlikely event that they are available, and even unassembled units need storage. + +### Weighing the Odds ### + +I have been generalizing wildly here, but anyone who has ever been involved in producing anything will recognize what I am describing as the norm. And just to make matters worse, open hardware producers typically discover the situation as they are going through it. Inevitably, they make mistakes, which adds still more delays. + +But the point is, if you have any sense of the process at all, your knowledge is going to change how you react to news of another attempt at hardware. The process means that, unless a company has been in serious stealth mode, an announcement that a product will be out in six months will rapidly prove to be an outdate guestimate. 12-18 months is more likely, and the obstacles I describe may mean that the product will never actually be released. + +For example, as I write, people are waiting for the emergence of the first Steam Machines, the Linux-based gaming consoles. They are convinced that the Steam Machines will utterly transform both Linux and gaming. + +As a market category, Steam Machines may do better than other new products, because those who are developing them at least have experience developing software products. However, none of the dozen or so Steam Machines in development have produced more than a prototype after almost a year, and none are likely to be available for buying until halfway through 2015. Given the realities of hardware manufacturing, we will be lucky if half of them see daylight. In fact, a release of 2-4 might be more realistic. + +I make that prediction with next to no knowledge of any of the individual efforts. But, having some sense of how hardware manufacturing works, I suspect that it is likely to be closer to what happens next year than all the predictions of a new Golden Age for Linux and gaming. I would be entirely happy being wrong, but the fact remains: what is surprising is not that so many Linux-associated hardware products fail, but that any succeed even briefly. + +-------------------------------------------------------------------------------- + +via: http://www.datamation.com/open-source/what-linux-users-should-know-about-open-hardware-1.html + +作者:[Bruce Byfield][a] +译者:[译者ID](https://github.com/译者ID) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://www.datamation.com/author/Bruce-Byfield-6030.html diff --git a/sources/talk/The history of Android/07 - The history of Android.md b/sources/talk/The history of Android/07 - The history of Android.md deleted file mode 100644 index 2be62866ad..0000000000 --- a/sources/talk/The history of Android/07 - The history of Android.md +++ /dev/null @@ -1,109 +0,0 @@ -The history of Android -================================================================================ -![Both screens of the Email app. The first two screenshots show the combined label/inbox view, and the last shows a message.](http://cdn.arstechnica.net/wp-content/uploads/2014/01/email2lol.png) -Both screens of the Email app. The first two screenshots show the combined label/inbox view, and the last shows a message. -Photo by Ron Amadeo - -The message view was—surprise!—white. Android's e-mail app has historically been a watered-down version of the Gmail app, and you can see that close connection here. The message and compose views were taken directly from Gmail with almost no modifications. - -![The “IM" applications. Screenshots show the short-lived provider selection screen, the friends list, and a chat.](http://cdn.arstechnica.net/wp-content/uploads/2013/12/IM2.png) -The “IM" applications. Screenshots show the short-lived provider selection screen, the friends list, and a chat. -Photo by Ron Amadeo - -Before Google Hangouts and even before Google Talk, there was "IM"—the only instant messaging client that shipped on Android 1.0. Surprisingly, multiple IM services were supported: users could pick from AIM, Google Talk, Windows Live Messenger, and Yahoo. Remember when OS creators cared about interoperability? - -The friends list was a black background with white speech bubbles for open chats. Presence was indicated with colored circles, and a little Android on the right hand side would indicate that a person was mobile. It's amazing how much more communicative the IM app was than Google Hangouts. Green means the person is using a device they are signed into, yellow means they are signed in but idle, red means they have manually set busy and don't want to be bothered, and gray is offline. Today, Hangouts only shows when a user has the app open or closed. - -The chats interface was clearly based on the Messaging program, and the chat backgrounds were changed from white and blue to white and green. No one changed the color of the blue text entry box, though, so along with the orange highlight effect, this screen used white, green, blue, and orange. - -![YouTube on Android 1.0. The screens show the main page, the main page with the menu open, the categories screen, and the videos screen.](http://cdn.arstechnica.net/wp-content/uploads/2013/12/yt5000.png) -YouTube on Android 1.0. The screens show the main page, the main page with the menu open, the categories screen, and the videos screen. -Photo by Ron Amadeo - -YouTube might not have been the mobile sensation it is today with the 320p screen and 3G data speeds of the G1, but Google's video service was present and accounted for on Android 1.0. The main screen looked like a tweaked version of the Android Market, with a horizontally scrolling featured section along the top and vertically scrolling categories along the bottom. Some of Google's category choices were pretty strange: what would the difference be between "Most popular" and "Most viewed?" - -In a sign that Google had no idea how big YouTube would eventually become, one of the video categories was "Most recent." Today, with [100 hours of video][1] uploaded to the site every minute, if this section actually worked it would be an unreadable blur of rapidly scrolling videos. - -The menu housed search, favorites, categories, and settings. Settings (not pictured) was the lamest screen ever, housing one option to clear the search history. Categories was equally barren, showing only a black list of text. - -The last screen shows a video, which only supported horizontal mode. The auto-hiding video controls weirdly had rewind and fast forward buttons, even though there was a seek bar. - -![YouTube’s video menu, description page, and comments.](http://cdn.arstechnica.net/wp-content/uploads/2013/12/yt3.png) -YouTube’s video menu, description page, and comments. -Photo by Ron Amadeo - -Additional sections for each video could be brought up by hitting the menu button. Here you could favorite the video, access details, and read comments. All of these screens, like the videos, were locked to horizontal mode. - -"Share" didn't bring up a share dialog yet; it just kicked the link out to a Gmail message. Texting or IMing someone a link wasn't possible. Comments could be read, but you couldn't rate them or post your own. You couldn't rate or like a video either. - -![The camera app’s picture taking interface, menu, and photo review mode.](http://cdn.arstechnica.net/wp-content/uploads/2013/12/camera.png) -The camera app’s picture taking interface, menu, and photo review mode. -Photo by Ron Amadeo - -Real Android on real hardware meant a functional camera app, even if there wasn't much to look at. That black square on the left was the camera interface, which should be showing a viewfinder image, but the SDK screenshot utility can't capture it. The G1 had a hardware camera button (remember those?), so there wasn't a need for an on-screen shutter button. There were no settings for exposure, white balance, or HDR—you could take a picture and that was about it. - -The menu button revealed a meager two options: a way to jump to the Pictures app and Settings screen with two options. The first settings option was whether or not to enable geotagging for pictures, and the second was for a dialog prompt after every capture, which you can see on the right. Also, you could only take pictures—there was no video support yet. - -![The Calendar’s month view, week view with the menu open, day view, and agenda.](http://cdn.arstechnica.net/wp-content/uploads/2013/12/calviews.png) -The Calendar’s month view, week view with the menu open, day view, and agenda. -Photo by Ron Amadeo - -Like most apps of this era, the primary command interface for the calendar was the menu. It was used to switch views, add a new event, navigate to the current day, pick visible calendars, and go to the settings. The menu functioned as a catch-all for every single button. - -The month view couldn't show appointment text. Every date had a bar next to it, and appointments were displayed as green sections in the bar denoting what time of day an appointment was. Week view couldn't show text either—the 320×480 display of the G1 just wasn't dense enough—so you got a white block with a strip of color indicating which calendar it was from. The only views that provided text were the agenda and day views. You could move through dates by swiping—week and day used left and right, and month and agenda used up and down. - -![The main settings page, the Wireless section, and the bottom of the about page.](http://cdn.arstechnica.net/wp-content/uploads/2013/12/settings.png) -The main settings page, the Wireless section, and the bottom of the about page. -Photo by Ron Amadeo - -Android 1.0 finally brought a settings screen to the party. It was a black and white wall of text that was roughly broken down into sections. Down arrows next to each list item confusingly look like they would expand line-in to show more of something, but touching anywhere on the list item would just load the next screen. All the screens were pretty boring and samey looking, but hey, it's a settings screen. - -Any option with an on/off state used a cartoony-looking checkbox. The original checkboxes in Android 1.0 were pretty strange—even when they were "unchecked," they still had a gray check mark in them. Android treated the check mark like a light bulb that would light up when on and be dim when off, but that's not how checkboxes work. We did finally get an "About" page, though. Android 1.0 ran Linux kernel 2.6.25. - -A settings screen means we can finally open the security settings and change lock screens. Android 1.0 only had two styles, the gray square lock screen pictured in the Android 0.9 section, and pattern unlock, which required you to draw a pattern over a grid of 9 dots. A swipe pattern like this was easier to remember and input than a PIN even if it did not add any more security. - -![The Voice Dialer, pattern lock screen, low battery warning, and time picker.](http://cdn.arstechnica.net/wp-content/uploads/2013/12/grabbag.png) -The Voice Dialer, pattern lock screen, low battery warning, and time picker. -Photo by Ron Amadeo - -oice functions arrived in 1.0 with Voice Dialer. This feature hung around in various capacities in AOSP for a while, as it was a simple voice command app for calling numbers and contacts. Voice Dialer was completely unrelated to Google's future voice products, however, and it worked the same way a voice dialer on a dumbphone would work. - -As for a final note, low battery popup would occur when the battery dropped below 15 percent. It was a funny graphic, depicting plugging the wrong end of the power cord into the phone. That wasn't (and still isn't) how phones work, Google. - -Android 1.0 was a great first start, but there were still so many gaps in functionality. Physical keyboards and tons of hardware buttons were mandatory, as Android devices were still not allowed to be sold without a d-pad or trackball. Base smartphone functionality like auto-rotate wasn't here yet, either. Updates for built-in apps weren't possible through the Android Market the way they were today. All the Google Apps were interwoven with the operating system. If Google wanted to update a single app, an update for the entire operating system needed to be pushed out through the carriers. There was still a lot of work to do. - -### Android 1.1—the first truly incremental update ### - -![All of Android 1.1’s new features: Search by voice, the Android Market showing paid app support, Google Latitude, and the new “system updates" option in the settings.](http://cdn.arstechnica.net/wp-content/uploads/2013/12/11.png) -All of Android 1.1’s new features: Search by voice, the Android Market showing paid app support, Google Latitude, and the new “system updates" option in the settings. -Photo by Ron Amadeo - -Four and a half months after Android 1.0, in February 2009, Android got its first public update in Android 1.1. Not much changed in the OS, and just about every new thing Google added with 1.1 has been shut down by now. Google Voice Search was Android's first foray into cloud-powered voice search, and it had its own icon in the app drawer. While the app can't communicate with Google's servers anymore, you can check out how it used to work [on the iPhone][2]. It wasn't yet Voice Actions, but you could speak and the results would go to a simple Google Search. - -Support for paid apps was added to the Android Market, but just like the beta client, this version of the Android Market could no longer connect to the Google Play servers. The most that we could get to work was this sorting screen, which lets you pick between displaying free apps, paid apps, or a mix of both. - -Maps added [Google Latitude][3], a way to share your location with friends. Latitude was shut down in favor of Google+ a few months ago and no longer works. There was an option for it in the Maps menu, but tapping on it just brings up a loading spinner forever. - -Given that system updates come quickly in the Android world—or at least, that was the plan before carriers and OEMs got in the way—Google also added a button to the "About Phone" screen to check for system updates. - ----------- - -![Ron Amadeo](http://cdn.arstechnica.net/wp-content//uploads/authors/ron-amadeo-sq.jpg) - -[Ron Amadeo][a] / Ron is the Reviews Editor at Ars Technica, where he specializes in Android OS and Google products. He is always on the hunt for a new gadget and loves to rip things apart to see how they work. - -[@RonAmadeo][t] - --------------------------------------------------------------------------------- - -via: http://arstechnica.com/gadgets/2014/06/building-android-a-40000-word-history-of-googles-mobile-os/7/ - -译者:[译者ID](https://github.com/译者ID) 校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[1]:http://www.youtube.com/yt/press/statistics.html -[2]:http://www.youtube.com/watch?v=y3z7Tw1K17A -[3]:http://arstechnica.com/information-technology/2009/02/google-tries-location-based-social-networking-with-latitude/ -[a]:http://arstechnica.com/author/ronamadeo -[t]:https://twitter.com/RonAmadeo \ No newline at end of file diff --git a/sources/talk/The history of Android/08 - The history of Android.md b/sources/talk/The history of Android/08 - The history of Android.md index 3bd0c3a8c5..589822dbc7 100644 --- a/sources/talk/The history of Android/08 - The history of Android.md +++ b/sources/talk/The history of Android/08 - The history of Android.md @@ -1,3 +1,5 @@ +alim0x translating + The history of Android ================================================================================ ![Android 1.5’s on-screen keyboard showing the suggestion bar while typing, the capital letters keyboard, the number and symbols screen, and an additional key popup.](http://cdn.arstechnica.net/wp-content/uploads/2013/12/kb5.png) @@ -88,15 +90,15 @@ The HTC Magic, the second Android device, and the first without a hardware keybo Photo by HTC > #### Google Maps is the first built-in app to hit the Android Market #### -> +> > While this article is (mostly) organizing app updates by Android version for simplicity's sake, there are a few outliers that deserve special recognition. On June 14, 2009, Google Maps was the first packed-in Android app to be updated via the Android Market. While every other app required a full system release to be updated, Maps was broken out of the OS, free to receive out-of-cycle updates whenever a new feature was ready. -> +> > Moving apps out of the core OS and onto the Android Market would be a big focus for Google going forward. In general, OTA updates were a big initiative—they required the cooperation of the OEM and the carrier, both of which could drag their feet. Updates also didn’t make it to every device. Today, the Android Market gives Google a direct line to every Android phone with no such interference from outside parties. -> +> > These were problems for a later date, though. In 2009, Google had only two unskinned phones to support, and the early Android carriers were seemingly responsive to Google’s update needs. This early move would prove to be a very proactive decision on Google’s part. At first, the company went this route only with its most important properties—Maps and Gmail—but later it would port the majority of the packed-in apps to the Android Market. Later initiatives like Google Play Services even brought app APIs out of the OS and into Google’s store. -> +> > As for the new Maps at the time, it gained a new directions interface, along with the ability to give mass transit and walking directions. For now, directions were given on a plain black list—turn-by-turn-style navigation would come later. -> +> > June 2009 was also the time Apple launched the third iPhone—the 3GS—and the third version of iPhone OS. iPhone OS 3's headline features were mostly catch-up items like copy/paste and MMS support. Apple's hardware was still nicer, and the software was smoother, more cohesive, and better designed. Google's insane pace of development was putting it on a path to parity though. iPhone OS 2 launched just before the Milestone 5 build of Android 0.5, which makes five Android releases in the span of the yearly iOS release cycle. Android 1.5 gave the YouTube app the ability to upload videos to the site. Uploading was accomplished by sharing a video from the Gallery to the YouTube app, or by opening a video directly from the YouTube app. This would bring up an upload screen, where the user would set things like the video title, tags, and access rights. Photos could be uploaded to Picasa, Google's original photo site, in a similar fashion. @@ -125,4 +127,4 @@ via: http://arstechnica.com/gadgets/2014/06/building-android-a-40000-word-histor [1]:http://en.wikipedia.org/wiki/Diacritic [a]:http://arstechnica.com/author/ronamadeo -[t]:https://twitter.com/RonAmadeo \ No newline at end of file +[t]:https://twitter.com/RonAmadeo diff --git a/sources/tech/20140711 How to use systemd for system administration on Debian.md b/sources/tech/20140711 How to use systemd for system administration on Debian.md deleted file mode 100644 index 12e2ca24ff..0000000000 --- a/sources/tech/20140711 How to use systemd for system administration on Debian.md +++ /dev/null @@ -1,107 +0,0 @@ -[bazz2 hehe] -How to use systemd for system administration on Debian -================================================================================ -Soon enough, hardly any Linux user will be able to escape the ever growing grasp that systemd imposes on Linux, unless they manually opt out. systemd has created more technical, emotional, and social issues than any other piece of software as of late. This predominantly came to show in the [heated discussions][1] also dubbed as the 'Init Wars', that occupied parts of the Debian developer body for months. While the Debian Technical Comittee finally decided to include systemd in Debian 8 "Jessie", there were efforts to [supersede the decision][2] by a General Resolution, and even threats to the health of developers in favor of systemd. - -This goes to show how deep systemd interferes with the way of handling Linux systems that has, in large parts, been passed down to us from the Unix days. Theorems like "one tool for the job" are overthrown by the new kid in town. Besides substituting sysvinit as init system, it digs deep into system administration. For right now a lot of the commands you are used to will keep on working due to the compatibility layer provided by the package systemd-sysv. That might change as soon as systemd 214 is uploaded to Debian, destined to be released in the stable branch with Debian 8 "Jessie". From thereon, users need to utilize the new commands that come with systemd for managing services, processes, switching run levels, and querying the logging system. A workaround is to set up aliases in .bashrc. - -So let's have a look at how systemd will change your habits of administrating your computers and the pros and cons involved. Before making the switch to systemd, it is a good security measure to save the old sysvinit to be able to still boot, should systemd fail. This will only work as long as systemd-sysv is not yet installed, and can be easily obtained by running: - - # cp -av /sbin/init /sbin/init.sysvinit - -Thusly prepared, in case of emergency, just append: - - init=/sbin/init.sysvinit - -to the kernel boot-time parameters. - -### Basic Usage of systemctl ### - -systemctl is the command that substitutes the old "/etc/init.d/foo start/stop", but also does a lot more, as you can learn from its man page. - -Some basic use-cases are: - -- systemctl - list all loaded units and their state (where unit is the term for a job/service) -- systemctl list-units - list all units -- systemctl start [NAME...] - start (activate) one or more units -- systemctl stop [NAME...] - stop (deactivate) one or more units -- systemctl disable [NAME...] - disable one or more unit files -- systemctl list-unit-files - show all installed unit files and their state -- systemctl --failed - show which units failed during boot -- systemctl --type=mount - filter for types; types could be: service, mount, device, socket, target -- systemctl enable debug-shell.service - start a root shell on TTY 9 for debugging - -For more convinience in handling units, there is the package systemd-ui, which is started as user with the command systemadm. - -Switching runlevels, reboot and shutdown are also handled by systemctl: - -- systemctl isolate graphical.target - take you to what you know as init 5, where your X-server runs -- systemctl isolate multi-user.target - take you to what you know as init 3, TTY, no X -- systemctl reboot - shut down and reboot the system -- systemctl poweroff - shut down the system - -All these commands, other than the ones for switching runlevels, can be executed as normal user. - -### Basic Usage of journalctl ### - -systemd does not only boot machines faster than the old init system, it also starts logging much earlier, including messages from the kernel initialization phase, the initial RAM disk, the early boot logic, and the main system runtime. So the days where you needed to use a camera to provide the output of a kernel panic or otherwise stalled system for debugging are mostly over. - -With systemd, logs are aggregated in the journal which resides in /var/log/. To be able to make full use of the journal, we first need to set it up, as Debian does not do that for you yet: - - # addgroup --system systemd-journal - # mkdir -p /var/log/journal - # chown root:systemd-journal /var/log/journal - # gpasswd -a $user systemd-journal - -That will set up the journal in a way where you can query it as normal user. Querying the journal with journalctl offers some advantages over the way syslog works: - -- journalctl --all - show the full journal of the system and all its users -- journalctl -f - show a live view of the journal (equivalent to "tail -f /var/log/messages") -- journalctl -b - show the log since the last boot -- journalctl -k -b -1 - show all kernel logs from the boot before last (-b -1) -- journalctl -b -p err - shows the log of the last boot, limited to the priority "ERROR" -- journalctl --since=yesterday - since Linux people normally do not often reboot, this limits the size more than -b would -- journalctl -u cron.service --since='2014-07-06 07:00' --until='2014-07-06 08:23' - show the log for cron for a defined timeframe -- journalctl -p 2 --since=today - show the log for priority 2, which covers emerg, alert and crit; resembles syslog priorities emerg (0), alert (1), crit (2), err (3), warning (4), notice (5), info (6), debug (7) -- journalctl > yourlog.log - copy the binary journal as text into your current directory - -Journal and syslog can work side-by-side. On the other hand, you can remove any syslog packages like rsyslog or syslog-ng once you are satisfied with the way the journal works. - -For very detailed output, append "systemd.log_level=debug" to the kernel boot-time parameter list, and then run: - - # journalctl -alb - -Log levels can also be edited in /etc/systemd/system.conf. - -### Analyzing the Boot Process with systemd ### - -systemd allows you to effectively analyze and optimize your boot process: - -- systemd-analyze - show how long the last boot took for kernel and userspace -- systemd-analyze blame - show details of how long each service took to start -- systemd-analyze critical-chain - print a tree of the time-critical chain of units -- systemd-analyze dot | dot -Tsvg > systemd.svg - put a vector graphic of your boot process (requires graphviz package) -- systemd-analyze plot > bootplot.svg - generate a graphical timechart of the boot process - -![](https://farm6.staticflickr.com/5559/14607588994_38543638b3_z.jpg) - -![](https://farm6.staticflickr.com/5565/14423020978_14b21402c8_z.jpg) - -systemd has pretty good documentation for such a young project under heavy developement. First of all, there is the [0pointer series by Lennart Poettering][3]. The series is highly technical and quite verbose, and holds a wealth of information. Another good source is the distro agnostic [Freedesktop info page][4] with the largest collection of links to systemd resources, distro specific pages, bugtrackers and documentation. A quick glance at: - - # man systemd.index - -will give you an overview of all systemd man pages. The command structure for systemd for various distributions is pretty much the same, differences are found mainly in the packaging. - --------------------------------------------------------------------------------- - -via: http://xmodulo.com/2014/07/use-systemd-system-administration-debian.html - -译者:[译者ID](https://github.com/译者ID) 校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[1]:https://lists.debian.org/debian-devel/2013/10/msg00444.html -[2]:https://lists.debian.org/debian-devel/2014/02/msg00316.html -[3]:http://0pointer.de/blog/projects/systemd.html -[4]:http://www.freedesktop.org/wiki/Software/systemd/ diff --git a/sources/tech/20140729 10 Useful 'Squid Proxy Server' Interview Questions and Answers in Linux.md b/sources/tech/20140729 10 Useful 'Squid Proxy Server' Interview Questions and Answers in Linux.md deleted file mode 100644 index 42bf8dce15..0000000000 --- a/sources/tech/20140729 10 Useful 'Squid Proxy Server' Interview Questions and Answers in Linux.md +++ /dev/null @@ -1,132 +0,0 @@ -Translating by ZTinoZ -10 Useful “Squid Proxy Server” Interview Questions and Answers in Linux -================================================================================ -It’s not only to System Administrator and Network Administrator, who listens the phrase Proxy Server every now and then but we too. Proxy Server is now a corporate culture and is the need of the hour. Proxy server now a days is implemented from small schools, cafeteria to large MNCs. Squid (also known as proxy) is such an application which acts as proxy server and one of the most widely used tool of its kind. - -This Interview article aims at strengthening your base from Interview point on the ground of proxy server and squid. - -![Squid Interview Questions](http://www.tecmint.com/wp-content/uploads/2014/07/Squid-Interview-Questions.png) -Squid Interview Questions - -### 1. What do you mean by Proxy Server? What is the use of Proxy Server in Computer Networks? ### - -> **Answer** : A Proxy Server refers to physical machine or Application which acts intermediate between client and resource provider or server. A client seeks for file, page or data from the the proxy server and proxy server manages to get the requested demand of client fulfilled by handling all the complexities in between. - -Proxy servers are the backbone of WWW (World Wide Web). Most of the proxies of today are web proxies. A proxy server handles the complexity in between the Communication of client and Server. Moreover it provides anonymity on the web which simply means your identity and digital footprints are safe. Proxies can be configured to allow which sites client can see and which sites are blocked. - -### 2. What is Squid? ### - -> **Answer** : Squid is an Application software released under GNU/GPL which acts as a proxy server as well as web cache Daemon. Squid primarily supports Protocol like HTTP and FTP however other protocols like HTTPS, SSL,TLS, etc are well supported. The feature web cache Daemon makes web surfing faster by caching web and DNS for frequently visited websites. Squid is known to support all major platforms including Linux, UNIX, Microsoft Windows and Mac. - -### 3. What is the default port of squid and how to change its operating port? ### - -> **Answer** : The default port on which squid runs is 3128. We can change the operating port of squid from default to any custom unused port by editing its configuration file which is located at /etc/squid/squid.conf as suggested below. - -Open ‘/etc/squid/squid.conf’ file and with your choice of editor. - - # nano /etc/squid/squid.conf - -Now change this port to any other unused port. Save the editor and exit. - - http_port 3128 - -Restart the squid service as shown below. - - # service squid restart - -### 4. You works for a company the management of which ask you to block certain domains through squid proxy server. What are you going to do? ### - -> **Answer** : Blocking domain is a module which is implemented well in the configuration file. We just need to perform a little manual configuration as suggested below. - -a. Create a file say ‘blacklist’ under directory ‘/etc/squid’. - - # touch /etc/squid/blacklist - -b. Open the file ‘/etc/squid/blacklist’ with nano editor. - - # nano /etc/squid/blacklist - -c. Add all the domains to the file blacklist with one domain per line. - - .facebook.com - .twitter.com - .gmail.com - .yahoo.com - ... - -d. Save the file and exit. Now open the Squid configuration file from location ‘/etc/squid/squid.conf’. - - # nano /etc/squid/squid.conf - -e. Add the lines below to the Squid configuration file. - - acl BLACKLIST dstdom_regex -i “/etc/squid/blacklist” - http_access deny blacklist - -f. Save the configuration file and exit. Restart Squid service to make the changes effective. - - # service squid restart - -### 5. What is Media Range Limitation and partial download in Squid? ### - -> **Answer** : Media Range Limitation is a special feature of squid in which just the required data is requested from the server and not the whole file. This feature is very well implemented in various videos streaming websites like Youtube and Metacafe where a user can click on the middle of progress bar hence whole video need not be fetched except for the requested part. - -The squid’s feature of partial download is implemented well within windows update where downloads are requested in the form of small packets which can be paused. Because of this feature a update downloading windows machine can be restarted without any fear of data loss. Squid makes the Media Range Limitation and Partial Download possible only after storing a copy of whole data in it. Moreover the partial download gets deleted and not cached when user points to another page until Squid is specially configured somehow. - -### 6. What is reverse proxy in squid? ### - -> **Answer** : Reverse proxy is a feature of Squid which is used to accelerate the web surfing for end user. Say the Real server ‘RS’ contains the resource and ‘PS’ is the proxy Server. The client seek some data which is available at RS. It will rely on RS for the specified data for the first time and the copy of that specified data gets stored on PS for configurable amount of time. For every request for that data from now PS becomes the real source. This results in Less traffic, Lesser CPU usages, Lesser web resource utilization and hence lesser load to actual server RS. But RS has no statistics for the total traffic since PS acted as actual server and no Client reached RS. ‘X-Forwarded-For HTTP’ can be used to log the client IP although on RS. - -Technically it is feasible to use single squid server to act both as normal proxy server and reverse proxy server at the same point of time. - -### 7. Since Squid can be used as web-cache Daemon, is it possible to Clear its Cache? How? ### - -> **Answer** : No Doubt! Squid acts as web-cache Daemon which is used to accelerate web surfing still it is possible to clear its cache and that too very easily. - -a. First stop Squid proxy server and delete cache from the location ‘/var/lib/squid/cache’ directory. - - # service squid stop - # rm -rf /var/lib/squid/cache/*< - -b. Create Swap directories. - - # squid -z - -### 8. A client approaches you, who is working. They want the web access time be restricted for their children. How will you achieve this scenario? ### - -Say the web access allow time be 4′o clock to 7′o clock in the evening for three hours, sharply form Monday to Friday. - -a. To restrict web access between 4 to 7 from Monday to Friday, open the Squid configuration file. - - # nano /etc/squid/squid.conf - -b. Add the following lines and save the file and exit. - - acl ALLOW_TIME time M T W H F 16:00-19:00 - shttp_access allow ALLOW_TIME - -c. Restart the Squid Service. - - # service squid restart - -### 9. Squid stores data in which file format? ### - -> **Answer** : Data stored by Squid is in ufs format. Ufs is the old well-known Squid storage format. - -### 10. Where do cache gets stored by squid? ### - -> **Answer** : A squid stores cache in special folder at the location ‘/var/spool/squid’. - -That’s all for now. I’ll be here again with another interesting article soon. Till then stay tuned and connected to Tecmint. Don’t forget to provide us with your valuable feedback the comment section below. - --------------------------------------------------------------------------------- - -via: http://www.tecmint.com/squid-interview-questions/ - -作者:[Avishek Kumar][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://www.tecmint.com/author/avishek/ diff --git a/sources/tech/20140811 Check how much do you type with WhatPulse on Linux.md b/sources/tech/20140811 Check how much do you type with WhatPulse on Linux.md deleted file mode 100644 index 6037f59f96..0000000000 --- a/sources/tech/20140811 Check how much do you type with WhatPulse on Linux.md +++ /dev/null @@ -1,77 +0,0 @@ -Check how much do you type with WhatPulse on Linux -================================================================================ -![](http://cdn.linuxaria.com/wp-content/uploads/2014/08/whatpulse.png) - -If, like me, you are a statistics freak you must install this small application on all your computers: [WhatPulse][1] - -The software tracks a user’s pressed keys, mouse clicks and used [bandwidth][2] and the uptime of the system. Periodically, or by hand, the user can upload to the server the number of keystrokes made; this is called “pulsing”. - -Users can see where they are in a leaderboard of people who have joined the program and compare themselves against people from their own countries. Users can also join teams, which enables them to compare themselves against people with similar interests (Go Linux Users !!). - -There is a basic, and free, version where you can easily see and check all the basic statistics and a premium account where you can see some more stats. - -The software is available for Linux, Windows and Mac. - -### Registration on the website ### - -As first step you have to register your account on the [WhatPulse Website][1] or as alternative when you first start the WhatPulse client there is a practical wizard through which each user has the option to create an account to upload their own statistics (you can also log in with Facebook). - -You will be prompted to login, once you login, you have to search for your computers name, this is because you can login to several computers with this and they’ll all collectively go to the same statistic count. Once you’ve logged in, a small W will appear in your system tray, that’s it, your set up! - -### Installation of WhatPulse on Linux ### - -The official website offer on the [download page][3] a generic version distributed via a .tar.gz archive (available for 32 and 64 bit) and a debian package. - -Personally I’ve installed the debian package on my Mint Qiana and the [Aur Package][4] on My Arch Linux, no problems at all. - -If you want to go with the generic installation please keep in mind that WhatPulse requires several libraries to function. Mainly Qt, because WhatPulse is built on Qt. Here’s a list of requirements: - -- libQtCore -- libQtWebKit -- libqt4-sql -- libqt4-sql-sqlite -- openssl-devel (libssl-dev) -- libQtScript - -#### Input Statistics #### - -The client needs permissions to be allowed to read your keyboard/mouse input. Run the included interactive .sh script to set up these permissions. - -#### [Network][5] Statistics #### - -To enable the network measurements, you also need the package **libpcap** to allow WhatPulse to hook into the network traffic. If WhatPulse does not find libpcap, it will run but it will not display any network statistics. - -![](http://cdn.linuxaria.com/wp-content/uploads/2014/08/heatmap.png) - -### Using the Application ### - -By default WhatPulse will start automatically at the login of your graphical session and clicking on the W on your systray you’ll go to the Overview tab that gives a birds-eye view of all the different information gathered about your machine, for instance, the Linux version installed on your PC, processor model, RAM, GPU, total click counts, keystrokes and bandwidth usage. Clicking ‘Pulse’ under these information will upload the gathered data to the main server. - -It’s also possible to select when automatically ‘Pulse’ the data to the server, such as every 50.000 clicks or 1 GB downloaded. - -For further details, you can switch to each category’s pertaining tab. For example, the Input tab shows you the amount of key strokes and clicks your PC has registered during a certain time period. The time period can be sorted on a daily, weekly, monthly, yearly and all-time basis. The ‘all’ setting will show stats since the program was installed. - -Below the keystrokes, you’ll find the keyboard heat map, which basically uses light and warm colors to shows what keys were used more than others during the selected time period, as shown in the screenshot above. Below that, the app displays the total amount of clicks registered in the selected period. - -Under the Network tab, it’s possible to view the daily Internet usage. The application can monitor bandwidth usage of all the network devices, and even shows you bandwidth usage by country. Once again, you can navigate between available data using the arrow buttons at the top-right. - -On the website you’ll see the sum of all your computer statistics with the same information available on the client. - -Disclaimer: The link above to the WhatPulse website contains my referral link, using it when you register will give me a premium account for some time. - --------------------------------------------------------------------------------- - -via: http://linuxaria.com/recensioni/check-how-much-do-you-type-with-whatpulse-on-linux - -作者:[linuxari][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:https://plus.google.com/100563597940685405833?rel=author -[1]:http://whatpulse.org/ref/833872/ -[2]:http://linuxaria.com/article/tool-command-line-bandwidth-linux -[3]:http://www.whatpulse.org/downloads/ -[4]:https://aur.archlinux.org/packages/whatpulse/ -[5]:http://linuxaria.com/tag/network \ No newline at end of file diff --git a/sources/tech/20140818 Disable reboot using Ctrl-Alt-Del Keys in RHEL or CentOS.md b/sources/tech/20140818 Disable reboot using Ctrl-Alt-Del Keys in RHEL or CentOS.md deleted file mode 100644 index 2162c8fbb4..0000000000 --- a/sources/tech/20140818 Disable reboot using Ctrl-Alt-Del Keys in RHEL or CentOS.md +++ /dev/null @@ -1,44 +0,0 @@ -Disable reboot using Ctrl-Alt-Del Keys in RHEL / CentOS -================================================================================ -In Linux , It's a security concern for us to allow anyone to **reboot** the server using **Ctrl-Alt-Del keys**. It is always recommended in production boxes that one should disable reboot uisng Ctrl-Alt-Del keys. - -In this article we will discuss how can we disable reboot via above keys in RHEL & CentOS - -### For RHEL 5.X & CentOS 5.X ### - -To prevent the **init** process from handling **Ctrl-Alt-Del**, edit the file '**/etc/inittab**' comment the line which begins with '**ca::ctrlaltdel**:' as shown below : - - [root@localhost ~]# cat /etc/inittab - # Trap CTRL-ALT-DELETE - #ca::ctrlaltdel:/sbin/shutdown -t3 -r now - -We can also modify the line 'ca::ctrlaltdel:' to generate logs , if anybody try to reboot the server using the keys , - - [root@localhost ~]# cat /etc/inittab - # Trap CTRL-ALT-DELETE - ca::ctrlaltdel:/bin/logger -p authpriv.warning -t init "Console-invoked Ctrl-Alt-Del was ignored" - -### For RHEL6.X & CentOS 6.X ### - -In RHEL 6.X / CentOS 6.X , reboot using the keys are handled by the file '**/etc/init/control-alt-delete.conf**'. - -**Step:1** Before making the changes , first take the backup using below command - - [root@localhost ~]# cp -v /etc/init/control-alt-delete.conf /etc/init/control-alt-delete.override - -**Step:2** Edit the file , replacing the 'exec /sbin/shutdown' line with the following, which will simply generate a log entry each time Ctrl-Alt-Del is pressed: - - [root@localhost ~]# cat /etc/init/control-alt-delete.conf - exec /usr/bin/logger -p authpriv.notice -t init "Ctrl-Alt-Del was pressed and ignored" - --------------------------------------------------------------------------------- - -via: http://www.linuxtechi.com/disable-reboot-using-ctrl-alt-del-keys/ - -作者:[Pradeep Kumar][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://www.linuxtechi.com/author/pradeep/ \ No newline at end of file diff --git a/sources/tech/20140818 How to Take 'Snapshot of Logical Volume and Restore' in LVM--Part III.md b/sources/tech/20140818 How to Take 'Snapshot of Logical Volume and Restore' in LVM--Part III.md deleted file mode 100644 index fa5024fe1c..0000000000 --- a/sources/tech/20140818 How to Take 'Snapshot of Logical Volume and Restore' in LVM--Part III.md +++ /dev/null @@ -1,200 +0,0 @@ -How to Take ‘Snapshot of Logical Volume and Restore’ in LVM – Part III -================================================================================ -**LVM Snapshots** are space efficient pointing time copies of lvm volumes. It works only with lvm and consume the space only when changes are made to the source logical volume to snapshot volume. If source volume has a huge changes made to sum of 1GB the same changes will be made to the snapshot volume. Its best to always have a small size of changes for space efficient. Incase the snapshot runs out of storage, we can use lvextend to grow. And if we need to shrink the snapshot we can use lvreduce. - -![Take Snapshot in LVM](http://www.tecmint.com/wp-content/uploads/2014/08/Take-Snapshot-in-LVM.jpg) -Take Snapshot in LVM - -If we have accidentally deleted any file after creating a Snapshot we don’t have to worry because the snapshot have the original file which we have deleted. It is possible if the file was there when the snapshot was created. Don’t alter the snapshot volume, keep as it while snapshot used to do a fast recovery. - -Snapshots can’t be use for backup option. Backups are Primary Copy of some data’s, so we cant use snapshot as a backup option. - -#### Requirements #### - -注:此两篇文章如果发布后可换成发布后链接,原文在前几天更新中 - -- [Create Disk Storage with LVM in Linux – PART 1][1] -- [How to Extend/Reduce LVM’s in Linux – Part II][2] - -### My Server Setup ### - -- Operating System – CentOS 6.5 with LVM Installation -- Server IP – 192.168.0.200 - -#### Step 1: Creating LVM Snapshot #### - -First, check for free space in volume group to create a new snapshot using following ‘**vgs**‘ command. - - # vgs - # lvs - -![Check LVM Disk Space](http://www.tecmint.com/wp-content/uploads/2014/08/Check-LVM-Disk-Space.jpg) -Check LVM Disk Space - -You see, there is 8GB of free space left in above **vgs** output. So, let’s create a snapshot for one of my volume named **tecmint_datas**. For demonstration purpose, I am going to create only 1GB snapshot volume using following commands. - - # lvcreate -L 1GB -s -n tecmint_datas_snap /dev/vg_tecmint_extra/tecmint_datas - -OR - - # lvcreate --size 1G --snapshot --name tecmint_datas_snap /dev/vg_tecmint_extra/tecmint_datas - -Both the above commands does the same thing: - -- **-s** – Creates Snapshot -- **-n** – Name for snapshot - -![Create LVM Snapshot](http://www.tecmint.com/wp-content/uploads/2014/08/Create-LVM-Snapshot.jpg) -Create LVM Snapshot - -Here, is the explanation of each point highlighted above. - -- Size of snapshot Iam creating here. -- Creates snapshot. -- Creates name for the snapshot. -- New snapshots name. -- Volume which we are going to create a snapshot. - -If you want to remove a snapshot, you can use ‘**lvremove**‘ command. - -# lvremove /dev/vg_tecmint_extra/tecmint_datas_snap - -![Remove LVM Snapshot](http://www.tecmint.com/wp-content/uploads/2014/08/Remove-LVM-Snapshot.jpg) -Remove LVM Snapshot - -Now, list the newly created snapshot using following command. - - # lvs - -![Verify LVM Snapshot](http://www.tecmint.com/wp-content/uploads/2014/08/Verify-LVM-Snapshot.jpg) -Verify LVM Snapshot - -You see above, a snapshot was created successfully. I have marked with an arrow where snapshots origin from where its created, Its **tecmint_datas**. Yes, because we have created a snapshot for **tecmint_datas l-volume**. - -![Check LVM Snapshot Space](http://www.tecmint.com/wp-content/uploads/2014/08/Check-LVM-Snapshot-Space.jpg) -Check LVM Snapshot Space - -Let’s add some new files into **tecmint_datas**. Now volume has some data’s around 650MB and our snapshot size is 1GB. So there is enough space to backup our changes in snap volume. Here we can see, what is the status of our snapshot using below command. - - # lvs - -![Check Snapshot Status](http://www.tecmint.com/wp-content/uploads/2014/08/Check-Snapshot-Status.jpg) -Check Snapshot Status - -You see, **51%** of snapshot volume was used now, no issue for more modification in your files. For more detailed information use command. - - # lvdisplay vg_tecmint_extra/tecmint_data_snap - -![View Snapshot Information](http://www.tecmint.com/wp-content/uploads/2014/08/Snapshot-Information.jpg) -View Snapshot Information - -Again, here is the clear explanation of each point highlighted in the above picture. - -- Name of Snapshot Logical Volume. -- Volume group name currently under use. -- Snapshot volume in read and write mode, we can even mount the volume and use it. -- Time when the snapshot was created. This is very important because snapshot will look for every changes after this time. -- This snapshot belongs to tecmint_datas logical volume. -- Logical volume is online and available to use. -- Size of Source volume which we took snapshot. -- Cow-table size = copy on Write, that means whatever changes was made to the tecmint_data volume will be written to this snapshot. -- Currently snapshot size used, our tecmint_datas was 10G but our snapshot size was 1GB that means our file is around 650 MB. So what its now in 51% if the file grow to 2GB size in tecmint_datas size will increase more than snapshot allocated size, sure we will be in trouble with snapshot. That means we need to extend the size of logical volume (snapshot volume). -- Gives the size of chunk for snapshot. - -Now, let’s copy more than 1GB of files in **tecmint_datas**, let’s see what will happen. If you do, you will get error message saying ‘**Input/output error**‘, it means out of space in snapshot. - -![Add Files to Snapshot](http://www.tecmint.com/wp-content/uploads/2014/08/Add-Files-to-Snapshot.jpg) -Add Files to Snapshot - -If the logical volume become full it will get dropped automatically and we can’t use it any more, even if we extend the size of snapshot volume. It is the best idea to have the same size of Source while creating a snapshot, **tecmint_datas** size was 10G, if I create a snapshot size of 10GB it will never over flow like above because it has enough space to take snap of your volume. - -#### Step 2: Extend Snapshot in LVM #### - -If we need to extend the snapshot size before overflow we can do it using. - - # lvextend -L +1G /dev/vg_tecmint_extra/tecmint_data_snap - -Now there was totally 2GB size for snapshot. - -![Extend LVM Snapshot](http://www.tecmint.com/wp-content/uploads/2014/08/Extend-LVM-Snapshot.jpg) -Extend LVM Snapshot - -Next, verify the new size and COW table using following command. - - # lvdisplay /dev/vg_tecmint_extra/tecmint_data_snap - -To know the size of snap volume and usage **%**. - - # lvs - -![Check Size of Snapshot](http://www.tecmint.com/wp-content/uploads/2014/08/Check-Size-of-Snapshot.jpg) -Check Size of Snapshot - -But if, you have snapshot volume with the same size of Source volume we don’t need to worry about these issues. - -#### Step 3: Restoring Snapshot or Merging #### - -To restore the snapshot, we need to un-mount the file system first. - - # unmount /mnt/tecmint_datas/ - -![Un-mount File System](http://www.tecmint.com/wp-content/uploads/2014/08/Unmount-File-System.jpg) -Un-mount File System - -Just check for the mount point whether its unmounted or not. - - # df -h - -![Check File System Mount Points](http://www.tecmint.com/wp-content/uploads/2014/08/Check-Mount-Points.jpg) -Check File System Mount Points - -Here our mount has been unmounted, so we can continue to restore the snapshot. To restore the snap using command **lvconvert**. - - # lvconvert --merge /dev/vg_tecmint_extra/tecmint_data_snap - -![Restore LVM Snapshot](http://www.tecmint.com/wp-content/uploads/2014/08/Restore-Snapshot.jpg) -Restore LVM Snapshot - -After the merge is completed, snapshot volume will be removed automatically. Now we can see the space of our partition using **df** command. - - # df -Th - -![Check Size of Snapshot](http://www.tecmint.com/wp-content/uploads/2014/08/Check-Snapshot-Space.jpg) - -After the snapshot volume removed automatically. You can see the size of logical volume. - - # lvs - -![Check Size of Logical Volume](http://www.tecmint.com/wp-content/uploads/2014/08/Check-Size-of-LV.jpg) -Check Size of Logical Volume - -**Important**: To Extend the Snapshots automatically, we can do it using some modification in conf file. For manual we can extend using lvextend. - -Open the lvm configuration file using your choice of editor. - - # vim /etc/lvm/lvm.conf - -Search for word autoextend. By Default the value will be similar to below. - -![LVM Configuration](http://www.tecmint.com/wp-content/uploads/2014/08/LVM-Configuration.jpg) -LVM Configuration - -Change the **100** to **75** here, if so auto extend threshold is **75** and auto extend percent is 20, it will expand the size more by **20 Percent** - -If the snapshot volume reach **75%** it will automatically expand the size of snap volume by **20%** more. Thus,we can expand automatically. Save and exit the file using **wq!**. - -This will save snapshot from overflow drop. This will also help you to save more time. LVM is the only Partition method in which we can expand more and have many features as thin Provisioning, Striping, Virtual volume and more Using thin-pool, let us see them in the next topic. - --------------------------------------------------------------------------------- - -via: http://www.tecmint.com/take-snapshot-of-logical-volume-and-restore-in-lvm/ - -作者:[Babin Lonston][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://www.tecmint.com/author/babinlonston/ -[1]:http://www.tecmint.com/create-lvm-storage-in-linux/ -[2]:http://www.tecmint.com/extend-and-reduce-lvms-in-linux/ \ No newline at end of file diff --git a/sources/tech/20140818 What are useful CLI tools for Linux system admins.md b/sources/tech/20140818 What are useful CLI tools for Linux system admins.md index 261af07857..49bd994f71 100644 --- a/sources/tech/20140818 What are useful CLI tools for Linux system admins.md +++ b/sources/tech/20140818 What are useful CLI tools for Linux system admins.md @@ -1,3 +1,5 @@ +translating by haimingfg + What are useful CLI tools for Linux system admins ================================================================================ System administrators (sysadmins) are responsible for day-to-day operations of production systems and services. One of the critical roles of sysadmins is to ensure that operational services are available round the clock. For that, they have to carefully plan backup policies, disaster management strategies, scheduled maintenance, security audits, etc. Like every other discipline, sysadmins have their tools of trade. Utilizing proper tools in the right case at the right time can help maintain the health of operating systems with minimal service interruptions and maximum uptime. @@ -184,4 +186,4 @@ via: http://xmodulo.com/2014/08/useful-cli-tools-linux-system-admins.html [17]:http://rsync.samba.org/ [18]:http://www.nongnu.org/rdiff-backup/ [19]:http://nethogs.sourceforge.net/ -[20]:http://code.google.com/p/inxi/ \ No newline at end of file +[20]:http://code.google.com/p/inxi/ diff --git a/sources/tech/20140819 8 Options to Trace or Debug Programs using Linux strace Command.md b/sources/tech/20140819 8 Options to Trace or Debug Programs using Linux strace Command.md deleted file mode 100644 index 3cbf25c52b..0000000000 --- a/sources/tech/20140819 8 Options to Trace or Debug Programs using Linux strace Command.md +++ /dev/null @@ -1,112 +0,0 @@ -8 Options to Trace/Debug Programs using Linux strace Command -================================================================================ -The strace is the tool that helps in debugging issues by tracing system calls executed by a program. It is handy when you want to see how the program interacts with the operating system, like what system calls are executed in what order. - -This simple yet very powerful tool is available for almost all the Linux based operating systems and can be used to debug a large number of programs. - -### 1. Command Usage ### - -Let’s see how we can use strace command to trace the execution of a program. - -In the simplest form, any command can follow strace. It will list a whole lot of system calls. Not all of it would make sence at first, but if you’re really looking for something particular, then you should be able to figure something out of this output. -Lets see the system calls trace for simple ls command. - - raghu@raghu-Linoxide ~ $ strace ls - -![Stracing ls command](http://linoxide.com/wp-content/uploads/2014/08/01.strace_ls.png) - -This output shows the first few lines for strace command. The rest of the output is truncated. - -![Strace write system call (ls)](http://linoxide.com/wp-content/uploads/2014/08/02.strace_ls_write.png) - -The above part of the output shows the write system call where it outputs to STDOUT the current directory’s listing. Following image shows the listing of the directoy by ls command (without strace). - - raghu@raghu-Linoxide ~ $ ls - -![ls command output](http://linoxide.com/wp-content/uploads/2014/08/03.ls_.png) - -#### 1.1 Find configuration file read by program #### - -One use of strace (Except debugging some problem) is that you can find out which configuration files are read by a program. For example, - - raghu@raghu-Linoxide ~ $ strace php 2>&1 | grep php.ini - -![Strace config file read by program](http://linoxide.com/wp-content/uploads/2014/08/04.strace_php_configuration.png) - -#### 1.2 Trace specific system call #### - -The -e option to strace command can be used to display certain system calls only (for example, open, write etc.) - -Lets trace only ‘open’ system call for cat command. - - raghu@raghu-Linoxide ~ $ strace -e open cat dead.letter - -![Stracing specific system call (open here)](http://linoxide.com/wp-content/uploads/2014/08/05.strace_open_systemcall.png) - -#### 1.3 Stracing a process #### - -The strace command can not only be used on the commands, but also on the running processes with -p option. - - raghu@raghu-Linoxide ~ $ sudo strace -p 1846 - -![Strace a process](http://linoxide.com/wp-content/uploads/2014/08/06.strace_process.png) - -#### 1.4 Statistical summary of strace #### - -The summary of the system calls, time of execution, errors etc. can be displayed in a neat manner with -c option: - - raghu@raghu-Linoxide ~ $ strace -c ls - -![Strace summary display](http://linoxide.com/wp-content/uploads/2014/08/07.strace_summary.png) - -#### 1.5 Saving output #### - -The output of strace command can be saved into a file with -o option. - - raghu@raghu-Linoxide ~ $ sudo strace -o process_strace -p 3229 - -![Strace a process](http://linoxide.com/wp-content/uploads/2014/08/08.strace_output_file.png) - -The above command is run with sudo as it will display error in case the user ID does not match with the process owner. - -### 1.6 Displaying timestamp ### - -The timestamp can be displayed before each output line with -t option. - - raghu@raghu-Linoxide ~ $ strace -t ls - -![Timestamp before each output line](http://linoxide.com/wp-content/uploads/2014/08/09.strace_timestamp.png) - -#### 1.7 The Finer timestamp #### - -The -tt option displays timestamp followed by microsecond. - - raghu@raghu-Linoxide ~ $ strace -tt ls - -![Time - Microseconds](http://linoxide.com/wp-content/uploads/2014/08/010.strace_finer_timestamp.png) - -The -ttt displays microseconds like above, but instead of printing surrent time, it displays the number of seconds since the epoch. - - raghu@raghu-Linoxide ~ $ strace -ttt ls - -![Seconds since epoch](http://linoxide.com/wp-content/uploads/2014/08/011.strace_epoch_seconds.png) - -#### 1.8 Relative Time #### - -The -r option displays the relative timestamp between the system calls. - - raghu@raghu-Linoxide ~ $ strace -r ls - -![Relative Timestamp](http://linoxide.com/wp-content/uploads/2014/08/012.strace_relative-time.png) - --------------------------------------------------------------------------------- - -via: http://linoxide.com/linux-command/linux-strace-command-examples/ - -作者:[Raghu][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://linoxide.com/author/raghu/ \ No newline at end of file diff --git a/sources/tech/20140819 Build a Raspberry Pi Arcade Machine.md b/sources/tech/20140819 Build a Raspberry Pi Arcade Machine.md deleted file mode 100644 index 6c0663723e..0000000000 --- a/sources/tech/20140819 Build a Raspberry Pi Arcade Machine.md +++ /dev/null @@ -1,135 +0,0 @@ -Build a Raspberry Pi Arcade Machine -================================================================================ -**Relive the golden majesty of the 80s with a little help from a marvel of the current decade.** - -### WHAT YOU’LL NEED ### - -- Raspberry Pi w/4GB SD-CARD. -- HDMI LCD monitor. -- Games controller or… -- A JAMMA arcade cabinet. -- J-Pac or I-Pac. - -The 1980s were memorable for many things; the end of the cold war, a carbonated drink called Quatro, the Korg Polysix synthesiser and the Commodore 64. But to a certain teenager, none of these were as potent, or as perhaps familiarly illicit, as the games arcade. Enveloped by cigarette smoke and a barrage of 8-bit sound effects, they were caverns you visited only on borrowed time: 50 pence and a portion of chips to see you through lunchtime while you honed your skills at Galaga, Rampage, Centipede, Asteroids, Ms Pacman, Phoenix, R-Rype, Donkey Kong, Rolling Thunder, Gauntlet, Street Fighter, Outrun, Defender… The list is endless. - -These games, and the arcade machine form factor that held them, are just as compelling today as they were 30 years ago. And unlike the teenage version of yourself, you can now play many of them without needing a pocket full of change, finally giving you an edge over the rich kids and their endless ‘Continues’. It’s time to build your own Linux-based arcade machine and beat that old high score. - -We’re going to cover all the steps required to turn a cheap shell of an arcade machine into a Linux-powered multi-platform retro games system. But that doesn’t mean you’ve got to build the whole system at the same scale. You could, for example, forgo the large, heavy and potentially carcinogenic hulk of the cabinet itself and stuff the controlling innards into an old games console or an even smaller case. Or you could just as easily forgo the diminutive Raspberry Pi and replace the brains of your system with a much more capable Linux machine. This might make an ideal platform for SteamOS, for example, and for playing some of its excellent modern arcade games. - -Over the next few pages we’ll construct a Raspberry Pi-based arcade machine, but you should be able to see plenty of ideas for your own projects, even if they don’t look just like ours. And because we’re building it on the staggeringly powerful MAME, you’ll be able to get it running on almost anything. - -![](http://www.linuxvoice.com/wp-content/uploads/2014/08/picade3.png) - -We did this project before the model B+ came out. It should all work exactly the same on the newer board, and you should be able to get by without a powered USB Hub (click for larger). - -### Disclaimer ### - -One again we’re messing with electrical components that could cause you a shock. Make sure you get any modifications you make checked by a qualified electrician. We don’t go into any details on how to obtain games, but there are legal sources such as old games releases and newer commercial titles based on the MAME emulator. - -#### Step1: The Cabinet #### - -The cabinet itself is the biggest challenge. We bought an old two-player Bubble Bobble machine from the early 90s from eBay. It cost £220 delivered in the back of an old estate car. The prices for cabinets like these can vary. We’ve seen many for less than £100. At the other end of the scale, people pay thousands for machines with original decals on the side. - -There are two major considerations when it comes to buying a cabinet. The first is the size: These things are big and heavy. They take up a lot of space and it takes at least two people to move them around. If you’ve got the money, you can buy DIY cabinets or new smaller form-factors, such as cabinets that fit on tables. And cocktail cabinets can be easier to fit, too. - -![](http://www.linuxvoice.com/wp-content/uploads/2014/08/picade4.jpg) - -Cabinets can be cheap, but they’re heavy. Don’t lift them on your own. Older ones may need some TLC, such as are-spray and some repair work(click for larger). - -One of the best reasons for buying an original cabinet, apart from getting a much more authentic gaming experience, is being able to use the original controls. Many machines you can buy on eBay will be for two concurrent players, with two joysticks and a variety of buttons for each player, plus the player one and player two controls. For compatibility with the widest number of games, we’d recommend finding a machine with six buttons for each player, which is a common configuration. You might also want to look into a panel with more than two players, or one with space for other input controllers, such as an arcade trackball (for games like Marble Madness), or a spinner (Arkanoid). These can be added without too much difficulty later, as modern USB devices exist. - -Controls are the second, and we’d say most important consideration, because it’s these that transfer your twitches and tweaks into game movement. What you need to consider for when buying a cabinet is something called JAMMA, an acronym for Japan Amusement Machinery Manufacturers. JAMMA is a standard in arcade machines that defines how the circuit board containing the game chips connects to the game controllers and the coin mechanism. It’s an interface conduit for all the cables coming from the buttons and the joysticks, for two players, bringing them into a standard edge connector. The JAMMA part is the size and layout of this connector, as it means the buttons and controls will be connected to the same functions on whichever board you install so that the arcade owner would only have to change the cabinet artwork to bring in new players. - -But first, a word of warning: the JAMMA connector also carries the 12V power supply, usually from a power unit installed in most arcade machines. We disconnecting the power supply completely to avoid damaging anything with a wayward short-circuit or dropped screwdriver. We don’t use any of the power connectors in any further stage of the tutorial. - -![](http://www.linuxvoice.com/wp-content/uploads/2014/08/picade2.png) - -#### Step 2: J-PAC #### - -What’s brilliant is that you can buy a device that connects to the JAMMA connector inside your cabinet and a USB port on your computer, transforming all the buttons presses and keyboard movements into (configurable) keyboard commands that you can use from Linux to control any game you wish. This device is called the J-Pac ([www.ultimarc.com/jpac.html][1] – approximately £54). - -Its best feature isn’t the connectivity; it’s the way it handles and converts the input signals, because it’s vastly superior to a standard USB joystick. Every input generates its own interrupt, and there’s no limit to the number of simultaneous buttons and directions you can press or hold down. This is vital for games like Street Fighter, because they rely on chords of buttons being pressed simultaneously and quickly, but it’s also essential when delivering the killing blow to cheating players who sulk and hold down all their own buttons. Many other controllers, especially those that create keyboard inputs, are restricted by their USB keyboard controllers to six inputs and a variety of Alt, Shift and Ctrl hacks. The J-Pac can also be connected to a tilt sensor and even some coin mechanisms, and it works in Linux without any pre-configuration. - -Another option is a similar device called an I-Pac. It does the same thing as the J-Pac, only without the JAMMA connector. That means you can’t connect your JAMMA controls, but it does mean you can design your own controller layout and wire each control to the I-Pac yourself. This might be a little ambitious for a first project, but it’s a route that many arcade aficionados take, especially when they want to design a panel for four players, or one that incorporates many different kinds of controls. Our approach isn’t necessarily one we’d recommend, but we re-wired an old X-Arcade Tankstick control panel that suffered from input contention, replaced the joysticks and buttons with new units and connected it to a new JAMMA harness, which is an excellent way of buying all the cables you need plus the edge connector for a low price (£8). - -![](http://www.linuxvoice.com/wp-content/uploads/2014/08/picade5.jpg) - -Our J-Pac in situ. The blue and red wires on the right connect to the extra 1- and 2-player buttons on our cabinet (click for larger). - -Whether you choose an I-Pac or a J-Pac, all the keys generated by both devices are the default values for MAME. That means you won’t have to make any manual input changes when you start to run the emulator. Player 1, for example, creates cursor up, down, left and right as well as left Ctrl, left ALT, Space and left Shift for fire buttons 1–4. But the really useful feature, for us, is the two-button shortcuts. While holding down the player 1 button, you can generate the P key to pause the game by pulling down on the player 1 joystick, adjust the volume by pressing up and enter MAME’s own configuration menu by pushing right. These escape codes are cleverly engineered to not get in the way of playing games, as they’re only activated when holding down the Player 1 button, and they enable you to do almost anything you need to from within a running game. You can completely reconfigure MAME, for example, using its own menus, and change input assignments and sensitivity while playing the game itself. - -Finally, holding down Player 1 and then pressing Player 2 will quit MAME, which is useful if you’re using a launch menu or MAME manager, as these manage launching games automatically, and let you get on with playing another game as quickly as possible. - -We took a rather cowardly route with the screen, removing the original, bulky and broken CRT that came with the cabinet and replacing it with a low-cost LCD monitor. This approach has many advantages. First, the screen has HDMI, so it will interface with a Raspberry Pi or a modern graphics card without any difficulty. Second, you don’t have to configure the low-frequency update modes required to drive an arcade machine’s screen, nor do you need the specific graphics hardware that drives it. And third, this is the safest option because an arcade machine’s screen is often unprotected from the rear of a case, leaving very high voltages inches away from your hands. That’s not to say you shouldn’t use a CRT if that’s the experience you’re after – it’s the most authentic way to get the gaming experience you’re after, but we’ve fined-tuned the CRT emulation enough in software that we’re happy with the output, and we’re definitely happier not to be using an ageing CRT. - -You might also want to look into using an older LCD with a 4:3 aspect ratio, rather than the widescreen modern options, because 4:3 is more practical for playing both vertical and horizontal games. A vertical shooter such as Raiden, for example, will have black bars on either side of the gaming area if you use a widescreen monitor. Those black bars can be used to display the game instructions, or you could rotate the screen 90 degrees so that every pixel is used, but this is impractical unless you’re only going to play vertical games or have easy access to a rotating mount. - -Mounting a screen is also important. If you’ve removed a CRT, there’s nowhere for an LCD to go. Our solution was to buy some MDF cut to fit the space where the CRT was. This was then screwed into position and we fitted a cheap VESA mounting plate into the centre of the new MDF. VESA mounts can be used by the vast majority of screens, big and small. Finally, because our cabinet was fronted with smoked glass, we had to be sure both the brightness and contrast were set high enough. - -### Step 3: Installation ### - -With the large hardware choices now made, and presumably the cabinet close to where you finally want to install it, putting the physical pieces together isn’t that difficult. We safely split the power input from the rear of the cabinet and wired a multiple socket into the space at the back. We did this to the cable after it connects to the power switch. - -Nearly all arcade cabinets have a power switch on the top-right surface, but there’s usually plenty of cable to splice into this at a lower point in the cabinet, and it meant we could use normal power connectors for our equipment. Our cabinet has a fluorescent tube, used to backlight the top marquee on the machine, connected directly to the power, and we were able to keep this connected by attaching a regular plug. When you turn the power on from the cabinet switch, power flows to the components inside the case – your Raspberry Pi and screen will come on, and all will be well with the world. - -The J-Pac slides straight into the JAMMA interface, but you may also have to do a little manual wiring. The JAMMA standard only supports up to three buttons for each player (although many unofficially support four), while the J-Pac can handle up to six buttons. To get those extra buttons connected, you need to connect one side of the button’s switch to GND fed from the J-Pac with the other side of the switch going into one of the screw-mounted inputs in the side of the J-Pac. These are labelled 1SW4, 1SW5, 1SW6, 2SW4, 2SW5 and 2SW6. The J-Pac also includes passthrough connections for audio, but we’ve found this to be incredibly noisy. Instead, we wired the speaker in our cabinet to an old SoundBlaster amplifier and connected this to the audio outputs on the Raspberry Pi. You don’t want audio to be pristine, but you do want it to be loud enough. - -![](http://www.linuxvoice.com/wp-content/uploads/2014/08/picade6.jpg) - -Our Raspberry Pi is now connected to the J-Pac on the left and both the screen and the USB hub (click for larger). - -The J-Pac or I-Pac then connects to your PC or Raspberry Pi using a PS2-to-USB cable, which should also be used to connect to a PS2 port on your PC directly. There is an additional option to use an old PS2 connector, if your PC is old enough to have one, but we found in testing that the USB performance is identical. This won’t apply to the PS2-less Raspberry Pi, of course, and don’t forget that the Pi will also need powering. We always recommend doing so from a compatible powered hub, as a lack of power is the most common source of Raspberry Pi errors. You’ll also need to get networking to your Raspberry Pi, either through the Ethernet port (perhaps using a powerline adaptor hidden in the cabinet), or by using a wireless USB device. Networking is essential because it enables you to reconfigure your PI while it’s tucked away within the cabinet, and it also enables you to change settings and perform administration tasks without having to connect a keyboard or mouse. - -> ### Coin Mechanism ### - -> In the emulation community, getting your coin mechanism to work with your emulator was often considered a step too close to commercial production. It meant you could potential charge people to use your machine. Not only would this be wrong, but considering the provenance of many of the games you run on your own arcade machine, it could also be illegal. And it’s definitely against the spirit of emulation. However, we and many other devotees thinking that a working coin mechanism is another step closer to the realism of an arcade machine, and is worth the effort in recreating the nostalgia of an old arcade. There’s nothing like dropping a 10p piece into the coin tray and to hear the sound of the credits being added to the machine. - -> It’s not actually that difficult. It depends on the coin mechanism in your arcade machine and how it sends a signal to say how many credits had been inserted. Most coin mechanisms come in two parts. The large part is the coin acceptor/validator. This is the physical side of the process that detects whether a coin is authentic, and determines its value. It does this with the help of a credit/logic board, usually attached via a ribbon cable and featuring lots of DIP switches. These switches are used to change which coins are accepted and how many credits they generate. It’s then usually as simple as finding the output switch, which is triggered with a credit, and connecting this to the coin input on your JAMMA connector, or directly onto the J-Pac. Our coin mechanism is a Mars MS111, common in the UK in the early 90s, and there’s plenty of information online about what each of the DIP switches do, as well as how to programme the controller for newer coins. We were also able to wire the 12V connector from the mechanism to a small light for behind the coin entry slot. - -#### Step 4: Software #### - -MAME is the only viable emulator for a project of this scale, and it now supports many thousands of different games running on countless different platforms, from the first arcade machines through to some more recent ones. It’s a project that has also spawned MESS, the multi-emulator super system, which targets platforms such as home computers and consoles from the 80s and 90s. - -Configuring MAME could take a six-page article in itself. It’s a complex, sprawling, magnificent piece of software that emulates so many CPUs, so many sound devices, chips, controllers with so many options, that like MythTV, you never really stop configuring it. - -But there’s an easier option, and one that’s purpose-built for the Raspberry Pi. It’s called PiMAME. This is both a distribution download and a script you can run on top of Raspbian, the Pi’s default distribution. Not only does it install MAME on your Raspberry Pi (which is useful because it’s not part of any of the default repositories), it also installs a selection of other emulators along with front-ends to manage them. MAME, for example, is a command-line utility with dozens of options. But PiMAME has another clever trick up its sleeve – it installs a simple web server that enables you to install new games through a browser connected to your network. This is a great advantage, because getting games into the correct folders is one of the trials of dealing with MAME, and it also enables you to make best use of whatever storage you’ve got connected to your Pi. Plus, PiMAME will update itself from the same script you use to install it, so keeping on top of updates couldn’t be easier. This could be especially useful at the moment, as at the time of writing the project was on the cusp of a major upgrade in the form of the 0.8 release. We found it slightly unstable in early March, but we’re sure everything will be sorted by the time you read this. - -The best way to install PiMAME is to install Raspbian first. You can do this either through NOOBS, using a graphical tool from your desktop, or by using the dd command to copy the contents of the Raspbian image directly onto your SD card. As we mentioned in last month’s BrewPi tutorial, this process has been documented many times before, so we won’t waste the space here. Just install NOOBS if you want the easy option, following the instructions on the Raspberry Pi site. With Raspbian installed and running, make sure you use the configuration tool to free the space on your SD card, and that the system is up to date (sudo apt-get update; sudo apt-get upgrade). You then need to make sure you’ve got the git package already installed. Any recent version of Raspbian will have installed git already, but you can check by typing sudo apt-get install git just to check. - -You then have to type the following command to clone the PiMAME installer from the project’s GitHub repository: - - git clone https://github.com/ssilverm/pimame_installer - -After that, you should get the following feedback if the command works: - - Cloning into ‘pimame_installer’... - remote: Reusing existing pack: 2306, done. - remote: Total 2306 (delta 0), reused 0 (delta 0) - Receiving objects: 100% (2306/2306), 4.61 MiB | 11 KiB/s, done. - Resolving deltas: 100% (823/823), done. - -This command will create a new folder called ‘pimame_installer’, and the next step is to switch into this and run the script it contains: - - cd pimame_installer/ - sudo ./install.sh - -This command installs and configures a lot of software. The length of time it takes will depend on your internet connection, as a lot of extra packages are downloaded. Our humble Pi with a 15Mb internet connection took around 45 minutes to complete the script, after which you’re invited to restart the machine. You can do this safely by typing sudo shutdown -r now, as this command will automatically handle any remaining write operations to the SD card. - -And that’s all there is to the installation. After rebooting your Pi, you will be automatically logged in and the PiMAME launch menu will appear. It’s a great-looking interface in version 0.8, with photos of each of the platforms supported, plus small red icons to indicate how many games you’ve got installed.This should now be navigable through your controller. If you want to make sure the controller is correctly detected, use SSH to connect to your Pi and check for the existence of **/dev/input/by-id/usb-Ultimarc_I-PAC_Ultimarc_I-PAC-event-kbd**. - -The default keyboard controls will enable you to select what kind of emulator you want to run on your arcade machine. The option we’re most interested in is the first, labelled ‘AdvMAME’, but you might also be surprised to see another MAME on offer, MAME4ALL. MAME4ALL is built specifically for the Raspberry Pi, and takes an old version of the MAME source code so that the performance of the ROMS that it does support is optimal. This makes a lot of sense, because there’s no way your Pi is going to be able to play anything too demanding, so there’s no reason to belabour the emulator with unneeded compatibility. All that’s left to do now is get some games onto your system (see the boxout below), and have fun! - -![](http://www.linuxvoice.com/wp-content/uploads/2014/08/picade1.png) - --------------------------------------------------------------------------------- - -via: http://www.linuxvoice.com/arcade-machine/ - -作者:[Ben Everard][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://www.linuxvoice.com/author/ben_everard/ -[1]:http://www.ultimarc.com/jpac.html \ No newline at end of file diff --git a/sources/tech/20140819 How to Encrypt Email in Linux.md b/sources/tech/20140819 How to Encrypt Email in Linux.md deleted file mode 100644 index d878e1cd4c..0000000000 --- a/sources/tech/20140819 How to Encrypt Email in Linux.md +++ /dev/null @@ -1,106 +0,0 @@ -[translating by KayGuoWhu] -How to Encrypt Email in Linux -================================================================================ -![Kgpg provides a nice GUI for creating and managing your encryption keys.](http://www.linux.com/images/stories/41373/fig-1-kgpg.png) -Kgpg provides a nice GUI for creating and managing your encryption keys. - -If you've been thinking of encrypting your email, it is a rather bewildering maze to sort through thanks to the multitude of email services and mail clients. There are two levels of encryption to consider: SSL/TLS encryption protects your login and password to your mailserver. [GnuPG][1] is the standard strong Linux encryption tool, and it encrypts and authenticates your messages. It is best if you manage your own GPG encryption and not leave it up to third parties, which we will discuss in a moment. - -Encrypting messages still leaves you vulnerable to traffic analysis, as message headers must be in the clear. So that necessitates yet another tool such as the [Tor network][2] for hiding your Internet footprints. Let's look at various mail services and clients, and the pitfalls and benefits therein. - -### Forget Webmail ### - -If you use GMail, Yahoo, Hotmail, or another Web mail provider, forget about it. Anything you type in a Web browser is vulnerable to JavaScript attacks, and whatever mischiefs the service provider engages in. GMail, Yahoo, and Hotmail all offer SSL/TLS encryption to protect your messages from wiretapping. But they offer no protections from their own data-mining habits, so they don't offer end-to-end encryption. Yahoo and Google both claim they're going to roll out end-to-end encryption next year. Color me skeptical, because they will wither and die if anything interferes with the data-mining that is their core business. - -There are various third-party email security services such as [Virtru][3] and [SafeMess][4] that claim to offer secure encryption for all types of email. Again I am skeptical, because whoever holds your encryption keys has access to your messages, so you're still depending on trust rather than technology. - -Peer messaging avoids many of the pitfalls of using centralized services. [RetroShare][5] and [Bitmessage][6] are two popular examples of this. I don't know if they live up to their claims, but the concept certainly has merit. - -What about Android and iOS? It's safest to assume that the majority of Android and iOS apps are out to get you. Don't take my word for it-- read their terms of service and examine the permissions they require to install on your devices. And even if their terms are acceptable when you first install them, unilateral TOS changes are industry standard, so it is safest to assume the worst. - -### Zero Knowledge ### - -[Proton Mail][7] is a new email service that claims zero-knowledge message encryption. Authentication and message encryption are two separate steps, Proton is under Swiss privacy laws, and they do not log user activity. Zero knowledge encryption offers real security. This means that only you possess your encryption keys, and if you lose them your messages are not recoverable. - -There are many encrypted email services that claim to protect your privacy. Read the fine print carefully and look for red flags such as limited user data collection, sharing with partners, and cooperation with law enforcement. These indicate that they collect and share user data, and have access to your encryption keys and can read your messages. - -### Linux Mail Clients ### - -A standalone open source mail client such as KMail, Thunderbird, Mutt, Claws, Evolution, Sylpheed, or Alpine, set up with your own GnuPG keys that you control gives you the most protection. (The easiest way to set up more secure email and Web surfing is to run the TAILS live Linux distribution. See [Protect Yourself Online With Tor, TAILS, and Debian][8].) - -Whether you use TAILS or a standard Linux distro, managing GnuPG is the same, so let's learn how to encrypt messages with GnuPG. - -### How to Use GnuPG ### - -First, a quick bit of terminology. OpenPGP is an open email encryption and authentication protocol, based on Phil Zimmerman's Pretty Good Privacy (PGP). GNU Privacy Guard (GnuPG or GPG) is the GPL implementation of OpenPGP. GnuPG uses symmetric public key cryptography. This means that you create pairs of keys: a public key that anyone can use to encrypt messages to send to you, and a private key that only you possess to decrypt them. GnuPG performs two separate functions: digitally-signing messages to prove they came from you, and encrypting messages. Anyone can read your digitally-signed messages, but only people you have exchanged keys with can read your encrypted messages. Remember, never share your private keys! Only public keys. - -Seahorse is GNOME's graphical front-end to GnuPG, and KGpg is KDE's graphical GnuPG tool. - -Now let's run through the basic steps of creating and managing GnuPG keys. This command creates a new key: - - $ gpg --gen-key - -This is a multi-step process; just answer all the questions, and the defaults are fine for most people. When you create your passphrase, write it down and keep it in a secure place because if you lose it you cannot decrypt anything. All that advice about never writing down your passwords is wrong. Most of us have dozens of logins and passwords to track, including some that we rarely use, so it's not realistic to remember all of them. You know what happens when people don't write down their passwords? They create simple passwords and re-use them. Anything you store on your computer is potentially vulnerable; a nice little notebook kept in a locked drawer is impervious to everything but a physical intrusion, if an intruder even knew to look for it. - -I must leave it as your homework to figure out how to configure your mail client to use your new key, as every one is different. You can list your key or keys: - - $ gpg --list-keys - /home/carla/.gnupg/pubring.gpg - ------------------------------ - pub 2048R/587DD0F5 2014-08-13 - uid Carla Schroder (my gpg key) - sub 2048R/AE05E1E4 2014-08-13 - -This is a fast way to grab necessary information like the location of your keys, and your key name, which is the UID. Suppose you want to upload your public key to a keyserver; this is how it looks using my example key: - - $ gpg --send-keys 'Carla Schroder' --keyserver http://example.com - -When you create a new key for upload to public key servers, you should also create a revocation certificate. Don't do it later-- create it when you create your new key. You can give it any arbitrary name, so instead of revoke.asc you could give it a descriptive name like mycodeproject.asc: - - $ gpg --output revoke.asc --gen-revoke 'Carla Schroder' - -Now if your key ever becomes compromised you can revoke it by first importing the revocation certificate into your keyring: - - $ gpg --import ~/.gnupg/revoke.asc - -Then create and upload a new key to replace it. Any users of your old key will be notified as they refresh their key databases. - -You must guard your revocation certificate just as zealously as your private key. Copy it to a CD or USB stick and lock it up, and delete it from your computer. It is a plain-text key, so you could even print it on paper. - -If you ever need a copy-and-paste key, for example on public keyrings that allow pasting your key into a web form, or if you want to post your public key on your Web site, then you must create an ASCII-armored version of your public key: - - $ gpg --output carla-pubkey.asc --export -a 'Carla Schroder' - -This creates the familiar plain-text public key you've probably seen, like this shortened example: - - -----BEGIN PGP PUBLIC KEY BLOCK----- - Version: GnuPG v1 - mQENBFPrn4gBCADeEXKdrDOV3AFXL7QQQ+i61rMOZKwFTxlJlNbAVczpawkWRC3l - IrWeeJiy2VyoMQ2ZXpBLDwGEjVQ5H7/UyjUsP8h2ufIJt01NO1pQJMwaOMcS5yTS - [...] - I+LNrbP23HEvgAdNSBWqa8MaZGUWBietQP7JsKjmE+ukalm8jY8mdWDyS4nMhZY= - =QL65 - -----END PGP PUBLIC KEY BLOCK----- - -That should get you started learning your way around GnuPG. [The GnuPG manuals][9] have complete details on using GnuPG and all of its options. - --------------------------------------------------------------------------------- - -via: http://www.linux.com/learn/tutorials/784165-how-to-encrypt-email-in-linux - -作者:[Carla Schroder][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://www.linux.com/component/ninjaboard/person/3734 -[1]:http://www.openpgp.org/members/gnupg.shtml -[2]:https://www.torproject.org/ -[3]:https://www.virtru.com/ -[4]:https://www.safemess.com/ -[5]:http://retroshare.sourceforge.net/ -[6]:http://retroshare.sourceforge.net/ -[7]:https://protonmail.ch/ -[8]:http://www.linux.com/learn/docs/718398-protect-yourself-online-with-tor-+tails-and-debian -[9]:https://www.gnupg.org/documentation/manuals.html \ No newline at end of file diff --git a/sources/tech/20140821 How to sniff HTTP traffic from the command line on Linux.md b/sources/tech/20140821 How to sniff HTTP traffic from the command line on Linux.md deleted file mode 100644 index 69d3402043..0000000000 --- a/sources/tech/20140821 How to sniff HTTP traffic from the command line on Linux.md +++ /dev/null @@ -1,103 +0,0 @@ -How to sniff HTTP traffic from the command line on Linux -================================================================================ -Suppose you want to sniff live HTTP web traffic (i.e., HTTP requests and responses) on the wire for some reason. For example, you may be testing experimental features of a web server. Or you may be debugging a web application or a RESTful service. Or you may be trying to troubleshoot [PAC (proxy auto config)][1] or check for any malware files surreptitiously downloaded from a website. Whatever the reason is, there are cases where HTTP traffic sniffing is helpful, for system admins, developers, or even end users. - -While [packet sniffing tools][2] such as tcpdump are popularly used for live packet dump, you need to set up proper filtering to capture HTTP traffic, and even then, their raw output typically cannot be interpreted on the HTTP protocol level so easily. Real-time web server log parsers such as [ngxtop][3] provide human-readable real-time web traffic traces, but only applicable with a full access to live web server logs. - -What will be nice is to have tcpdump-like traffic sniffing tool, but targeting HTTP traffic only. In fact, [httpry][4] is extactly that: **HTTP packet sniffing tool**. httpry captures live HTTP packets on the wire, and displays their content at the HTTP protocol level in a human-readable format. In this tutorial, let's see how we can sniff HTTP traffic with httpry. - -### Install httpry on Linux ### - -On Debian-based systems (Ubuntu or Linux Mint), httpry is not available in base repositories. So build it from the source: - - $ sudo apt-get install gcc make git libpcap0.8-dev - $ git clone https://github.com/jbittel/httpry.git - $ cd httpry - $ make - $ sudo make install - -On Fedora, CentOS or RHEL, you can install httpry with yum as follows. On CentOS/RHEL, enable [EPEL repo][5] before running yum. - - $ sudo yum install httpry - -If you still want to build httpry from the source, you can easily do that by: - - $ sudo yum install gcc make git libpcap-devel - $ git clone https://github.com/jbittel/httpry.git - $ cd httpry - $ make - $ sudo make install - -### Basic Usage of httpry ### - -The basic use case of httpry is as follows. - - $ sudo httpry -i - -httpry then listens on a specified network interface, and displays captured HTTP requests/responses in real time. - -![](https://farm4.staticflickr.com/3883/14985851635_7b94787c6d_z.jpg) - -In most cases, however, you will be swamped with the fast scrolling output as packets are coming in and out. So you want to save captured HTTP packets for offline analysis. For that, use either '-b' or '-o' options. The '-b' option allows you to save raw HTTP packets into a binary file as is, which then can be replayed with httpry later. On the other hand, '-o' option saves human-readable output of httpry into a text file. - -To save raw HTTP packets into a binary file: - - $ sudo httpry -i eth0 -b output.dump - -To replay saved HTTP packets: - - $ httpry -r output.dump - -Note that when you read a dump file with '-r' option, you don't need root privilege. - -To save httpr's output to a text file: - - $ sudo httpry -i eth0 -o output.txt - -### Advanced Usage of httpry ### - -If you want to monitor only specific HTTP methods (e.g., GET, POST, PUT, HEAD, CONNECT, etc), use '-m' option: - - $ sudo httpry -i eth0 -m get,head - -![](https://farm6.staticflickr.com/5551/14799184220_3b449d422c_z.jpg) - -If you downloaded httpry's source code, you will notice that the source code comes with a collection of Perl scripts which aid in analyzing httpry's output. These scripts are found in httpry/scripts/plugins directory. If you want to write a custom parser for httpry's output, these scripts can be good examples to start from. Some of their capabilities are: - -- **hostnames**: Displays a list of unique host names with counts. -- **find_proxies**: Detect web proxies. -- **search_terms**: Find and count search terms entered in search services. -- **content_analysis**: Find URIs which contain specific keywords. -- **xml_output**: Convert output into XML format. -- **log_summary**: Generate a summary of log. -- **db_dump**: Dump log file data into a database. - -Before using these scripts, first run httpry with '-o' option for some time. Once you obtained the output file, run the scripts on it at once by using this command: - - $ cd httpry/scripts - $ perl parse_log.pl -d ./plugins - -You may encounter warnings with several plugins. For example, db_dump plugin may fail if you haven't set up a MySQL database with DBI interface. If a plugin fails to initialize, it will automatically be disabled. So you can ignore those warnings. - -After parse_log.pl is completed, you will see a number of analysis results (*.txt/xml) in httpry/scripts directory. For example, log_summary.txt looks like the following. - -![](https://farm4.staticflickr.com/3845/14799162189_b85abdf21d_z.jpg) - -To conclude, httpry can be a life saver if you are in a situation where you need to interpret live HTTP packets. That might not be so common for average Linux users, but it never hurts to be prepared. What do you think of this tool? - --------------------------------------------------------------------------------- - -via: http://xmodulo.com/2014/08/sniff-http-traffic-command-line-linux.html - -作者:[Dan Nanni][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://xmodulo.com/author/nanni -[1]:http://xmodulo.com/2012/12/how-to-set-up-proxy-auto-config-on-ubuntu-desktop.html -[2]:http://xmodulo.com/2012/11/what-are-popular-packet-sniffers-on-linux.html -[3]:http://xmodulo.com/2014/06/monitor-nginx-web-server-command-line-real-time.html -[4]:http://dumpsterventures.com/jason/httpry/ -[5]:http://xmodulo.com/2013/03/how-to-set-up-epel-repository-on-centos.html \ No newline at end of file diff --git a/sources/tech/20140826 How to configure SNMPv3 on ubuntu 14.04 server.md b/sources/tech/20140826 How to configure SNMPv3 on ubuntu 14.04 server.md deleted file mode 100644 index d76ba38676..0000000000 --- a/sources/tech/20140826 How to configure SNMPv3 on ubuntu 14.04 server.md +++ /dev/null @@ -1,99 +0,0 @@ -How to configure SNMPv3 on ubuntu 14.04 server -================================================================================ -Simple Network Management Protocol (SNMP) is an "Internet-standard protocol for managing devices on IP networks". Devices that typically support SNMP include routers, switches, servers, workstations, printers, modem racks and more.It is used mostly in network management systems to monitor network-attached devices for conditions that warrant administrative attention. SNMP is a component of the Internet Protocol Suite as defined by the Internet Engineering Task Force (IETF). It consists of a set of standards for network management, including an application layer protocol, a database schema, and a set of data objects.[2] - -SNMP exposes management data in the form of variables on the managed systems, which describe the system configuration. These variables can then be queried (and sometimes set) by managing applications. - -### Why you want to use SNMPv3 ### - -Although SNMPv3 makes no changes to the protocol aside from the addition of cryptographic security, it looks much different due to new textual conventions, concepts, and terminology. - -SNMPv3 primarily added security and remote configuration enhancements to SNMP. - -Security has been the biggest weakness of SNMP since the beginning. Authentication in SNMP Versions 1 and 2 amounts to nothing more than a password (community string) sent in clear text between a manager and agent.[1] Each SNMPv3 message contains security parameters which are encoded as an octet string. The meaning of these security parameters depends on the security model being used. - -SNMPv3 provides important security features: - -Confidentiality -- Encryption of packets to prevent snooping by an unauthorized source. - -Integrity -- Message integrity to ensure that a packet has not been tampered while in transit including an optional packet replay protection mechanism. - -Authentication -- to verify that the message is from a valid source. - -### Install SNMP server and client in ubuntu ### - -Open the terminal and run the following command - - sudo apt-get install snmpd snmp - -After installation you need to do the following changes. - -### Configuring SNMPv3 in Ubuntu ### - -Get access to the daemon from the outside. - -The default installation only provides access to the daemon for localhost. In order to get access from the outside open the file /etc/default/snmpd in your favorite editor - - sudo vi /etc/default/snmpd - -Change the following line - -From - - SNMPDOPTS='-Lsd -Lf /dev/null -u snmp -g snmp -I -smux,mteTrigger,mteTriggerConf -p /var/run/snmpd.pid' - -to - - SNMPDOPTS='-Lsd -Lf /dev/null -u snmp -I -smux -p /var/run/snmpd.pid -c /etc/snmp/snmpd.conf' - -and restart snmpd - - sudo /etc/init.d/snmpd restart - -### Define SNMPv3 users, authentication and encryption parameters ### - -SNMPv3 can be used in a number of ways depending on the “securityLevel” configuration parameter: - -noAuthNoPriv -- No authorisation and no encryption, basically no security at all! -authNoPriv -- Authorisation is required but collected data sent over the network is not encrypted. -authPriv -- The strongest form. Authorisation required and everything sent over the network is encrypted. - -The snmpd configuration settings are all saved in a file called /etc/snmp/snmpd.conf. Open this file in your editor as in: - - sudo vi /etc/snmp/snmpd.conf - -Add the following lines to the end of the file: - - # - createUser user1 - createUser user2 MD5 user2password - createUser user3 MD5 user3password DES user3encryption - # - rouser user1 noauth 1.3.6.1.2.1.1 - rouser user2 auth 1.3.6.1.2.1 - rwuser user3 priv 1.3.6.1.2.1 - -Note:- If you want to use your own username/password combinations you need to note that the password and encryption phrases should have a length of at least 8 characters - -Also you need to do the following change so that snmp can listen for connections on all interfaces - -From - - #agentAddress udp:161,udp6:[::1]:161 - -to - - agentAddress udp:161,udp6:[::1]:161 - -Save your modified snmpd.conf file and restart the daemon with: - - sudo /etc/init.d/snmpd restart - --------------------------------------------------------------------------------- - -via: http://www.ubuntugeek.com/how-to-configure-snmpv3-on-ubuntu-14-04-server.html - -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 \ No newline at end of file diff --git a/sources/tech/20140826 Linux Tutorial--Install Ansible Configuration Management And IT Automation Tool.md b/sources/tech/20140826 Linux Tutorial--Install Ansible Configuration Management And IT Automation Tool.md deleted file mode 100644 index b2b007b3e2..0000000000 --- a/sources/tech/20140826 Linux Tutorial--Install Ansible Configuration Management And IT Automation Tool.md +++ /dev/null @@ -1,466 +0,0 @@ -Linux Tutorial: Install Ansible Configuration Management And IT Automation Tool -================================================================================ -![](http://s0.cyberciti.org/uploads/cms/2014/08/ansible_core_circle.png) - -Today I will be talking about ansible, a powerful configuration management solution written in python. There are many configuration management solutions available, all with pros and cons, ansible stands apart from many of them for its simplicity. What makes ansible different than many of the most popular configuration management systems is that its agent-less, no need to setup agents on every node you want to control. Plus, this has the benefit of being able to control you entire infrastructure from more than one place, if needed. That last point's validity, of being a benefit, may be debatable but I find it as a positive in most cases. Enough talk, lets get started with Ansible installation and configuration on a RHEL/CentOS, and Debian/Ubuntu based systems. - -### Prerequisites ### - -1. Distro: RHEL/CentOS/Debian/Ubuntu Linux -1. Jinja2: A modern and designer friendly templating language for Python. -1. PyYAML: A YAML parser and emitter for the Python programming language. -1. parmiko: Native Python SSHv2 protocol library. -1. httplib2: A comprehensive HTTP client library. -1. Most of the actions listed in this post are written with the assumption that they will be executed by the root user running the bash or any other modern shell. - -How Ansible works - -Ansible tool uses no agents. It requires no additional custom security infrastructure, so it’s easy to deploy. All you need is ssh client and server: - - +----------------------+ +---------------+ - |Linux/Unix workstation| SSH | file_server1 | - |with Ansible |<------------------>| db_server2 | Unix/Linux servers - +----------------------+ Modules | proxy_server3 | in local/remote - 192.168.1.100 +---------------+ data centers - -Where, - -1. 192.168.1.100 - Install Ansible on your local workstation/server. -1. file_server1..proxy_server3 - Use 192.168.1.100 and Ansible to automates configuration management of all servers. -1. SSH - Setup ssh keys between 192.168.1.100 and local/remote servers. - -### Ansible Installation Tutorial ### - -Installation of ansible is a breeze, many distributions have a package available in their 3rd party repos which can easily be installed, a quick alternative is to just pip install it or grab the latest copy from github. To install using your package manager, on [RHEL/CentOS Linux based systems you will most likely need the EPEL repo][1] then: - -#### Install ansible on a RHEL/CentOS Linux based system #### - -Type the following [yum command][2]: - - $ sudo yum install ansible - -#### Install ansible on a Debian/Ubuntu Linux based system #### - -Type the following [apt-get command][3]: - - $ sudo apt-get install software-properties-common - $ sudo apt-add-repository ppa:ansible/ansible - $ sudo apt-get update - $ sudo apt-get install ansible - -#### Install ansible using pip #### - -The [pip command is a tool for installing and managing Python packages][4], such as those found in the Python Package Index. The following method works on Linux and Unix-like systems: - - $ sudo pip install ansible - -#### Install the latest version of ansible using source code #### - -You can install the latest version from github as follows: - - $ cd ~ - $ git clone git://github.com/ansible/ansible.git - $ cd ./ansible - $ source ./hacking/env-setup - -When running ansible from a git checkout, one thing to remember is that you will need to setup your environment everytime you want to use it, or you can add it to your bash rc file: - - # ADD TO BASH RC - $ echo "export ANSIBLE_HOSTS=~/ansible_hosts" >> ~/.bashrc - $ echo "source ~/ansible/hacking/env-setup" >> ~/.bashrc - -The hosts file for ansible is basically a list of hosts that ansible is able to perform work on. By default ansible looks for the hosts file at /etc/ansible/hosts, but there are ways to override that which can be handy if you are working with multiple installs or have several different clients for whose datacenters you are responsible for. You can pass the hosts file on the command line using the -i option: - - $ ansible all -m shell -a "hostname" --ask-pass -i /etc/some/other/dir/ansible_hosts - -My preference however is to use and environment variable, this can be useful if source a different file when starting work for a specific client. The environment variable is $ANSIBLE_HOSTS, and can be set as follows: - - $ export ANSIBLE_HOSTS=~/ansible_hosts - -Once all requirements are installed and you have you hosts file setup you can give it a test run. For a quick test I put 127.0.0.1 into the ansible hosts file as follow: - - $ echo "127.0.0.1" > ~/ansible_hosts - -Now lets test with a quick ping: - - $ ansible all -m ping - -OR ask for the ssh password: - - $ ansible all -m ping --ask-pass - -I have run across a problem a few times regarding initial setup, it is highly recommended you setup keys for ansible to use but in the previous test we used --ask-pass, on some machines you will need [to install sshpass][5] or add a -c paramiko like so: - - $ ansible all -m ping --ask-pass -c paramiko - -Or you [can install sshpass][6], however sshpass is not always available in the standard repos so paramiko can be easier. - -### Setup SSH Keys ### - -Now that we have gotten the configuration, and other simple stuff, out of the way lets move onto doing something productive. Alot of the power of ansible lies in playbooks, which are basically scripted ansible runs (for the most part), but we will start with some one liners before we build out a playbook. Lets start with creating and configuring keys so we can avoid the -c and --ask-pass options: - - $ ssh-keygen -t rsa - -Sample outputs: - - Generating public/private rsa key pair. - Enter file in which to save the key (/home/mike/.ssh/id_rsa): - Enter passphrase (empty for no passphrase): - Enter same passphrase again: - Your identification has been saved in /home/mike/.ssh/id_rsa. - Your public key has been saved in /home/mike/.ssh/id_rsa.pub. - The key fingerprint is: - 94:a0:19:02:ba:25:23:7f:ee:6c:fb:e8:38:b4:f2:42 mike@ultrabook.linuxdork.com - The key's randomart image is: - +--[ RSA 2048]----+ - |... . . | - |. . + . . | - |= . o o | - |.* . | - |. . . S | - | E.o | - |.. .. | - |o o+.. | - | +o+*o. | - +-----------------+ - -Now obviously there are plenty of ways to put this in place on the remote machine but since we are using ansible, lets use that: - - $ ansible all -m copy -a "src=/home/mike/.ssh/id_rsa.pub dest=/tmp/id_rsa.pub" --ask-pass -c paramiko - -Sample outputs: - - SSH password: - 127.0.0.1 | success >> { - "changed": true, - "dest": "/tmp/id_rsa.pub", - "gid": 100, - "group": "users", - "md5sum": "bafd3fce6b8a33cf1de415af432774b4", - "mode": "0644", - "owner": "mike", - "size": 410, - "src": "/home/mike/.ansible/tmp/ansible-tmp-1407008170.46-208759459189201/source", - "state": "file", - "uid": 1000 - } - -Next, add the public key in remote server, enter: - - $ ansible all -m shell -a "cat /tmp/id_rsa.pub >> /root/.ssh/authorized_keys" --ask-pass -c paramiko - -Sample outputs: - - SSH password: - 127.0.0.1 | FAILED | rc=1 >> - /bin/sh: /root/.ssh/authorized_keys: Permission denied - -Whoops, we want to be able to run things as root, so lets add a -u option: - - $ ansible all -m shell -a "cat /tmp/id_rsa.pub >> /root/.ssh/authorized_keys" --ask-pass -c paramiko -u root - -Sample outputs: - - SSH password: - 127.0.0.1 | success | rc=0 >> - -Please note, I wanted to demonstrate a file transfer using ansible, there is however a more built in way for managing keys using ansible: - - $ ansible all -m authorized_key -a "user=mike key='{{ lookup('file', '/home/mike/.ssh/id_rsa.pub') }}' path=/home/mike/.ssh/authorized_keys manage_dir=no" --ask-pass -c paramiko - -Sample outputs: - - SSH password: - 127.0.0.1 | success >> { - "changed": true, - "gid": 100, - "group": "users", - "key": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCq+Z8/usprXk0aCAPyP0TGylm2MKbmEsHePUOd7p5DO1QQTHak+9gwdoJJavy0yoUdi+C+autKjvuuS+vGb8+I+8mFNu5CvKiZzIpMjZvrZMhHRdNud7GuEanusTEJfi1pUd3NA2iXhl4a6S9a/4G2mKyf7QQSzI4Z5ddudUXd9yHmo9Yt48/ASOJLHIcYfSsswOm8ux1UnyeHqgpdIVONVFsKKuSNSvZBVl3bXzhkhjxz8RMiBGIubJDBuKwZqNSJkOlPWYN76btxMCDVm07O7vNChpf0cmWEfM3pXKPBq/UBxyG2MgoCGkIRGOtJ8UjC/daadBUuxg92/u01VNEB mike@ultrabook.linuxdork.com", - "key_options": null, - "keyfile": "/home/mike/.ssh/authorized_keys", - "manage_dir": false, - "mode": "0600", - "owner": "mike", - "path": "/home/mike/.ssh/authorized_keys", - "size": 410, - "state": "file", - "uid": 1000, - "unique": false, - "user": "mike" - } - -Now that the keys are in place lets try running an arbitrary command like hostname and hope we don't get prompted for a password - - $ ansible all -m shell -a "hostname" -u root - -Sample outputs: - - 127.0.0.1 | success | rc=0 >> - -Success!!! Now that we can run commands as root and not be bothered by using a password we are in a good place to easily configure any and all hosts in the ansible hosts file. Let's remove the key from /tmp: - - $ ansible all -m file -a "dest=/tmp/id_rsa.pub state=absent" -u root - -Sample outputs: - - 127.0.0.1 | success >> { - "changed": true, - "path": "/tmp/id_rsa.pub", - "state": "absent" - } - -Next, I'm going to make sure we have a few packages installed and on the latest version and we will move on to something a little more complicated: - - $ ansible all -m zypper -a "name=apache2 state=latest" -u root - -Sample outputs: - - 127.0.0.1 | success >> { - "changed": false, - "name": "apache2", - "state": "latest" - } - -Alright, the key we placed in /tmp is now absent and we have the latest version of apache installed. This brings me to the next point, something that makes ansible very flexible and gives more power to playbooks, many may have noticed the -m zypper in the previous commands. Now unless you use openSuse or Suse enterpise you may not be familiar with zypper, it is basically the equivalent of yum in the suse world. In all of the examples above I have only had one machine in my hosts file, and while everything but the last command should work on any standard *nix systems with standard ssh configs, this leads to a problem. What if we had multiple machine types that we wanted to manage? Well this is where playbooks, and the configurability of ansible really shines. First lets modify our hosts file a little, here goes: - - $ cat ~/ansible_hosts - -Sample outputs: - - [RHELBased] - 10.50.1.33 - 10.50.1.47 - - [SUSEBased] - 127.0.0.1 - -First, we create some groups of servers, and give them some meaningful tags. Then we create a playbook that will do different things for the different kinds of servers. You might notice the similarity between the yaml data structures and the command line instructions we ran earlier. Basically the -m is a module, and -a is for module args. In the YAML representation you put the module then :, and finally the args. - - --- - - hosts: SUSEBased - remote_user: root - tasks: - - zypper: name=apache2 state=latest - - hosts: RHELBased - remote_user: root - tasks: - - yum: name=httpd state=latest - -Now that we have a simple playbook, we can run it as follows: - - $ ansible-playbook testPlaybook.yaml -f 10 - -Sample outputs: - - PLAY [SUSEBased] ************************************************************** - - GATHERING FACTS *************************************************************** - ok: [127.0.0.1] - - TASK: [zypper name=apache2 state=latest] ************************************** - ok: [127.0.0.1] - - PLAY [RHELBased] ************************************************************** - - GATHERING FACTS *************************************************************** - ok: [10.50.1.33] - ok: [10.50.1.47] - - TASK: [yum name=httpd state=latest] ******************************************* - changed: [10.50.1.33] - changed: [10.50.1.47] - - PLAY RECAP ******************************************************************** - 10.50.1.33 : ok=2 changed=1 unreachable=0 failed=0 - 10.50.1.47 : ok=2 changed=1 unreachable=0 failed=0 - 127.0.0.1 : ok=2 changed=0 unreachable=0 failed=0 - -Now you will notice that you will see output from each machine that ansible contacted. The -f is what lets ansible run on multiple hosts in parallel. Instead of using all, or a name of a host group, on the command line you can put this passwords for the ask-pass prompt into the playbook. While we no longer need the --ask-pass since we have ssh keys setup, it comes in handy when setting up new machines, and even new machines can run from a playbook. To demonstrate this lets convert our earlier key example into a playbook: - - --- - - hosts: SUSEBased - remote_user: mike - sudo: yes - tasks: - - authorized_key: user=root key="{{ lookup('file', '/home/mike/.ssh/id_rsa.pub') }}" path=/root/.ssh/authorized_keys manage_dir=no - - hosts: RHELBased - remote_user: mdonlon - sudo: yes - tasks: - - authorized_key: user=root key="{{ lookup('file', '/home/mike/.ssh/id_rsa.pub') }}" path=/root/.ssh/authorized_keys manage_dir=no - -Now there are plenty of other options here that could be done, for example having the keys dropped during a kickstart, or via some other kind of process involved with bringing up machines on the hosting of your choice, but this can be used in pretty much any situation assuming ssh is setup to accept a password. One thing to think about before writing out too many playbooks, version control can save you a lot of time. Machines need to change over time, you don't need to re-write a playbook every time a machine changes, just update the pertinent bits and commit the changes. Another benefit of this ties into what I said earlier about being able to manage the entire infrastructure from multiple places. You can easily git clone your playbook repo onto a new machine and be completely setup to manage everything in a repetitive manner. - -#### Real world ansible example #### - -I know a lot of people make great use of services like pastebin, and a lot of companies for obvious reasons setup their own internal instance of something similar. Recently, I came across a newish application called showterm and coincidentally I was asked to setup an internal instance of it for a client. I will spare you the details of this app, but you can google showterm if interested. So for a reasonable real world example I will attempt to setup a showterm server, and configure the needed app on the client to use it. In the process we will need a database server as well. So here goes, lets start with the client configuration. - - --- - - hosts: showtermClients - remote_user: root - tasks: - - yum: name=rubygems state=latest - - yum: name=ruby-devel state=latest - - yum: name=gcc state=latest - - gem: name=showterm state=latest user_install=no - -That was easy, lets move on to the main server: - - --- - - hosts: showtermServers - remote_user: root - tasks: - - name: ensure packages are installed - yum: name={{item}} state=latest - with_items: - - postgresql - - postgresql-server - - postgresql-devel - - python-psycopg2 - - git - - ruby21 - - ruby21-passenger - - name: showterm server from github - git: repo=https://github.com/ConradIrwin/showterm.io dest=/root/showterm - - name: Initdb - command: service postgresql initdb - creates=/var/lib/pgsql/data/postgresql.conf - - - name: Start PostgreSQL and enable at boot - service: name=postgresql - enabled=yes - state=started - - gem: name=pg state=latest user_install=no - handlers: - - name: restart postgresql - service: name=postgresql state=restarted - - - hosts: showtermServers - remote_user: root - sudo: yes - sudo_user: postgres - vars: - dbname: showterm - dbuser: showterm - dbpassword: showtermpassword - tasks: - - name: create db - postgresql_db: name={{dbname}} - - - name: create user with ALL priv - postgresql_user: db={{dbname}} name={{dbuser}} password={{dbpassword}} priv=ALL - - hosts: showtermServers - remote_user: root - tasks: - - name: database.yml - template: src=database.yml dest=/root/showterm/config/database.yml - - hosts: showtermServers - remote_user: root - tasks: - - name: run bundle install - shell: bundle install - args: - chdir: /root/showterm - - hosts: showtermServers - remote_user: root - tasks: - - name: run rake db tasks - shell: 'bundle exec rake db:create db:migrate db:seed' - args: - chdir: /root/showterm - - hosts: showtermServers - remote_user: root - tasks: - - name: apache config - template: src=showterm.conf dest=/etc/httpd/conf.d/showterm.conf - -Not so bad, now keeping in mind that this is a somewhat random and obscure app that we can now install in a consistent fashion on any number of machines, this is where the benefits of configuration management really come to light. Also, in most cases the declarative syntax almost speaks for itself and wiki pages need not go into as much detail, although a wiki page with too much detail is never a bad thing in my opinion. - -### Expanding Configuration ### - -We have not touched on everything here, Ansible has many options for configuring you setup. You can do things like embedding variables in your hosts file, so that Ansible will interpolate them on the remote nodes, eg. - - [RHELBased] - 10.50.1.33 http_port=443 - 10.50.1.47 http_port=80 ansible_ssh_user=mdonlon - - [SUSEBased] - 127.0.0.1 http_port=443 - -While this is really handy for quick configurations, you can also layer variables across multiple files in yaml format. In you hosts file path you can make two sub directories named group_vars and host_vars. Any files in those paths that match the name of the group of hosts, or a host name in your hosts file will be interpolated at run time. So the previous example would look like this: - - ultrabook:/etc/ansible # pwd - /etc/ansible - ultrabook:/etc/ansible # tree - . - ├── group_vars - │ ├── RHELBased - │ └── SUSEBased - ├── hosts - └── host_vars - ├── 10.50.1.33 - └── 10.50.1.47 - ----------- - - 2 directories, 5 files - ultrabook:/etc/ansible # cat hosts - [RHELBased] - 10.50.1.33 - 10.50.1.47 - ----------- - - [SUSEBased] - 127.0.0.1 - ultrabook:/etc/ansible # cat group_vars/RHELBased - ultrabook:/etc/ansible # cat group_vars/SUSEBased - --- - http_port: 443 - ultrabook:/etc/ansible # cat host_vars/10.50.1.33 - --- - http_port: 443 - ultrabook:/etc/ansible # cat host_vars/10.50.1.47 - --- - http_port:80 - ansible_ssh_user: mdonlon - -### Refining Playbooks ### - -There are many ways to organize playbooks as well. In the previous examples we used a single file, and everything is really simplified. One way of organizing things that is commonly used is creating roles. Basically you load a main file as your playbook, and that then imports all the data from the extra files, the extra files are organized as roles. For example if you have a wordpress site, you need a web head, and a database. The web head will have a web server, the app code, and any needed modules. The database is sometimes ran on the same host and some times ran on remote hosts, and this is where roles really shine. You make a directory, and small playbook for each role. In this case we can have an apache role, mysql role, wordpress role, mod_php, and php roles. The big advantage to this is that not every role has to be applied on one server, in this case mysql could be applied to a separate machine. This also allows for code re-use, for example you apache role could be used with python apps and php apps alike. Demonstrating this is a little beyond the scope of this article, and there are many different ways of doing thing, I would recommend searching for ansible playbook examples. There are many people contributing code on github, and I am sure various other sites. - -### Modules ### - -All of the work being done behind the scenes in ansible is driven by modules. Ansible has an excellent library of built in modules that do things like package installation, transferring files, and everything we have done in this article. But for some people this will not be suitable for their setup, ansible has a means of adding your own modules. One great thing about the API provided by Ansible is that you are not restricted to the language it was written in, Python, you can use any language really. Ansible modules work by passing around JSON data structures, so as long as you can build a JSON data structure in your language of choice, which I am pretty sure any scripting language can do, you can begin coding something right away. There is much documentation on the Ansible site, about how the module interface works, and many examples of modules on github as well. Keep in mind that some obscure languages may not have great support, but that would only be because not enough people are contributing code in that language, try it out and publish your results somewhere! - -### Conclusion ### - -In conclusion, there are many systems around for configuration management, I hope this article shows the ease of setup for ansible which I believe is one of its strongest points. Please keep in mind that I was trying to show a lot of different ways to do things, and not everything above may be considered best practice in your private infrastructure, or the coding world abroad. Here are some more links to take you knowledge of ansible to the next level: - -- [Ansible project][7] home page. -- [Ansible project documentation][8]. -- [Multistage environments with Ansible][9]. - - - - --------------------------------------------------------------------------------- - -via: http://www.cyberciti.biz/python-tutorials/linux-tutorial-install-ansible-configuration-management-and-it-automation-tool/ - -作者:[Nix Craft][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://www.cyberciti.biz/tips/about-us -[1]:http://www.cyberciti.biz/faq/fedora-sl-centos-redhat6-enable-epel-repo/ -[2]:http://www.cyberciti.biz/faq/rhel-centos-fedora-linux-yum-command-howto/ -[3]:http://www.cyberciti.biz/tips/linux-debian-package-management-cheat-sheet.html -[4]:http://www.cyberciti.biz/faq/debian-ubuntu-centos-rhel-linux-install-pipclient/ -[5]:http://www.cyberciti.biz/faq/noninteractive-shell-script-ssh-password-provider/ -[6]:http://www.cyberciti.biz/faq/noninteractive-shell-script-ssh-password-provider/ -[7]:http://www.ansible.com/ -[8]:http://docs.ansible.com/ -[9]:http://rosstuck.com/multistage-environments-with-ansible/ \ No newline at end of file diff --git a/sources/tech/20140828 How to create a site-to-site IPsec VPN tunnel using Openswan in Linux.md b/sources/tech/20140828 How to create a site-to-site IPsec VPN tunnel using Openswan in Linux.md deleted file mode 100644 index 53f2c551a8..0000000000 --- a/sources/tech/20140828 How to create a site-to-site IPsec VPN tunnel using Openswan in Linux.md +++ /dev/null @@ -1,218 +0,0 @@ -How to create a site-to-site IPsec VPN tunnel using Openswan in Linux -================================================================================ -A virtual private network (VPN) tunnel is used to securely interconnect two physically separate networks through a tunnel over the Internet. Tunneling is needed when the separate networks are private LAN subnets with globally non-routable private IP addresses, which are not reachable to each other via traditional routing over the Internet. For example, VPN tunnels are often deployed to connect different NATed branch office networks belonging to the same institution. - -Sometimes VPN tunneling may be used simply for its security benefit as well. Service providers or private companies may design their networks in such a way that vital servers (e.g., database, VoIP, banking servers) are placed in a subnet that is accessible to trusted personnel through a VPN tunnel only. When a secure VPN tunnel is required, [IPsec][1] is often a preferred choice because an IPsec VPN tunnel is secured with multiple layers of security. - -This tutorial will show how we can easily create a site-to-site VPN tunnel using [Openswan][2] in Linux. - -### Topology ### - -This tutorial will focus on the following topologies for creating an IPsec tunnel. - -![](https://farm4.staticflickr.com/3838/15004668831_fd260b7f1e_z.jpg) - -![](https://farm6.staticflickr.com/5559/15004668821_36e02ab8b0_z.jpg) - -![](https://farm6.staticflickr.com/5571/14821245117_3f677e4d58_z.jpg) - -### Installing Packages and Preparing VPN Servers ### - -Usually, you will be managing site-A only, but based on the requirements, you could be managing both site-A and site-B. We start the process by installing Openswan. - -On Red Hat based Systems (CentOS, Fedora or RHEL): - - # yum install openswan lsof - -On Debian based Systems (Debian, Ubuntu or Linux Mint): - - # apt-get install openswan - -Now we disable VPN redirects, if any, in the server using these commands: - - # for vpn in /proc/sys/net/ipv4/conf/*; - # do echo 0 > $vpn/accept_redirects; - # echo 0 > $vpn/send_redirects; - # done - -Next, we modify the kernel parameters to allow IP forwarding and disable redirects permanently. - - # vim /etc/sysctl.conf - ----------- - - net.ipv4.ip_forward = 1 - net.ipv4.conf.all.accept_redirects = 0 - net.ipv4.conf.all.send_redirects = 0 - -Reload /etc/sysctl.conf: - - # sysctl -p - -We allow necessary ports in the firewall. Please make sure that the rules are not conflicting with existing firewall rules. - - # iptables -A INPUT -p udp --dport 500 -j ACCEPT - # iptables -A INPUT -p tcp --dport 4500 -j ACCEPT - # iptables -A INPUT -p udp --dport 4500 -j ACCEPT - -Finally, we create firewall rules for NAT. - - # iptables -t nat -A POSTROUTING -s site-A-private-subnet -d site-B-private-subnet -j SNAT --to site-A-Public-IP - -Please make sure that the firewall rules are persistent. - -#### Note: #### - -- You could use MASQUERADE instead of SNAT. Logically it should work, but it caused me to have issues with virtual private servers (VPS) in the past. So I would use SNAT if I were you. -- If you are managing site-B as well, create similar rules in site-B server. -- Direct routing does not need SNAT. - -### Preparing Configuration Files ### - -The first configuration file that we will work with is ipsec.conf. Regardless of which server you are configuring, always consider your site as 'left' and remote site as 'right'. The following configuration is done in siteA's VPN server. - - # vim /etc/ipsec.conf - ----------- - - ## general configuration parameters ## - - config setup - plutodebug=all - plutostderrlog=/var/log/pluto.log - protostack=netkey - nat_traversal=yes - virtual_private=%v4:10.0.0.0/8,%v4:192.168.0.0/16,%v4:172.16.0.0/16 - ## disable opportunistic encryption in Red Hat ## - oe=off - - ## disable opportunistic encryption in Debian ## - ## Note: this is a separate declaration statement ## - include /etc/ipsec.d/examples/no_oe.conf - - ## connection definition in Red Hat ## - conn demo-connection-redhat - authby=secret - auto=start - ike=3des-md5 - ## phase 1 ## - keyexchange=ike - ## phase 2 ## - phase2=esp - phase2alg=3des-md5 - compress=no - pfs=yes - type=tunnel - left= - leftsourceip= - leftsubnet=/netmask - ## for direct routing ## - leftsubnet=/32 - leftnexthop=%defaultroute - right= - rightsubnet=/netmask - - ## connection definition in Debian ## - conn demo-connection-debian - authby=secret - auto=start - ## phase 1 ## - keyexchange=ike - ## phase 2 ## - esp=3des-md5 - pfs=yes - type=tunnel - left= - leftsourceip= - leftsubnet=/netmask - ## for direct routing ## - leftsubnet=/32 - leftnexthop=%defaultroute - right= - rightsubnet=/netmask - -Authentication can be done in several different ways. This tutorial will cover the use of pre-shared key, which is added to the file /etc/ipsec.secrets. - - # vim /etc/ipsec.secrets - ----------- - - siteA-public-IP siteB-public-IP: PSK "pre-shared-key" - ## in case of multiple sites ## - siteA-public-IP siteC-public-IP: PSK "corresponding-pre-shared-key" - -### Starting the Service and Troubleshooting ### - -The server should now be ready to create a site-to-site VPN tunnel. If you are managing siteB as well, please make sure that you have configured the siteB server with necessary parameters. For Red Hat based systems, please make sure that you add the service into startup using chkconfig command. - - # /etc/init.d/ipsec restart - -If there are no errors in both end servers, the tunnel should be up now. Taking the following into consideration, you can test the tunnel with ping command. - -1. The siteB-private subnet should not be reachable from site A, i.e., ping should not work if the tunnel is not up. -1. After the tunnel is up, try ping to siteB-private-subnet from siteA. This should work. - -Also, the routes to the destination's private subnet should appear in the server's routing table. - - # ip route - ----------- - - [siteB-private-subnet] via [siteA-gateway] dev eth0 src [siteA-public-IP] - default via [siteA-gateway] dev eth0 - -Additionally, we can check the status of the tunnel using the following useful commands. - - # service ipsec status - ----------- - - IPsec running - pluto pid: 20754 - pluto pid 20754 - 1 tunnels up - some eroutes exist - ----------- - - # ipsec auto --status - ----------- - - ## output truncated ## - 000 "demo-connection-debian": myip=; hisip=unset; - 000 "demo-connection-debian": ike_life: 3600s; ipsec_life: 28800s; rekey_margin: 540s; rekey_fuzz: 100%; keyingtries: 0; nat_keepalive: yes - 000 "demo-connection-debian": policy: PSK+ENCRYPT+TUNNEL+PFS+UP+IKEv2ALLOW+SAREFTRACK+lKOD+rKOD; prio: 32,28; interface: eth0; - - ## output truncated ## - 000 #184: "demo-connection-debian":500 STATE_QUICK_R2 (IPsec SA established); EVENT_SA_REPLACE in 1653s; newest IPSEC; eroute owner; isakmp#183; idle; import:not set - - ## output truncated ## - 000 #183: "demo-connection-debian":500 STATE_MAIN_I4 (ISAKMP SA established); EVENT_SA_REPLACE in 1093s; newest ISAKMP; lastdpd=-1s(seq in:0 out:0); idle; import:not set - -The log file /var/log/pluto.log should also contain useful information regarding authentication, key exchanges and information on different phases of the tunnel. If your tunnel doesn't come up, you could check there as well. - -If you are sure that all the configuration is correct, and if your tunnel is still not coming up, you should check the following things. - -1. Many ISPs filter IPsec ports. Make sure that UDP 500, TCP/UDP 4500 ports are allowed by your ISP. You could try connecting to your server IPsec ports from a remote location by telnet. -1. Make sure that necessary ports are allowed in the firewall of the server/s. -1. Make sure that the pre-shared keys are identical in both end servers. -1. The left and right parameters should be properly configured on both end servers. -1. If you are facing problems with NAT, try using SNAT instead of MASQUERADING. - -To sum up, this tutorial focused on the procedure of creating a site-to-site IPSec VPN tunnel in Linux using Openswan. VPN tunnels are very useful in enhancing security as they allow admins to make critical resources available only through the tunnels. Also VPN tunnels ensure that the data in transit is secured from eavesdropping or interception. - -Hope this helps. Let me know what you think. - --------------------------------------------------------------------------------- - -via: http://xmodulo.com/2014/08/create-site-to-site-ipsec-vpn-tunnel-openswan-linux.html - -作者:[Sarmed Rahman][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://xmodulo.com/author/sarmed -[1]:http://en.wikipedia.org/wiki/IPsec -[2]:https://www.openswan.org/ \ No newline at end of file diff --git a/sources/tech/20140828 Setup Thin Provisioning Volumes in Logical Volume Management (LVM)--Part IV.md b/sources/tech/20140828 Setup Thin Provisioning Volumes in Logical Volume Management (LVM)--Part IV.md deleted file mode 100644 index 365799b3a2..0000000000 --- a/sources/tech/20140828 Setup Thin Provisioning Volumes in Logical Volume Management (LVM)--Part IV.md +++ /dev/null @@ -1,213 +0,0 @@ -Setup Thin Provisioning Volumes in Logical Volume Management (LVM) – Part IV -================================================================================ -Logical Volume management has great features such as snapshots and Thin Provisioning. Previously in (Part – III) we have seen how to snapshot the logical volume. Here in this article, we will going to see how to setup thin Provisioning volumes in LVM. - -![Setup Thin Provisioning in LVM](http://www.tecmint.com/wp-content/uploads/2014/08/Setup-Thin-Provisioning-in-LVM.jpg) -Setup Thin Provisioning in LVM - -### What is Thin Provisioning? ### - -Thin Provisioning is used in lvm for creating virtual disks inside a thin pool. Let us assume that I have a **15GB** storage capacity in my server. I already have 2 clients who has 5GB storage each. You are the third client, you asked for 5GB storage. Back then we use to provide the whole 5GB (Thick Volume) but you may use 2GB from that 5GB storage and 3GB will be free which you can fill it up later. - -But what we do in thin Provisioning is, we use to define a thin pool inside one of the large volume group and define the thin volumes inside that thin pool. So, that whatever files you write will be stored and your storage will be shown as 5GB. But the full 5GB will not allocate the entire disk. The same process will be done for other clients as well. Like I said there are 2 clients and you are my 3rd client. - -So, let us assume how much total GB I have assigned for clients? Totally 15GB was already completed, If someone comes to me and ask for 5GB can I give? The answer is “**Yes**“, here in thin Provisioning I can give 5GB for 4th Client even though I have assigned 15GB. - -**Warning**: From 15GB, if we are Provisioning more than 15GB it is called Over Provisioning. - -### How it Works? and How we provide storage to new Clients? ### - -I have provided you 5GB but you may used only 2GB and other 3GB will be free. In Thick Provisioning we can’t do this, because it will allocate the whole space at first itself. - -In thin Provisioning if I’m defining 5GB for you it won’t allocate the whole disk space while defining a volume, it will grow till 5GB according to your data write, Hope you got it! same like you, other clients too won’t use the full volumes so there will be a chance to add 5GB to a new client, This is called over Provisioning. - -But it’s compulsory to monitored each and every volume growth, if not it will end-up in a disaster. While over Provisioning is done if the all 4 clients write the data’s badly to disk you may face an issue because it will fill up your 15GB and overflow to get drop the volumes. - -### Requirements ### - -注:此三篇文章如果发布后可换成发布后链接,原文在前几天更新中 - -- [Create Disk Storage with LVM in Linux – PART 1][1] -- [How to Extend/Reduce LVM’s in Linux – Part II][2] -- [How to Create/Restore Snapshot of Logical Volume in LVM – Part III][3] - -#### My Server Setup #### - - Operating System – CentOS 6.5 with LVM Installation - Server IP – 192.168.0.200 - -### Step 1: Setup Thin Pool and Volumes ### - -Let’s do it practically how to setup the thin pool and thin volumes. First we need a large size of Volume group. Here I’m creating Volume group with **15GB** for demonstration purpose. Now, list the volume group using the below command. - - # vgcreate -s 32M vg_thin /dev/sdb1 - -![Listing Volume Group](http://www.tecmint.com/wp-content/uploads/2014/08/Listing-Volume-Group.jpg) -Listing Volume Group - -Next, check for the size of Logical volume availability, before creating the thin pool and volumes. - - # vgs - # lvs - -![Check Logical Volume](http://www.tecmint.com/wp-content/uploads/2014/08/check-Logical-Volume.jpg) -Check Logical Volume - -We can see there is only default logical volumes for file-system and swap is present in the above lvs output. - -### Creating a Thin Pool ### - -To create a Thin pool for 15GB in volume group (vg_thin) use the following command. - - # lvcreate -L 15G --thinpool tp_tecmint_pool vg_thin - -- **-L** – Size of volume group -- **–thinpool** – To o create a thinpool -- **tp_tecmint_poolThin** - pool name -- **vg_thin** – Volume group name were we need to create the pool - -![Create Thin Pool](http://www.tecmint.com/wp-content/uploads/2014/08/Create-Thin-Pool.jpg) -Create Thin Pool - -To get more detail we can use the command ‘lvdisplay’. - - # lvdisplay vg_thin/tp_tecmint_pool - -![Logical Volume Information](http://www.tecmint.com/wp-content/uploads/2014/08/Logical-Volume-Information.jpg) -Logical Volume Information - -Here we haven’t created Virtual thin volumes in this thin-pool. In the image we can see Allocated pool data showing **0.00%**. - -### Creating Thin Volumes ### - -Now we can define thin volumes inside the thin pool with the help of ‘lvcreate’ command with option -V (Virtual). - - # lvcreate -V 5G --thin -n thin_vol_client1 vg_thin/tp_tecmint_pool - -I have created a Thin virtual volume with the name of **thin_vol_client1** inside the **tp_tecmint_pool** in my **vg_thin** volume group. Now, list the logical volumes using below command. - - # lvs - -![List Logical Volumes](http://www.tecmint.com/wp-content/uploads/2014/08/List-Logical-Volumes.jpg) -List Logical Volumes - -Just now, we have created the thin volume above, that’s why there is no data showing i.e. **0.00%M**. - -Fine, let me create 2 more Thin volumes for other 2 clients. Here you can see now there are 3 thin volumes created under the pool (**tp_tecmint_pool**). So, from this point, we came to know that I have used all 15GB pool. - -![Create Thin Volumes](http://www.tecmint.com/wp-content/uploads/2014/08/Create-Thin-Volumes.jpg) - -### Creating File System ### - -Now, create mount points and mount these three thin volumes and copy some files in it using below commands. - - # mkdir -p /mnt/client1 /mnt/client2 /mnt/client3 - -List the created directories. - - # ls -l /mnt/ - -![Creating Mount Points](http://www.tecmint.com/wp-content/uploads/2014/08/Creating-Mount-Points.jpg) -Creating Mount Points - -Create the file system for these created thin volumes using ‘mkfs’ command. - - # mkfs.ext4 /dev/vg_thin/thin_vol_client1 && mkfs.ext4 /dev/vg_thin/thin_vol_client2 && mkfs.ext4 /dev/vg_thin/thin_vol_client3 - -![Create File System](http://www.tecmint.com/wp-content/uploads/2014/08/Create-File-System.jpg) -Create File System - -Mount all three client volumes to the created mount point using ‘mount’ command. - - # mount /dev/vg_thin/thin_vol_client1 /mnt/client1/ && mount /dev/vg_thin/thin_vol_client2 /mnt/client2/ && mount /dev/vg_thin/thin_vol_client3 /mnt/client3/ - -List the mount points using ‘df’ command. - - # df -h - -![Print Mount Points](http://www.tecmint.com/wp-content/uploads/2014/08/Print-Mount-Points.jpg) -Print Mount Points - -Here, we can see all the 3 clients volumes are mounted and therefore only 3% of data are used in every clients volumes. So, let’s add some more files to all 3 mount points from my desktop to fill up some space. - -![Add Files To Volumes](http://www.tecmint.com/wp-content/uploads/2014/08/Add-Files-To-Volumes.jpg) -Add Files To Volumes - -Now list the mount point and see the space used in every thin volumes & list the thin pool to see the size used in pool. - - # df -h - # lvdisplay vg_thin/tp_tecmint_pool - -![Check Mount Point Size](http://www.tecmint.com/wp-content/uploads/2014/08/Check-Mount-Point-Size.jpg) -Check Mount Point Size - -![Check Thin Pool Size](http://www.tecmint.com/wp-content/uploads/2014/08/Check-Thin-Pool-Size.jpg) -Check Thin Pool Size - -The above command shows, the three mount pints along with their sizes in percentage. - - 13% of datas used out of 5GB for client1 - 29% of datas used out of 5GB for client2 - 49% of datas used out of 5GB for client3 - -While looking into the thin-pool we can see only **30%** of data is written totally. This is the total of above three clients virtual volumes. - -### Over Provisioning ### - -Now the **4th** client came to me and asked for 5GB storage space. Can I give? Because I had already given 15GB Pool to 3 clients. Is it possible to give 5GB more to another client? Yes it is possible to give. This is when we use **Over Provisioning**, which means giving the space more than what I have. - -Let me create 5GB for the 4th Client and verify the size. - - # lvcreate -V 5G --thin -n thin_vol_client4 vg_thin/tp_tecmint_pool - # lvs - -![Create thin Storage](http://www.tecmint.com/wp-content/uploads/2014/08/Create-thin-Storage.jpg) -Create thin Storage - -I have only 15GB size in pool, but I have created 4 volumes inside thin-pool up-to 20GB. If all four clients start to write data to their volumes to fill up the pace, at that time, we will face critical situation, if not there will no issue. - -Now I have created file system in **thin_vol_client4**, then mounted under **/mnt/client4** and copy some files in it. - - # lvs - -![Verify Thin Storage](http://www.tecmint.com/wp-content/uploads/2014/08/Verify-Thing-Storage.jpg) -Verify Thin Storage - -We can see in the above picture, that the total used size in newly created client 4 up-to **89.34%** and size of thin pool as **59.19%** used. If all these users are not writing badly to volume it will be free from overflow, drop. To avoid the overflow we need to extend the thin-pool size. - -**Important**: Thin-pools are just a logical volume, so if we need to extend the size of thin-pool we can use the same command like, we’ve used for logical volumes extend, but we can’t reduce the size of thin-pool. - - # lvextend - -Here we can see how to extend the logical thin-pool (**tp_tecmint_pool**). - - # lvextend -L +15G /dev/vg_thin/tp_tecmint_pool - -![Extend Thin Storage](http://www.tecmint.com/wp-content/uploads/2014/08/Extend-Thin-Storage.jpg) -Extend Thin Storage - -Next, list the thin-pool size. - - # lvs - -![Verify Thin Storage](http://www.tecmint.com/wp-content/uploads/2014/08/Verify-Thin-Storage.jpg) -Verify Thin Storage - -Earlier our **tp_tecmint_pool** size was 15GB and 4 thin volumes which was over Provision by 20GB. Now it has extended to 30GB so our over Provisioning has been normalized and thin volumes are free from overflow, drop. This way you can add ever more thin volumes to the pool. - -Here, we have seen how to create a thin-pool using a large size of volume group and create thin-volumes inside a thin-pool using Over-Provisioning and extending the pool. In the next article we will see how to setup a lvm Striping. - --------------------------------------------------------------------------------- - -via: http://www.tecmint.com/setup-thin-provisioning-volumes-in-lvm/ - -作者:[Babin Lonston][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://www.tecmint.com/author/babinlonston/ -[1]:http://www.tecmint.com/create-lvm-storage-in-linux/ -[2]:http://www.tecmint.com/extend-and-reduce-lvms-in-linux/ -[3]:http://www.tecmint.com/take-snapshot-of-logical-volume-and-restore-in-lvm/ \ No newline at end of file diff --git a/sources/tech/20140829 6 Interesting Funny Commands of Linux (Fun in Terminal) – Part II.md b/sources/tech/20140829 6 Interesting Funny Commands of Linux (Fun in Terminal) – Part II.md deleted file mode 100644 index b1a3fad83e..0000000000 --- a/sources/tech/20140829 6 Interesting Funny Commands of Linux (Fun in Terminal) – Part II.md +++ /dev/null @@ -1,107 +0,0 @@ -wangjiezhe translating -6 Interesting Funny Commands of Linux (Fun in Terminal) – Part II -================================================================================ -In our past following articles, we’ve shown some useful articles on some funny commands of Linux, which shows that Linux is not as complex as it seems and can be fun if we know how to use it. Linux command line can perform any complex task very easily and with perfection and can be interesting and joyful. - -- [20 Funny Commands of Linux – Part I][1]注,此篇的原文应该翻译过,文件名应该是:20 Funny Commands of Linux or Linux is Fun in Terminal -- [Fun in Linux Terminal – Play with Word and Character Counts][2]注:这篇文章刚刚补充上 - -![Funny Linux Commands](http://www.tecmint.com/wp-content/uploads/2014/08/Funny-Linux-Commands.png) -Funny Linux Commands - -The former Post comprises of 20 funny Linux Commands/Script (and subcommands) which was highly appreciated by our readers. The other post, though not that much popular as former comprises of Commands/ Scripts and Tweaks which lets you play with text files, words and strings. - -This post aims at bringing some new fun commands and one-liner scripts which is going to rejoice you. - -### 1. pv Command ### - -You might have seen simulating text in movies. It appears as, it is being typed in real time. Won’t it be nice, if you can have such an effect in terminal? - -This can be achieved, by installing ‘**pv**‘ command in your Linux system by using ‘**apt**‘ or ‘**yum**‘ tool. Let’s install ‘**pv**‘ command as shown. - - # yum install pv [On RedHat based Systems] - - # sudo apt-get install pv [On Debian based Systems] - -Once, ‘**pv**‘ command installed successfully on your system, let’s try to run the following one liner command to see the real time text effect on the screen. - - $ echo "Tecmint[dot]com is a community of Linux Nerds and Geeks" | pv -qL 10 - -![pv command in action](http://www.tecmint.com/wp-content/uploads/2014/08/pv-command.gif) -pv command in action - -**Note**: The ‘**q**‘ option means ‘quite’, no output information and option ‘**L**‘ means the Limit of Transfer of bytes per second. The number value can be adjusted in either direction (must be integer) to get desired simulation of text. - -### 2. toilet Command ### - -How about printing text with border in terminal, using an one-liner script command ‘**toilet**‘. Again, you must have ‘**toilet**‘ command installed on your system, if not use apt or yum to install it. - - $ while true; do echo “$(date | toilet -f term -F border –Tecmint)”; sleep 1; done - -![toilet command in action](http://www.tecmint.com/wp-content/uploads/2014/08/toilet-command.gif) -toilet command in action - -**Note**: The above script needs to be suspended using **ctrl+z** key. - -### 3. rig Command ### - -This command generates a random identity and address, every time. To run, this command you need to install ‘**rig**‘ using apt or yum. - - # rig - -![rig command in action](http://www.tecmint.com/wp-content/uploads/2014/08/rig-command.gif) -rig command in action - -### 4. aview Command ### - -How about viewing an image in ASCII format on the terminal? We must have a package ‘**aview**‘ installed, just apt or yum it. I’ve an image named ‘**elephant.jpg**‘ in my current working directory and I want view it on terminal as ASCII format. - - $ asciiview elephant.jpg -driver curses - -![aview command in action](http://www.tecmint.com/wp-content/uploads/2014/08/elephant.gif) -aview command in action - -### 5. xeyes Command ### - -In last article we introduced a command ‘**oneko**‘ which attaches jerry with mouse pointer and keeps on chasing it. A similar program ‘**xeyes**‘ which is a graphical programs and as soon as you fire the command you will see two monster eyes chasing your movement. - - $ xeyes - -![xeyes command in action](http://www.tecmint.com/wp-content/uploads/2014/08/xeyes.gif) -xeyes command in action - -### 6. cowsay Command ### - -Do you remember last time we introduced command, which is useful in output of desired text with animated character cow. What if you want other animal in place of cow? Check a list of available animals. - - $ cowsay -l - -How about Elephant inside ASCII Snake? - - $ cowsay -f elephant-in-snake Tecmint is Best - -![cowsay command in action](http://www.tecmint.com/wp-content/uploads/2014/08/cowsay.gif) -cowsay command in action - -How about Elephant inside ASCII goat? - - $ cowsay -f gnu Tecmint is Best - -![cowsay goat in action](http://www.tecmint.com/wp-content/uploads/2014/08/cowsay-goat.gif) -cowsay goat in action - -That’s all for now. I’ll be here again with another interesting article. Till then stay update and connected to Tecmint. Don’t forget to provide us with your valuable feedback in the comments below. - --------------------------------------------------------------------------------- - -via: http://www.tecmint.com/linux-funny-commands/ - -作者:[Avishek Kumar][a] -译者:[wangjiezhe](https://github.com/wangjiezhe) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://www.tecmint.com/author/avishek/ -[1]:http://www.tecmint.com/20-funny-commands-of-linux-or-linux-is-fun-in-terminal/ -[2]:http://www.tecmint.com/play-with-word-and-character-counts-in-linux/ diff --git a/sources/tech/20140901 How to install and configure ownCloud on Debian.md b/sources/tech/20140901 How to install and configure ownCloud on Debian.md deleted file mode 100644 index a0a18225b6..0000000000 --- a/sources/tech/20140901 How to install and configure ownCloud on Debian.md +++ /dev/null @@ -1,209 +0,0 @@ -How to install and configure ownCloud on Debian -================================================================================ -According to its official website, ownCloud gives you universal access to your files through a web interface or WebDAV. It also provides a platform to easily view, edit and sync your contacts, calendars and bookmarks across all your devices. Even though ownCloud is very similar to the widely-used Dropbox cloud storage, the primary difference is that ownCloud is free and open-source, making it possible to set up a Dropbox-like cloud storage service on your own server. With ownCloud, only you have complete access and control over your private data, with no limits on storage space (except for hard disk capacity) or the number of connected clients. - -ownCloud is available in Community Edition (free of charge) and Enterprise Edition (business-oriented with paid support). The pre-built package of ownCloud Community Edition is available for CentOS, Debian, Fedora openSUSE, SLE and Ubuntu. This tutorial will demonstrate how to install and configure ownCloud Community Edition on Debian Wheezy. - -### Installing ownCloud on Debian ### - -Go to the official website: [http://owncloud.org][1], and click on the 'Install' button (upper right corner). - -![](https://farm4.staticflickr.com/3885/14884771598_323f2fc01c_z.jpg) - -Now choose "Packages for auto updates" for the current version (v7 in the image below). This will allow you to easily keep ownCloud up to date using Debian's package management system, with packages maintained by the ownCloud community. - -![](https://farm6.staticflickr.com/5589/15071372505_298a796ff6_z.jpg) - -Then click on Continue on the next screen: - -![](https://farm6.staticflickr.com/5589/14884818527_554d1483f9_z.jpg) - -Select Debian 7 [Wheezy] from the list of available operating systems: - -![](https://farm6.staticflickr.com/5581/14884669449_433e3334e0_z.jpg) - -Add the ownCloud's official Debian repository: - - # echo 'deb http://download.opensuse.org/repositories/isv:/ownCloud:/community/Debian_7.0/ /' >> /etc/apt/sources.list.d/owncloud.list - -Add the repository key to apt: - - # wget http://download.opensuse.org/repositories/isv:ownCloud:community/Debian_7.0/Release.key - # apt-key add - < Release.key - -Go ahead and install ownCloud: - - # aptitude update - # aptitude install owncloud - -Open your web browser and navigate to your ownCloud instance, which can be found at http:///owncloud: - -![](https://farm4.staticflickr.com/3869/15071011092_f8f32ffe11_z.jpg) - -Note that ownCloud may be alerting about an Apache misconfiguration. Follow the steps below to solve this issue, and get rid of that error message. - -a) Edit the /etc/apache2/apache2.conf file (set the AllowOverride directive to All): - - - Options Indexes FollowSymLinks - AllowOverride All - Order allow,deny - Allow from all - - -b) Edit the /etc/apache2/conf.d/owncloud.conf file - - - Options Indexes FollowSymLinks MultiViews - AllowOverride All - Order allow,deny - Allow from all - - -c) Restart the web server: - - # service apache2 restart - -d) Refresh the web browser. Verify that the security warning has disappeared. - -![](https://farm6.staticflickr.com/5562/14884771428_fc9c063418_z.jpg) - -### Setting up a Database ### - -Now it's time to set up a database for ownCloud. - -First, log in to the local MySQL/MariaDB server: - - $ mysql -u root -h localhost -p - -Create a database and user account for ownCloud as follows. - - mysql> CREATE DATABASE owncloud_DB; - mysql> CREATE USER ‘owncloud-web’@'localhost' IDENTIFIED BY ‘whateverpasswordyouchoose’; - mysql> GRANT ALL PRIVILEGES ON owncloud_DB.* TO ‘owncloud-web’@'localhost'; - mysql> FLUSH PRIVILEGES; - -Go to ownCloud page at http:///owncloud, and choose the 'Storage & database' section. Enter the rest of the requested information (MySQL/MariaDB user, password, database and hostname), and click on Finish setup. - -![](https://farm6.staticflickr.com/5584/15071010982_b76c23c384_z.jpg) - -### Configuring ownCloud for SSL Connections ### - -Before you start using ownCloud, it is strongly recommended to enable SSL support in ownCloud. Using SSL provides important security benefits such as encrypting ownCloud traffic and providing proper authentication. In this tutorial, a self-signed certificate will be used for SSL. - -Create a new directory where we will store the server key and certificate: - - # mkdir /etc/apache2/ssl - -Create a certificate (and the key that will protect it) which will remain valid for one year. - - # openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout /etc/apache2/ssl/apache.key -out /etc/apache2/ssl/apache.crt - -![](https://farm6.staticflickr.com/5587/15068784081_f281b54b72_z.jpg) - -Edit the /etc/apache2/conf.d/owncloud.conf file to enable HTTPS. For details on the meaning of the rewrite rules NC, R, and L, you can refer to the [Apache docs][2]: - - Alias /owncloud /var/www/owncloud - - - RewriteEngine on - ReWriteCond %{SERVER_PORT} !^443$ - RewriteRule ^/(.*) https://%{HTTP_HOST}/$1 [NC,R,L] - - - - SSLEngine on - SSLCertificateFile /etc/apache2/ssl/apache.crt - SSLCertificateKeyFile /etc/apache2/ssl/apache.key - DocumentRoot /var/www/owncloud/ - - Options Indexes FollowSymLinks MultiViews - AllowOverride All - Order allow,deny - Allow from all - - - -Enable the rewrite module and restart Apache: - - # a2enmod rewrite - # service apache2 restart - -Open your ownCloud instance. Notice that even if you try to use plain HTTP, you will be automatically redirected to HTTPS. - -Be advised that even having followed the above steps, the first time that you launch your ownCloud instance, an error message will be displayed stating that the certificate has not been issued by a trusted authority (that is because we created a self-signed certificate). You can safely ignore this message, but if you are considering deploying ownCloud in a production server, you may want to purchase a certificate from a trusted company. - -### Create an Account ### - -Now we are ready to create an ownCloud admin account. - -![](https://farm6.staticflickr.com/5587/15048366536_430b4fd64e.jpg) - -Welcome to your new personal cloud! Note that you can install a desktop or mobile client app to sync your files, calendars, contacts and more. - -![](https://farm4.staticflickr.com/3862/15071372425_c391d912f5_z.jpg) - -In the upper right corner, click on your user name, and a drop-down menu is displayed: - -![](https://farm4.staticflickr.com/3897/15071372355_3de08d2847.jpg) - -Click on Personal to change your settings, such as password, display name, email address, profile picture, and more. - -### ownCloud Use Case: Access Calendar ### - -Let's start by adding an event to your calendar and later downloading it. - -Click on the upper left corner drop-down menu and choose Calendar. - -![](https://farm4.staticflickr.com/3891/15048366346_7dcc388244.jpg) - -Add a new event and save it to your calendar. - -![](https://farm4.staticflickr.com/3882/14884818197_f55154fd91_z.jpg) - -Download your calendar and add it to your Thunderbird calendar by going to 'Event and Tasks' -> 'Import...' -> 'Select file': - -![](https://farm4.staticflickr.com/3840/14884818217_16a53400f0_z.jpg) - -![](https://farm4.staticflickr.com/3871/15048366356_a7f98ca63d_z.jpg) - -TIP: You also need to set your time zone in order to successfully import your calendar in another application (by default, the Calendar application uses the UTC +00:00 time zone). To change the time zone, go to the bottom left corner and click on the small gear icon. The Calendar settings menu will appear and you will be able to select your time zone: - -![](https://farm4.staticflickr.com/3858/14884669029_4e0cd3e366.jpg) - -### ownCloud Use Case: Upload a File ### - -Next, we will upload a file from the client computer. - -Go to the Files menu (upper left corner) and click on the up arrow to open a select-file dialog. - -![](https://farm4.staticflickr.com/3851/14884818067_4a4cc73b40.jpg) - -Select a file and click on Open. - -![](https://farm6.staticflickr.com/5591/14884669039_5a9dd00ca9_z.jpg) - -You can then open/edit the selected file, move it into another folder, or delete it. - -![](https://farm4.staticflickr.com/3909/14884771088_d0b8a20ae2_o.png) - -### Conclusion ### - -ownCloud is a versatile and powerful cloud storage that makes the transition from another provider quick, easy, and painless. In addition, it is FOSS, and with little time and effort you can configure it to meet all your needs. For further information, you can always refer to the [User][3], [Admin][4], or [Developer][5] manuals. - --------------------------------------------------------------------------------- - -via: http://xmodulo.com/2014/08/install-configure-owncloud-debian.html - -作者:[Gabriel Cánepa][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://www.gabrielcanepa.com.ar/ -[1]:http://owncloud.org/ -[2]:http://httpd.apache.org/docs/2.2/rewrite/flags.html -[3]:http://doc.owncloud.org/server/7.0/ownCloudUserManual.pdf -[4]:http://doc.owncloud.org/server/7.0/ownCloudAdminManual.pdf -[5]:http://doc.owncloud.org/server/7.0/ownCloudDeveloperManual.pdf \ No newline at end of file diff --git a/sources/tech/20140901 How to use on-screen virtual keyboard on Linux.md b/sources/tech/20140901 How to use on-screen virtual keyboard on Linux.md index 11bdaaf42c..83a619d261 100644 --- a/sources/tech/20140901 How to use on-screen virtual keyboard on Linux.md +++ b/sources/tech/20140901 How to use on-screen virtual keyboard on Linux.md @@ -1,3 +1,5 @@ +chi1shi2 is translating. + How to use on-screen virtual keyboard on Linux ================================================================================ On-screen virtual keyboard is an alternative input method that can replace a real hardware keyboard. Virtual keyboard may be a necessity in various cases. For example, your hardware keyboard is just broken; you do not have enough keyboards for extra machines; your hardware does not have an available port left to connect a keyboard; you are a disabled person with difficulty in typing on a real keyboard; or you are building a touchscreen-based web kiosk. diff --git a/sources/tech/20140902 How to share on linux the output of your shell commands.md b/sources/tech/20140902 How to share on linux the output of your shell commands.md deleted file mode 100644 index 1ef7846540..0000000000 --- a/sources/tech/20140902 How to share on linux the output of your shell commands.md +++ /dev/null @@ -1,112 +0,0 @@ -How to share on linux the output of your shell commands -================================================================================ -Some time ago I posted an article about [shelr.tv][1] a website and a service that was made to allow you to share your [terminal][2] records directly from the website. - -Now the website of shelr.tv seems dead and so I’ve took a look around to see if there are similar websites and I’ve found [commands.com][3]. - -For what I can see from their homepage it’s a service similar to the other, so let’s test it. - -### Step 1 – Register on the website ### - -Just [register][4] with a new username/password or use your github account to do it quickly. - -### Step 2 – download and install the program monitor ### - -[Monitor][5] is a command-line tool that captures command-line input/output and sends it to commands.com, the program it’s open source and hosted on github. - -Monitor makes it easy to automate set-up/install of repos. With it you can easily show at people the most common errors and output from commands. - -In short with it you can easily share your commands and their output with the world. - -To install it follow these simple steps: - -1) Clone the github repository of this project, in this way you’ll get the latest source code. - -To do this you need the git command installed on your system, if you get an error with this command install it with your package manager, such as - -Debian based distributions: - - apt-get install git - -Redhat/Centos/Fedora distributions - - yum install git - -And now from a terminal clone the repository with: - - git clone https://github.com/dtannen/monitor.git - -2) Install readline and curl, these libraries are a pre-requisite for building the program from the sources: - -Debian based distributions: - - apt-get install libreadline-dev libcurl4-openssl-dev - -Redhat/Centos/Fedora distributions - - yum install readline-devel curl-devel - -3) Build the program: - -To do this you have to go to the directory we just cloned with git and compile the c program: - - cd monitor - make - sudo make install - -The default installation will put the binary in /usr/local/bin - -![](http://cdn.linuxaria.com/wp-content/uploads/2014/08/commands.png) - -### Step 3 – using the monitor command ### - -The command monitor it’s pretty easy to use: - - monitor {-d} {-h} {-u } - - -d : do not delete /tmp files - -h : help - -u : commands.com username - -To exit the monitor program you just have to use ctrl-c. - -So for me this means just opening a terminal and give these commands: - - riccio@mint-desktop ~ $ monitor -u ricciocri - Password: - - Successfully logged in... - AuthKey saved to /tmp/.riccio.commands.com. Delete file to return to Anonymous posting. - monitor$ cd /tmp - ... - -Want to see which command I’ve used after these ? -I’ve made this session public (the default it’s private) so you can simply check this url: [https://commands.com/JTNSHRLQJA][6] - -From there you can see the commands I’ve used and their output, an interesting options it’s the “fold/expand” so you could fold all commands and just expand the output of the one you like more. - -### Conclusions ### - -This is just the a basic startup guide, from the website you can make more “social” activity such as comment script/shell sessions, fork them or choose your favorites. - -Like github, you can fork any public script/command and change it directly from the website and after that you can also get a public (or private url) that you can use to run directly your script with something like this: - - curl commands.io/JTNSHRLQJA | sh - -That’s great to store on the net some scripts that you run frequently on different computers/server, as usual don’t put anything with passwords or sensible information on the net and you’ll be safe enough. - --------------------------------------------------------------------------------- - -via: http://linuxaria.com/article/how-to-share-on-linux-the-output-of-your-shell-commands - -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[1]:http://linuxaria.com/recensioni/shelr-broadcast-your-linux-shell-on-the-net -[2]:http://linuxaria.com/tag/shell -[3]:https://commands.com/ -[4]:https://commands.com/Register/Index -[5]:https://github.com/dtannen/monitor -[6]:https://commands.com/JTNSHRLQJA \ No newline at end of file diff --git a/sources/tech/20140902 Photo Editing on Linux with Krita.md b/sources/tech/20140902 Photo Editing on Linux with Krita.md deleted file mode 100644 index c3e4367556..0000000000 --- a/sources/tech/20140902 Photo Editing on Linux with Krita.md +++ /dev/null @@ -1,76 +0,0 @@ -Photo Editing on Linux with Krita -================================================================================ -![Figure 1: Annabelle the pygmy goat.](http://www.linux.com/images/stories/41373/fig-1-annabelle.jpg) -Figure 1: Annabelle the pygmy goat. - -[Krita][1] is a wonderful drawing and painting program, and it's also a nice photo editor. Today we will learn how to add text to an image, and how to selectively sharpen portions of a photo. - -### Navigating Krita ### - -Like all image creation and editing programs, Krita contains hundreds of tools and options, and redundant controls for exposing and using them. It's worth taking some time to explore it and to see where everything is. - -The default theme for Krita is a dark theme. I'm not a fan of dark themes, but fortunately Krita comes with a nice batch of themes that you can change anytime in the Settings > Theme menu. - -Krita uses docking tool dialogues. Check Settings > Show Dockers to see your tool docks in the right and left panes, and Settings > Dockers to select the ones you want to see. The individual docks can drive you a little bit mad, as some of them open in a tiny squished aspect so you can't see anything. You can drag them to the top and sides of your Krita window, enlarge and shrink them, and you can drag them out of Krita to any location on your computer screen. If you drop a dock onto another dock they automatically create tabs. - -When you have arranged your perfect workspace, you can preserve it in the "Choose Workspace" picker. This is a button at the right end of the Brushes and Stuff toolbar (Settings > Toolbars Shown). This comes with a little batch of preset workspaces, and you can create your own (figure 2). - -![Figure 2: Preserve custom workspaces in the Choose Workspace dialogue.](http://www.linux.com/images/stories/41373/fig-2-workspaces.jpg) -Figure 2: Preserve custom workspaces in the Choose Workspace dialogue. - -Krita has multiple zoom controls. Ctrl+= zooms in, Ctrl+- zooms out, and Ctrl+0 resets to 100%. You can also use the View > Zoom controls, and the zoom slider at the bottom right. There is also a dropdown zoom menu to the left of the slider. - -The Tools menu sits in the left pane, and this contains your shape and selection tools. You have to hover your cursor over each tool to see its label. The Tool Options dock always displays options for the current tool you are using, and by default it sits in the right pane. - -### Crop Tool ### - -Of course there is a crop tool in the Tools dock, and it is very easy to use. Draw a rectangle that contains the area you want to keep, use the drag handles to adjust it, and press the Return key. In the Tools Options dock you can choose to apply the crop to all layers or just the current layer, adjust the dimensions by typing in the size values, or size it as a percentage. - -### Adding Text ### - -When you want to add some simple text to a photo, such as a label or a caption, Krita may leave you feeling overwhelmed because it contains so many artistic text effects. But it also supports adding simple text. Click the Text tool, and the Tool Options dock looks like figure 3. - -![Figure 3: Text options.](http://www.linux.com/images/stories/41373/fig-3-text.jpg) -Figure 3: Text options. - -Click the Multiline button. This opens the simple text tool; first draw a rectangle to contain your text, then start typing your text. The Tool Options dock has all the usual text formatting options: font selector, font size, text and background colors, alignment, and a bunch of paragraph styles. When you're finished click the Shape Handling tool, which is the white arrow next to the Text tool button, to adjust the size, shape, and position of your text box. The Tool Options for the Shape Handling tool include borders of various thicknesses, colors, and alignments. Figure 4 shows the gleeful captioned photo I send to my city-trapped relatives. - -![Figure 4: Green acres is the place to be.](http://www.linux.com/images/stories/41373/fig-4-frontdoor.jpg) -Figure 4: Green acres is the place to be. - -How to edit your existing text isn't obvious. Click the Shape Handling tool, and double-click inside the text box. This opens editing mode, which is indicated by the text cursor. Now you can select text, add new text, change formatting, and so on. - -### Sharpening Selected Areas ### - -Krita has a number of nice tools for making surgical edits. In figure 5 I want to sharpen Annabelle's face and eyes. (Annabelle lives next door, but she has a crush on my dog and spends a lot of time here. My dog is terrified of her and runs away, but she is not discouraged.) First select an area with the "Select an area by its outline" tool. Then open Filter > Enhance > Unsharp Mask. You have three settings to play with: Half-Size, Amount, and Threshold. Most image editing software has Radius, Amount, and Threshold settings. A radius is half of a diameter, so Half-Size is technically correct, but perhaps needlessly confusing. - -![Figure 5: Selecting an arbitrary area to edit.](http://www.linux.com/images/stories/41373/fig-5-annabelle.jpg) -Figure 5: Selecting an arbitrary area to edit. - -The Half-Size value controls the width of the sharpening lines. You want a large enough value to get a good affect, but not so large that it's obvious. - -The Threshold value determines how different two pixels need to be for the sharpening effect to be applied. 0 = maximum sharpening, and 99 is no sharpening. - -Amount controls the strength of the sharpening effect; higher values apply more sharpening. - -Sharpening is nearly always the last edit you want to make to a photo, because it is affected by anything else you do to your image: crop, resize, color and contrast... if you apply sharpening first and then make other changes it will mess up your sharpening. - -And what, you ask, does unsharp mask mean? The name comes from the sharpening technique: the unsharp mask filter creates a blurred mask of the original, and then layers the unsharp mask over the original. This creates an image that appears sharper and clearer without creating a lot of obvious sharpening artifacts. - -That is all for today. The documentation for Krita is abundant, but disorganized. Start at [Krita Tutorials][2], and poke around YouTube for a lot of good video how-tos. - -- [krita Official Web Site][1] - --------------------------------------------------------------------------------- - -via: http://www.linux.com/learn/tutorials/786040-photo-editing-on-linux-with-krita - -作者:[Carla Schroder][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://www.linux.com/community/forums/person/3734 -[1]:https://krita.org/ -[2]:https://krita.org/learn/tutorials/ \ No newline at end of file diff --git a/sources/tech/20140904 Use LaTeX In Ubuntu 14.04 and Linux Mint 17 With Texmaker.md b/sources/tech/20140904 Use LaTeX In Ubuntu 14.04 and Linux Mint 17 With Texmaker.md deleted file mode 100644 index f143e85c85..0000000000 --- a/sources/tech/20140904 Use LaTeX In Ubuntu 14.04 and Linux Mint 17 With Texmaker.md +++ /dev/null @@ -1,46 +0,0 @@ -johnhoow translating... -Use LaTeX In Ubuntu 14.04 and Linux Mint 17 With Texmaker -================================================================================ -![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/09/texmaker_Ubuntu.jpeg) - -[LaTeX][1] is a document markup language and document preparation system. It is widely used as a standard in universities and academics to write professional scientific papers, thesis and other such documents. In this quick post, we shall see **how to use LaTeX in Ubuntu 14.04**. - -### Install Texmaker to use LaTeX in Ubuntu 14.04 & Linux Mint 17 ### - -[Texmaker][2] is a free and open source LaTeX editor which is available for all major desktop OS i.e. Windows, Linux and OS X. Followings are the salient features of the Texmaker: - -- Unicode editor -- Spell checker -- Code folding -- Code completion -- Fast navigation -- Integrated Pdf viewer -- Easy compilation -- 370 Mathematical symbols -- LaTeX documentation -- Export to html and odt via TeX4ht -- Regex support - -You can install Texmaker in Ubuntu 14.04 by downloading the binaries from the given link: - -- [Download Texmaker LaTeX editor][3] - -Since it is .deb packaging, same installation files can be used n any other Debian based distribution such as Linux Mint, Elementary OS, Pinguy OS etc. - -If you want a Github type markdown editor, you should check [Remarkable editor][4]. I hope Texmaker helps you with **LaTeX in Ubuntu** and Linux Mint. - --------------------------------------------------------------------------------- - -via: http://itsfoss.com/install-latex-ubuntu-1404/ - -作者:[Abhishek][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://itsfoss.com/author/Abhishek/ -[1]:http://www.latex-project.org/ -[2]:http://www.xm1math.net/texmaker/index.html -[3]:http://www.xm1math.net/texmaker/download.html#linux -[4]:http://itsfoss.com/remarkable-markdown-editor-linux/ diff --git a/sources/tech/20140905 Linux TCP or IP networking--net-tools vs. iproute2.md b/sources/tech/20140905 Linux TCP or IP networking--net-tools vs. iproute2.md index e7353fc182..418ab6642d 100644 --- a/sources/tech/20140905 Linux TCP or IP networking--net-tools vs. iproute2.md +++ b/sources/tech/20140905 Linux TCP or IP networking--net-tools vs. iproute2.md @@ -1,4 +1,6 @@ >>Linchenguang is translating + +》》延期申请 Linux TCP/IP networking: net-tools vs. iproute2 ================================================================================ Many sysadmins still manage and troubleshoot various network configurations by using a combination of ifconfig, route, arp and netstat command-line tools, collectively known as net-tools. Originally rooted in the BSD TCP/IP toolkit, the net-tools was developed to configure network functionality of older Linux kernels. Its development in the Linux community so far has ceased since 2001. Some Linux distros such as Arch Linux and CentOS/RHEL 7 have already deprecated net-tools in favor of iproute2. diff --git a/sources/tech/20140910 How to create a cloud-based encrypted file system on Linux.md b/sources/tech/20140910 How to create a cloud-based encrypted file system on Linux.md index 1e8f3c62d1..3eccb78edd 100644 --- a/sources/tech/20140910 How to create a cloud-based encrypted file system on Linux.md +++ b/sources/tech/20140910 How to create a cloud-based encrypted file system on Linux.md @@ -1,3 +1,5 @@ +[felixonmars translating...] + How to create a cloud-based encrypted file system on Linux ================================================================================ Commercial cloud storage services such as [Amazon S3][1] and [Google Cloud Storage][2] offer highly available, scalable, infinite-capacity object store at affordable costs. To accelerate wide adoption of their cloud offerings, these providers are fostering rich developer ecosystems around their products based on well-defined APIs and SDKs. Cloud-backed file systems are one popular by-product of such active developer communities, for which several open-source implementations exist. @@ -153,4 +155,4 @@ via: http://xmodulo.com/2014/09/create-cloud-based-encrypted-file-system-linux.h [4]:http://aws.amazon.com/ [5]:http://ask.xmodulo.com/create-amazon-aws-access-key.html [6]:https://aur.archlinux.org/packages/s3ql/ -[7]:http://www.rath.org/s3ql-docs/ \ No newline at end of file +[7]:http://www.rath.org/s3ql-docs/ diff --git a/sources/tech/20140910 How to download GOG games from the command line on Linux.md b/sources/tech/20140910 How to download GOG games from the command line on Linux.md deleted file mode 100644 index 081e22cb0f..0000000000 --- a/sources/tech/20140910 How to download GOG games from the command line on Linux.md +++ /dev/null @@ -1,75 +0,0 @@ -How to download GOG games from the command line on Linux -================================================================================ -If you are a gamer and a Linux user, you probably were delighted when [GOG][1] announced a few months ago that it will start proposing games for your favorite OS. If you have never heard of GOG before, I encourage you to check out their catalog of “good old games”, reasonably priced, DRM-free, and packed with goodies. However, if the Windows client for GOG existed for quite some time now, an official Linux version is nowhere to be seen. So if waiting for the official version is uncomfortable for you, an unofficial open source program named LGOGDownloader gives you access to your library from the command line. - -![](https://farm4.staticflickr.com/3843/15121593356_b13309c70f_z.jpg) - -### Install LGOGDownloader on Linux ### - -For Ubuntu users, the [official page][2] recommends that you download the sources and do: - - $ sudo apt-get install build-essential libcurl4-openssl-dev liboauth-dev libjsoncpp-dev libhtmlcxx-dev libboost-system-dev libboost-filesystem-dev libboost-regex-dev libboost-program-options-dev libboost-date-time-dev libtinyxml-dev librhash-dev help2man - $ tar -xvzf lgogdownloader-2.17.tar.gz - $ cd lgogdownloader-2.17 - $ make release - $ sudo make install - -If you are an Archlinux user, an [AUR package][2] is waiting for you. - -### Usage of LGOGDownloader ### - -Once the program is installed, you will need to identify yourself with the command: - - $ lgogdownloader --login - -![](https://farm6.staticflickr.com/5593/15121593346_9c5d02d5ce_z.jpg) - -Notice that the configuration file if you need it is at ~/.config/lgogdownloader/config.cfg - -Once authenticated, you can list all the games in your library with: - - $ lgogdownloader --list - -![](https://farm6.staticflickr.com/5581/14958040387_8321bb71cf.jpg) - -Then download one with: - - $ lgogdownloader --download --game [game name] - -![](https://farm6.staticflickr.com/5585/14958040367_b1c584a2d1_z.jpg) - -You will notice that lgogdownloader allows you to resume previously interrupted downloads, which is nice because typical game downloads are not small. - -Like every respectable command line utility, you can add various options: - -- **--platform [number]** to select your OS where 1 is for windows and 4 for Linux. -- **--directory [destination]** to download the installer in a particular directory. -- **--language [number]** for a particular language pack (check the manual pages for the number corresponding to your language). -- **--limit-rate [speed]** to limit the downloading rate at a particular speed. - -As a side bonus, lgogdownloader also comes with the possibility to check for updates on the GOG website: - - $ lgogdownloader --update-check - -![](https://farm4.staticflickr.com/3882/14958035568_7889acaef0.jpg) - -The result will list the number of forum and private messages you have received, as well as the number of updated games. - -To conclude, lgogdownloader is pretty standard when it comes to command line utilities. I would even say that it is an epitome of clarity and coherence. It is true that we are far in term of features from the relatively recent Steam Linux client, but on the other hand, the official GOG windows client does not do much more than this unofficial Linux version. In other words lgogdownloader is a perfect replacement. I cannot wait to see more Linux compatible games on GOG, especially after their recent announcements to offer DRM free movies, with a thematic around video games. Hopefully we will see an update in the client for when movie catalog matches the game library. - -What do you think of GOG? Would you use the unofficial Linux Client? Let us know in the comments. - --------------------------------------------------------------------------------- - -via: http://xmodulo.com/2014/09/download-gog-games-command-line-linux.html - -作者:[Adrien Brochard][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://xmodulo.com/author/adrien -[1]:http://www.gog.com/ -[2]:https://sites.google.com/site/gogdownloader/home -[3]:https://aur.archlinux.org/packages/lgogdownloader/ \ No newline at end of file diff --git a/sources/tech/20140910 How to set up Nagios Remote Plugin Executor (NRPE) in Linux.md b/sources/tech/20140910 How to set up Nagios Remote Plugin Executor (NRPE) in Linux.md deleted file mode 100644 index 568400420c..0000000000 --- a/sources/tech/20140910 How to set up Nagios Remote Plugin Executor (NRPE) in Linux.md +++ /dev/null @@ -1,236 +0,0 @@ -How to set up Nagios Remote Plugin Executor (NRPE) in Linux -================================================================================ -As far as network management is concerned, Nagios is one of the most powerful tools. Nagios can monitor the reachability of remote hosts, as well as the state of services running on them. However, what if we want to monitor something other than network services for a remote host? For example, we may want to monitor the disk utilization or [CPU processor load][1] of a remote host. Nagios Remote Plugin Executor (NRPE) is a tool that can help with doing that. NRPE allows one to execute Nagios plugins installed on remote hosts, and integrate them with an [existing Nagios server][2]. - -This tutorial will cover how to set up NRPE on an existing Nagios deployment. The tutorial is primarily divided into two parts: - -- Configure remote hosts. -- Configure a Nagios monitoring server. - -We will then finish off by defining some custom commands that can be used with NRPE. - -### Configure Remote Hosts for NRPE ### - -#### Step One: Installing NRPE Service #### - -You need to install NRPE service on every remote host that you want to monitor using NRPE. NRPE service daemon on each remote host will then communicate with a Nagios monitoring server. - -Necessary packages for NRPE service can easily be installed using apt-get or yum, subject to the platform. In case of CentOS, we will need to [add Repoforge repository][3] as NRPE is not available in CentOS repositories. - -**On Debian, Ubuntu or Linux Mint:** - - # apt-get install nagios-nrpe-server - -**On CentOS, Fedora or RHEL:** - - # yum install nagios-nrpe - -#### Step Two: Preparing Configuration File #### - -The configuration file /etc/nagios/nrpe.cfg is similar for Debian-based and RedHat-based systems. The configuration file is backed up, and then updated as follows. - - # vim /etc/nagios/nrpe.cfg - ----------- - - ## NRPE service port can be customized ## - server_port=5666 - - ## the nagios monitoring server is permitted ## - ## NOTE: There is no space after the comma ## - allowed_hosts=127.0.0.1,X.X.X.X-IP_v4_of_Nagios_server - - ## The following examples use hard-coded command arguments. - ## These parameters can be modified as needed. - - ## NOTE: For CentOS 64 bit, use /usr/lib64 instead of /usr/lib ## - - command[check_users]=/usr/lib/nagios/plugins/check_users -w 5 -c 10 - command[check_load]=/usr/lib/nagios/plugins/check_load -w 15,10,5 -c 30,25,20 - command[check_hda1]=/usr/lib/nagios/plugins/check_disk -w 20% -c 10% -p /dev/hda1 - command[check_zombie_procs]=/usr/lib/nagios/plugins/check_procs -w 5 -c 10 -s Z - command[check_total_procs]=/usr/lib/nagios/plugins/check_procs -w 150 -c 200 - -Now that the configuration file is ready, NRPE service is ready to be fired up. - -#### Step Three: Initiating NRPE Service #### - -For RedHat-based systems, the NRPE service needs to be added as a startup service. - -**On Debian, Ubuntu, Linux Mint:** - - # service nagios-nrpe-server restart - -**On CentOS, Fedora or RHEL:** - - # service nrpe restart - # chkconfig nrpe on - -#### Step Four: Verifying NRPE Service Status #### - -Information about NRPE daemon status can be found in the system log. For a Debian-based system, the log file will be /var/log/syslog. The log file for a RedHat-based system will be /var/log/messages. A sample log is provided below for reference. - - nrpe[19723]: Starting up daemon - nrpe[19723]: Listening for connections on port 5666 - nrpe[19723]: Allowing connections from: 127.0.0.1,X.X.X.X - -In case firewall is running, TCP port 5666 should be open, which is used by NRPE daemon. - - # netstat -tpln | grep 5666 - ----------- - - tcp 0 0 0.0.0.0:5666 0.0.0.0:* LISTEN 19885/nrpe - -### Configure Nagios Monitoring Server for NRPE ### - -The first step in configuring an existing Nagios monitoring server for NRPE is to install NRPE plugin on the server. - -#### Step One: Installing NRPE Plugin #### - -In case the Nagios server is running on a Debian-based system (Debian, Ubuntu or Linux Mint), a necessary package can be installed using apt-get. - - # apt-get install nagios-nrpe-plugin - -After the plugin is installed, the check_nrpe command, which comes with the plugin, is modified a bit. - - # vim /etc/nagios-plugins/config/check_nrpe.cfg - ----------- - - ## the default command is overwritten ## - define command{ - command_name check_nrpe - command_line /usr/lib/nagios/plugins/check_nrpe -H '$HOSTADDRESS$' -c '$ARG1$' - } - -In case the Nagios server is running on a RedHat-based system (CentOS, Fedora or RHEL), you can install NRPE plugin using yum. On CentOS, [adding Repoforge repository][4] is necessary. - - # yum install nagios-plugins-nrpe - -Now that the NRPE plugin is installed, proceed to configure a Nagios server following the rest of the steps. - -#### Step Two: Defining Nagios Command for NRPE Plugin #### - -First, we need to define a command in Nagios for using NRPE. - - # vim /etc/nagios/objects/commands.cfg - ----------- - - ## NOTE: For CentOS 64 bit, use /usr/lib64 instead of /usr/lib ## - define command{ - command_name check_nrpe - command_line /usr/lib/nagios/plugins/check_nrpe -H '$HOSTADDRESS$' -c '$ARG1$' - } - -#### Step Three: Adding Host and Command Definition #### - -Next, define remote host(s) and commands to execute remotely on them. - -The following shows sample definitions of a remote host a command to execute on the host. Naturally, your configuration will be adjusted based on your requirements. The path to the file is slightly different for Debian-based and RedHat-based systems. But the content of the files are identical. - -**On Debian, Ubuntu or Linux Mint:** - - # vim /etc/nagios3/conf.d/nrpe.cfg - -**On CentOS, Fedora or RHEL:** - - # vim /etc/nagios/objects/nrpe.cfg - ----------- - - define host{ - use linux-server - host_name server-1 - alias server-1 - address X.X.X.X-IPv4_address_of_remote_host - } - - define service { - host_name server-1 - service_description Check Load - check_command check_nrpe!check_load - check_interval 1 - use generic-service - } - -#### Step Four: Restarting Nagios Service #### - -Before restarting Nagios, updated configuration is verified with a dry run. - -**On Ubuntu, Debian, or Linux Mint:** - - # nagios3 -v /etc/nagios3/nagios.cfg - -**On CentOS, Fedora or RHEL:** - - # nagios -v /etc/nagios/nagios.cfg - -If everything goes well, Nagios service can be restarted. - - # service nagios restart - -![](https://farm8.staticflickr.com/7024/13330387845_0bde8b6db5_z.jpg) - -### Configuring Custom Commands with NRPE ### - -#### Setup on Remote Servers #### - -The following is a list of custom commands that can be used with NRPE. These commands are defined in the file /etc/nagios/nrpe.cfg located at the remote servers. - - ## Warning status when load average exceeds 1, 2 and 1 for 1, 5, 15 minute interval, respectively. - ## Critical status when load average exceeds 3, 5 and 3 for 1, 5, 15 minute interval, respectively. - command[check_load]=/usr/lib/nagios/plugins/check_load -w 1,2,1 -c 3,5,3 - - ## Warning level 25% and critical level 10% for free space of /home. - ## Could be customized to monitor any partition (e.g. /dev/sdb1, /, /var, /home) - command[check_disk]=/usr/lib/nagios/plugins/check_disk -w 25% -c 10% -p /home - - ## Warn if number of instances for process_ABC exceeds 10. Critical for 20 ## - command[check_process_ABC]=/usr/lib/nagios/plugins/check_procs -w 1:10 -c 1:20 -C process_ABC - - ## Critical if the number of instances for process_XYZ drops below 1 ## - command[check_process_XYZ]=/usr/lib/nagios/plugins/check_procs -w 1: -c 1: -C process_XYZ - -#### Setup on Nagios Monitoring Server #### - -To apply the custom commands defined above, we modify the service definition at Nagios monitoring server as follows. The service definition could go to the file where all the services are defined (e.g., /etc/nagios/objects/nrpe.cfg or /etc/nagios3/conf.d/nrpe.cfg) - - ## example 1: check process XYZ ## - define service { - host_name server-1 - service_description Check Process XYZ - check_command check_nrpe!check_process_XYZ - check_interval 1 - use generic-service - } - - ## example 2: check disk state ## - define service { - host_name server-1 - service_description Check Process XYZ - check_command check_nrpe!check_disk - check_interval 1 - use generic-service - } - -To sum up, NRPE is a powerful add-on to Nagios as it provides provision for monitoring a remote server in a highly configurable fashion. Using NRPE, we can monitor server load, running processes, logged in users, disk states and other parameters. - -Hope this helps. - --------------------------------------------------------------------------------- - -via: http://xmodulo.com/2014/03/nagios-remote-plugin-executor-nrpe-linux.html - -作者:[Sarmed Rahman][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://xmodulo.com/author/sarmed -[1]:http://xmodulo.com/2012/08/how-to-measure-average-cpu-utilization.html -[2]:http://xmodulo.com/2013/12/install-configure-nagios-linux.html -[3]:http://xmodulo.com/2013/01/how-to-set-up-rpmforge-repoforge-repository-on-centos.html -[4]:http://xmodulo.com/2013/01/how-to-set-up-rpmforge-repoforge-repository-on-centos.html diff --git a/sources/tech/20140911 Install UberWriter Markdown Editor In Ubuntu 14.04.md b/sources/tech/20140911 Install UberWriter Markdown Editor In Ubuntu 14.04.md deleted file mode 100644 index 80dd3eff6f..0000000000 --- a/sources/tech/20140911 Install UberWriter Markdown Editor In Ubuntu 14.04.md +++ /dev/null @@ -1,61 +0,0 @@ -johnhoow translating... -Install UberWriter Markdown Editor In Ubuntu 14.04 -================================================================================ -Quick tutorial to show you **how to install UberWriter markdown editor in Ubuntu 14.04** for free via official PPA. - -[UberWriter][1] is a [markdown][2] editor for Ubuntu with a clean interface with focus on writing only. UberWriter utilizes [pandoc][3] markdown. The UI is based on GTK3 which is not yet fully integrated with Unity. A quick list of features for UberWriter is as following: - -- Clean interface -- pandoc markdown -- Preview option -- Distraction free “focus mode” -- Spell check -- Syntax highlighting and math in html and pdf -- Option to export as PDF, HTML, ODT etc - -### Install UberWriter in Ubuntu 14.04 ### - -UberWriter is available in [Ubuntu Software Center][4] but it costs $5. I would really recommend that you buy it, if you like it and if you can afford it to support the developer. - -UberWriter is also available for free via its official PPA. You can install it using the following commands in terminal: - - sudo add-apt-repository ppa:w-vollprecht/ppa - sudo apt-get update - sudo apt-get install uberwriter - -Once installed, you can run it from Unity Dash. Write down your document in UberWriter. As you can see, it highlights the markdown syntax: - -![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/09/UberWriter_Ubuntu.jpeg) - -You can use the preview feature to see how your document will actually look like: - -![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/09/UberWriter_Ubuntu_1.jpeg) - -I tried to export it as PDF but it asked me to install texlive. - -![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/09/UberWriter_Ubuntu_PDF_Export.png) - -Export to HTML and ODT was fine though. - -There are several other markdown editors available for Linux. [Remarkable][5] is one of them which has the feature of real time preview, which is not in UberWriter. But overall it is a nice application. If you are looking for document writing tool, you can also use [Texmaker LaTeX editor][6]. - -I hope this tutorial helped you to **install UberWriter in Ubuntu 14.04**. I haven’t tried but I presume that it should also work in Ubuntu 12.04, Linux Mint 17, Elementary OS and other Linux distributions based on Ubuntu. - - --------------------------------------------------------------------------------- - -via: http://itsfoss.com/install-uberwriter-markdown-editor-ubuntu-1404/ - -作者:[Abhishek][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://itsfoss.com/author/Abhishek/ -[1]:http://uberwriter.wolfvollprecht.de/ -[2]:http://en.wikipedia.org/wiki/Markdown -[3]:http://johnmacfarlane.net/pandoc/ -[4]:apt://uberwriter -[5]:http://itsfoss.com/remarkable-markdown-editor-linux/ -[6]:http://itsfoss.com/install-latex-ubuntu-1404/ diff --git a/sources/tech/20140911 Sysstat--All-in-One System Performance and Usage Activity Monitoring Tool For Linux.md b/sources/tech/20140911 Sysstat--All-in-One System Performance and Usage Activity Monitoring Tool For Linux.md deleted file mode 100644 index 541999538b..0000000000 --- a/sources/tech/20140911 Sysstat--All-in-One System Performance and Usage Activity Monitoring Tool For Linux.md +++ /dev/null @@ -1,124 +0,0 @@ -Sysstat – All-in-One System Performance and Usage Activity Monitoring Tool For Linux -================================================================================ -**Sysstat** is really a handy tool which comes with number of utilities to monitor system resources, their performance and usage activities. Number of utilities that we all use in our daily bases comes with sysstat package. It also provide the tool which can be scheduled using cron to collect all performance and activity data. - -![Install Sysstat in Linux](http://www.tecmint.com/wp-content/uploads/2014/08/sysstat.png) - -Install Sysstat in Linux - -Following are the list of tools included in sysstat packages. - -### Sysstat Features ### - -- [**iostat**][1]: Reports all statistics about your CPU and I/O statistics for I/O devices. -- **mpstat**: Details about CPUs (individual or combined). -- **pidstat**: Statistics about running processes/task, CPU, memory etc. -- **sar**: Save and report details about different resources (CPU, Memory, IO, Network, kernel etc..). -- **sadc**: System activity data collector, used for collecting data in backend for sar. -- **sa1**: Fetch and store binary data in sadc data file. This is used with sadc. -- **sa2**: Summaries daily report to be used with sar. -- **Sadf**: Used for displaying data generated by sar in different formats (CSV or XML). -- **Sysstat**: Man page for sysstat utility. -- **nfsiostat**-sysstat: I/O statistics for NFS. -- **cifsiostat**: Statistics for CIFS. - -Recenlty, on 17th of June 2014, **Sysstat 11.0.0** (stable version) has been released with some new interesting features as follows. - -pidstat command has been enhanced with some new options: first is “-R” which will provide information about the policy and task scheduling priority. And second one is “**-G**” which we can search processes with name and to get the list of all matching threads. - -Some new enhancement have been brought to sar, sadc and sadf with regards to the data files: Now data files can be renamed using “**saYYYYMMDD**” instead of “**saDD**” using option **–D** and can be located in directory different from “**/var/log/sa**”. We can define new directory by setting variable “SA_DIR”, which is being used by sa1 and sa2. - -### Installation of Sysstat in Linux ### - -The ‘**Sysstat**‘ package also available to install from default repository as a package in all major Linux distributions. However, the package which is available from the repo is little old and outdated version. So, that’s the reason, we here going to download and install the latest version of sysstat (i.e. version **11.0.0**) from source package. - -First download the latest version of sysstat package using the following link or you may also use **wget** command to download directly on the terminal. - -- [http://sebastien.godard.pagesperso-orange.fr/download.html][2] - - # wget http://pagesperso-orange.fr/sebastien.godard/sysstat-11.0.0.tar.gz - -![Download Sysstat Package](http://www.tecmint.com/wp-content/uploads/2014/08/Download-Sysstat.png) - -Download Sysstat Package - -Next, extract the downloaded package and go inside that directory to begin compile process. - - # tar -xvf sysstat-11.0.0.tar.gz - # cd sysstat-11.0.0/ - -Here you will have two options for compilation: - -a). Firstly, you can use **iconfig** (which will give you flexibility for choosing/entering the customized values for each parameters). - - # ./iconfig - -![Sysstat iconfig Command](http://www.tecmint.com/wp-content/uploads/2014/08/Sysstat-iconfig-Command.png) - -Sysstat iconfig Command - -b). Secondly, you can use standard **configure** command to define options in single line. You can run **./configure –help command** to get list of different supported options. - - # ./configure --help - -![Sysstat Configure Help](http://www.tecmint.com/wp-content/uploads/2014/08/Configure-Help.png) - -Sysstat Configure Help - -Here, we are moving ahead with standard option i.e. **./configure** command to compile sysstat package. - - # ./configure - # make - # make install - -![Configure Sysstat in Linux](http://www.tecmint.com/wp-content/uploads/2014/08/Configure-Sysstat.png) - -Configure Sysstat in Linux - -After compilation process completes, you will see the output similar to above. Now, verify the sysstat version by running following command. - - # mpstat -V - - sysstat version 11.0.0 - (C) Sebastien Godard (sysstat orange.fr) - -### Updating Sysstat in Linux ### - -By default sysstat use “**/usr/local**” as its prefix directory. So, all binary/utilities will get installed in “**/usr/local/bin**” directory. If you have existing sysstat package installed, then those will be there in “**/usr/bin**”. - -Due to existing sysstat package, you will not get your updated version reflected, because your “**$PATH**” variable don’t have “**/usr/local/bin set**”. So, make sure that “**/usr/local/bin**” exist there in your “$PATH” or set **–prefix** option to “**/usr**” during compilation and remove existing version before starting updating. - - # yum remove sysstat [On RedHat based System] - # apt-get remove sysstat [On Debian based System] - ----------- - - # ./configure --prefix=/usr - # make - # make install - -Now again, verify the updated version of systat using same ‘mpstat’ command with option ‘**-V**’. - - # mpstat -V - - sysstat version 11.0.0 - (C) Sebastien Godard (sysstat orange.fr) - -**Reference**: For more information please go through [Sysstat Documentation][3] - -That’s it for now, in my upcoming article, I will show some practical examples and usages of sysstat command, till then stay tuned to updates and don’t forget to add your valuable thoughts about the article at below comment section. - --------------------------------------------------------------------------------- - -via: http://www.tecmint.com/install-sysstat-in-linux/ - -作者:[Kuldeep Sharma][a] -译者:[译者ID](https://github.com/译者ID) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://www.tecmint.com/author/kuldeepsharma47/ -[1]:http://www.tecmint.com/linux-performance-monitoring-with-vmstat-and-iostat-commands/ -[2]:http://sebastien.godard.pagesperso-orange.fr/download.html -[3]:http://sebastien.godard.pagesperso-orange.fr/documentation.html \ No newline at end of file diff --git a/sources/tech/20140917 How to create a software RAID-1 array with mdadm on Linux.md b/sources/tech/20140917 How to create a software RAID-1 array with mdadm on Linux.md new file mode 100644 index 0000000000..8352450697 --- /dev/null +++ b/sources/tech/20140917 How to create a software RAID-1 array with mdadm on Linux.md @@ -0,0 +1,224 @@ + +How to create a software RAID-1 array with mdadm on Linux +================================================================================ +Redundant Array of Independent Disks (RAID) is a storage technology that combines multiple hard disks into a single logical unit to provide fault-tolerance and/or improve disk I/O performance. Depending on how data is stored in an array of disks (e.g., with striping, mirroring, parity, or any combination thereof), different RAID levels are defined (e.g., RAID-0, RAID-1, RAID-5, etc). RAID can be implemented either in software or with a hardware RAID card. On modern Linux, basic software RAID functionality is available by default. + +In this post, we'll discuss the software setup of a RAID-1 array (also known as a "mirroring" array), where identical data is written to the two devices that form the array. While it is possible to implement RAID-1 with partitions on a single physical hard drive (as with other RAID levels), it won't be of much use if that single hard drive fails. In fact, that's why most RAID levels normally use multiple physical drives to provide redundancy. In the event of any single drive failure, the virtual RAID block device should continue functioning without issues, and allow us to replace the faulty drive without significant production downtime and, more importantly, with no data loss. However, it does not replace the need to save periodic system backups in external storage. + +Since the actual storage capacity (size) of a RAID-1 array is the size of the smallest drive, normally (if not always) you will find two identical physical drives in RAID-1 setup. + +### Installing mdadm on Linux ### + +The tool that we are going to use to create, assemble, manage, and monitor our software RAID-1 is called mdadm (short for **m**ultiple **d**isks **adm**in). On Linux distros such as Fedora, CentOS, RHEL or Arch Linux, mdadm is available by default. On Debian-based distros, mdadm can be installed with aptitude or apt-get. + +#### Fedora, CentOS or RHEL #### + +As mdadm comes pre-installed, all you have to do is to start RAID monitoring service, and configure it to auto-start upon boot: + + # systemctl start mdmonitor + # systemctl enable mdmonitor + +For CentOS/RHEL 6, use these commands instead: + + # service mdmonitor start + # chkconfig mdmonitor on + +#### Debian, Ubuntu or Linux Mint #### + +On Debian and its derivatives, mdadm can be installed with **aptitude or apt-get**: + + # aptitude install mdadm + +On Ubuntu, you will be asked to configure postfix MTA for sending out email notifications (as part of RAID monitoring). You can skip it for now. + +On Debian, the installation will start with the following explanatory message to help us decide whether or not we are going to install the root filesystem on a RAID array. What we need to enter on the next screen will depend on this decision. Read it carefully: + +![](https://farm4.staticflickr.com/3918/15220883382_c14eb95914_z.jpg) + +Since we will not use our RAID-1 for the root filesystem, we will leave the answer blank: + +![](https://farm6.staticflickr.com/5555/15198241896_29e08b977f.jpg) + +When asked whether we want to start (reassemble) our array automatically during each boot, choose "Yes". Note that we will need to add an entry to the /etc/fstab file later in order for the array to be properly mounted during the boot process as well. + +![](https://farm4.staticflickr.com/3875/15220883342_2b1d689a0a_z.jpg) + +### Partitioning Hard Drives ### + +Now it's time to prepare the physical devices that will be used in our array. For this setup, I have plugged in two 8 GB USB drives that have been identified as /dev/sdb and /dev/sdc from dmesg output: + + # dmesg | less + +---------- + +[ 60.014863] sd 3:0:0:0: [sdb] 15826944 512-byte logical blocks: (8.10 GB/7.54 GiB) +[ 75.066466] sd 4:0:0:0: [sdc] 15826944 512-byte logical blocks: (8.10 GB/7.54 GiB) + +We will use fdisk to create a primary partition on each disk that will occupy its entire size. The following steps show how to perform this task on /dev/sdb, and assume that this drive hasn't been partitioned yet (otherwise, we can delete the existing partition(s) to start off with a clean disk): + + # fdisk /dev/sdb + +Press 'p' to print the current partition table: + +![](https://farm4.staticflickr.com/3883/15198241836_24625edcf3_z.jpg) + +(if one or more partitions are found, they can be deleted with 'd' option. Then 'w' option is used to apply the changes). + +Since no partitions are found, we will create a new primary partition ['n'] as a primary partition ['p'], assign the partition number = ['1'] to it, and then indicate its size. You can press Enter key to accept the proposed default values, or enter a value of your choosing, as shown in the image below. + +![](https://farm4.staticflickr.com/3875/15034475369_7e72fb9f2e_z.jpg) + +Now repeat the same process for /dev/sdc. + +If we have two drives of different sizes, say 750 GB and 1 TB for example, we should create a primary partition of 750 GB on each of them, and use the remaining space on the bigger drive for another purpose, independent of the RAID array. + +### Create a RAID-1 Array ### + +Once you are done with creating the primary partition on each drive, use the following command to create a RAID-1 array: + + # mdadm -Cv /dev/md0 -l1 -n2 /dev/sdb1 /dev/sdc1 + +Where: + +- **-Cv**: creates an array and produce verbose output. +- **/dev/md0**: is the name of the array. +- **-l1** (l as in "level"): indicates that this will be a RAID-1 array. +- **-n2**: indicates that we will add two partitions to the array, namely /dev/sdb1 and /dev/sdc1. + +The above command is equivalent to: + + # mdadm --create --verbose /dev/md0 --level=1 --raid-devices=2 /dev/sdb1 /dev/sdc1 + +If alternatively you want to add a spare device in order to replace a faulty disk in the future, you can add '--spare-devices=1 /dev/sdd1' to the above command. + +Answer "y" when prompted if you want to continue creating an array, then press Enter: + +![](https://farm4.staticflickr.com/3894/15034569970_709bd51718.jpg) + +You can check the progress with the following command: + + # cat /proc/mdstat + +![](https://farm6.staticflickr.com/5565/15221267975_701b819e6d_z.jpg) + +Another way to obtain more information about a RAID array (both while it's being assembled and after the process is finished) is: + + # mdadm --query /dev/md0 + # mdadm --detail /dev/md0 (or mdadm -D /dev/md0) + +![](https://farm6.staticflickr.com/5583/15034683868_6c28564e5a_z.jpg) + +Of the information provided by 'mdadm -D', perhaps the most useful is that which shows the state of the array. The active state means that there is currently I/O activity happening. Other possible states are clean (all I/O activity has been completed), degraded (one of the devices is faulty or missing), resyncing (the system is recovering from an unclean shutdown such as a power outage), or recovering (a new drive has been added to the array, and data is being copied from the other drive onto it), to name the most common states. + +### Formatting and Mounting a RAID Array ### + +The next step is formatting (with ext4 in this example) the array: + + # mkfs.ext4 /dev/md0 + +![](https://farm4.staticflickr.com/3849/15034683838_01e34e7196_z.jpg) + +Now let's mount the array, and verify that it was mounted correctly: + + # mount /dev/md0 /mnt + # mount + +![](https://farm6.staticflickr.com/5554/15034696167_c4fc907c8e_z.jpg) + +### Monitor a RAID Array ### + +The mdadm tool comes with RAID monitoring capability built in. When mdadm is set to run as a daemon (which is the case with our RAID setup), it periodically polls existing RAID arrays, and reports on any detected events via email notification or syslog logging. Optionally, it can also be configured to invoke contingency commands (e.g., retrying or removing a disk) upon detecting any critical errors. + +By default, mdadm scans all existing partitions and MD arrays, and logs any detected event to /var/log/syslog. Alternatively, you can specify devices and RAID arrays to scan in mdadm.conf located in /etc/mdadm/mdadm.conf (Debian-based) or /etc/mdadm.conf (Red Hat-based), in the following format. If mdadm.conf does not exist, create one. + + DEVICE /dev/sd[bcde]1 /dev/sd[ab]1 + + ARRAY /dev/md0 devices=/dev/sdb1,/dev/sdc1 + ARRAY /dev/md1 devices=/dev/sdd1,/dev/sde1 + ..... + + # optional email address to notify events + MAILADDR your@email.com + +After modifying mdadm configuration, restart mdadm daemon: + +On Debian, Ubuntu or Linux Mint: + + # service mdadm restart + +On Fedora, CentOS/RHEL 7: + + # systemctl restart mdmonitor + +On CentOS/RHEL 6: + + # service mdmonitor restart + +### Auto-mount a RAID Array ### + +Now we will add an entry in the /etc/fstab to mount the array in /mnt automatically during boot (you can specify any other mount point): + + # echo "/dev/md0 /mnt ext4 defaults 0 2" << /etc/fstab + +To verify that mount works okay, we now unmount the array, restart mdadm, and remount. We can see that /dev/md0 has been mounted as per the entry we just added to /etc/fstab: + + # umount /mnt + # service mdadm restart (on Debian, Ubuntu or Linux Mint) + or systemctl restart mdmonitor (on Fedora, CentOS/RHEL7) + or service mdmonitor restart (on CentOS/RHEL6) + # mount -a + +![](https://farm6.staticflickr.com/5563/15218183681_63a10da704_z.jpg) + +Now we are ready to access the RAID array via /mnt mount point. To test the array, we'll copy the /etc/passwd file (any other file will do) into /mnt: + +![](https://farm6.staticflickr.com/5593/15034475219_a3476aec0a_o.png) + +On Debian, we need to tell the mdadm daemon to automatically start the RAID array during boot by setting the AUTOSTART variable to true in the /etc/default/mdadm file: + + AUTOSTART=true + +### Simulating Drive Failures ### + +We will simulate a faulty drive and remove it with the following commands. Note that in a real life scenario, it is not necessary to mark a device as faulty first, as it will already be in that state in case of a failure. + +First, unmount the array: + + # umount /mnt + +Now, notice how the output of 'mdadm -D /dev/md0' indicates the changes after performing each command below. + + # mdadm /dev/md0 --fail /dev/sdb1 #Marks /dev/sdb1 as faulty + # mdadm --remove /dev/md0 /dev/sdb1 #Removes /dev/sdb1 from the array + +Afterwards, when you have a new drive for replacement, re-add the drive again: + + # mdadm /dev/md0 --add /dev/sdb1 + +The data is then immediately started to be rebuilt onto /dev/sdb1: + +![](https://farm4.staticflickr.com/3855/15221267875_dfc6af8804_z.jpg) + +Note that the steps detailed above apply for systems with hot-swappable disks. If you do not have such technology, you will also have to stop a current array, and shutdown your system first in order to replace the part: + + # mdadm --stop /dev/md0 + # shutdown -h now + +Then add the new drive and re-assemble the array: + + # mdadm /dev/md0 --add /dev/sdb1 + # mdadm --assemble /dev/md0 /dev/sdb1 /dev/sdc1 + +Hope this helps. + +-------------------------------------------------------------------------------- + +via: http://xmodulo.com/2014/09/create-software-raid1-array-mdadm-linux.html + +作者:[Gabriel Cánepa][a] +译者:[译者ID](https://github.com/译者ID) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://xmodulo.com/author/gabriel diff --git a/sources/tech/20140929 Using GIT to backup your website files on linux.md b/sources/tech/20140929 Using GIT to backup your website files on linux.md new file mode 100644 index 0000000000..2507bf80f2 --- /dev/null +++ b/sources/tech/20140929 Using GIT to backup your website files on linux.md @@ -0,0 +1,121 @@ +wangjiezhe translating + +Using GIT to backup your website files on linux +================================================================================ +![](http://techarena51.com/wp-content/uploads/2014/09/git_logo-1024x480-580x271.png) + +Well not exactly Git but a software based on Git known as BUP. I generally use rsync to backup my files and that has worked fine so far. The only problem or drawback is that you cannot restore your files to a particular point in time. Hence, I started looking for an alternative and found BUP a git based software which stores your data in repositories and gives you the option to restore data to a particular point in time. + +With BUP you will first need to initialize an empty repository, then take a backup of all your files. When BUP takes a backup it creates a restore point which you can later restore to. It also creates an index of all your files, this index contains file attributes and checksum. When another backup is scheduled BUP compares the files with this attribute and only saves data if anything has changed. This saves you a lot of space. + +### Installing BUP (Tested on Centos 6 & 7) ### + +Ensure you have RPMFORGE and EPEL repos installed. + + [techarena51@vps ~]$sudo yum groupinstall "Development Tools" + [techarena51@vps ~]$ sudo yum install python python-devel + [techarena51@vps ~]$ sudo yum install fuse-python pyxattr pylibacl + [techarena51@vps ~]$ sudo yum install perl-Time-HiRes + [techarena51@vps ~]$ git clone git://github.com/bup/bup + [techarena51@vps ~]$cd bup + [techarena51@vps ~]$ make + [techarena51@vps ~]$ make test + [techarena51@vps ~]$sudo make install + +For debian/ubuntu users you can do “apt-get build-dep bup” on recent versions for more information check out https://github.com/bup/bup +You may get errors on CentOS 7 at “make test”, but you can continue to run make install. + +The first step like git is to initialize an empty repository. + + [techarena51@vps ~]$bup init + +By default, bup will store it’s repository under “~/.bup” but you can change that by setting the “export BUP_DIR=/mnt/user/bup” environment variable + +Next you create an index of all files. The index, as I mentioned earlier stores a listing of files, their attributes, and their git object ids (sha1 hashes). ( Attributes include soft links, permissions as well as the immutable bit + + bup index /path/to/file + bup save -n nameofbackup /path/to/file + + #Example + [techarena51@vps ~]$ bup index /var/www/html + Indexing: 7973, done (4398 paths/s). + bup: merging indexes (7980/7980), done. + + [techarena51@vps ~]$ bup save -n techarena51 /var/www/html + + Reading index: 28, done. + Saving: 100.00% (4/4k, 28/28 files), done. + bloom: adding 1 file (7 objects). + Receiving index from server: 1268/1268, done. + bloom: adding 1 file (7 objects). + +“BUP save” will split all the contents of the file into chunks and store them as objects. The “-n” option takes the name of backup. + +You can check a list of backups as well as a list of backed up files. + + [techarena51@vps ~]$ bup ls + local-etc techarena51 test + #Check for a list of backups available for my site + [techarena51@vps ~]$ bup ls techarena51 + 2014-09-24-064416 2014-09-24-071814 latest + #Check for the files available in these backups + [techarena51@vps ~]$ bup ls techarena51/2014-09-24-064416/var/www/html + apc.php techarena51.com wp-config-sample.php wp-load.php + +Backing up files on the same server is never a good option. BUP allows you to remotely backup your website files, you however need to ensure that your SSH keys and BUP are installed on the remote server. + + bup index path/to/dir + bup save-r remote-vps.com -n backupname path/to/dir + +### Example: Backing up the “/var/www/html” directory ### + + [techarena51@vps ~]$bup index /var/www/html + [techarena51@vps ~]$ bup save -r user@remotelinuxvps.com: -n techarena51 /var/www/html + Reading index: 28, done. + Saving: 100.00% (4/4k, 28/28 files), done. + bloom: adding 1 file (7 objects). + Receiving index from server: 1268/1268, done. + bloom: adding 1 file (7 objects). + +### Restoring your Backup ### + +Log into the remote server and type the following + + [techarena51@vps ~]$bup restore -C ./backup techarena51/latest + + #Restore an older version of the entire working dir elsewhere + [techarena51@vps ~]$bup restore -C /tmp/bup-out /testrepo/2013-09-29-195827 + #Restore one individual file from an old backup + [techarena51@vps ~]$bup restore -C /tmp/bup-out /testrepo/2013-09-29-201328/root/testbup/binfile1.bin + +The only drawback is you cannot restore files to another server, you have to manually copy the files via SCP or even rsync. + +View your backups via an integrated web server + + bup web + #specific port + bup web :8181 + +You can run bup along with a shell script and a cron job once everyday. + + #!/bin/bash + + bup index /var/www/html + bup save -r user@remote-vps.com: -n techarena51 /var/www/html + +BUP may not be perfect, but it get’s the job done pretty well. I would definitely like to see more development on this project and hopefully a remote restore as well. + +You may also like to read using [inotify-tools][1] for real time file syncing. + +-------------------------------------------------------------------------------- + +via: http://techarena51.com/index.php/using-git-backup-website-files-on-linux/ + +作者:[Leo G][a] +译者:[译者ID](https://github.com/译者ID) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://techarena51.com/ +[1]:http://techarena51.com/index.php/inotify-tools-example/ diff --git a/sources/tech/20141004 Practical Lessons in Peer Code Review.md b/sources/tech/20141004 Practical Lessons in Peer Code Review.md new file mode 100644 index 0000000000..3576dd0e98 --- /dev/null +++ b/sources/tech/20141004 Practical Lessons in Peer Code Review.md @@ -0,0 +1,138 @@ +johnhoow translating... +# Practical Lessons in Peer Code Review # + +Millions of years ago, apes descended from the trees, evolved opposable thumbs and—eventually—turned into human beings. + +We see mandatory code reviews in a similar light: something that separates human from beast on the rolling grasslands of the software +development savanna. + +Nonetheless, I sometimes hear comments like these from our team members: + +"Code reviews on this project are a waste of time." +"I don't have time to do code reviews." +"My release is delayed because my dastardly colleague hasn't done my review yet." +"Can you believe my colleague wants me to change something in my code? Please explain to them that the delicate balance of the universe will +be disrupted if my pristine, elegant code is altered in any way." + +### Why do we do code reviews? ### + +Let us remember, first of all, why we do code reviews. One of the most important goals of any professional software developer is to +continually improve the quality of their work. Even if your team is packed with talented programmers, you aren't going to distinguish +yourselves from a capable freelancer unless you work as a team. Code reviews are one of the most important ways to achieve this. In +particular, they: + +provide a second pair of eyes to find defects and better ways of doing something. +ensure that at least one other person is familiar with your code. +help train new staff by exposing them to the code of more experienced developers. +promote knowledge sharing by exposing both the reviewer and reviewee to the good ideas and practices of the other. +encourage developers to be more thorough in their work since they know it will be reviewed by one of their colleagues. + +### Doing thorough reviews ### + +However, these goals cannot be achieved unless appropriate time and care are devoted to reviews. Just scrolling through a patch, making sure +that the indentation is correct and that all the variables use lower camel case, does not constitute a thorough code review. It is +instructive to consider pair programming, which is a fairly popular practice and adds an overhead of 100% to all development time, as the +baseline for code review effort. You can spend a lot of time on code reviews and still use much less overall engineer time than pair +programming. + +My feeling is that something around 25% of the original development time should be spent on code reviews. For example, if a developer takes +two days to implement a story, the reviewer should spend roughly four hours reviewing it. + +Of course, it isn't primarily important how much time you spend on a review as long as the review is done correctly. Specifically, you must +understand the code you are reviewing. This doesn't just mean that you know the syntax of the language it is written in. It means that you +must understand how the code fits into the larger context of the application, component or library it is part of. If you don't grasp all the +implications of every line of code, then your reviews are not going to be very valuable. This is why good reviews cannot be done quickly: it +takes time to investigate the various code paths that can trigger a given function, to ensure that third-party APIs are used correctly +(including any edge cases) and so forth. + +In addition to looking for defects or other problems in the code you are reviewing, you should ensure that: + +All necessary tests are included. +Appropriate design documentation has been written. +Even developers who are good about writing tests and documentation don't always remember to update them when they change their code. A +gentle nudge from the code reviewer when appropriate is vital to ensure that they don't go stale over time. + +### Preventing code review overload ### + +If your team does mandatory code reviews, there is the danger that your code review backlog will build up to the point where it is +unmanageable. If you don't do any reviews for two weeks, you can easily have several days of reviews to catch up on. This means that your +own development work will take a large and unexpected hit when you finally decide to deal with them. It also makes it a lot harder to do +good reviews since proper code reviews require intense and sustained mental effort. It is difficult to keep this up for days on end. + +For this reason, developers should strive to empty their review backlog every day. One approach is to tackle reviews first thing in the +morning. By doing all outstanding reviews before you start your own development work, you can keep the review situation from getting out of +hand. Some might prefer to do reviews before or after the midday break or at the end of the day. Whenever you do them, by considering code +reviews as part of your regular daily work and not a distraction, you avoid: + +Not having time to deal with your review backlog. +Delaying a release because your reviews aren't done yet. +Posting reviews that are no longer relevant since the code has changed so much in the meantime. +Doing poor reviews since you have to rush through them at the last minute. + +### Writing reviewable code ### + +The reviewer is not always the one responsible for out-of-control review backlogs. If my colleague spends a week adding code willy-nilly +across a large project then the patch they post is going to be really hard to review. There will be too much to get through in one session. +It will be difficult to understand the purpose and underlying architecture of the code. + +This is one of many reasons why it is important to split your work into manageable units. We use scrum methodology so the appropriate unit +for us is the story. By making an effort to organize our work by story and submit reviews that pertain only to the specific story we are +working on, we write code that is much easier to review. Your team may use another methodology but the principle is the same. + +There are other prerequisites to writing reviewable code. If there are tricky architectural decisions to be made, it makes sense to meet +with the reviewer beforehand to discuss them. This will make it much easier for the reviewer to understand your code, since they will know +what you are trying to achieve and how you plan to achieve it. This also helps avoid the situation where you have to rewrite large swathes +of code after the reviewer suggests a different and better approach. + +Project architecture should be described in detail in your design documentation. This is important anyway since it enables a new project +member to get up to speed and understand the existing code base. It has the further advantage of helping a reviewer to do their job +properly. Unit tests are also helpful in illustrating to the reviewer how components should be used. + +If you are including third-party code in your patch, commit it separately. It is much harder to review code properly when 9000 lines of +jQuery are dropped into the middle. + +One of the most important steps for creating reviewable code is to annotate your code reviews. This means that you go through the review +yourself and add comments anywhere you feel that this will help the reviewer to understand what is going on. I have found that annotating +code takes relatively little time (often just a few minutes) and makes a massive difference in how quickly and well the code can be +reviewed. Of course, code comments have many of the same advantages and should be used where appropriate, but often a review annotation +makes more sense. As a bonus, studies have shown that developers find many defects in their own code while rereading and annotating it. + +### Large code refactorings ### + +Sometimes it is necessary to refactor a code base in a way that affects many components. In the case of a large application, this can take +several days (or more) and result in a huge patch. In these cases a standard code review may be impractical. + +The best solution is to refactor code incrementally. Figure out a partial change of reasonable scope that results in a working code base and +brings you in the direction you want to go. Once that change has been completed and a review posted, proceed to a second incremental change +and so forth until the full refactoring has been completed. This might not always be possible, but with thought and planning it is usually +realistic to avoid massive monolithic patches when refactoring. It might take more time for the developer to refactor in this way, but it +also leads to better quality code as well as making reviews much easier. + +If it really isn't possible to refactor code incrementally (which probably says something about how well the original code was written and +organized), one solution might be to do pair programming instead of code reviews while working on the refactoring. + +### Resolving disputes ### + +Your team is doubtless made up of intelligent professionals, and in almost all cases it should be possible to come an agreement when +opinions about a specific coding question differ. As a developer, keep an open mind and be prepared to compromise if your reviewer prefers a +different approach. Don't take a proprietary attitude to your code and don't take review comments personally. Just because someone feels +that you should refactor some duplicated code into a reusable function, it doesn't mean that you are any less of an attractive, brilliant +and charming individual. + +As a reviewer, be tactful. Before suggesting changes, consider whether your proposal is really better or just a matter of taste. You will +have more success if you choose your battles and concentrate on areas where the original code clearly requires improvement. Say things like +"it might be worth considering..." or "some people recommend..." instead of "my pet hamster could write a more efficient sorting algorithm +than this." + +If you really can't find middle ground, ask a third developer who both of you respect to take a look and give their opinion. + +-------------------------------------------------------------------------------- + +via: http://blog.salsitasoft.com/practical-lessons-in-peer-code-review/ +作者:[Matt][a] +译者:[译者ID](https://github.com/译者ID) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + + diff --git a/translated/talk/20140818 Why Your Company Needs To Write More Open Source Software.md b/translated/talk/20140818 Why Your Company Needs To Write More Open Source Software.md new file mode 100644 index 0000000000..23ed4a63d7 --- /dev/null +++ b/translated/talk/20140818 Why Your Company Needs To Write More Open Source Software.md @@ -0,0 +1,68 @@ +为什么你的公司需要参与更多开源软件的编写 +================================================================================ +>闭关锁国是产生不了创新的。 + +![](http://a5.files.readwrite.com/image/upload/c_fill,h_900,q_70,w_1600/MTE5NDg0MDYxMTkxMzQxNTgz.jpg) + + +**华尔街日报 [称][1],有消息表明,Zulily正在开发** 更多的内部软件,但实际上根本不是。多年前[Eric Raymond写道][2],全世界95%的软件写来用的,而不是售卖。原因很多,但是其中有一个比较突出:正如Zulily的CIO Luke Friang所说,几乎没有一个[非定制]软件解决方案能跟上我们的步伐。 + +20年前是这样,现在也是这样。 + +但是有一点是不同的,这也正是华尔街日报完全忽略的地方。而这也正是历史上开发的内部软件始终保持着专有的原因了,因为她是一个公司的 核心竞争力。然而今天,越来越多的公司意识到另一面:开源内部软件将会比保持专有获益更多。 + +这也就是为什么你的公司需要为开源项目做出更多的贡献。记住是更多。 + +我们刚刚经历了一个很不一样的20年,那时很多软件的开发都是为了内部的使用,大多数人的精力都放在由SAP和微软这样的厂商建立的应用广泛的企业级解决方案。 + +不管怎么说,这都是一个理论。 + +在实践中,买方花费很少的钱购买license,然后至少付出5倍以上的代价来使软件符合他们的需求。比如说,一个公司可能在一个ERP系统上花费 100,000美元,但是他们还得继续花费500,000来维持软件正常运行。 + +开源软件甚至是应用程序正式发展起来的原因之一是很多公司可以免费获得一些功能性的产品(或者是以一个相对便宜的费用获得产品), 然后定制为他们所需要的。不管怎样,定制是有必要的,而且开源的根本是使成本更低,或许,这样的定制或许能产生更好的结果。 + +同时,开发者尽量的减少同类之间的相似之处。作为Redmonk分析师,[Stephen O'Grady认为][3]: + +> 从最近几年看,主流技术产业都有意避开专业化。运行在定制操作系统上的虚拟设备,已经彻底败给了RHEL和Windowns这些通用的操作系统。 最快20年,任何程序的数据保存都意味着一件事:一个关联的数据库,如果你要做的是企业级应用开发,那么你首先要接触的是Java,等等。 + +然而,开源的道路上,一些公司也发现,有些销售商不能很好地描述他们所想要的,即便是很好理解的产品类别,如像内容管理系统,他们需要 知道的是产品亮点,而不希望是一个模子刻出来的。 + +所以顾客没了,他们中有一部分上转变变成了供应商。 + +这也是常有的事,[O'Grady指出了][4]这一点。2010年,O'Grady发现了一个有趣的现象:“软件提供商正面对着一个强有力的市场竞争者:他们 的顾客。” + +回想一下今天的高科技,大多数都是开源的,几乎所有的项目一开始都是某些公司的内部项目,或者仅仅是有些开发者的爱好,Linux,Git,Hadoop,Cassandra,MongDB,Android,等等。没有一个项目起初是为了售卖而产生的。 + +相反,这些项目通常是由一些公司维护,他们使用开源的资源来构建软件并[完善软件][5],这主要是一些Web公司。不像以前银行,医院和一些组织开发的软件只供内部使用,他们开源源码。 + +虽然,[有些公司避免定制软件][6],因为他们不想自己维护它,开源(稍微)减轻了这些发展中公司来维护一个项目的压力。从而为项目发起人均摊项目的开发成本,Yahoo,开始于Hadoop,但是现在最大的贡献者是Cloudera和Hortonworks。Facebook开始于Cassandra,但是现在主要是靠DataStax在维护。等等。 + +今天,真正的软件创新并不是闭门造车能造出来的,即便是可以,它也不会在那儿,开源项目颠覆了几十年的软件开发传统。 + +这不仅仅是一个人的一点点力量。 + +最好的开源项目都[发展得很快][7],但是这并不意味着别人在乎你的开源代码。[开放你的源码有显著的优缺点][8],其中一个很重要的优点是 很多伟大的开发者都希望为开源做出贡献:如果你也想找一个伟大的开发者跟你一起,你需要给他们一个开放的源代码来让他们工作。([Netflix][9]说) + +但是,我们没有理由站在一边看,现在正是时候参与开源社区了,而不是一些不清楚的社区。是的,开源最大的参与者正是你们和你们的公司。 赶紧开始吧。 + +主要图片来自于Shutterstock. (注:Shutterstock是美国的一家摄影图片网站。) +-------------------------------------------------------------------------------- + +via: http://readwrite.com/2014/08/16/open-source-software-business-zulily-erp-wall-street-journal + +作者:[Matt Asay][a] +译者:[barney-ro](https://github.com/barney-ro) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://readwrite.com/author/matt-asay +[1]:http://blogs.wsj.com/cio/2014/08/08/zulily-calls-in-house-software-a-differentiator-for-competitive-advantage/ +[2]:http://oreilly.com/catalog/cathbazpaper/chapter/ch05.html +[3]:http://redmonk.com/sogrady/2010/01/12/roll-your-own/#ixzz3ATBuZsef +[4]:http://redmonk.com/sogrady/2010/01/12/roll-your-own/ +[5]:http://en.wikipedia.org/wiki/The_Cathedral_and_the_Bazaar +[6]:http://www.abajournal.com/magazine/article/roll_your_own_software_hidden_dangers_on_the_road_less_traveled/ +[7]:http://readwrite.com/2013/12/12/open-source-innovation +[8]:http://readwrite.com/2014/07/07/open-source-software-pros-cons +[9]:http://techblog.netflix.com/2012/07/open-source-at-netflix-by-ruslan.html diff --git a/translated/talk/20140825 China Will Change The Way All Software Is Bought And Sold.md b/translated/talk/20140825 China Will Change The Way All Software Is Bought And Sold.md deleted file mode 100644 index c564b47f12..0000000000 --- a/translated/talk/20140825 China Will Change The Way All Software Is Bought And Sold.md +++ /dev/null @@ -1,67 +0,0 @@ -中国将要改变软件购买和销售的方式 -================================================================================ -![](http://a5.files.readwrite.com/image/upload/c_fill,h_900,q_70,w_1600/MTE5NDg0MDYyMzQ4MzE0MTI3.jpg) - -> 这一切都是关于“开源”. - -**中国并不需要开源,也不需要你的软件。具体说来,中国市场并不需要你的工程师日以继夜的工作,也不需要你提供的任何东西。 - -中国每年会产生超过100000名新软件工程师们,这些工程师会写出一大批令人惊叹的奇妙软件。如果有中国市场上尚未出现的软件,中国的工程师们就会从国外“借鉴”。在2012年,这样的软件掠夺达到了77%之多。对于那些已经面对着开源和云服务的挑战的软件卖家来说,中国无疑让他们的日子更苦难了。 - -不止是更困难,简直是举步维艰。 - -中国正在挑战西方公司在中国或者其他地方赚钱的模式。对于那些已经明白如何在中国运营的公司来说,他们的未来看起来一片光明。 - -### 抵制中国模式 ### - -当然,并非每家公司都会坐以待毙。以微软为例,微软通用美国的国家司法权力来禁止中国公司做生意——除非他们像微软购买许可证。这是一种很聪明的做法,而且它可能会为微软创造数以十亿计的价值。但是最终这一做法看起来与中国市场格格不入。 - -原因很简单,中国与微软对待知识产权的态度十分不同。 - -正如 [我所提到的][2],“中国的企业更倾向于购买复杂的,面向企业的软件。因为这种软件比服务大众的公司设计出来的软件更先进,就像同在亚洲的印度。”但这种形势不会持续太久,因为中国的软件产业正在以一种惊人的速度前进,并毫无颓势。中国一定会坚持向西方国家“借鉴”代码直到有一天有足够的能力可以创造出有创新能力的软件。 - -但是即使这样,中国的软件公司与美国软件的运营模式还是有所不同,美国的软件大多都已经捆绑在设备、架构在云端或者公司只因为提供软件支持而要价。而这些运营模式中国是无法克隆的。 - -不出所料的,每一个收费模式是公司门使用“开源”进行盈利。 - -### 开源化中国 ### - -正如CCID的分析师在 [J. Aaron Farr 的关于中国开源化报告][3] 中指出的,中国的开源社区规模很小而且没什么影响力。开源社区们没有大项目、参与者稀少而且资金匮乏。 - -这真是个坏消息。 - -好消息是,像华为这样的公司就把开源作为一种战略前景。具体而言,当华为的开源项目过时或者不是很强势的时候,这种现象就证明了他们的科技步伐是错误的。在与参与了开源项目的华为公司内部顾问的谈话中,虽然华为对如何参与到开源社区还处于摸索阶段,但他们总是对华为的开源项目赞不绝口。 - -这种无人关注开源的现象不会长久地持续下去。 - -从一件事就可以看出端倪。中国最大的互联网公司们都纷纷以积极地姿态拥抱开源,这意味着中国开源时代的到来。你若是和任意一位在百度、阿里巴巴、微博的员工谈话,你会发现他们的软件项目都是彻底开源的。这些开源的软件都是运行在这些公司自己研发的硬件上而不是西方的硬件上。 - -换句话说,这样的模式已经和西方的运营模式如出一辙了。 - -抬头看看 [现金软件行业内最炙手可热的新公司][5], 你就会知道中国的互联网公司未来的主流趋势,正如发生在西方世界的一样。不出意料的,许多都是关于“开源”。 - -### 销售给中国 ### - -所有的一切都表明中国的软件行业不会像美国的软件行业发展历史一般发展。中国不会产生在柜台上卖卖软件就赚上亿美元的公司。因为西方对于知识产权的观念就是不适于中国的科技经济。 - -所以,软件卖家们需要售卖币软件更丰富的产品。云服务是一大前景。硬件设施看起来也是前途璀璨。软件支持和咨询服务(虽然有一些非主流)也很被公司门看好。总而言之,中国的软件行业会充满了开源味道,而不能靠着简单的售卖专柜软件的形式赚钱。 - -图片由 [hackNY.org][6] 提供。 - --------------------------------------------------------------------------------- - -原文: http://readwrite.com/2014/08/12/china-opensource-software-ip-programmers-united-states - -作者:[Matt Asay][a] -译者:[chi1shi2](https://github.com/chi1shi2) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://readwrite.com/author/matt-asay -[1]:http://readwrite.com/2014/03/17/microsoft-anti-piracy-strategy-china -[2]:http://readwrite.com/2014/04/11/india-starts-paying-for-software-china-it -[3]:http://cdn.oreillystatic.com/en/assets/1/event/12/Open%20Source%20in%20China%20Presentation%201.pdf -[4]:http://huawei.com/en/about-huawei/Partner/openathuawei/index.htm -[5]:http://codingvc.com/which-technologies-do-startups-use-an-exploration-of-angellist-data -[6]:https://www.flickr.com/photos/hackny/8675057448/ \ No newline at end of file diff --git a/translated/talk/20140828 Interesting facts about Linux.md b/translated/talk/20140828 Interesting facts about Linux.md new file mode 100644 index 0000000000..689003b93b --- /dev/null +++ b/translated/talk/20140828 Interesting facts about Linux.md @@ -0,0 +1,85 @@ +Linux趣事 +================================================================================ +今天,8月25号,是Linux的第23个生日。1991年,8月25日,21岁的赫尔辛基大学的学生发布了举世闻名的[新闻组][1](Usenet post),标志着现在世界著名的Linux正式诞生。 + +23年以后的今天,linux已经无处不在,不仅仅被安装于桌面系统,[智能手机][2]和嵌入式系统,甚至也被[龙头企业][3]用于他们的关键系统,比如说像[美国海军的核潜艇][4](US Navy's nuclear submarines)和[联邦航空局的空中管制系统][5](FAA's air traffic control)。进入无处不在的云计算时代,linux在云计算平台方面仍然保持着它的优势。 + +今天,我们一起庆祝linux 23岁生日,就让我们告诉你**一些你可能不知道的linux趣事和linux历史**。如果有什么要补充的,请在评论中分享出来。在这篇文章里,我可能用会用“linux”,“kernel”和“Linux kernel”来表示同一个意思。 + +1.关于linux是否是一个开源的操作系统这种争论一直是无休无止的。事实上,“Linux”操作系统的核心组件参照的是Linux kernel(内核)。而反派认为Linux不是一个纯粹的操作系统,因为他们认为仅仅一个内核(kernel),并不是一个操作系统,自由软件的推崇者认为最大的操作系统应叫做“[GNU/Linux][7]”把功劳归于应得的人。(比如:[GNU project][8])。另一方面,一些linux的开发者认为,linux拥有成为一个操作系统的资格,因为它实现了[POSIX标准][9]。 + +2.从openhub网站的统计来看,绝大部分(95%)的Linux是用C语言写的。第二(2.8%)受欢迎的是汇编语言。毫无疑问,C语言比C++ 的更受欢迎,也表明了linus对C++的立场。下面是Linus编程语言的分类。 + +![](https://farm4.staticflickr.com/3845/15025332121_055cfe3a2c_z.jpg) + +3.在世界上,Linux已经被[13,036个贡献者][10]创建和修改。当然,贡献最多的还是Linus Torvalds自己。直到目前,他提交了20,000次以上的代码。下图显示了所有提交次数最多的前十位Linux贡献者。 + +![](https://farm4.staticflickr.com/3837/14841786838_7a50625f9d_b.jpg) + +4.Linux的代码行(SLOC)有超过1700万行。估计整个代码库的花费大概是5,526人年,或者是超过300M(1M=10*1000万亿)美元,[基于模型的基本估算法][11](basic COCOMO model)。 + +5.企业并不是单纯的Linux消费者。他们的员工也在[积极参与][12]Linux的开发。下图显示了前十的Linux内核开发参与的企业员工2013年提交次数的总和。他们包括linux的商业版发行者(Red Hat,SUSE),芯片/嵌入式系统制造商(Intel,Texas Instrument,wolfson),非盈利性组织(Linaro)和其他的IT公司(IBM,Samsung,Google)。 + +![](https://farm6.staticflickr.com/5573/14841856427_a5a1828245_o.png) + +6.Linux的官方吉祥物是“小企鹅”,一个非常可爱的企鹅标志。[第一次提出][13]并决定小企鹅作为Linux吉祥物/标志这个想法的是Linus自己。为什么是小企鹅呢?因为Linus本人很喜欢企鹅,尽管他曾经被一只凶猛的企鹅咬伤过,还导致他得了一场病。 + +7.一个Linux系统“包括”Linux内核、支持GUN的组件和库、和一些第三方的应用。[distrowatch网站][14]显示,现在总共有286个活跃的Linux发行版。其中最老的一个版本叫[Slackware][15],它是从1993年正式发布出来的一个可用的版本。 + +8.Kernel.org是一个Linux源码的主要仓库,曾经在2011年8月被一个匿名的攻击者[攻陷][16],攻击者打算篡改kernel.org的服务器。为了加强linux内核的访问策略的安全性,Linux基金会最近在Linux内核的Git官方托管的仓库上[开启了][17]双重认证。 + +9.Linux在500强超级计算机中的优势还在[增加][18]。截至2014年6月,运算速度最快的计算机97%都是运行在Linux上面的。 + +10.太空监视(spacewatch),是亚利桑那大学月球与行星实验室的一个研究项目,在GNU/Linux和它的创造者们出现之后,用他们名字命名了几颗小行星([小行星9793 Torvalds][19],[小行星9882 Stallman][20],[小行星9885 Linux][21],[小行星9965 GUN][22]),以表彰他们把开源操作系统用于他们的小行星调查活动。 + +11.纵观Linux内核发展得近代史,版本从2.6到3.0有一个很大的跳跃。这个[重编的版本号3][23]实际上并不是意味着Linux内核有什么重大的构建,但却标志着Linux 20周年的一个里程碑。 + +12.在2000年的时候,乔帮主还在苹果。他当时就[尝试雇佣][24]Linus Torvalds,让他放弃Linux的开发,转而为“Unix最大的用户群工作”,这个项目后面发展成了MAC OS X。当时,linus拒绝了乔帮主的邀请。 + +13.Linux 内核的重启函数[reboot()][25]要求两个神奇的数字,而这第二个数字来自Linus Torvalds和他的3个女儿的出生日期。 + +14.虽然全世界都有Linux的很多粉丝,但是也仍然存在很多对Linux的批评(主要是桌面系统),如缺乏硬件支持,缺乏标准化,由于很短的升级和发布周期导致系统的不稳定,等。2014年Linux内核小组在linuxCon大会上,当Linus被问及Linux的未来将何去何从,他表示“I still want the desktop”(我仍然希望桌面化)。 + +如果你还知道些关于Linux的趣事,请写在评论里。 + +生日快乐,Linux! + +-------------------------------------------------------------------------------- + +via: http://xmodulo.com/2014/08/interesting-facts-linux.html + +作者:[Dan Nanni][a] +译者:[barney-ro](https://github.com/barney-ro) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://xmodulo.com/author/nanni +[1]:https://groups.google.com/forum/message/raw?msg=comp.os.minix/dlNtH7RRrGA/SwRavCzVE7gJ +[2]:http://developer.android.com/about/index.html +[3]:http://fortune.com/2013/05/06/how-linux-conquered-the-fortune-500/ +[4]:http://www.linuxjournal.com/article/7789 +[5]:http://fcw.com/Articles/2006/05/01/FAA-manages-air-traffic-with-Linux.aspx +[6]:http://thecloudmarket.com/stats +[7]:http://www.gnu.org/gnu/why-gnu-linux.html +[8]:http://www.gnu.org/gnu/gnu-history.html +[9]:http://en.wikipedia.org/wiki/POSIX +[10]:https://www.openhub.net/p/linux/contributors/summary +[11]:https://www.openhub.net/p/linux/estimated_cost +[12]:http://www.linuxfoundation.org/publications/linux-foundation/who-writes-linux-2013 +[13]:http://www.sjbaker.org/wiki/index.php?title=The_History_of_Tux_the_Linux_Penguin +[14]:http://distrowatch.com/search.php?ostype=All&category=All&origin=All&basedon=All¬basedon=None&desktop=All&architecture=All&status=Active +[15]:http://www.slackware.com/info/ +[16]:http://pastebin.com/BKcmMd47 +[17]:http://www.linux.com/news/featured-blogs/203-konstantin-ryabitsev/784544-linux-kernel-git-repositories-add-2-factor-authentication +[18]:http://www.top500.org/statistics/details/osfam/1 +[19]:http://ssd.jpl.nasa.gov/sbdb.cgi?sstr=9793 +[20]:http://ssd.jpl.nasa.gov/sbdb.cgi?sstr=9882 +[21]:http://ssd.jpl.nasa.gov/sbdb.cgi?sstr=9885 +[22]:http://ssd.jpl.nasa.gov/sbdb.cgi?sstr=9965 +[23]:https://lkml.org/lkml/2011/5/29/204 +[24]:http://www.wired.com/2012/03/mr-linux/2/ +[25]:http://lxr.free-electrons.com/source/kernel/reboot.c#L199 +[26]:http://www.nndb.com/people/444/000022378/ +[27]:http://linuxfonts.narod.ru/why.linux.is.not.ready.for.the.desktop.current.html +[28]:https://www.youtube.com/watch?v=8myENKt8bD0 diff --git a/translated/talk/20140910 Drab Desktop Try These 4 Beautiful Linux Icon Themes.md b/translated/talk/20140910 Drab Desktop Try These 4 Beautiful Linux Icon Themes.md new file mode 100644 index 0000000000..39b62717bc --- /dev/null +++ b/translated/talk/20140910 Drab Desktop Try These 4 Beautiful Linux Icon Themes.md @@ -0,0 +1,89 @@ +桌面看腻了?试试这 4 款漂亮的 Linux 图标主题吧 +================================================================================ +**Ubuntu 的默认图标主题在 5 年内[并未发生太大的变化][1],那些说“[图标早就彻底更新过了][2]”的你过来,我保证不打你。如果你确实想尝试一些新鲜的东西,我们将向你展示一些惊艳的替代品,它们会让你感到眼前一亮。** + +如果还是感到不太满意,你可以在文末的评论里留下你比较中意的图标主题的链接地址。 + +### Captiva ### + +![Captiva 图标 + elementary 文件夹图标 + Moka GTK](http://www.omgubuntu.co.uk/wp-content/uploads/2014/09/moka-and-captiva.jpg) + +Captiva 图标 + elementary 文件夹图标 + Moka GTK + +Captiva 是一款相对较新的图标主题,即使那些有华丽图标倾向的用户也会接受它。 + +Captiva 由 DeviantArt 的用户 ~[bokehlicia][3] 制作,它并未使用现在非常流行的平面扁平风格,而是采用了一种圆润、柔和的外观。图标本身呈现出一种很有质感的材质外观,同时通过微调的阴影和亮丽的颜色提高了自身的格调。 + +不过 Captiva 图标主题并未包含文件夹图标在内,因此它将使用 elementary(如果可以的话)或者普通的 Ubuntu 文件夹图标。 + +要想在 Ubuntu 14.04 中安装 Captiva 图标,你可以新开一个终端,按如下方式添加官方 PPA 并进行安装: + + sudo add-apt-repository ppa:captiva/ppa + + sudo apt-get update && sudo apt-get install captiva-icon-theme + +或者,如果你不擅长通过软件源安装的话,你也可以直接从 DeviantArt 的主页上下载图标压缩包。把解压过的文件夹挪到家目录的‘.icons’目录下,即可完成安装。 + +不过在你完成安装后,你必须得通过像 [Unity Tweak Tool][4] 这样的工具来把你安装的图标主题(本文列出的其他图标主题也要这样)应用到系统上。 + +- [DeviantArt 上的 Captiva 图标主题][5] + +### Square Beam ### + +![Square Beam 图标在 Orchis GTK 主题下](http://www.omgubuntu.co.uk/wp-content/uploads/2014/09/squarebeam.jpg) + +Square Beam 图标在 Orchis GTK 主题下 + +厌倦有棱角的图标了?尝试下 Square Beam 吧。Square Beam 因为其艳丽的色泽、尖锐的坡度变化和鲜明的图标形象,比本文列出的其他图标具有更加宏大的视觉效果。Square Beam 声称自己有超过 30,000 个(抱歉,我没有仔细数过...)的不同图标(!),因此你很难找到它没有考虑到的地方。 + +- [GNOME-Look.org 上的 Square Beam 图标主题][6] + +### Moka & Faba ### + +![Moka/Faba Mono 图标在 Orchis GTK 主题下](http://www.omgubuntu.co.uk/wp-content/uploads/2014/09/moka-faba.jpg) + +Moka/Faba Mono 图标在 Orchis GTK 主题下 + +这里得稍微介绍下 Moka 图标集。事实上,我敢打赌阅读此文的绝大部分用户正在使用这款图标。 + +柔和的颜色、平滑的边缘以及简洁的图标艺术设计,Moka 是一款真正出色的覆盖全面的应用图标。它的兄弟 Faba 将这些特点展现得淋漓尽致,而 Moka 也将延续这些 —— 涵盖所有的系统图标、文件夹图标、面板图标,等等。 + +欲知 Ubuntu 上的安装详情、访问项目官方网站?请点击下面的链接。 + +- [下载 Moka & Faba 图标主题][7] + +### Compass ### + +![Compass 图标在 Numix Blue GTK 主题下](http://www.omgubuntu.co.uk/wp-content/uploads/2014/09/compass1.jpg) + +Compass 图标在 Numix Blue GTK 主题下 + +在本文最后推荐的是 Compass,最后推荐当然不是最差的意思。这款图标现在仍然保持着‘2D,双色’的 UI 设计风格。它也许是不像本文推荐的其他图标那样鲜明,但这正是它的特色。Compass 秉持这点并与之不断的完善 —— 看看文件夹的图标就知道了! + +可以通过 GNOME-Look(下面有链接)进行下载和安装,或者通过添加 Nitrux Artwork 的 PPA 安装: + + sudo add-apt-repository ppa:nitrux/nitrux-artwork + + sudo apt-get update && sudo apt-get install compass-icon-theme + +- [GNOME-Look.org 上的 Compass 图标主题][8] + +-------------------------------------------------------------------------------- + +via: http://www.omgubuntu.co.uk/2014/09/4-gorgeous-linux-icon-themes-download + +作者:[Joey-Elijah Sneddon][a] +译者:[SteveArcher](https://github.com/SteveArcher) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:https://plus.google.com/117485690627814051450/?rel=author +[1]:http://www.omgubuntu.co.uk/2010/02/lucid-gets-new-icons-for-rhythmbox-ubuntuone-memenu-more +[2]:http://www.omgubuntu.co.uk/2012/08/new-icon-theme-lands-in-lubuntu-12-10 +[3]:http://bokehlicia.deviantart.com/ +[4]:http://www.omgubuntu.co.uk/2014/06/unity-tweak-tool-0-7-development-download +[5]:http://bokehlicia.deviantart.com/art/Captiva-Icon-Theme-479302805 +[6]:http://gnome-look.org/content/show.php/Square-Beam?content=165094 +[7]:http://mokaproject.com/moka-icon-theme/download/ubuntu/ +[8]:http://gnome-look.org/content/show.php/Compass?content=160629 \ No newline at end of file diff --git a/translated/talk/20140912 What' s wrong with IPv4 and Why we are moving to IPv6.md b/translated/talk/20140912 What' s wrong with IPv4 and Why we are moving to IPv6.md new file mode 100644 index 0000000000..902765e77a --- /dev/null +++ b/translated/talk/20140912 What' s wrong with IPv4 and Why we are moving to IPv6.md @@ -0,0 +1,88 @@ +IPv6:IPv4犯的罪,为什么要我来弥补 +================================================================================ +(LCTT:标题党了一把,哈哈哈好过瘾,求不拍砖) + +在过去的十年间,IPv6 本来应该得到很大的发展,但事实上这种好事并没有降临。由此导致了一个结果,那就是大部分人都不了解 IPv6 的一些知识:它是什么,怎么使用,以及,为什么它会存在?(LCTT:这是要回答蒙田的“我是谁”哲学思考题吗?) + +![IPv4 and IPv6 Comparison](http://www.tecmint.com/wp-content/uploads/2014/09/ipv4-ipv6.gif) + +IPv4 和 IPv6 的区别 + +### IPv4 做错了什么? ### + +自从1981年发布了 RFC 791 标准以来我们就一直在使用 **IPv4**。在那个时候,电脑又大又贵还不多见,而 IPv4 号称能提供**40亿条 IP 地址**,在当时看来,这个数字好大好大。不幸的是,这么多的 IP 地址并没有被充分利用起来,地址与地址之间存在间隙。举个例子,一家公司可能有**254(2^8-2)**条地址,但只使用其中的25条,剩下的229条被空占着,以备将来之需。于是这些空闲着的地址不能服务于真正需要它们的用户,原因就是网络路由规则的限制。最终的结果是在1981年看起来那个好大好大的数字,在2014年看起来变得好小好小。 + +互联网工程任务组(**IETF**)在90年代指出了这个问题,并提供了两套解决方案:无类型域间选路(**CIDR**)以及私有地址。在 CIDR 出现之前,你只能选择三种网络地址长度:**24 位** (共可用16,777,214个地址), **20位** (共可用1,048,574个地址)以及**16位** (共可用65,534个地址)。CIDR 出现之后,你可以将一个网络再划分成多个子网。 + +举个例子,如果你需要**5个 IP 地址**,你的 ISP 会为你提供一个子网,里面的主机地址长度为3位,也就是说你最多能得到**6个地址**(LCTT:抛开子网的网络号,3位主机地址长度可以表示0~7共8个地址,但第0个和第7个有特殊用途,不能被用户使用,所以你最多能得到6个地址)。这种方法让 ISP 能尽最大效率分配 IP 地址。“私有地址”这套解决方案的效果是,你可以自己创建一个网络,里面的主机可以访问外网的主机,但外网的主机很难访问到你创建的那个网络上的主机,因为你的网络是私有的、别人不可见的。你可以创建一个非常大的网络,因为你可以使用16,777,214个主机地址,并且你可以将这个网络分割成更小的子网,方便自己管理。 + +也许你现在正在使用私有地址。看看你自己的 IP 地址,如果这个地址在这些范围内:**10.0.0.0 – 10.255.255.255**、**172.16.0.0 – 172.31.255.255**或**192.168.0.0 – 192.168.255.255**,就说明你在使用私有地址。这两套方案有效地将“IP 地址用尽”这个灾难延迟了好长时间,但这毕竟只是权宜之计,现在我们正面临最终的审判。 + +**IPv4** 还有另外一个问题,那就是这个协议的消息头长度可变。如果数据通过软件来路由,这个问题还好说。但现在路由器功能都是由硬件提供的,处理变长消息头对硬件来说是一件困难的事情。一个大的路由器需要处理来自世界各地的大量数据包,这个时候路由器的负载是非常大的。所以很明显,我们需要固定消息头的长度。 + +还有一个问题,在分配 IP 地址的时候,美国人发了因特网(LCTT:这个万恶的资本主义国家占用了大量 IP 地址)。其他国家只得到了 IP 地址的碎片。我们需要重新定制一个架构,让连续的 IP 地址能在地理位置上集中分布,这样一来路由表可以做的更小(LCTT:想想吧,网速肯定更快)。 + +还有一个问题,这个问题你听起来可能还不大相信,就是 IPv4 配置起来比较困难,而且还不好改变。你可能不会碰到这个问题,因为你的路由器为你做了这些事情,不用你去操心。但是你的 ISP 对此一直是很头疼的。 + +下一代因特网需要考虑上述的所有问题。 + +### IPv6 和它的优点 ### + +**IETF** 在1995年12月公布了下一代 IP 地址标准,名字叫 IPv6,为什么不是 IPv5?因为某个错误原因,“版本5”这个编号被其他项目用去了。IPv6 的优点如下: + +- 128位地址长度(共有3.402823669×10³⁸个地址) +- 这个架构下的地址在逻辑上聚合 +- 消息头长度固定 +- 支持自动配置和修改你的网络。 + +我们一项一项地分析这些特点: + +#### 地址 #### + +人们谈到 **IPv6** 时,第一件注意到的事情就是它的地址好多好多。为什么要这么多?因为设计者考虑到地址不能被充分利用起来,我们必须提供足够多的地址,让用户去挥霍,从而达到一些特殊目的。所以如果你想架设自己的 IPv6 网络,你的 ISP 可以给你分配拥有**64位**主机地址长度的网络(可以分配1.844674407×10¹⁹台主机),你想怎么玩就怎么玩。 + +#### 聚合 #### + +有这么多的地址,这个地址可以被稀稀拉拉地分配给主机,从而更高效地路由数据包。算一笔帐啊,你的 ISP 拿到一个**80位**地址长度的网络空间,其中16位是 ISP 的子网地址,剩下64位分给你作为主机地址。这样一来,你的 ISP 可以分配65,534个子网。 + +然而,这些地址分配不是一成不变地,如果 ISP 想拥有更多的小子网,完全可以做到(当然,土豪 ISP 可能会要求再来一个80位网络空间)。最高的48位地址是相互独立地,也就是说 ISP 与 ISP 之间虽然可能分到相同地80位网络空间,但是这两个空间是相互隔离的,好处就是一个网络空间里面的地址会聚合在一起。 + +#### 固定的消息头长度 #### + +**IPv4** 消息头长度可变,但 **IPv6** 消息头长度被固定为40字节。IPv4 会由于额外的参数导致消息头变长,IPv6 中,如果有额外参数,这些信息会被放到一个紧挨着消息头的地方,不会被路由器处理,当消息到达目的地时,这些额外参数会被软件提取出来。 + +IPv6 消息头有一个部分叫“flow”,是一个20位伪随机数,用于简化路由器对数据包地路由过程。如果一个数据包存在“flow”,路由器就可以根据这个值作为索引查找路由表,不必慢吞吞地遍历整张路由表来查询路由路径。这个优点使 **IPv6** 更容易被路由。 + +#### 自动配置 #### + +**IPv6** 中,当主机开机时,会检查本地网络,看看有没有其他主机使用了自己的 IP 地址。如果地址没有被使用,就接着查询本地的 IPv6 路由器,找到后就向它请求一个 IPv6 地址。然后这台主机就可以连上互联网了 —— 它有自己的 IP 地址,和自己的默认路由器。 + +如果这台默认路由器当机,主机就会接着找其他路由器,作为备用路由器。这个功能在 IPv4 协议里实现起来非常困难。同样地,假如路由器想改变自己的地址,自己改掉就好了。主机会自动搜索路由器,并自动更新路由器地址。路由器会同时保存新老地址,直到所有主机都把自己地路由器地址更新成新地址。 + +IPv6 自动配置还不是一个完整地解决方案。想要有效地使用互联网,一台主机还需要另外的东西:域名服务器、时间同步服务器、或者还需要一台文件服务器。于是 **dhcp6** 出现了,提供与 dhcp 一样的服务,唯一的区别是 dhcp6 的机器可以在可路由的状态下启动,一个 dhcp 进程可以为大量网络提供服务。 + +#### 唯一的大问题 #### + +如果 IPv6 真的比 IPv4 好那么多,为什么它还没有被广泛使用起来(Google 在**2014年5月份**估计 IPv6 的市场占有率为**4%**)?一个最基本的原因是“先有鸡还是先有蛋”问题,用户需要让自己的服务器能为尽可能多的客户提供服务,这就意味着他们必须部署一个 **IPv4** 地址。 + +当然,他们可以同时使用 IPv4 和 IPv6 两套地址,但很少有客户会用到 IPv6,并且你还需要对你的软件做一些小修改来适应 IPv6。另外比较头疼的一点是,很多家庭的路由器压根不支持 IPv6。还有就是 ISP 也不愿意支持 IPv6,我问过我的 ISP 这个问题,得到的回答是:只有客户明确指出要部署这个时,他们才会用 IPv6。然后我问了现在有多少人有这个需求,答案是:包括我在内,共有1个。 + +与这种现实状况呈明显对比的是,所有主流操作系统:Windows、OS X、Linux 都默认支持 IPv6 好多年了。这些操作系统甚至提供软件让 IPv6 的数据包披上 IPv4 的皮来骗过那些会丢弃 IPv6 数据包的主机,从而达到传输数据的目的(LCTT:呃,这是高科技偷渡?)。 + +#### 总结 #### + +IPv4 已经为我们服务了好长时间。但是它的缺陷会在不远的将来遭遇不可克服的困难。IPv6 通过改变地址分配规则、简化数据包路由过程、简化首次加入网络时的配置过程等策略,可以完美解决这个问题。 + +问题是,大众在接受和使用 IPv6 的过程中进展缓慢,因为改变代价太大了。好消息是所有操作系统都支持 IPv6,所以当你有一天想做出改变,你的电脑只需要改变一点点东西,就能转到全新的架构体系中去。 + +-------------------------------------------------------------------------------- + +via: http://www.tecmint.com/ipv4-and-ipv6-comparison/ + +作者:[Jeff Silverman][a] +译者:[bazz2](https://github.com/bazz2) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://www.tecmint.com/author/jeffsilverm/ diff --git a/translated/talk/20140915 Make Downloading Files Effortless.md b/translated/talk/20140915 Make Downloading Files Effortless.md new file mode 100644 index 0000000000..eb7b27e8bc --- /dev/null +++ b/translated/talk/20140915 Make Downloading Files Effortless.md @@ -0,0 +1,189 @@ +让下载更方便 +================================================================================ +下载管理器是一个电脑程序,专门处理下载文件,优化带宽占用,以及让下载更有条理等任务。有些网页浏览器,例如Firefox,也集成了一个下载管理器作为功能,但是它们的方式还是没有专门的下载管理器(或者浏览器插件)那么专业,没有最佳地使用带宽,也没有好用的文件管理功能。 + +对于那些经常下载的人,使用一个好的下载管理器会更有帮助。它能够最大化下载速度(加速下载),断点续传以及制定下载计划,让下载更安全也更有价值。下载管理器已经没有之前流行了,但是最好的下载管理器还是很实用,包括和浏览器的紧密结合,支持类似YouTube的主流网站,以及更多。 + +有好几个能在Linux下工作都非常优秀的开源下载管理器,以至于让人无从选择。我整理了一个摘要,是我喜欢的下载管理器,以及Firefox里的一个非常好用的下载插件。这里列出的每一个程序都是开源许可发布的。 + +---------- + +![](http://www.linuxlinks.com/portal/content2/png/uGet.png) + +![](http://www.linuxlinks.com/portal/content/reviews/Utilities/Screenshot-uGet.png) + +uGet是一个轻量级,容易使用,功能完备的开源下载管理器。uGet允许用户从不同的源并行下载来加快速度,添加文件到下载序列,暂停或继续下载,提供高级分类管理,和浏览器集成,监控剪贴板,批量下载,支持26种语言,以及其他许多功能。 + +uGet是一个成熟的软件;保持开发超过11年。在这个时间里,它发展成一个非常多功能的下载管理器,拥有一套很高价值的功能集,还保持了易用性。 + +uGet是用C语言开发的,使用了cURL作为底层支持,以及应用库libcurl。uGet有非常好的平台兼容性。它一开始是Linux系统下的项目,但是被移植到在Mac OS X,FreeBSD,Android和Windows平台运行。 + +#### 功能点: #### + +- 容易使用 +- 下载队列可以让下载任务按任意多或少或你希望的数量同时进行。 +- 断点续传 +- 默认分类 +- 完美实现的剪贴板监控功能 +- 批量下载 +- 支持从HTML文件导入下载任务 +- 支持通过HTTP,HTTPS,FTP,BitTorrent和Metalink下载 +- 多线程下载(也被称为分块下载):每个下载任务支持最多20个线程同时连接,支持自适应的分块管理,意味着如果某个下载块中断了,那么会其他连接会把它捡起来,以时刻保证最佳的下载速度。 +- 多镜像下载 +- FTP登录和匿名FTP +- 强大的计划任务 +- 通过FlashGot和FireFox集成 +- Aria2插件 +- 多变的主题 +- 安静模式 +- 键盘快捷键 +- 支持命令行/终端控制 +- 自动创建目录 +- 下载历史管理 +- 支持GnuTLS +- 支持26种语言,包括:阿拉伯语,白俄罗斯语,简体中文,繁体中文,捷克语,丹麦语,英语(默认),法语,格鲁吉亚语,德语,匈牙利语,印尼语,意大利语,波兰语,葡萄牙语(巴西),俄语,西班牙语,土耳其语,乌克兰语,以及越南语。 + + +- 网站:[ugetdm.com][1] +- 开发人员:C.H. Huang and contributors +- 许可:GNU LGPL 2.1 +- 版本:1.10.5 + +---------- + +![](http://www.linuxlinks.com/portal/content2/png/DownThemAll%21.png) + +![](http://www.linuxlinks.com/portal/content/reviews/Utilities/Screenshot-DownThemAll%21.png) + +DownThemAll!是一个小巧的,可靠的以及易用的,开源下载管理器/加速器,是Firefox的一个组件。它可以让用户下载一个页面上所有链接和图片以及更多功能。它可以让用户完全控制下载任务,随时分配下载速度以及同时下载的任务数量。通过使用Metalinks或者手动添加镜像的方式,可以同时从不同的服务器下载同一个文件。 + +DownThemAll会根据你要下载的文件大小,切割成不同的部分,然后并行下载。 + +#### 功能点: #### + +- 和Firefox的完全集成 +- 分块下载,允许用户下载不同的文件块,完成之后再拼接成完整的文件;这样的话当连接到一个缓慢的服务器的时候可以加快下载速度。 +- 支持Metalink,允许发送下载文件的多个URL以及它的校验值和其他信息到DTA +- 支持爬虫方式通过一个单独的链接遍历整个网页 +- 下载过滤 +- 高级重命名选项 +- 暂停和继续下载任务 + + +- 网站:[addons.mozilla.org/en-US/firefox/addon/downthemall][2] +- 开发人员:Federico Parodi, Stefano Verna, Nils Maier +- 许可:GNU GPL v2 +- 版本:2.0.17 + +---------- + +![](http://www.linuxlinks.com/portal/content2/png/JDownloader.png) + +![](http://www.linuxlinks.com/portal/content/reviews/Utilities/Screenshot-JDownloader.png) + +JDownloader是一个免费,开源的下载管理工具,拥有一个大型社区的开发者支持,让下载更简单和快捷。用户可以开始,停止或暂停下载,设置带宽限制,自动解压缩包,以及更多功能。它提供了一个容易扩展的框架。 + +JDownloader简化了从一键下载网站下载文件。它还支持从不同并行资源下载,手势识别,自动文件解压缩以及更多功能。另外,还支持许多“加密链接”网站-所以你只需要复制粘贴“加密的”链接,然后JDownloader会处理剩下的事情。JDownloader还能导入CCF,RSDF和DLC文件。 + +#### 功能点: #### + +- 一次下载多个文件 +- 从多个连接同时下载 +- JD有一个自己实现的强大的OCR模块 +- 自动解压(包括密码搜索)(RAR压缩包) +- 支持主题 +- 支持多国语言 +- 大约110个站点以及超过300个解密插件 +- 通过JDLiveHeaderScripts重连:(支持1400路由) +- 网页更新 +- 集成包管理器支持额外模块(例如,Webinterface,Shutdown) + + +- 网站:[jdownloader.org][3] +- 开发人员:AppWork UG +- 许可:GNU GPL v3 +- 版本:0.9.581 + +---------- + +![](http://www.linuxlinks.com/portal/content2/png/FreeRapidDownloader.png) + +![](http://www.linuxlinks.com/portal/content/reviews/Utilities/Screenshot-FreeRapidDownloader.png) + +FreeRapid Downloader是一个易用的开源下载程序,支持从Rapidshare,Youtube,Facebook,Picasa和其他文件分享网站下载。他的下载引擎基于一些插件,所以可以从特殊站点下载。 + +对于需要针对特定文件分享网站的下载管理器用户来说,FreeRapid Downloader是理想的选择。 + +FreeRapid Downloader使用Java语言编写。需要至少Sun Java 7.0版本才可以运行。 + +#### 功能点: #### + +- 容易使用 +- 支持从不同服务站点并行下载 +- 支持断点续传 +- 支持通过代理列表下载 +- 支持流视频或图片 +- 下载历史 +- 聪明的剪贴板监控 +- 自动检查服务器文件后缀 +- 自动关机选项 +- 插件自动更新 +- 简单验证码识别 +- 支持跨平台 +- 支持多国语言:英语,保加利亚语,捷克语,芬兰语,葡萄牙语,斯洛伐克语,匈牙利语,简体中文,以及其他 +- 支持超过700个站点 + + +- 网站:[wordrider.net/freerapid/][4] +- 开发人员:Vity and contributors +- 许可:GNU GPL v2 +- 版本:0.9u4 + +---------- + +![](http://www.linuxlinks.com/portal/content2/png/FlashGot.png) + +![](http://www.linuxlinks.com/portal/content/reviews/Utilities/Screenshot-FlashGot.png) + +FlashGot是一个Firefox和Thunderbird的免费组件,旨在通过外置下载管理器来处理单个和大规模(“所有”和“已选”)下载。 + +FlashGot把所支持的所有下载管理器统一成Firefox中的一个下载管理器。 + +#### 功能点: #### + +- Linux下支持:Aria, Axel Download Accelerator, cURL, Downloader 4 X, FatRat, GNOME Gwget, FatRat, JDownloader, KDE KGet, pyLoad, SteadyFlow, uGet, wxDFast, 和wxDownload Fast +- 支持图库功能,可以帮助把原来分散在不同页面的系列资源,整合到一个所有媒体库页面中,然后可以轻松迅速地“下载所有” +- FlashGot Link会使用默认下载管理器下载当前鼠标选中的链接 +- FlashGot Selection +- FlashGot All +- FlashGot Tabs +- FlashGot Media +- 抓取页面里所有链接 +- 抓取所有标签栏的所有链接 +- 链接过滤(例如,只下载指定类型文件) +- 在网页上抓取点击所产生的所有链接 +- 支持从大多数链接保护和文件托管服务器直接和批量下载 +- 隐私选项 +- 支持国际化 + + +- 网站:[flashgot.net][5] +- 开发人员:Giorgio Maone +- 许可:GNU GPL v2 +- 版本:1.5.6.5 + +-------------------------------------------------------------------------------- + +via: http://www.linuxlinks.com/article/20140913062041384/DownloadManagers.html + +作者:Frazer Kline +译者:[zpl1025](https://github.com/zpl1025) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[1]:http://ugetdm.com/ +[2]:https://addons.mozilla.org/en-US/firefox/addon/downthemall/ +[3]:http://jdownloader.org/ +[4]:http://wordrider.net/freerapid/ +[5]:http://flashgot.net/ diff --git a/translated/talk/20140924 7 killer open source monitoring tools.md b/translated/talk/20140924 7 killer open source monitoring tools.md new file mode 100644 index 0000000000..125ddf62e8 --- /dev/null +++ b/translated/talk/20140924 7 killer open source monitoring tools.md @@ -0,0 +1,65 @@ +7个杀手级的开源监测工具 +================================================================================ +想要更清晰的了解你的网络吗?没有比这几个免费的工具更好用的了。 + +网络和系统监控是一个很宽的范畴。有监控服务器正常工作,网络设备,应用的方案。也有跟踪这些系统和设备性能,提供趋势性能分析的解决方案。有些工具像个闹钟一样,当发现问题的时候就会报警,而另外的一些工具甚至可以在警报响起的时候触发一些动作。这里,收集了一些开源的工具,旨在解决上述的一些甚至大部分问题。 + +### Cacti ### + +![](http://images.techhive.com/images/idge/imported/imageapi/2014/09/22/12/slide_02-netmon-cacti-100448914-orig.jpg) + +Cacti是一个性能广泛的图表和趋势分析工具,可以用来跟踪,并且几乎可以绘制出任何可监测指标,并描绘出图表。从硬盘的利用率到风扇的转速,在一个电脑管理系统中,只要是可以被监测的指标,Cacti都可以监测,并快速的转换成可视化的图表。 + +### Nagios ### + +![](http://images.techhive.com/images/idge/imported/imageapi/2014/09/22/12/slide_03-netmon-nagios-100448915-orig.jpg) + +Nagios是一个经典的老牌系统和网络监测工具。运行速度快,可靠,需要针对应用定制。Nagios对于初学者是一个挑战。但是它的极其复杂的配置正好也反应出它的强大,因为它几乎可以适用于任何监控任务。要说缺点的话就是不怎么耐看,但是其强劲的动力和可靠性弥补了这个缺点。 + +### Icinga ### + +![](http://images.techhive.com/images/idge/imported/imageapi/2014/09/22/12/slide_04-netmon-icinga-100448916-orig.jpg) + +Icinga 是一个正在重建的Nagios的分支,它提供了一个全面的监控和警报的框架,致力于设计一个像Nagios一样的开放的和可扩展性的平台。但是和Nagios拥有不一样的Web界面。Icinga 1 是Nagios非常的相近,不过Icinga 2就重写了。两个版本都能很好的兼容,而且,Nagios用户可以很轻松的转到Icinga 1平台。 + +### NeDi ### + +![](http://images.techhive.com/images/idge/imported/imageapi/2014/09/22/12/slide_05-netmon-nedi-100448917-orig.jpg) + +NeDi可能不如其他的工具一样文明全世界,但它确是一个跟踪网络接入的一个强大的解决方案。它可以很流畅的运行网络基础设施和设备目录,保持对任何事件的跟踪。并且可以提供任意设备的当前位置,也包括历史位置。 + +NeDi可以被用于定位被偷的,或者是丢失掉的设备,只要设备出现在网络上。它甚至可以在地图上显示所有已发现的节点。并且很清晰的告诉人们网络是怎么互联的到物理设备端口的。 + +### Observium ### + +![](http://images.techhive.com/images/idge/imported/imageapi/2014/09/22/12/slide_06-netmon-observium-100448918-orig.jpg) + +Observium 综合系统网路在性能趋势监测上有很好的表现,它支持静态和动态发现来确认服务器和网络设备,利用多种监测方法,可以监测任何可用的指标。Web界面非常的整洁,易用。 + +就如我们看到的,Observium也可以在地图上显示任何被监测节点的实际位置。需要注意的是面板上关于活跃设备和警报的计数。 + +### Zabbix ### + +![](http://images.techhive.com/images/idge/imported/imageapi/2014/09/22/12/slide_07-netmon-zabbix-100448919-orig.jpg) + +Zabbix 利用广泛的矩阵工具监测服务器和网络。代理商的Zabbix针对大多数的操作系统,你可以被动的或者是使用外部检查,包括SNMP来监控主机和网络设备。你也会发现很多提醒和通知设施,和一个非常人性化的Web界面,适用于不同的面板,此外,Zabbix还拥有一些特殊的管理工具来监测Web应用和虚拟化的管理程序。 + +Zabbix 还可以提供详细的互联图,以便于我们了解某些对象是怎么连接的。这些图是可以定制的,并且,图也可以以被监测的服务器和主机的分组形式被创建。 + +### Ntop ### + +![](http://images.techhive.com/images/idge/imported/imageapi/2014/09/22/12/slide_08-netmon-ntop-100448920-orig.jpg) + +Ntop是一个数据包嗅探工具。有一个整洁的Web界面,用来显示被监测网络的实时数据。即时的网络数据通过一个高级的绘图工具可以可视化。主机信息流和主机通信信息对也可以被实时的进行可视化显示。 + +-------------------------------------------------------------------------------- + +via: http://www.networkworld.com/article/2686794/asset-management/164219-7-killer-open-source-monitoring-tools.html + +作者:[Paul Venezia][a] +译者:[barney-ro](https://github.com/barney-ro) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://www.networkworld.com/author/Paul-Venezia/ diff --git a/translated/talk/20140926 ChromeOS vs Linux--The Good, the Bad and the Ugly.md b/translated/talk/20140926 ChromeOS vs Linux--The Good, the Bad and the Ugly.md new file mode 100644 index 0000000000..2a193224b1 --- /dev/null +++ b/translated/talk/20140926 ChromeOS vs Linux--The Good, the Bad and the Ugly.md @@ -0,0 +1,82 @@ +ChromeOS 对战 Linux : 孰优孰劣,仁者见仁,智者见智 +================================================================================ +> 在 ChromeOS 和 Linux 的斗争过程中,不管是哪一家的操作系统都是有优有劣。 + +任何不关注Google 的人都不会相信Google在桌面用户当中扮演着一个很重要的角色。在近几年,我们见到的[ChromeOS][1]制造的[Google Chromebook][2]相当的轰动。和同期的人气火爆的Amazon 一样,似乎ChromeOS 势不可挡。 + +在本文中,我们要了解的是ChromeOS 的概念市场,ChromeOS 怎么影响着Linux 的份额,和整个 ChromeOS 对于linux 社区来说,是好事还是坏事。另外,我将会谈到一些重大的事情,和为什么没人去为他做点什么事情。 + +### ChromeOS 并非真正的Linux ### + +每当有朋友问我说是否ChromeOS 是否是Linux 的一个版本时,我都会这样回答:ChromeOS 对于Linux 就好像是 OS X 对于BSD 。换句话说,我认为,ChromeOS 是linux 的一个派生操作系统,运行于Linux 内核的引擎之下。而很多操作系统就组成了Google 的专利代码和软件。 + +尽管ChromeOS 是利用了Linux 内核引擎,但是它仍然有很大的不同和现在流行的Linux 分支版本。 + +尽管ChromeOS 的差异化越来越明显,是在于它给终端用户提供的app,包括Web 应用。因为ChromeOS 的每一个操作都是开始于浏览器窗口,这对于Linux 用户来说,可能会有很多不一样的感受,但是,对于没有Linux 经验的用户来说,这与他们使用的旧电脑并没有什么不同。 + +就是说,每一个以Google-centric 为生活方式的人来说,在ChromeOS上的感觉将会非常良好,就好像是回家一样。这样的优势就是这个人已经接受了Chrome 浏览器,Google 驱动器和Gmail 。久而久之,他们的亲朋好友使用ChromeOs 也就是很自然的事情了,就好像是他们很容易接受Chrome 浏览器,因为他们觉得早已经用过。 + +然而,对于Linux 爱好者来说,这样的约束就立即带来了不适应。因为软件的选择被限制,有范围的,在加上要想玩游戏和VoIP 是完全不可能的。那么对不起,因为[GooglePlus Hangouts][3]是代替不了VoIP 软件的。甚至在很长的一段时间里。 + +### ChromeOS 还是Linux 桌面 ### + +有人断言,ChromeOS 要是想在桌面系统的浪潮中对Linux 产生影响,只有在Linux 停下来浮出水面栖息的时候或者是满足某个非技术用户的时候。 + +是的,桌面Linux 对于大多数休闲型的用户来说绝对是一个好东西。然而,它必须有专人帮助你安装操作系统,并且提供“维修”服务,从windows 和 OS X 的阵营来看。但是,令人失望的是,在美国Linux 正好在这个方面很缺乏。所以,我们看到,ChromeOS 正慢慢的走入我们的视线。 + +我发现Linux 桌面系统最适合做网上技术支持来管理。比如说:家里的高级用户可以操作和处理更新政府和学校的IT 部门。Linux 还可以应用于这样的环境,Linux桌面系统可以被配置给任何技能水平和背景的人使用。 + +相比之下,ChromeOS 是建立在完全免维护的初衷之下的,因此,不需要第三者的帮忙,你只需要允许更新,然后让他静默完成即可。这在一定程度上可能是由于ChromeOS 是为某些特定的硬件结构设计的,这与苹果开发自己的PC 电脑也有异曲同工之妙。因为Google 的ChromeOS 附带一个硬件脉冲,它允许“犯错误”。对于某些人来说,这是一个很奇妙的地方。 + +滑稽的是,有些人却宣称,ChomeOs 的远期的市场存在很多问题。简言之,这只是一些Linux 激情的爱好者在找对于ChomeOS 的抱怨罢了。在我看来,停止造谣这些子虚乌有的事情才是关键。 + +问题是:ChromeOS 的市场份额和Linux 桌面系统在很长的一段时间内是不同的。这个存在可能会在将来被打破,然而在现在,仍然会是两军对峙的局面。 + +### ChromeOS 的使用率正在增长 ### + +不管你对ChromeOS 有怎么样的看法,事实是,ChromeOS 的使用率正在增长。专门针对ChromeOS 的电脑也一直有发布。最近,戴尔(Dell)也发布了一款针对ChromeOS 的电脑。命名为[Dell Chromebox][5],这款ChromeOS 设备将会是另一些传统设备的终结者。它没有软件光驱,没有反病毒软件,offers 能够无缝的在屏幕后面自动更新。对于一般的用户,Chromebox 和Chromebook 正逐渐成为那些工作在web 浏览器上的人的一个选择。 + +尽管增长速度很快,ChromeOS 设备仍然面临着一个很严峻的问题 - 存储。受限于有限的硬盘的大小和严重依赖于云存储,并且ChromeOS 不会为了任何使用它们电脑的人消减基本的web 浏览器的功能。 + +### ChromeOS 和Linux 的异同点 ### + +以前,我注意到ChromeOS 和Linux 桌面系统分别占有着两个完全不同的市场。出现这样的情况是源于,Linux 社区的致力于提升Linux 桌面系统的脱机性能。 + +是的,偶然的,有些人可能会第一时间发现这个“Linux 的问题”。但是,并没有一个人接着跟进这些问题,确保得到问题的答案,确保他们得到Linux 最多的帮助。 + +事实上,脱机故障可能是这样发现的: + +- 有些用户偶然的在Linux 本地事件发现了Linux 的问题。 +- 他们带回了DVD/USB 设备,并尝试安装这个操作系统。 +- 当然,有些人很幸运的成功的安装成功了这个进程,但是,据我所知大多数的人并没有那么幸运。 +- 令人失望的是,这些人希望在网上论坛里搜索帮助。很难做一个主计算机,没有网络和视频的问题。 +- 我真的是受够了,后来有很多失望的用户拿着他们的电脑到windows 商店来“维修”。除了重装一个windows 操作系统,他们很多时候都会听到一句话,“Linux 并不适合你们”,应该尽量避免。 + +有些人肯定会说,上面的举例肯定夸大其词了。让我来告诉你:这是发生在我身边真实的事的,而且是经常发生。醒醒吧,Linux 社区的人们,我们的这种模式已经过时了。 + +### 伟大的平台,强大的营销和结论 ### + +如果非要说ChromeOS 和Linux 桌面系统相同的地方,除了它们都使用了Linux 内核,就是它们都伟大的产品却拥有极其差劲的市场营销。而Google 的好处就是,他们投入大量的资金在网上构建大面积存储空间。 + +Google 相信他们拥有“网上的优势”,而线下的影响不是很重要。这真是一个让人难以置信的目光短浅,这也成了Google 历史上最大的一个失误之一。相信,如果你没有接触到他们在线的努力,你不值得困扰,仅仅就当是他们在是在选择网上存储空间上做出反击。 + +我的建议是:通过Google 的线下影响,提供Linux 桌面系统给ChromeOS 的市场。这就意味着Linux 社区的人需要筹集资金来出席县博览会、商场展览,在节日季节,和在社区中进行免费的教学课程。这会立即使Linux 桌面系统走入人们的视线,否则,最终将会是一个ChromeOS 设备出现在人们的面前。 + +如果说本地的线下市场并没有想我说的这样,别担心。Linux 桌面系统的市场仍然会像ChromeOS 一样增长。最坏也能保持现在这种两军对峙的市场局面。 + +-------------------------------------------------------------------------------- + +via: http://www.datamation.com/open-source/chromeos-vs-linux-the-good-the-bad-and-the-ugly-1.html + +作者:[Matt Hartley][a] +译者:[barney-ro](https://github.com/barney-ro) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://www.datamation.com/author/Matt-Hartley-3080.html +[1]:http://en.wikipedia.org/wiki/Chrome_OS +[2]:http://www.google.com/chrome/devices/features/ +[3]:https://plus.google.com/hangouts +[4]:http://en.wikipedia.org/wiki/Voice_over_IP +[5]:http://www.pcworld.com/article/2602845/dell-brings-googles-chrome-os-to-desktops.html diff --git a/translated/talk/The Open Source Witch Hunts Have Returned.md b/translated/talk/The Open Source Witch Hunts Have Returned.md deleted file mode 100644 index 9810a8e258..0000000000 --- a/translated/talk/The Open Source Witch Hunts Have Returned.md +++ /dev/null @@ -1,62 +0,0 @@ -开源女巫狩猎归来! -================================================================================ -![](http://readwrite.com/files/styles/1400_0/public/fields/shutterstock-open-gate.jpg) - -> 开源软件社区已经做出了改变,就像之前的美好时光。 - -开源软件已经变的温和了,之前我们有的那些不纯洁的想法,可是随后我们却奇怪的和别人分享自己的代码与创作。 - -幸运的是,这种务实主义要结束了。在过去的几周当中,我们团结在Mozilla身边支持DRM版权保护以及嘲笑Red Hat和OpenStack之间的竞争。社区那些年如数家珍的开源软件明星和[Open Core][1]产生了冲突而被反噬了. - -多么怀念啊。 - - -### 2003年的Red Hat ### - -Red Hat,开源软件理想主义的典范,在几周前拒绝支持它的竞争对手。Jodi Mardesich做了[非凡的工作][2]却受到了指控以及Red Hat的回击。但是真实情况是: - -Red Hat不想支持它的竞争对手OpenStack - -在另外一边这难道算是新闻吗? - - -### Mozilla变成了麻瓜 ### - -Red Hat作为开源软件理想主义的典范代表很容易成为各种带颜色攻击的目标,Mozilla其实是更大的一个目标。 - -Mozilla承诺为用户服务的罪过,它最近进行了一场自我牺牲似的行动违背CEO的策略同意加入DRM的技术,即纯Firefox浏览器源码可以使用户观看视频。 - -人们想看视频,Mozilla倾向于在它的浏览器中观看。 - -最新消息,这一次失败,开源软件组织[批评了][3] Mozilla,深切表达了自己对于Mozilla的失望,因为这种决定妥协的态度会导致浏览器份额的降低。 - -但是,Mozilla为什么要做这样的傻事呢,为了用户,你懂的。 - -说教部门不甘示弱,[电子前沿基金会感叹][4]到开放网络最后的抗争已经失败了。它对Mozilla失败的做法争论道:“接受DRM会改变这个行业”!DRM的倡导者一再妥协,一个公司又一个公司(PC行业)演变成一个行业,它通过锁定装置,监视器,接受每一个人的管理建立自己的利益关系。 - -[Mitchell Bake解释道][5],Mozilla可能并没有投降:“Firefox用户会需要使用另外的浏览器来观看他们自己想看的视频,这让人怀疑Firfox做一一个产品是否真的有用”。 - -Um, yes. - -### 回到我们的思想源头 ### - -However much we may want to force others to live by our absolutist ideals, the reality is that others may have different 我们或许很专制的意图其他的东西活着,事实上他们却有着不同的优先度。免费的软件让步给开源软件,更加严格,更加固定“正确的方式”去获得授权。 - -这种意识在目前还是有用的,但它并不总是方便和愉悦。我崇尚开源软件的实用主义,Apache软件基金会,这样有很大的好处提醒GPL组织在意识形态上的危机感。软件自由真的很重要。 - -这么多悲观的言论,我自己也感到了恐惧,希望回到一个不断会自我鞭策的免费的开软软件的组织。这使开源软件协作变少而且更难驾驭,但是会变得更有力而且关乎未来。 - - --------------------------------------------------------------------------------- - -via: http://readwrite.com/2014/05/21/open-source-witch-hunt-mozilla-openstack-redhat#feed=/hack&awesm=~oEYDhxfP0Qv5hE - -译者:[jiajia9linuxer](https://github.com/jiajia9linuxer) 校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[1]:http://en.m.wikipedia.org/wiki/Open_core -[2]:http://readwrite.com/2014/05/16/red-hat-openstack-mirantis-rhel-support -[3]:http://www.fsf.org/news/fsf-condemns-partnership-between-mozilla-and-adobe-to-support-digital-restrictions-management -[4]:https://www.eff.org/deeplinks/2014/05/mozilla-and-drm -[5]:https://blog.mozilla.org/blog/2014/05/14/drm-and-the-challenge-of-serving-users/ diff --git a/translated/talk/The history of Android/07 - The history of Android.md b/translated/talk/The history of Android/07 - The history of Android.md new file mode 100644 index 0000000000..583e847d6e --- /dev/null +++ b/translated/talk/The history of Android/07 - The history of Android.md @@ -0,0 +1,109 @@ +安卓编年史 +================================================================================ +![电子邮件应用的所有界面。前两张截图展示了标签/收件箱结合的视图,最后一张截图展示了一封邮件。](http://cdn.arstechnica.net/wp-content/uploads/2014/01/email2lol.png) +电子邮件应用的所有界面。前两张截图展示了标签/收件箱结合的视图,最后一张截图展示了一封邮件。 +Ron Amadeo供图 + +邮件视图是——令人惊讶的!——白色。安卓的电子邮件应用从历史角度来说算是个打了折扣的Gmail应用,你可以在这里看到紧密的联系。读邮件以及写邮件视图几乎没有任何修改地就从Gmail那里直接取过来使用。 + +![即时通讯应用。截图展示了服务提供商选择界面,朋友列表,以及一个对话。](http://cdn.arstechnica.net/wp-content/uploads/2013/12/IM2.png) +即时通讯应用。截图展示了服务提供商选择界面,朋友列表,以及一个对话。 +Ron Amadeo供图 + +在Google Hangouts之前,甚至是Google Talk之前,就有“IM”——安卓1.0带来的唯一一个即时通讯客户端。令人惊奇的是,它支持多种IM服务:用户可以从AIM,Google Talk,Windows Live Messenger以及Yahoo中挑选。还记得操作系统开发者什么时候关心过互通性吗? + +朋友列表是聊天中带有白色聊天气泡的黑色背景界面。状态用一个带颜色的圆形来指示,右侧的小安卓机器人指示出某人正在使用移动设备。IM应用相比Google Hangouts远比它有沟通性,这真是十分神奇的。绿色代表着某人正在使用设备并且已经登录,黄色代表着他们登录了但处于空闲状态,红色代表他们手动设置状态为忙,不想被打扰,灰色表示离线。现在Hangouts只显示用户是否打开了应用。 + +聊天对话界面明显基于信息应用,聊天的背景从白色和蓝色被换成了白色和绿色。但是没人更改信息输入框的颜色,所以加上橙色的高亮效果,界面共使用了白色,绿色,蓝色和橙色。 + +![安卓1.0上的YouTube。截图展示了主界面,打开菜单的主界面,分类界面,视频播放界面。](http://cdn.arstechnica.net/wp-content/uploads/2013/12/yt5000.png) +安卓1.0上的YouTube。截图展示了主界面,打开菜单的主界面,分类界面,视频播放界面。 +Ron Amadeo供图 + +YouTube仅仅以G1的320p屏幕和3G网络速度可能不会有今天这样的移动意识,但谷歌的视频服务在安卓1.0上就被置入发布了。主界面看起来就像是安卓市场调整过的版本,顶部带有一个横向滚动选择部分,下面有垂直滚动分类列表。谷歌的一些分类选择还真是奇怪:“最热门”和“最多观看”有什么区别? + +一个谷歌没有意识到YouTube最终能达到多庞大的标志——有一个视频分类是“最近更新”。在今天,每分钟有[100小时时长的视频][1]上传到Youtube上,如果这个分类能正常工作的话,它会是一个快速滚动的视频列表,快到以至于变为一片无法阅读的模糊。 + +菜单含有搜索,喜爱,分类,设置。设置(没有图片)是有史以来最简陋的,只有个清除搜索历史的选项。分类都是一样的平淡,仅仅是个黑色的文本列表。 + +最后一张截图展示了视频播放界面,只支持横屏模式。尽管自动隐藏的播放控制有个进度条,但它还是很奇怪地包含了后退和前进按钮。 + +![YouTube的视频菜单,描述页面,评论。](http://cdn.arstechnica.net/wp-content/uploads/2013/12/yt3.png) +YouTube的视频菜单,描述页面,评论。 +Ron Amadeo供图 + +每个视频的更多选项可以通过点击菜单按钮来打开。在这里你可以把视频标记为喜爱,查看详细信息,以及阅读评论。所有的这些界面,和视频播放一样,是锁定横屏模式的。 + +然而“共享”不会打开一个对话框,它只是向Gmail邮件中加入了视频的链接。想要把链接通过短信或即时消息发送给别人是不可能的。你可以阅读评论,但是没办法评价他们或发表自己的评论。你同样无法给视频评分或赞。 + +![相机应用的拍照界面,菜单,照片浏览模式。](http://cdn.arstechnica.net/wp-content/uploads/2013/12/camera.png) +相机应用的拍照界面,菜单,照片浏览模式。 +Ron Amadeo供图 + +在实体机上跑上真正的安卓意味着相机功能可以正常运作,即便那里没什么太多可关注的。左边的黑色方块是相机的界面,原本应该显示取景器图像,但SDK的截图工具没办法捕捉下来。G1有个硬件实体的拍照键(还记得吗?),所以相机没必要有个屏幕上的快门键。相机没有曝光,白平衡,或HDR设置——你可以拍摄照片,仅此而已。 + +菜单按钮显示两个选项:跳转到相册应用和带有两个选项的设置界面。第一个设置选项是是否给照片加上地理标记,第二个是在每次拍摄后显示提示菜单,你可以在上面右边看到截图。同样的,你目前还只能拍照——还不支持视频拍摄。 + +![日历的月视图,打开菜单的周视图,日视图,以及日程。](http://cdn.arstechnica.net/wp-content/uploads/2013/12/calviews.png) +日历的月视图,打开菜单的周视图,日视图,以及日程。 +Ron Amadeo供图 + +就像这个时期的大多数应用一样,日历的主命令界面是菜单。菜单用来切换视图,添加新事件,导航至当天,选择要显示的日程,以及打开设置。菜单扮演着每个单独按钮的入口的作用。 + +月视图不能显示约会事件的文字。每个日期旁边有个侧边,约会会显示为侧边上的绿色部分,通过位置来表示约会是在一天中的什么时候。周视图同样不能显示预约文字——G1的320×480的显示屏像素还不够密——所以你会在日历中看到一个带有颜色指示条的白块。唯一一个显示文字的是日程和日视图。你可以用滑动来切换日期——左右滑动切换周和日,上下滑动切换月份和日程。 + +![设置主界面,无线设置,关于页面的底部。](http://cdn.arstechnica.net/wp-content/uploads/2013/12/settings.png) +设置主界面,无线设置,关于页面的底部。 +Ron Amadeo供图 + +安卓1.0最终带来了设置界面。这个界面是个带有文字的黑白界面,粗略地分为各个部分。每个列表项边的下箭头让人误以为点击它会展开折叠的更多东西,但是触摸列表项的任何位置只会加载下一屏幕。所有的界面看起来确实无趣,都差不多一样,但是嘿,这可是设置啊。 + +任何带有开/关状态的选项都使用了卡通风的复选框。安卓1.0最初的复选框真是奇怪——就算是在“未选中”状态时,它们还是有个灰色的勾选标记在里面。安卓把勾选标记当作了灯泡,打开时亮起来,关闭的时候变得黯淡,但这不是复选框的工作方式。然而我们最终还是见到了“关于”页面。安卓1.0运行Linux内核2.6.25版本。 + +设置界面意味着我们终于可以打开安全设置并更改锁屏。安卓1.0只有两种风格,安卓0.9那样的灰色方形锁屏,以及需要你在9个点组成的网格中画出图案的图形解锁。像这样的滑动图案相比PIN码更加容易记忆和输入,尽管它没有增加多少安全性。 + +![语音拨号,图形锁屏,电池低电量警告,时间设置。](http://cdn.arstechnica.net/wp-content/uploads/2013/12/grabbag.png) +语音拨号,图形锁屏,电池低电量警告,时间设置。 +Ron Amadeo供图 + +语音功能和语音拨号一同来到了1.0。这个特性以各种功能实现在AOSP徘徊了一段时间,然而它是一个简单的拨打号码和联系人的语音命令应用。语音拨号是个和谷歌未来的语音产品完全无关的应用,但是,它的工作方式和非智能机上的语音拨号一样。 + +关于最后一个值得注意的,当电池电量低于百分之十五的时候会触发低电量弹窗。这是个有趣的图案,它把电源线错误的一端插入手机。谷歌,那可不是(现在依然不是)手机应该有的充电方式。 + +安卓1.0是个伟大的开头,但是功能上仍然有许多缺失。实体键盘和大量硬件按钮被强制要求配备,因为不带有十字方向键或轨迹球的安卓设备依然不被允许销售。另外,基本的智能手机功能比如自动旋转依然缺失。内置应用不可能像今天这样通过安卓市场来更新。所有的谷歌系应用和系统交织在一起。如果谷歌想要升级一个单独的应用,需要通过运营商推送整个系统的更新。安卓依然还有许多工作要做。 + +### 安卓1.1——第一个真正的增量更新 ### + +![安卓1.1的所有新特性:语音搜索,安卓市场付费应用支持,谷歌纵横,设置中的新“系统更新”选项。](http://cdn.arstechnica.net/wp-content/uploads/2013/12/11.png) +安卓1.1的所有新特性:语音搜索,安卓市场付费应用支持,谷歌纵横,设置中的新“系统更新”选项。 +Ron Amadeo供图 + +安卓1.0发布四个半月后,2009年2月,安卓在安卓1.1中得到了它的第一个公开更新。系统方面没有太多变化,谷歌向1.1中添加新东西现如今也都已被关闭。谷歌语音搜索是安卓向云端语音搜索的第一个突击,它在应用抽屉里有自己的图标。尽管这个应用已经不能与谷歌服务器通讯,你可以[在iPhone上][2]看到它以前是怎么工作的。它还没有语音操作,但你可以说出想要搜索的,结果会显示在一个简单的谷歌搜索中。 + +安卓市场添加了对付费应用的支持,但是就像beta客户端中一样,这个版本的安卓市场不再能够连接Google Play服务器。我们最多能够看到分类界面,你可以在免费应用,付费应用和全部应用中选择。 + +地图添加了[谷歌纵横][3],一个向朋友分享自己位置的方法。纵横在几个月前为了支持Google+而被关闭并且不再能够工作。地图菜单里有个纵横的选项,但点击它现在只会打开一个带载入中圆圈的画面,并永远停留在这里。 + +安卓世界的系统更新来得更加迅速——或者至少是一条在运营商和OEM推送之前获得更新的途径——谷歌向“关于手机”界面添加了检查系统更新按钮。 + +---------- + +![Ron Amadeo](http://cdn.arstechnica.net/wp-content//uploads/authors/ron-amadeo-sq.jpg) + +[Ron Amadeo][a] / Ron是Ars Technica的评论编缉,专注于安卓系统和谷歌产品。他总是在追寻新鲜事物,还喜欢拆解事物看看它们到底是怎么运作的。 + +[@RonAmadeo][t] + +-------------------------------------------------------------------------------- + +via: http://arstechnica.com/gadgets/2014/06/building-android-a-40000-word-history-of-googles-mobile-os/7/ + +译者:[alim0x](https://github.com/alim0x) 校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[1]:http://www.youtube.com/yt/press/statistics.html +[2]:http://www.youtube.com/watch?v=y3z7Tw1K17A +[3]:http://arstechnica.com/information-technology/2009/02/google-tries-location-based-social-networking-with-latitude/ +[a]:http://arstechnica.com/author/ronamadeo +[t]:https://twitter.com/RonAmadeo diff --git a/translated/tech/20140711 How to use systemd for system administration on Debian.md b/translated/tech/20140711 How to use systemd for system administration on Debian.md new file mode 100644 index 0000000000..fce9af826f --- /dev/null +++ b/translated/tech/20140711 How to use systemd for system administration on Debian.md @@ -0,0 +1,106 @@ +在 Debian 上使用 systemd 管理系统 +================================================================================ +人类已经无法阻止 systemd 占领全世界的 Linux 系统了,唯一阻止它的方法是在你自己的机器上手动卸载它。到目前为止,systemd 已经创建了比任何软件都多的技术问题、感情问题和社会问题。这一点从[热议][1](也称 Linux 初始化软件之战)上就能看出,这场争论在 Debian 开发者之间持续了好几个月。当 Debian 技术委员会最终决定将 systemd 放到 Debian 8(代号 Jessie)的发行版里面时,其反对者试图通过多种努力来[取代这项决议][2],甚至有人扬言要威胁那些支持 systemd 的开发者的生命安全。 + +这也说明了 systemd 对 Unix 传承下来的系统处理方式有很大的干扰。“一个软件只做一件事情”的哲学思想已经被这个新来者彻底颠覆。除了取代了 sysvinit 成为新的系统初始化工具外,systemd 还是一个系统管理工具。目前为止,由于 systemd-sysv 这个软件包提供的兼容性,那些我们使用惯了的工具还能继续工作。但是当 Debian 将 systemd 升级到214版本后,这种兼容性就不复存在了。升级措施预计会在 Debian 8 "Jessie" 的稳定分支上进行。从此以后用户必须使用新的命令来管理系统、执行任务、变换运行级别、查询系统日志等等。不过这里有一个应对方案,那就是在 .bashrc 文件里面添加一些别名。 + +现在就让我们来看看 systemd 是怎么改变你管理系统的习惯的。在使用 systemd 之前,你得先把 sysvinit 保存起来,以防 systemd 出错的时候还能用 sysvinit 启动系统。这种方法只有在没安装 systemd-sysv 的情况下才能生效,具体操作方法如下: + + # cp -av /sbin/init /sbin/init.sysvinit + +在紧急情况下,可以把下面的文本: + + init=/sbin/init.sysvinit + +添加到内核启动参数项那里。 + +### systemctl 的基本用法 ### + +systemctl 的功能是替代“/etc/init.d/foo start/stop”这类命令,另外,其实它还能做其他的事情,这点你可以参考 man 文档。 + +一些基本用法: + +- systemctl - 列出所有单元(UNIT)以及它们的状态(这里的 UNIT 指的就是系统上的 job 和 service) +- systemctl list-units - 列出所有 UNIT +- systemctl start [NAME...] - 启动一项或多项 UNIT +- systemctl stop [NAME...] - 停止一项或多项 UNIT +- systemctl disable [NAME...] - 将 UNIT 设置为开机不启动 +- systemctl list-unit-files - 列出所有已安装的 UNIT,以及它们的状态 +- systemctl --failed - 列出开机启动失败的 UNIT +- systemctl --type=mount - 列出某种类型的 UNIT,类型包含:service, mount, device, socket, target +- systemctl enable debug-shell.service - 将一个 shell 脚本设置为开机启动,用于调试 + +为了更方便处理这些 UNIT,你可以使用 systemd-ui 软件包,你只要输入 systemadm 命令就可以使用这个软件。 + +你同样可以使用 systemctl 实现转换运行级别、重启系统和关闭系统的功能: + +- systemctl isolate graphical.target - 切换到运行级别5,就是有桌面的级别 +- systemctl isolate multi-user.target - 切换到运行级别3,没有桌面的级别 +- systemctl reboot - 重启系统 +- systemctl poweroff - 关机 + +所有命令,包括切换到其他运行级别的命令,都可以在普通用户的权限下执行。 + +### journalctl 的基本用法 ### + +systemd 不仅提供了比 sysvinit 更快的启动速度,还让日志系统在更早的时候启动起来,可以记录内核初始化阶段、内存初始化阶段、前期启动步骤以及主要的系统执行过程的日志。所以以前那种需要通过对显示屏拍照或者暂停系统来调试程序的日子已经一去不复返啦。 + +systemd 的日志文件都被放在 /var/log 目录。如果你想使用它的日志功能,需要执行一些命令,因为 Debian 没有打开日志功能。命令如下: + + # addgroup --system systemd-journal + # mkdir -p /var/log/journal + # chown root:systemd-journal /var/log/journal + # gpasswd -a $user systemd-journal + +通过上面的设置,你就可以以普通用户权限使用 journal 软件查看日志。使用 journalctl 查询日志可以获得一些比 syslog 软件更方便的玩法: + +- journalctl --all - 显示系统上所有日志,以及它的用户 +- journalctl -f - 监视系统日志的变化(类似 tail -f /var/log/messages 的效果) +- journalctl -b - 显示系统启动以后的日志 +- journalctl -k -b -1 - 显示上一次(-b -1)系统启动前产生的内核日志 +- journalctl -b -p err - 显示系统启动后产生的“ERROR”日志 +- journalctl --since=yesterday - 当系统不会经常重启的时候,这条命令能提供比 -b 更短的日志记录 +- journalctl -u cron.service --since='2014-07-06 07:00' --until='2014-07-06 08:23' - 显示 cron 服务在某个时间段内打印出来的日志 +- journalctl -p 2 --since=today - 显示优先级别为2以内的日志,包含 emerg、alert、crit三个级别。所有日志级别有: emerg (0), alert (1), crit (2), err (3), warning (4), notice (5), info (6), debug (7) +- journalctl > yourlog.log - 将二进制日志文件复制成文本文件并保存到当前目录 + +Journal 和 syslog 可以很好的共存。而另一方面,一旦你习惯了操作 journal,你也可以卸载掉所有 syslog 的软件,比如 rsyslog 或 syslog-ng。 + +如果想要得到更详细的日志信息,你可以在内核启动参数上添加“systemd.log_level=debug”,然后运行下面的命令: + + # journalctl -alb + +你也可以编辑 /etc/systemd/system.conf 文件来修改日志级别。 + +### 利用 systemd 分析系统启动过程 ### + +systemd 可以让你能更有效地分析和优化你的系统启动过程: + +- systemd-analyze - 显示本次启动系统过程中用户态和内核态所花的时间 +- systemd-analyze blame - 显示每个启动项所花费的时间明细 +- systemd-analyze critical-chain - 按时间顺序打印 UNIT 树 +- systemd-analyze dot | dot -Tsvg > systemd.svg - 为开机启动过程生成向量图(需要安装 graphviz 软件包) +- systemd-analyze plot > bootplot.svg - 产生开机启动过程的时间图表 + +![](https://farm6.staticflickr.com/5559/14607588994_38543638b3_z.jpg) + +![](https://farm6.staticflickr.com/5565/14423020978_14b21402c8_z.jpg) + +systemd 虽然是个年轻的项目,但存在大量文档。首先要介绍的是[Lennart Poettering 的 0pointer 系列][3]。这个系列非常详细,非常有技术含量。另外一个是[免费桌面信息文档][4],它包含了最详细的关于 systemd 的链接:发行版特性文件、bug 跟踪系统和说明文档。你可以使用下面的命令来查询 systemd 都提供了哪些文档: + + # man systemd.index + +不同发行版之间的 systemd 提供的命令基本一样,最大的不同之处就是打包方式。 + +-------------------------------------------------------------------------------- + +via: http://xmodulo.com/2014/07/use-systemd-system-administration-debian.html + +译者:[bazz2](https://github.com/bazz2) 校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[1]:https://lists.debian.org/debian-devel/2013/10/msg00444.html +[2]:https://lists.debian.org/debian-devel/2014/02/msg00316.html +[3]:http://0pointer.de/blog/projects/systemd.html +[4]:http://www.freedesktop.org/wiki/Software/systemd/ diff --git a/translated/tech/20140718 Need Microsoft Office on Ubuntu--Install the Official Webapps.md b/translated/tech/20140718 Need Microsoft Office on Ubuntu--Install the Official Webapps.md deleted file mode 100644 index 32991be99b..0000000000 --- a/translated/tech/20140718 Need Microsoft Office on Ubuntu--Install the Official Webapps.md +++ /dev/null @@ -1,58 +0,0 @@ -需要在Ubuntu上安装微软办公软件?去安装官方的网络应用程序 -================================================== ============================== -![](http://www.omgubuntu.co.uk/wp-content/uploads/2014/07/office-web-app-.jpg) - -**这是微软办公软件及其一贯繁琐的文件指令,而不是每个人的一杯咖啡。同时这是许多工作和教育环境的主要依靠——无论是好还是坏** - -通过使用[LibreOffice的应用程序套件][1],阅读、编辑和保存这些专有指令出现在Ubuntu上是有着某种程度的可能。在作家中,Calc和Impress都不同程度的夸耀微软办公软件文件的协作性,但在我自己的实际操作经验中(谢天谢地,它很简洁!)它并不完美。 - -时不时的,你会不得不使用微软办公软件,(虽然我们大多数人都心里向着开放标准,但是我们不应该无视实际问题)但你已经没有意愿去购买一个完整的微软办公软件许可证来运行这个窗口模拟器,那么微软的在线网络应用程序是完美的解决方法。 - -###安装微软在线办公软件上的应用程序在Ubuntu### - -为了使从Ubuntu的桌面访问这些在线版本更容易,“Linux的网络应用程序项目”创造了一个小的、非官方的安装程序。它可以添加网络应用程序的快捷方式(“荣耀书签”)到您的应用程序启动器。 - -![](http://www.omgubuntu.co.uk/wp-content/uploads/2014/07/microsoft-office-web-apps.jpg) - -通过快捷方式,相应的Microsoft Web应用程序在你默认的系统浏览器中打开,不可能有比这更精美的了。听起来漂亮吗?下面是你的应用程序的快捷方式: - -- 文档 -- 表格 -- 幻灯片 -- Outlook -- OneDrive -- 日历 -- OneNote -- 通讯录 - -该软件包还创建了一个新的应用程序类别来容纳这些链接,不但可以让您把这些快捷方式从其他应用程序单独分开来,而且是直接位于常见的“办公软件”应用程序下。 - -这些都是必不可少的吗?不见得。他们有用吗?这取决于你的工作流程。但它是不错的选择吗?一定是的。 - -你可以从下面的链接保存含有.deb文件安装程序,其中有安装链接。适用于Ubuntu14.04 LTS和更高版本。 - -- [下载微软的在线办公应用(.deb)][2] - -###其他可选项### - -![](http://d0od.wpengine.netdna-cdn.com/wp-content/uploads/2014/04/Screen-Shot-2014-04-15-at-15.29.35-350x200.png) - -类似的替代方案是[安装Chrome官方网上应用商店的在线办公应用程序][3],然后添加应用程序启动器到Linux。这次短跑中仍然会为它们创建可启动的快捷方式,但那些可以被设置为打开自己的窗框,而且不需要安装任何第三方软件包。 - -同时,谷歌最近在整合完整的Office功能(由于其购买了QuickOffice)[到自己的文档,幻灯片和床单应用][4]。Android应用程序Quickoffice退出了舞台,同时Chrome也实现了扩展。 - -如果你是一个深度的谷歌网络硬盘/文档的用户,那么这个解决方案可能对你是更加好了。 - --------------------------------------------------- ------------------------------ - -via: http://www.omgubuntu.co.uk/2014/07/run-microsoft-office-web-apps-ubuntu-desktop - -译者:[cereuz](https://github.com/cereuz) -校对:[校对者ID](https://github.com/校对者ID) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[1]:http://www.libreoffice.org/ -[2]:https://docs.google.com/file/d/0ByQnaVw7riBQMjNCUFh4ZlM4Y0E/edit?usp=sharing -[3]:http://www.omgchrome.com/microsoft-brings-office-online-chrome-web-store/ -[4]:http://www.omgchrome.com/quickoffice-chrome-extension-gets-name-change/ diff --git a/translated/tech/20140811 Check how much do you type with WhatPulse on Linux.md b/translated/tech/20140811 Check how much do you type with WhatPulse on Linux.md new file mode 100644 index 0000000000..7be54ae2ca --- /dev/null +++ b/translated/tech/20140811 Check how much do you type with WhatPulse on Linux.md @@ -0,0 +1,77 @@ +Linux输入统计神器——WhatPulse +================================================================================ +![](http://cdn.linuxaria.com/wp-content/uploads/2014/08/whatpulse.png) + +如果,你想我这样,是个对统计数据有着狂热癖好的人,那么你必须在你的计算机上安装这个小应用:[WhatPulse][1] + +此软件会追踪用户的击键、鼠标点击以及使用的[带宽][2]和系统开机时间。用户可以周期性地,或者手动上传击键的数量到服务器上,这称之为“脉动”。 + +用户可以看到他们在所有加入该程序的人的领先选手排名板的所处位置,并且与他们自己国家的人作比较。用户也可以加入团队,在团队中他们可以和有着相同爱好的人作对比(去吧,Linux用户们!!)。 + +软件分为免费的基础版和高级版,在基础版中你可以查看并检查所有的基本统计数据,而在高级版中你可以看到更多。 + +该软件可用于Linux,Windows和Mac。 + +### 在线注册 ### + +第一步,你必须在[WhatPulse网站][1]注册帐号,或者也可以在你第一次启动WhatPulse客户端时出现的实用向导中创建帐号,以用于上传自己的统计数据(你也可以使用Facebook的帐号登录)。 + +你会被提示需要登录,登录之后,你必须搜索你的计算机名,这是因为你可以通过该帐号登录到多台计算机,而它们的数据都会上传到同一统计帐号。一旦你登入后,一个小小的W将出现在你的系统托盘中,那就对了,你已搞定! + +### 在Linux上安装WhatPulse ### + +官方网站在[下载页][3]提供了一个通用版本.tar.gz归档压缩包(用于32位和64位)和一个debian包。 + +就我个人而言,我已经在我的Mint Qiana上安装了debian包,在我的Arch Linux[Aur包][4]一点问题都没有。 + +如果你想要使用通用版本安装,请记住:WhatPulse需要几个库文件。最主要的是QT,因为WhatPulse构建于QT平台。下面列出了软件安装需求: + +- libQtCore +- libQtWebKit +- libqt4-sql +- libqt4-sql-sqlite +- openssl-devel (libssl-dev) +- libQtScript + +#### 输入统计数据 #### + +客户端需要设置相应的权限,以读取键盘/鼠标输入。运行包含的交互脚本.sh来设置这些权限。 + +#### [网络][5]统计数据 #### + +要启用网络测量,你也需要**libpcap**包来允许WhatPulse挂钩到网络通信。如果WhatPulse找不到libpcap,它会运行,但不会显示任何网络统计数据。 + +![](http://cdn.linuxaria.com/wp-content/uploads/2014/08/heatmap.png) + +### 使用应用程序 ### + +默认情况下,WhatPulse会在登入图形会话后自动启动。点击系统托盘上的W图标,你将进入总览标签页,这里显示你机器上收集到的所有不同信息的鸟瞰图。例如,安装在你PC上的Linux版本、处理器型号、RAM、GPU、总点击次数、击键和带宽使用。点击这些信息下面的‘Pulse’,它将会上传这些收集到的数据到主服务器上。 + +也可以选择自动‘Pulse’数据到服务器的时间,如每50.000点击,或者1GB下载量。 + +要了解深度详情,你可以切换到每个类目的附属标签。例如,Input标签展示给你的是注册后一段时间内的击键的数量和点击次数。时间周期分为每日、每周、每月、每年以及全时。‘all’设置将显示程序安装以来的数据。 + +在击键下面,你会找到键盘点击热图,它简单地使用冷暖色显示选定周期内各个键的使用状况,如上述截图所示。在图的下面,应用显示了选定周期内记录的点击总量。 + +在Network标签下,可以查看到日常互联网使用情况。应用程序可以监控所有网络设备的带宽使用量,甚至也可以给你展示按国家分布的带宽使用情况。再次提醒,你可以使用顶部右边的箭头按钮浏览可用的数据。 + +在网站上,你会看到与客户端上相同的所有统计数据。 + +免责声明:上面的WhatPulse网站链接包含了我的参考链接,注册时请使用该链接,这会让我的帐号在某天升级到高级帐号。 + +-------------------------------------------------------------------------------- + +via: http://linuxaria.com/recensioni/check-how-much-do-you-type-with-whatpulse-on-linux + +作者:[linuxari][a] +译者:[GOLinux](https://github.com/GOLinux) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:https://plus.google.com/100563597940685405833?rel=author +[1]:http://whatpulse.org/ref/833872/ +[2]:http://linuxaria.com/article/tool-command-line-bandwidth-linux +[3]:http://www.whatpulse.org/downloads/ +[4]:https://aur.archlinux.org/packages/whatpulse/ +[5]:http://linuxaria.com/tag/network diff --git a/translated/tech/20140818 Disable reboot using Ctrl-Alt-Del Keys in RHEL or CentOS.md b/translated/tech/20140818 Disable reboot using Ctrl-Alt-Del Keys in RHEL or CentOS.md new file mode 100644 index 0000000000..f95f9d4eb4 --- /dev/null +++ b/translated/tech/20140818 Disable reboot using Ctrl-Alt-Del Keys in RHEL or CentOS.md @@ -0,0 +1,44 @@ +在RHEL / CentOS下停用按下Ctrl-Alt-Del 重启系统的功能 +================================================================================ +在Linux里,由于对安全的考虑,我们允许任何人按下**Ctrl-Alt-Del**来**重启**系统。但是在生产环境中,应该停用按下Ctrl-Alt-Del 重启系统的功能。 + +在这篇文章里,我们将要介绍如何在RHEL和CentOS下停用该热键。 + +### 在RHEL 5.X和CentOS 5.X下 ### + +保护**init**进程免于**Ctrl-Alt-Del**,像下面一样编辑'**/etc/inittab**'里由'**ca::ctrlaltdel**:'开头的一行: + + [root@localhost ~]# cat /etc/inittab + # Trap CTRL-ALT-DELETE + #ca::ctrlaltdel:/sbin/shutdown -t3 -r now + +我们还可以改变'ca::ctrlaltdel:'这行来输出日志 ,如果任何人想用该热键重启服务器,就会有日志, + + [root@localhost ~]# cat /etc/inittab + # Trap CTRL-ALT-DELETE + ca::ctrlaltdel:/bin/logger -p authpriv.warning -t init "Console-invoked Ctrl-Alt-Del was ignored" + +### 在RHEL6.X和CentOS 6.X下 ### + +在RHEL6.X和CentOS 6.X下, 该热键的行为由'**/etc/init/control-alt-delete.conf**'控制. + +**第一步** 在变化之前,先用下列命令备份配置 + + [root@localhost ~]# cp -v /etc/init/control-alt-delete.conf /etc/init/control-alt-delete.override + +**第二步**编辑文件,把'exec /sbin/shutdown'这一行用下方配置代替,这个配置会在每次按下Ctrl-Alt-Del 时输出日志: + + [root@localhost ~]# cat /etc/init/control-alt-delete.conf + exec /usr/bin/logger -p authpriv.notice -t init "Ctrl-Alt-Del was pressed and ignored" + +-------------------------------------------------------------------------------- + +via: http://www.linuxtechi.com/disable-reboot-using-ctrl-alt-del-keys/ + +作者:[Pradeep Kumar][a] +译者:[2q1w2007](https://github.com/2q1w2007) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://www.linuxtechi.com/author/pradeep/ \ No newline at end of file diff --git a/translated/tech/20140818 How to Take 'Snapshot of Logical Volume and Restore' in LVM--Part III.md b/translated/tech/20140818 How to Take 'Snapshot of Logical Volume and Restore' in LVM--Part III.md new file mode 100644 index 0000000000..6213ea22d4 --- /dev/null +++ b/translated/tech/20140818 How to Take 'Snapshot of Logical Volume and Restore' in LVM--Part III.md @@ -0,0 +1,200 @@ +在LVM中“录制逻辑卷快照并恢复”——第三部分 +================================================================================ +**LVM快照**是空间有效指向时间的lvm卷副本。它只在lvm中工作,并只在源逻辑卷发生改变时消耗快照卷的空间。如果源卷的变化达到1GB这么大,快照卷同样也会产生这样大的改变。因而,对于空间有效利用的最佳途径,就是总是进行小的修改。如果快照将存储空间消耗殆尽,我们可以使用lvextend来扩容。而如果我们需要缩减快照,可以使用lvreduce。 + +![Take Snapshot in LVM](http://www.tecmint.com/wp-content/uploads/2014/08/Take-Snapshot-in-LVM.jpg) +在LVM中录制快照 + +如果我们在创建快照后意外地删除了无论什么文件,我们没有必要担心,因为快照里包含了我们所删除的文件的原始文件。创建快照时,很有可能文件每次都在那。不要改变快照卷,保持创建时的样子,因为它用于快速恢复。 + +快照不可以用于备份选项。备份是某些数据的基础副本,因此我们不能使用快照作为备份的一个选择。 + +#### 需求 #### + +注:此两篇文章如果发布后可换成发布后链接,原文在前几天更新中 + +- [在Linux中使用LVM创建磁盘存储 — 第一部分][1] +- [在Linux中扩展/缩减LVM — 第二部分][2] + +### 我的服务器设置 ### + +- 操作系统 — 安装有LVM的CentOS 6.5 +- 服务器IP — 192.168.0.200 + +#### 步骤1: 创建LVM快照 #### + +首先,使用‘**vgs**’命令检查卷组中的空闲空间以创建新的快照。 + + # vgs + # lvs + +![Check LVM Disk Space](http://www.tecmint.com/wp-content/uploads/2014/08/Check-LVM-Disk-Space.jpg) +检查LVM磁盘空间 + +正如你所见,在**vgs**命令输出中,我们可以看到有8GB的剩余空闲空间。所以,让我们为我的名为**tecmint_datas**的卷之一创建快照。处于演示的目的,我将会使用以下命令来创建1GB的快照卷。 + + # lvcreate -L 1GB -s -n tecmint_datas_snap /dev/vg_tecmint_extra/tecmint_datas + +或者 + + # lvcreate --size 1G --snapshot --name tecmint_datas_snap /dev/vg_tecmint_extra/tecmint_datas + +上面的两个命令都是干得同一件事: + +- **-s** – 创建快照 +- **-n** – 为快照命名 + +![Create LVM Snapshot](http://www.tecmint.com/wp-content/uploads/2014/08/Create-LVM-Snapshot.jpg) +创建LVM快照 + +此处,是对上面高亮要点的说明。 + +- 我在此创建的快照的大小。 +- 创建快照。 +- 创建快照名。 +- 新的快照名。 +- 要创建快照的卷。 + +如果你想要移除快照,可以使用‘**lvremove**’命令。 + +# lvremove /dev/vg_tecmint_extra/tecmint_datas_snap + +![Remove LVM Snapshot](http://www.tecmint.com/wp-content/uploads/2014/08/Remove-LVM-Snapshot.jpg) +移除LVM快照 + +现在,使用以下命令列出新创建的快照。 + + # lvs + +![Verify LVM Snapshot](http://www.tecmint.com/wp-content/uploads/2014/08/Verify-LVM-Snapshot.jpg) +验证LVM快照 + +上面的你看到了吧,成功创建了一个快照。上面我用箭头标出了快照创建的源,它就是**tecmint_datas**。是的,因为我已经为**tecmint_datas l-volume**创建了一个快照。 + +![Check LVM Snapshot Space](http://www.tecmint.com/wp-content/uploads/2014/08/Check-LVM-Snapshot-Space.jpg) +检查LVM快照空间 + +让我们添加一些新文件到**tecmint_datas**里头。现在卷里大概有650MB左右的数据,而我我们的快照有1GB大。因此,有足够的空间在快照卷里备份我们的修改。这里我们可以使用下面的命令来查看到,我们的快照当前的状态。 + + # lvs + +![Check Snapshot Status](http://www.tecmint.com/wp-content/uploads/2014/08/Check-Snapshot-Status.jpg) +检查快照状态 + +你看到了,现在已经用掉了**51%**的快照卷,你要对你的文件作更多的修改都没有问题。使用下面的命令来查看更多详细信息。 + + # lvdisplay vg_tecmint_extra/tecmint_data_snap + +![View Snapshot Information](http://www.tecmint.com/wp-content/uploads/2014/08/Snapshot-Information.jpg) +查看快照信息 + +再来对上面图片中高亮的要点作个清楚的说明。 + +- 快照逻辑卷名称。 +- 当前使用的卷组名。 +- 读写模式下的快照卷,我们甚至可以挂载并使用该卷。 +- 快照创建时间。这个很重要,因为快照将跟踪此时间之后的每个改变。 +- 该快照属于tecmint_datas逻辑卷。 +- 逻辑卷在线并可用。 +- 我们录制快照的源卷大小。 +- 写时复制表大小,Cow = copy on Write,这是说对tecmint_data卷所作的任何改变都会写入此快照。 +- 当前使用的快照大小,我们的tecmint_data有10GB,而我们的快照大小是1GB,这就意味着我们的数据大概有650MB。所以,如果tecmint_datas中的文件增长到2GB,现在的51%中的内容将增加到超过所分配的快照的大小,当然,我们在创建快照时会出现问题。这就意味着我们需要扩展逻辑卷大小(快照逻辑卷) +- 给出快照组块的大小。 + +现在,让我们复制超过1GB的文件到**tecmint_datas**。让我们看看会发生什么。如果你那么做了,你将会见到‘**Input/output error**’这样的错误信息,它告诉你快照超出空间大小了。 + +![Add Files to Snapshot](http://www.tecmint.com/wp-content/uploads/2014/08/Add-Files-to-Snapshot.jpg) +添加文件到快照 + +如果逻辑卷满了,它就会自动下线,我们就不能再使用了,就算我们去扩展快照卷的大小也不行。最好的方法就是在创建快照时,创建一个和源一样大小的快照卷。**tecmint_datas**的大小是10GB,如果我们创建一个10GB大小的快照,它就永远都不会像上面那样超载,因为它有足够的空间来录制你的逻辑卷的快照。 + +#### 步骤2: 在LVM中扩展快照 #### + +如果我们需要在超载前扩展快照大小,我们可以使用以下命令来完成此项任务。 + + # lvextend -L +1G /dev/vg_tecmint_extra/tecmint_data_snap + +现在,那里有总计2GB大小的快照空间。 + +![Extend LVM Snapshot](http://www.tecmint.com/wp-content/uploads/2014/08/Extend-LVM-Snapshot.jpg) +扩展LVM快照 + +接下来,使用以下命令来验证新的大小和写时复制表。 + + # lvdisplay /dev/vg_tecmint_extra/tecmint_data_snap + +要知道快照卷的大小使用**%**。 + + # lvs + +![Check Size of Snapshot](http://www.tecmint.com/wp-content/uploads/2014/08/Check-Size-of-Snapshot.jpg) +检查快照大小 + +然而,如果你的快照大小和源卷一样,我们就没有必要担心这些问题了。 + +#### 步骤3: 恢复快照或合并 #### + +要恢复快照,我们首先需要卸载文件系统。 + + # unmount /mnt/tecmint_datas/ + +![Un-mount File System](http://www.tecmint.com/wp-content/uploads/2014/08/Unmount-File-System.jpg) +卸载文件系统 + +只想检查挂载点是否卸载,可以使用下面的命令。 + + # df -h + +![Check File System Mount Points](http://www.tecmint.com/wp-content/uploads/2014/08/Check-Mount-Points.jpg) +检查文件系统挂载点 + +这里,我们的挂载已经被卸载,所以我们可以继续恢复快照。要恢复快照,可以使用**lvconvert**命令。 + + # lvconvert --merge /dev/vg_tecmint_extra/tecmint_data_snap + +![Restore LVM Snapshot](http://www.tecmint.com/wp-content/uploads/2014/08/Restore-Snapshot.jpg) +恢复LVM快照 + +在合并完成后,快照卷将被自动移除。现在我们可以使用**df**命令来查看分区大小。 + + # df -Th + +![Check Size of Snapshot](http://www.tecmint.com/wp-content/uploads/2014/08/Check-Snapshot-Space.jpg) + +在快照卷自动移除后,你可以用下面的命令查看逻辑卷大小。 + + # lvs + +![Check Size of Logical Volume](http://www.tecmint.com/wp-content/uploads/2014/08/Check-Size-of-LV.jpg) +检查逻辑卷大小 + +**重要**:要自动扩展快照,我们可以通过修改配置文件来进行。对于手动扩展,我们可以使用lvextend。 + +使用你喜欢的编辑器打开lvm配置文件。 + + # vim /etc/lvm/lvm.conf + +搜索单词autoextend。默认情况下,该值和下图中的类似。 + +![LVM Configuration](http://www.tecmint.com/wp-content/uploads/2014/08/LVM-Configuration.jpg) +LVM配置 + +修改此处的**100**为**75**,这样自动扩展的起始点就是**75**,而自动扩展百分比为20,它将自动扩容**百分之20**。 + +如果快照卷达到**75%**,它会自动为快照卷扩容**20%**。这样,我们可以自动扩容了。使用**wq!**来保存并退出。 + +这将把快照从超载下线中拯救出来,这也会帮助你节省更多时间。LVM是我们扩容以及获得其它众多特性如精简资源调配、拆卸、虚拟卷和使用精简池的唯一方法,让我们在下一个话题中来讨论吧。 + +-------------------------------------------------------------------------------- + +via: http://www.tecmint.com/take-snapshot-of-logical-volume-and-restore-in-lvm/ + +作者:[Babin Lonston][a] +译者:[GOLinux](https://github.com/GOLinux) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://www.tecmint.com/author/babinlonston/ +[1]:http://www.tecmint.com/create-lvm-storage-in-linux/ +[2]:http://www.tecmint.com/extend-and-reduce-lvms-in-linux/ diff --git a/translated/tech/20140819 Build a Raspberry Pi Arcade Machine.md b/translated/tech/20140819 Build a Raspberry Pi Arcade Machine.md new file mode 100644 index 0000000000..498a05b8f3 --- /dev/null +++ b/translated/tech/20140819 Build a Raspberry Pi Arcade Machine.md @@ -0,0 +1,135 @@ +自制一台树莓派街机 +================================================================================ +**利用当代神奇设备来重温80年代的黄金威严。** + +### 你需要以下硬件 ### + +- 一台树莓派以及一张4GBSD卡 +- 一台支持HDMI的LCD显示屏 +- 游戏手柄或者... +- 一个JAMMA街机游戏机外壳机箱 +- J-Pac或者I-Pac + +80年代有太多难忘的记忆;冷战结束,Quatro碳酸饮料,Korg Polysix合成器,以及Commodore 64家用电脑。但对于某些年轻人来说,这些都没有街机游戏机那样有说服力,或那种甜蜜的叛逆。笼罩着烟味和此起彼伏的8比特音效,它们就是在挤出来的时间里去探索的洞穴:50分钱和一份代币能让你消耗整个午餐时间,在这些游戏上磨练着你的技能:小蜜蜂,城市大金刚,蜈蚣,行星射击,吃豆小姐,火凤凰,R-Rype,大金刚,雷霆计划,铁手套,街头霸王,超越赛车,防卫者争战...这个列表太长了。 + +这些游戏,以及玩这些游戏的街机机器,仍然像30年前那样有吸引力。不像年轻时候那样,现在可以不用装一兜零钱就能玩了,最终让你超越那些有钱的孩子以及他们无休止的‘继续游戏’。所以是时候打造一个你自己的基于Linux的街机游戏机了,然后挑战一下过去的最高分。 + +我们将会覆盖所有的步骤,来将一个便宜的街机游戏机器外壳变成一台Linux驱动的多平台复古游戏系统。但是这并不意味着你就一定要搭建一个同样的系统。比如说,你可以放弃那个又大又重还有潜在致癌性外壳的箱子本身,而是将内部控制核心装进一个旧游戏主机或同等大小的盒子里。或者说,你也可以简单地放弃小巧的树莓派,而将系统的大脑换成一台更强劲的Linux主机。举个例子,它可以作为运行SteamOS的一个理想平台,用来玩那些更优秀的现代街机游戏。 + +在之后的几个页面里,我们将搭建一台基于树莓派的街机游戏机,你应该也能从其中发现很多点子应用到你自己的项目上,即使它们和我们这个项目不太一样。然后因为我们是用无比强大的MAME来做这件事情,你几乎可以让它在任意平台上运行。 + +![](http://www.linuxvoice.com/wp-content/uploads/2014/08/picade3.png) + +我们在B+型号出来以前完成的这个项目。它应该也可以同样工作在更新的主板上,你应该不用一个带电源的USB Hub也可以(点击看大图)。 + +### 声明 ### + +强调一下,我们捣腾的电子器件可能会让你受到电击。请确保你做的任何改动都是有资质的电子工程师帮你检查过的。我们也不会深入讨论如何获取游戏,但是有很多合法的资源,例如基于MAME模拟器的老游戏,以及较新的商业游戏。 + +#### 第一步:街机机柜 #### + +街机机柜本身就是最大的挑战。我们在eBay上淘了个二手的90年代初的双人泡泡龙游戏机。然后花了£220装在一台旅行车后面送过来。类似这种机柜的价格并不确定。我们看到过很多在£100以内的。而另一方面,还有很多人愿意花数千块钱去买原版侧面贴纸完整的机器。 + +决定买一个街机机柜,主要有两个考虑。第一个是它的体积:这东西又大又重。又占地方,而且需要至少两个人才能搬动。如果你不缺钱的话,还可以买DIY机柜或者全新的小一点的,例如适合摆在桌子上的那种。然后,酒柜也能很合适。 + +![](http://www.linuxvoice.com/wp-content/uploads/2014/08/picade4.jpg) + +这种机柜可能很便宜,但是他们都很重。不要一个人去搬。一些更古老的机器可能还会需要一点小关怀,例如重新喷个漆以及一些修理工作(点击看大图)。 + +除了获得更加真实的游戏体验以外,购买原版的街机机柜的一个绝佳理由是可以使用原版的控制器。从eBay上买到的大多数机器都支持两个人同时玩,有两个摇杆以及每个玩家各自的一些按钮,再加上玩家一和玩家二的选择按钮。为了兼容更多游戏,我们建议您找一台每个玩家都有6个按键,这个是通用配置。也许你还想看看支持超过两位玩家的控制台,或者有空间放其他游戏控制器的,比如说街机轨迹球(类似疯狂弹珠这种游戏需要的),或者一个旋钮(打砖块)。这些待会都可以轻松装上去,因为有现成的现代USB设备。 + +控制器是第二考虑的,而且我们认为是最重要的,因为要通过它把你的摇动和拍打转变成游戏里的动作。当你准备买一个机柜时需要考虑一种叫JAMMA的东西,它是日本娱乐机械制造商协会(Japan Amusement Machinery Manufacturers Association)的缩写。JAMMA是街机游戏机里的行业标准,定义了包含游戏芯片的电路板和游戏控制器的连接方式,以及投币机制。它是一个连接两个玩家的摇杆和按钮的所有线缆的接口电路,把它们统一到一个标准的连接头。JAMMA就是这个连接头的大小以及引脚定义,这就意味着不管你安装的主板是什么,按钮和控制器都将会连接到相同功能接口,所以街机的主人只需要再更换下机柜上的外观图片,就可以招揽新玩家了。 + +但是首先,提醒一下:JAMMA连接头上带有12V电压供电,通常由大多数街机里都有的电源模块供给。为了避免意外短路或是不小心掉个螺丝刀什么的造成损坏,我们完全切断了这个供电。在本教程后面的任何阶段,我们也不会用到这个连接头上的任何电源脚。 + +![](http://www.linuxvoice.com/wp-content/uploads/2014/08/picade2.png) + +#### 第二步:J-PAC #### + +有一点非常方便,你可以买到这样一种设备,连接街机机柜里的JAMMA接头和电脑的USB端口,将机柜上的摇杆和按键动作都转换成(可配置的)键盘命令,它们可以在Linux里用来控制任何想玩的游戏。这个设备就叫J-Pac([www.ultimarc.com/jpac.html][1] – 大概£54)。 + +它最大的特点不是它的连接性;而是它处理和转换输入信号的方式,因为它比标准的USB手柄强太多太多了。每一个输入都有自己独立的中断,而且没有限制同时按下或按住的按钮或摇杆方向的数量。这对于类似街头霸王的游戏来说非常关键,因为他们依赖于同时迅速按下的组合键,而且用来对那些发飙后按下自己所有按键的不良对手发出致命一击时也必不可少。许多其他控制器,特别是那些生成键盘输入的,受到他们所采用的USB控制器的同时六个输入的限制,以及一堆的Alt,Shift和Ctrl键的特殊处理的限制。J-Pac还可以接入倾角传感器,甚至某些投币装置,不用预先配置就可以在Linux下工作了。 + +另外的选择是一个类似的叫I-Pac的设备。它做了和J-Pac相同的事情,只不过不支持JAMMA接头。这意味着你不能把JAMMA控制器接上去,但同时也就是说你可以设计你自己的控制器布局,再把每个控制接到I-Pac上去。这对第一个项目来说也许有点小难,但是这却是许多街机迷们选择的方式,特别是他们想设计一个支持四个玩家的控制板的时候,或者是一个整合许多不同类型控制的面板的时候。我们采用的方式并不是我们推荐必须要做的,我们改造了一个输入有问题的二手X-Arcade Tankstick控制面板,换上了新的摇杆和按钮,再接到新的JAMMA接口,这样有一个非常好的地方就是可以用便宜的价格(£8)买到所有用到的线材包括电路板边缘插头。 + +![](http://www.linuxvoice.com/wp-content/uploads/2014/08/picade5.jpg) + +我们的已经装到机柜上的J-Pac。右边的蓝色和红色导线接到我们的机柜上额外的1号和2号玩家按钮(点击看大图)。 + +不管你选择的是I-Pac或是J-Pac,它们产生的按键都是MAME的默认值。也就是说运行模拟器之后不需要手动调整输入。例如玩家1,会默认将键盘方向键映射成上下左右,以及将左边的Ctrl,左边的ALT,空格和左边的Shift键映射到按钮1-4。但是真正实用的功能是,对于我们来说,是双键快捷方式。当按下并按住玩家1按钮后,就可以通过把玩家1的摇杆拉到下的位置发出用来暂停游戏的P按键,推到上的位置调整音量,以及推到右的位置来进入MAME自己的设置界面。这些特殊组合键设计的很巧妙,不会对正常玩游戏带来任何干扰,因为他们只有在按住玩家1按钮后才会生效,然后可以让你正在运行游戏的时候也能做任何需要的事情。例如,你可以完全地重新配置MAME,使用它自己的菜单,在玩游戏的时候改变输入绑定和灵敏度。 + +最后,按住玩家1按钮然后按下玩家2按钮就可以退出MAME,如果你使用了启动菜单或MAME管理器的话就很有用了,因为他们会自动启动游戏,然后你就可以用最快的速度开始玩另一个游戏了。 + +对于显示屏我们采取了比较保守的方式,拿掉了街机原装的笨重的而且已经坏掉的CRT,换成一个低成本的LCD显示器。这样做有很多好处。首先,这个显示器有HDMI接口,这样他就可以轻易地直接连接到树莓派或是现代的显卡上。第二,你也不用去设定驱动街机屏幕所需要的低频率刷新模式,也不需要驱动它的专用图形硬件。第三,这也是最安全的方式,因为街机屏幕往往在机身背后没有保护措施,让很高的电压离你的手只有几英寸的距离。也不是说你完全不能用CRT,如果那就是你追求的体验的话 – 这也是获得所追求的游戏体验的最真实的方式,但是我们在软件里充分细调了CRT模拟部分,我们对输出已经很满意了,而且不需要用那个古老的CRT更是让我们高兴。 + +你也许还需要考虑用一个老式的4:3长宽比的LCD,而不是那种宽屏的现代产品,因为4:3模式用来玩竖屏或横屏的游戏更实用。比如说玩竖屏的射击游戏,例如雷电,如果使用宽屏显示器的话,会在屏幕两边都有一个黑条。这些黑条一般会用来显示一些游戏指引,或者你也可以把屏幕翻转90度,这样就可以用上每个像素了,但这却不实用,除非你只玩竖屏游戏或者有一个容易操作的旋转支座。 + +装载显示屏也很重要。如果你拿掉了CRT的话,没有现成的地方安装LCD。我们的方式是买了一些中密度纤维板(MDF)并切割成适合原来摆放CRT的地方。固定以好,我们把一个便宜的VESA支座放在中间。VESA底座可以用来挂载大多数屏幕,大的或小的。最后,因为我们的机柜前面有烟玻璃,我们必须保证亮度和对比度都设置的足够高。 + +### 第三步:装配 ### + +现在几个硬件大件都选好了,而且也基本上确定了最终街机机柜要摆放的地方,把这几个配件装到一起并没有太大难度。我们安全地把机柜后面的电源输入部分拆开,然后在背后的空间接了一个符合插座。接在了电源开关之后的电线上。 + +几乎所有的街机机柜右上角都有个电源开关,但通常在机柜靠下一点的地方有大量的导线铰接在它上面,也就是说我们的设备可以使用普通的电源连接头。我们的机柜上还有一个荧光管,用做机器上边灯罩的背光,之前是直接连接到电源上的,我们可以用一个普通插头让它保持和电源连接。当你打开机柜上的电源开关的时候,电流会流入机柜里的各个部件 - 你的树莓派和显示屏都会开机,所有一切就都准备好了。 + +J-Pac模块直接插到JAMMA接口上,但你可能还需要一点手动调整。标准的JAMMA只支持每个玩家最多三个按键(尽管许多非正式的支持四个),而J-Pac可以支持六个。为了连接额外的按钮,你需要把按钮开关的一端接到J-Pac的GND上,另一端接到J-Pac板边有螺丝固定的输入上。它们被标记成1SW4,1SW5,1SW6,2SW4,2SW5和2SW6。J-Pac也有声音的直通连接,但是我们发现杂音太多没法用。改成把机柜上的喇叭连接到一个二手的SoundBlaster功放上,再接到树莓派的音频输出端口。声音不一定要纯正,但音量一定要足够大。 + +![](http://www.linuxvoice.com/wp-content/uploads/2014/08/picade6.jpg) + +我们的树莓派已经接到J-Pac左边,也已经连接了显示屏和USB hub(点击看大图)。 + +然后把J-Pac或I-Pac模块通过PS2转USB连接线接到你的PC或树莓派,也可以直接接到PC的PS2接口。要用旧的PS2接头的话额外还有个要求,你的电脑得足够古老还有这个,但是我们测试发现用USB性能是一样的。当然,这个不能用于不带PS2的树莓派,而且别忘了树莓派也需要供电。我们一般建议使用一个带电源的USB hub,因为没有供电是树莓派不工作最常见的错误。你还需要保证树莓派的网络正常,要么通过以太网(也许使用一个藏到机柜里的电力线适配器),或者通过无线USB设备。网络很关键是因为在树莓派被藏到机柜里后你还可以重新配置它,不用接键盘或鼠标就可以让你调整设置以及执行管理任务。 + +> ### 投币装置 ### + +> 在街机模拟社区里,让投币装置工作在模拟器上工作就会和商业产品太接近了。这就意味着你有潜在的可能对使用你机器的人收取费用。这不仅仅只是不正当,考虑到运行在你自己街机上的那些游戏的来源,这将会是非法的。这很显然违背了模拟的精神。不过,我们和其他热爱者觉得一个能工作的投币装置更进一步地靠近了街机的真实,而且值得付出努力来营造对那个过去街机的怀念。丢个10便士硬币到投币口然后再听到机器发出增加点数的声音,没有什么比得上。 + +> 实际上难度也不大。取决于你街机上的投币装置,以及它如何发信号通知投了几个币。大多数投币装置分为两个部分。较大的一部分是硬币接收和验证装置。这是投币过程的物理部分,用于检测硬币是否真实以及确定它的价值。这是通过一个游戏点数逻辑电路板来实现的,通常用一个排线连接,上边还带有很多DIP开关。这些开关用来决定接受哪种硬币,以及一个硬币能产生多少点数。然后就是简单地找到输出开关,每个点数都会触发它一次,然后把它接到JAMMA连接头的投币输入上,或者直接接到J-Pac。我们的投币装置型号是Mars MS111,在90年代早期的英国很常见,网上有大量关于每个DIP开关作用的信息,也有如何重新编程控制器来接受新硬币的方法。我们还能在这个装置的12V上接个小灯用来照亮投币孔。 + +#### 第四步:软件 #### + +MAME是这种规模项目唯一可行的模拟器,它如今支持运行在数不清的不同平台上的各种各样的游戏,从第一代街机到一些最近的机器。从这个项目中还孕育出了MESS,一个多模拟器的超级系统,针对的平台是80到90年代的家庭电脑以及电视游戏机。 + +如何配置MAME本身都可以写上六页的文章了。它是一个复杂的,无序的,伟大的软件程序,模拟了如此之多的CPU,声卡,芯片,控制器以及那么多的选项,就像MythTV,你都永远不能真正停止配置它。 + +但是也有个相对省事的方式,一个特别为树莓派构建的版本。它叫PiMAME。它是一个可下载的发布版和脚本,基于Raspbian,这是树莓派的默认发布版。它不仅仅会把MAME装到树莓派上(这很有用因为没有哪个默认仓库里有这个),还会安装其他一些精选出来的模拟器,并通过一个前端来管理他们。MAME,举个例子,是一个有数十个参数的命令行应用。但是PiMAME还有一个妙招 - 它安装了一个简单的网页服务器,可以在连接上网络后让你通过浏览器来安装新游戏。这是一个很好的优点,因为把游戏文件放到正确的目录下是使用MAME的困难之一,这还能让你连接到树莓派的存储设备得到最优使用。还有,PiMAME会通过用来安装它的脚本更新自己,所以保持最新版本就太简单了。目前来说这个非常有用,因为在编写这个项目的时候,正好在0.8版这样一个重大更新发布的时间点上。我们在三月份早期时发现有一些轻微的不稳定,但是我们确定在你读到这篇文章的时候一切都会解决。 + +安装PiMAME最好的方式就是先装Raspbian。你可以通过NOOBS安装,使用电脑上的图形工具,或者通过dd命令把Raspbian的内容直接写入到你的SD卡中。就像我们上个月的BrewPi教程里曾提到的,这个过程在之前已经被记录过很多次,所以就不再浪费口水了。想简单点就装一下NOOBS,参照树莓派网站上的指引。在装好Raspbian并跑起来以后,请确保使用配置工具来释放SD卡上的空间,以及确保系统已经更新到最新(`sudo apt-get update; sudo apt-get upgrade`)。然后再确保已经安装好了git工具包。当前任意Raspbian版本都会自带git,不过你仍然可以通过命令`sudo apt-get install git`检查一下。 + +然后再在终端里输入下面的命令把PiMAME安装器从项目的GitHub仓库克隆到本地: + + git clone https://github.com/ssilverm/pimame_installer + +之后,如果命令工作正常的话你应该能看到如下的反馈输出: + + Cloning into ‘pimame_installer’... + remote: Reusing existing pack: 2306, done. + remote: Total 2306 (delta 0), reused 0 (delta 0) + Receiving objects: 100% (2306/2306), 4.61 MiB | 11 KiB/s, done. + Resolving deltas: 100% (823/823), done. + +这个命令会创建一个叫‘pimame_installer’的新目录,然后下一步就是进入这个目录再执行它里面的脚本: + + cd pimame_installer/ + sudo ./install.sh + +这个命令会安装和配置很多软件。所需的时间长短也取决于你的因特网速度,因为需要下载大量的包。我们那个简陋的树莓派加15Mb因特网连接用了差不多45分钟来执行完这个脚本,在这之后你会收到重启机器的提示。你现在可以安全的通过输入`sudo shutdown -r`来重启了,因为这个命令会自动处理剩下的SD卡写入操作。 + +这就是安装的全部事情了。在重启树莓派后,就会自动登录,然后会出现PiMAME启动菜单。在0.8版本里这是个非常漂亮的界面,有每个支持平台的图片,还有红色图标提示已经安装了多少个游戏。现在应该可以用控制器来操作了。如果需要检查控制器是否正确连接,可以用SSH连接到树莓派然后检查一下文件**/dev/input/by-id/usb-Ultimarc_I-PAC_Ultimarc_I-PAC-event-kbd**是否存在。 + +默认的按键配置就可以让你选择要在你的街机上运行哪个模拟器。我们最感兴趣的就是第一个,名字叫‘AdvMAME’,不过你也许会很惊讶看到还有一个MAME可选的,MAME4ALL。MAME4ALL是特别为树莓派构建的,使用了旧版的MAME源代码,所以它所支持的ROMS的性能也是最佳的。这是很合理的,因为你的树莓派不可能玩那些要求很高的游戏,所以没有理由苛求模拟器的没必要的兼容性。现在剩下的事情就是找些游戏装到你的系统里(参考下面的方法),然后尽情享受吧! + +![](http://www.linuxvoice.com/wp-content/uploads/2014/08/picade1.png) + +-------------------------------------------------------------------------------- + +via: http://www.linuxvoice.com/arcade-machine/ + +作者:[Ben Everard][a] +译者:[zpl1025](https://github.com/zpl1025) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://www.linuxvoice.com/author/ben_everard/ +[1]:http://www.ultimarc.com/jpac.html diff --git a/translated/tech/20140819 How to Encrypt Email in Linux.md b/translated/tech/20140819 How to Encrypt Email in Linux.md new file mode 100644 index 0000000000..9dadd06e8f --- /dev/null +++ b/translated/tech/20140819 How to Encrypt Email in Linux.md @@ -0,0 +1,105 @@ +在Linux中加密邮件 +================================================================================ +![Kgpg provides a nice GUI for creating and managing your encryption keys.](http://www.linux.com/images/stories/41373/fig-1-kgpg.png) +Kgpg为了创建了管理加密秘钥提供了一个很好的GUI界面. + +如果你一直在考虑如何加密电子邮件,那么在众多的邮件服务和邮件客户端中挑来挑去一定是件头痛的事情.可以考虑两种加密方法:SSL或TLS加密会保护发送到邮件服务器的登录名和密码.[Gunpg][1]是一款标准有用的Linux加密工具,可以加密和认证消息.如果你可以管理自己的GPG加密,并不考虑第三方工具,那它就够了,其它的我们将在稍后讨论. + +即便加密了消息,你仍然会暴露在流量分析中,因为消息头部必须是明文形式.所以需要另一款比如[Tor network][2]来隐藏你在互联网上的足迹.我们会看看各种邮件服务和客户端,以及其中的利弊. + +### 忘掉Web邮件 ### + +如果你使用过GMail, Yahoo,Hotmail或者其它Web邮件提供商的邮件服务,那就忘掉它们吧.你在Web浏览器里输入的任何信息都会暴露在JavaScript攻击中,而且无论服务提供商提供什么保障都是过眼云烟(译者注:此说法靠谱否?).GMail,Yahoo和Hotmail均提供SSL/TLS加密来防止消息被窃听.但是它们不会提供任何保护来阻碍它们自己的数据挖掘,因此并不会提供端到端的加密.Yahoo和Google都声称将在明年推出端到端的加密.对此我持怀疑态度,因为如果一旦它们的核心业务数据挖掘受到干预,它们就什么都干不了了. + +市面上也有各式各样的声称可以为所有类型的电子邮件都能提供安全加密的第三方邮件加密服务,比如[Virtru][3]和[SafeMess][4].对此我依旧表示怀疑,因为无论是谁,只要持有加密秘钥就可以访问你的消息,所以你还是要依赖于可信而不是技术. + +对等消息可以避免许多使用集中化服务中的缺陷.[RetroShare][5]和[Bitmessage][6]是两种流行的范例.我不知道它们是否如实所述,但这么说肯定由可取之处. + +那Anddroid和iOS又如何呢?假设大部分的Android和iOS应用都没有权限获取你的消息的话,那就是最安全的.不要照搬我说的 -- 在应用将要安装到你的设备上时麻烦读读相关的服务条款并检查所要求的权限.即便在初次安装时它们的条款是可接受的,也记得单方面的条款改变是行业的标准,所以做最坏的打算是最安全的. + +### 零基础知识 ### + +[Proton Mail][7]是一款全新的邮件服务,声称无需任何基础就可以实现消息加密.认证和消息加密分为两个单独的步骤,Proton受到Swiss隐私条款的保护,它们不会通过日志记录用户的活动.零基础知识加密提供真正的安全.这代表只有你拥有你的加密秘钥,如果你丢了它们,你的消息就无法恢复了. + +也有许多加密电子邮件服务声称可以保护你的隐私.认真阅读细则,查看红色标注的地方,比如受限的用户数据采集,与好友分享,与执法部门的合作等.这些条款暗示它们会收集和共享用户数据,拥有权限获取你的加密秘钥,并读取你的消息. + +### Linux邮件客户端 ### + +一款独立的开源邮件客户端,比如, Mutt, Claws, Evolution, Sylpheed和Alpine,可建立你自己控制的GnuPG秘钥,给你大部分的保护.(建立更安全的电子邮件和Web浏览的最容易的方式是运行TAILS live的Linux发行版.详情查看[Protect Yourself Online With Tor, TAILS, and Debian][8].) + +无论你使用的是TAILS还是一款标准Linux发行版,管理GnuPG的方法是相同的,所以下面来学习如何使用GnuPG加密消息. + +### 使用GnuPG ### + +首先,熟悉一下相关术语。OpenPGP是一种开放的电子邮件加密和认证协议,基于菲利普·齐默曼的Pretty Good Privacy (PGP)。GNU Privacy Guard (GnuPG or GPG)是OpenPGP的GPL实现。GnuPG使用对称公钥加密算法,也就是说会生成一堆密钥:一个任何人都可以用来加密发送给你的消息的公钥和一个只有你自己拥有用来解密消息的的私钥。GnuPG执行两个分开的函数:数字化签名消息以证明消息来自你和加密消息。任何人都可以读到你的数字签名消息,但只有那些与你交换密钥的人才可以读取加密消息。切记千万不要与他人分享你的密钥!只能分享公钥。 + +Seahorse是GnuPG对应的GNOME图形化前端,KGpg是KDE图形化的GnuPG工具。 + +现在我们执行生成和管理GunPG密钥的基本步骤。这个命令生成一个新的密钥: + + $ gpg --gen-key + +这个过程有许多步骤;对于大部分人来说,只需要回答所有的问题,遵循默认设置就好。当你生成你的密钥时,记下来并将其保存在一个安全的地方,因为如果你丢掉了它,你就不能解密任何消息了。任何关于不要写下密码的建议都是错误的。我们中的大部分人要记住许多登录名和密码,包括那些我们几乎从来不会用到的,所以全部记住它们是不现实的。你知道当人们不写下他们的密码时会发生什么吗?他们会选择生成简单的密码并不断重复使用。你存储在电脑里的任何东西都潜在地会被攻击窃取;一个保存在上锁的柜子里的小本是无法通过渗透获取的,除了物理的入侵,当然入侵者要知道如何去寻找它。 + +我必须叮嘱你们去弄清楚如何使用新密钥去配置邮件客户端,因为每一个都不同。你可以按照如下操作列出你的密钥: + + $ gpg --list-keys + /home/carla/.gnupg/pubring.gpg + ------------------------------ + pub 2048R/587DD0F5 2014-08-13 + uid Carla Schroder (my gpg key) + sub 2048R/AE05E1E4 2014-08-13 + +这能快速地获知像密钥的位置、名称(也就是UID)等必要信息。假设你想要把公钥上传到密钥服务器,可以参考实例操作: + + $ gpg --send-keys 'Carla Schroder' --keyserver http://example.com + +当你为上传到公钥服务器生成了一个新的密钥,你也应该生成一个撤销证书。不要推迟到以后做———当你生成新密钥时就生成它。你可以给它取任意的名称,比如使用一个像mycodeproject.asc的描述性名称来代替revoke.asc: + + $ gpg --output revoke.asc --gen-revoke 'Carla Schroder' + +如果你的密钥缺乏抵抗力,你可以通过向keyring导入撤销证书来撤销它: + + $ gpg --import ~/.gnupg/revoke.asc + +然后生成并上传一个新的密钥来取代它。当它们更新到密钥数据库时,所有使用旧密钥的用户都会被通知。 + +你必须像保护私钥一样保护撤销证书。将它拷贝到CD或USB存储器中,并加锁,然后从电脑中删除。这是明文密钥,所以你甚至可以将它打印出来。 + +如果你需要一份复制粘贴的密钥,比如在允许将密钥粘贴到网页表格中的公用keyring中,或者是想将公钥发布到个人站点上,那么你必须生成一份公钥的ASCII-armored版本: + + $ gpg --output carla-pubkey.asc --export -a 'Carla Schroder' + +这会生成可见的明文公钥,就像下面这个小例子: + + -----BEGIN PGP PUBLIC KEY BLOCK----- + Version: GnuPG v1 + mQENBFPrn4gBCADeEXKdrDOV3AFXL7QQQ+i61rMOZKwFTxlJlNbAVczpawkWRC3l + IrWeeJiy2VyoMQ2ZXpBLDwGEjVQ5H7/UyjUsP8h2ufIJt01NO1pQJMwaOMcS5yTS + [...] + I+LNrbP23HEvgAdNSBWqa8MaZGUWBietQP7JsKjmE+ukalm8jY8mdWDyS4nMhZY= + =QL65 + -----END PGP PUBLIC KEY BLOCK----- + +相信上面的教程应该使你学会如何使用GnuPG。如果不够,[The GnuPG manuals][9]上有使用GnuPG和相关全部配置的详细信息。 + +-------------------------------------------------------------------------------- + +via: http://www.linux.com/learn/tutorials/784165-how-to-encrypt-email-in-linux + +作者:[Carla Schroder][a] +译者:[KayGuoWhu](https://github.com/KayGuoWhu) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://www.linux.com/component/ninjaboard/person/3734 +[1]:http://www.openpgp.org/members/gnupg.shtml +[2]:https://www.torproject.org/ +[3]:https://www.virtru.com/ +[4]:https://www.safemess.com/ +[5]:http://retroshare.sourceforge.net/ +[6]:http://retroshare.sourceforge.net/ +[7]:https://protonmail.ch/ +[8]:http://www.linux.com/learn/docs/718398-protect-yourself-online-with-tor-+tails-and-debian +[9]:https://www.gnupg.org/documentation/manuals.html diff --git a/translated/tech/20140822 15 Practical Examples of 'cd' Command in Linux.md b/translated/tech/20140822 15 Practical Examples of 'cd' Command in Linux.md deleted file mode 100644 index 86e01c1809..0000000000 --- a/translated/tech/20140822 15 Practical Examples of 'cd' Command in Linux.md +++ /dev/null @@ -1,173 +0,0 @@ -15个关于Linux‘cd’命令的练习例子 -=== - -在Linux中,**‘cd‘(改变目录)**命令,是对新手和系统管理员来说,最重要最常用的命令。对管理无屏幕服务器的管理员,‘**cd**‘是引导进入目录,检查日志,执行程序/应用软件/脚本和其余每个任务的唯一方法。对新手来说,是他们必须自己动手学习的最初始命令 - -![15 cd command examples in linux](http://www.tecmint.com/wp-content/uploads/2014/08/cd-command-in-linux.png) -Linux中15个cd命令举例 - -所以,请用心,我们在这会带给你**15**个基础的‘**cd**‘命令,它们富有技巧和捷径,学会使用这些了解到的技巧,会大大减少你在终端上花费的努力和时间 - -### 课程细节 ### - -- 命令名称:cd -- 代表:切换目录 -- 使用平台:所有Linux发行版本 -- 执行方式:命令行 -- 权限:访问自己的目录或者其余指定目录 -- 级别:基础/初学者 - -1. 从当前目录切换到/usr/local - - avi@tecmint:~$ cd /usr/local - - avi@tecmint:/usr/local$ - -2. 使用绝对路径,从当前目录切换到/usr/local/lib - - avi@tecmint:/usr/local$ cd /usr/local/lib - - avi@tecmint:/usr/local/lib$ - -3. 使用相对路径,从当前路径切换到/usr/local/lib - - avi@tecmint:/usr/local$ cd lib - - avi@tecmint:/usr/local/lib$ - -4. **(a)**切换当前目录到上级目录 - -  avi@tecmint:/usr/local/lib$ cd - - - /usr/local - avi@tecmint:/usr/local$ - -4. **(b)**切换当前目录到上级目录 - - avi@tecmint:/usr/local/lib$ cd .. - - avi@tecmint:/usr/local$ - -5. 显示我们最后一个离开的工作目录(使用‘-’选项) - - avi@tecmint:/usr/local$ cd -- - - /home/avi - -6. 从当前目录向上级返回两层 - - avi@tecmint:/usr/local$ cd ../ ../ - - avi@tecmint:/usr$ - -7. 从任何目录返回到用户home目录 - - avi@tecmint:/usr/local$ cd ~ - - avi@tecmint:~$ - - or - - avi@tecmint:/usr/local$ cd - - avi@tecmint:~$ - -8. 切换工作目录到当前工作目录(通常情况下看上去没啥用) - - avi@tecmint:~/Downloads$ cd . - - avi@tecmint:~/Downloads$ - - or - - avi@tecmint:~/Downloads$ cd ./ - - avi@tecmint:~/Downloads$ - -9. 你当前目录是“/usr/local/lib/python3.4/dist-packages”,现在要切换到“home/avi/Desktop/”,要求:一行命令,通过向上一直切换直到‘/’,然后使用绝对路径 - -  avi@tecmint:/usr/local/lib/python3.4/dist-packages$ cd ../../../../../home/avi/Desktop/ - - avi@tecmint:~/Desktop$ - -10. 从当前工作目录切换到/var/www/html,要求:不要将命令打完整,使用TAB - - avi@tecmint:/var/www$ cd /v/w/h - - avi@tecmint:/var/www/html$ - -11. 从当前目录切换到/etc/v__ _,啊呀,你竟然忘了目录的名字,但是你又不想用TAB - - avi@tecmint:~$ cd /etc/v* - - avi@tecmint:/etc/vbox$ - -**请注意:**如果只有一个目录以‘**v**‘开头,这将会移动到‘**vbox**‘。如果有很多目录以‘**v**‘开头,而且命令行中没有提供更多的标准,这将会移动到第一个以‘**v**‘开头的目录(按照他们在标准字典里字母存在的顺序) - -12. 你想切换到用户‘**av**‘(不确定是avi还是avt)目录,不用**TAB** - - avi@tecmint:/etc$ cd /home/av? - - avi@tecmint:~$ - -13. Linux下的pushed和poped - -Pushed和poped是Linux bash命令,也是其他几个能够保存当前工作目录位置至内存,并且从内存读取目录作为当前目录的脚本,这些脚本也可以切换目录 - -  avi@tecmint:~$ pushd /var/www/html - - /var/www/html ~ - - avi@tecmint:/var/www/html$ - -上面的命令保存当前目录到内存,然后切换到要求的目录。一旦poped被执行,它会从内存取出保存的目录位置,作为当前目录 - -  avi@tecmint:/var/www/html$ popd - ~ - avi@tecmint:~$ - -14. 切换到带有空格的目录 - -  avi@tecmint:~$ cd test\ tecmint/ - - avi@tecmint:~/test tecmint$ - - or - - avi@tecmint:~$ cd 'test tecmint' - avi@tecmint:~/test tecmint$ - - or - - avi@tecmint:~$ cd "test tecmint"/ - avi@tecmint:~/test tecmint$ - -15. 从当前目录切换到下载目录,然后列出它所包含的内容(使用一行命令) - -  avi@tecmint:/usr$ cd ~/Downloads && ls - - … - . - service_locator_in.xls - sources.list - teamviewer_linux_x64.deb - tor-browser-linux64-3.6.3_en-US.tar.xz - . - ... - -我们尝试使用最少的词句和一如既往的友好,来让你了解Linux的工作和执行 - -这就是所有内容。我很快会带着另一个有趣的主题回来的。在此之前,保持和Tecmint的联系,别忘了在下面给我们提供你宝贵的反馈和评论 - ---- - -via: http://www.tecmint.com/cd-command-in-linux/ - -作者:[Avishek Kumar][a] -译者:[译者ID](https://github.com/译者ID) -校对:[su-kaiyao](https://github.com/su-kaiyao) - -本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 - -[a]:http://www.tecmint.com/author/avishek/ - diff --git a/translated/tech/20140826 Linux Tutorial--Install Ansible Configuration Management And IT Automation Tool.md b/translated/tech/20140826 Linux Tutorial--Install Ansible Configuration Management And IT Automation Tool.md new file mode 100644 index 0000000000..748ec68ee5 --- /dev/null +++ b/translated/tech/20140826 Linux Tutorial--Install Ansible Configuration Management And IT Automation Tool.md @@ -0,0 +1,466 @@ +Linux 教程:安装 Ansible 配置管理和 IT 自动化工具 +================================================================================ +![](http://s0.cyberciti.org/uploads/cms/2014/08/ansible_core_circle.png) + +今天我来谈谈 ansible,一个由 Python 编写的强大的配置管理解决方案。尽管市面上已经有很多可供选择的配置管理解决方案,但他们各有优劣,而 ansible 的特点就在于它的简洁。让 ansible 在主流的配置管理系统中与众不同的一点便是,它并不需要你在想要配置的每个节点上安装自己的组件。同时提供的一个优点在于,如果需要的话,你可以在不止一个地方控制你的整个基础结构。最后一点是它的正确性,或许这里有些争议,但是我认为在大多数时候这仍然可以作为它的一个优点。说得足够多了,让我们来着手在 RHEL/CentOS 和基于 Debian/Ubuntu 的系统中安装和配置 Ansible. + +### 准备工作 #### + +1. 发行版:RHEL/CentOS/Debian/Ubuntu Linux +1. Jinja2:Python 的一个对设计师友好的现代模板语言 +1. PyYAML:Python 的一个 YAML 编码/反编码函数库 +1. paramiko:纯 Python 编写的 SSHv2 协议函数库 (译者注:原文对函数库名有拼写错误,校对时请去掉此条注解) +1. httplib2:一个功能全面的 HTTP 客户端函数库 +1. 本文中列出的绝大部分操作已经假设你将在 bash 或者其他任何现代的 shell 中以 root 用户执行。 + +Ansible 如何工作 + +Ansible 工具并不使用守护进程,它也不需要任何额外的自定义安全架构,因此它的部署可以说是十分容易。你需要的全部东西便是 SSH 客户端和服务器了。 + + +-----------------+ +---------------+ + |安装了 Ansible 的| SSH | 文件服务器1 | + |Linux/Unix 工作站|<------------------>| 数据库服务器2 | 在本地或远程 + +-----------------+ 模块 | 代理服务器3 | 数据中心的 + 192.168.1.100 +---------------+ Unix/Linux 服务器 + +其中: + +1. 192.168.1.100 - 在你本地的工作站或服务器上安装 Ansible。 +1. 文件服务器1到代理服务器3 - 使用 192.168.1.100 和 Ansible 来自动管理所有的服务器。 +1. SSH - 在 192.168.1.100 和本地/远程的服务器之间设置 SSH 密钥。 + +### Ansible 安装教程 ### + +ansible 的安装轻而易举,许多发行版的第三方软件仓库中都有现成的软件包,可以直接安装。其他简单的安装方法包括使用 pip 安装它,或者从 github 里获取最新的版本。若想使用你的软件包管理器安装,在[基于 RHEL/CentOS Linux 的系统里你很可能需要 EPEL 仓库][1]。 + +#### 在基于 RHEL/CentOS Linux 的系统中安装 ansible #### + +输入如下 [yum 命令][2]: + + $ sudo yum install ansible + +#### 在基于 Debian/Ubuntu Linux 的系统中安装 ansible #### + +输入如下 [apt-get 命令][3]: + + $ sudo apt-get install software-properties-common + $ sudo apt-add-repository ppa:ansible/ansible + $ sudo apt-get update + $ sudo apt-get install ansible + +#### 使用 pip 安装 ansible #### + +[pip 命令是一个安装和管理 Python 软件包的工具][4],比如它能管理 Python Package Index 中的那些软件包。如下方式在 Linux 和类 Unix 系统中通用: + + $ sudo pip install ansible + +#### 从源代码安装最新版本的 ansible #### + +你可以通过如下命令从 github 中安装最新版本: + + $ cd ~ + $ git clone git://github.com/ansible/ansible.git + $ cd ./ansible + $ source ./hacking/env-setup + +当你从一个 git checkout 中运行 ansible 的时候,请记住你每次用它之前都需要设置你的环境,或者你可以把这个设置过程加入你的 bash rc 文件中: + + # 加入 BASH RC + $ echo "export ANSIBLE_HOSTS=~/ansible_hosts" >> ~/.bashrc + $ echo "source ~/ansible/hacking/env-setup" >> ~/.bashrc + +ansible 的 hosts 文件包括了一系列它能操作的主机。默认情况下 ansible 通过路径 /etc/ansible/hosts 查找 hosts 文件,不过这个行为也是可以更改的,这样当你想操作不止一个 ansible 或者针对不同的数据中心的不同客户操作的时候也是很方便的。你可以通过命令行参数 -i 指定 hosts 文件: + + $ ansible all -m shell -a "hostname" --ask-pass -i /etc/some/other/dir/ansible_hosts + +不过我更倾向于使用一个环境变量,这可以在你想要通过 source 一个不同的文件来切换工作目标的时候起到作用。这里的环境变量是 $ANSIBLE_HOSTS,可以这样设置: + + $ export ANSIBLE_HOSTS=~/ansible_hosts + +一旦所有需要的组件都已经安装完毕,而且你也准备好了你的 hosts 文件,你就可以来试一试它了。为了快速测试,这里我把 127.0.0.1 写到了 ansible 的 hosts 文件里: + + $ echo "127.0.0.1" > ~/ansible_hosts + +现在来测试一个简单的 ping: + + $ ansible all -m ping + +或者提示 ssh 密码: + + $ ansible all -m ping --ask-pass + +我在刚开始的设置中遇到过几次问题,因此这里强烈推荐为 ansible 设置 SSH 公钥认证。不过在刚刚的测试中我们使用了 --ask-pass,在一些机器上你会需要[安装 sshpass][5] 或者像这样指定 -c paramiko: + + $ ansible all -m ping --ask-pass -c paramiko + +当然你也可以[安装 sshpass][6],然而 sshpass 并不总是在标准的仓库中提供,因此 paramiko 可能更为简单。 + +### 设置 SSH 公钥认证 ### + +于是我们有了一份配置,以及一些基础的其他东西。现在让我们来做一些实用的事情。ansible 的强大很大程度上体现在 playbooks 上,后者基本上就是一些写好的 ansible 脚本(大部分来说),不过在制作一个 playbook 之前,我们将先从一些一句话脚本开始。现在让我们创建和配置 SSH 公钥认证,以便省去 -c 和 --ask-pass 选项: + + $ ssh-keygen -t rsa + +样例输出: + + Generating public/private rsa key pair. + Enter file in which to save the key (/home/mike/.ssh/id_rsa): + Enter passphrase (empty for no passphrase): + Enter same passphrase again: + Your identification has been saved in /home/mike/.ssh/id_rsa. + Your public key has been saved in /home/mike/.ssh/id_rsa.pub. + The key fingerprint is: + 94:a0:19:02:ba:25:23:7f:ee:6c:fb:e8:38:b4:f2:42 mike@ultrabook.linuxdork.com + The key's randomart image is: + +--[ RSA 2048]----+ + |... . . | + |. . + . . | + |= . o o | + |.* . | + |. . . S | + | E.o | + |.. .. | + |o o+.. | + | +o+*o. | + +-----------------+ + +现在显然有很多种方式来把它放到远程主机上应该的位置。不过既然我们正在使用 ansible,就用它来完成这个操作吧: + + $ ansible all -m copy -a "src=/home/mike/.ssh/id_rsa.pub dest=/tmp/id_rsa.pub" --ask-pass -c paramiko + +样例输出: + + SSH password: + 127.0.0.1 | success >> { + "changed": true, + "dest": "/tmp/id_rsa.pub", + "gid": 100, + "group": "users", + "md5sum": "bafd3fce6b8a33cf1de415af432774b4", + "mode": "0644", + "owner": "mike", + "size": 410, + "src": "/home/mike/.ansible/tmp/ansible-tmp-1407008170.46-208759459189201/source", + "state": "file", + "uid": 1000 + } + +下一步,把公钥文件添加到远程服务器里。输入: + + $ ansible all -m shell -a "cat /tmp/id_rsa.pub >> /root/.ssh/authorized_keys" --ask-pass -c paramiko + +样例输出: + + SSH password: + 127.0.0.1 | FAILED | rc=1 >> + /bin/sh: /root/.ssh/authorized_keys: Permission denied + +矮油,我们需要用 root 来执行这个命令,所以还是加上一个 -u 参数吧: + + $ ansible all -m shell -a "cat /tmp/id_rsa.pub >> /root/.ssh/authorized_keys" --ask-pass -c paramiko -u root + +样例输出: + + SSH password: + 127.0.0.1 | success | rc=0 >> + +请注意,我刚才这是想要演示通过 ansible 来传输文件的操作。事实上 ansible 有一个更加方便的内置 SSH 密钥管理支持: + + $ ansible all -m authorized_key -a "user=mike key='{{ lookup('file', '/home/mike/.ssh/id_rsa.pub') }}' path=/home/mike/.ssh/authorized_keys manage_dir=no" --ask-pass -c paramiko + +样例输出: + + SSH password: + 127.0.0.1 | success >> { + "changed": true, + "gid": 100, + "group": "users", + "key": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCq+Z8/usprXk0aCAPyP0TGylm2MKbmEsHePUOd7p5DO1QQTHak+9gwdoJJavy0yoUdi+C+autKjvuuS+vGb8+I+8mFNu5CvKiZzIpMjZvrZMhHRdNud7GuEanusTEJfi1pUd3NA2iXhl4a6S9a/4G2mKyf7QQSzI4Z5ddudUXd9yHmo9Yt48/ASOJLHIcYfSsswOm8ux1UnyeHqgpdIVONVFsKKuSNSvZBVl3bXzhkhjxz8RMiBGIubJDBuKwZqNSJkOlPWYN76btxMCDVm07O7vNChpf0cmWEfM3pXKPBq/UBxyG2MgoCGkIRGOtJ8UjC/daadBUuxg92/u01VNEB mike@ultrabook.linuxdork.com", + "key_options": null, + "keyfile": "/home/mike/.ssh/authorized_keys", + "manage_dir": false, + "mode": "0600", + "owner": "mike", + "path": "/home/mike/.ssh/authorized_keys", + "size": 410, + "state": "file", + "uid": 1000, + "unique": false, + "user": "mike" + } + +现在这些密钥已经设置好了。我们来试着随便跑一个命令,比如 hostname,希望我们不会被提示要输入密码 + + $ ansible all -m shell -a "hostname" -u root + +样例输出: + + 127.0.0.1 | success | rc=0 >> + +成功!!!现在我们可以用 root 来执行命令,并且不会被输入密码的提示干扰了。我们现在可以轻易地配置任何在 ansible hosts 文件中的主机了。让我们把 /tmp 中的公钥文件删除: + + $ ansible all -m file -a "dest=/tmp/id_rsa.pub state=absent" -u root + +样例输出: + + 127.0.0.1 | success >> { + "changed": true, + "path": "/tmp/id_rsa.pub", + "state": "absent" + } + +下面我们来做一些更复杂的事情,我要确定一些软件包已经安装了,并且已经是最新的版本: + + $ ansible all -m zypper -a "name=apache2 state=latest" -u root + +样例输出: + + 127.0.0.1 | success >> { + "changed": false, + "name": "apache2", + "state": "latest" + } + +很好,我们刚才放在 /tmp 中的公钥文件已经消失了,而且我们已经安装好了最新版的 apache。下面我们来看看前面命令中的 -m zypper,一个让 ansible 非常灵活,并且给了 playbooks 更多能力的功能。如果你不使用 openSuse 或者 Suse enterprise 你可能还不熟悉 zypper, 它基本上就是 suse 世界中相当于 yum 的存在。在上面所有的例子中,我的 hosts 文件中都只有一台机器。除了最后一个命令外,其他所有命令都应该在任何标准的 *nix 系统和标准的 ssh 配置中使用,这造成了一个问题。如果我们想要同时管理多种不同的机器呢?这便是 playbooks 和 ansible 的可配置性闪闪发光的地方了。首先我们来少许修改一下我们的 hosts 文件: + + $ cat ~/ansible_hosts + +样例输出: + + [RHELBased] + 10.50.1.33 + 10.50.1.47 + + [SUSEBased] + 127.0.0.1 + +首先,我们创建了一些分组的服务器,并且给了他们一些有意义的标签。然后我们来创建一个为不同类型的服务器执行不同操作的 playbook。你可能已经发现这个 yaml 的数据结构和我们之前运行的命令行语句中的相似性了。简单来说,-m 是一个模块,而 -a 用来提供模块参数。在 YAML 表示中你可以先指定模块,然后插入一个冒号 :,最后指定参数。 + + --- + - hosts: SUSEBased + remote_user: root + tasks: + - zypper: name=apache2 state=latest + - hosts: RHELBased + remote_user: root + tasks: + - yum: name=httpd state=latest + +现在我们有一个简单的 playbook 了,我们可以这样运行它: + + $ ansible-playbook testPlaybook.yaml -f 10 + +样例输出: + + PLAY [SUSEBased] ************************************************************** + + GATHERING FACTS *************************************************************** + ok: [127.0.0.1] + + TASK: [zypper name=apache2 state=latest] ************************************** + ok: [127.0.0.1] + + PLAY [RHELBased] ************************************************************** + + GATHERING FACTS *************************************************************** + ok: [10.50.1.33] + ok: [10.50.1.47] + + TASK: [yum name=httpd state=latest] ******************************************* + changed: [10.50.1.33] + changed: [10.50.1.47] + + PLAY RECAP ******************************************************************** + 10.50.1.33 : ok=2 changed=1 unreachable=0 failed=0 + 10.50.1.47 : ok=2 changed=1 unreachable=0 failed=0 + 127.0.0.1 : ok=2 changed=0 unreachable=0 failed=0 + +注意,你会看到 ansible 联系到的每一台机器的输出。-f 参数让 ansible 在多台主机上同时运行指令。除了指定全部主机,或者一个主机分组的名字以外,你还可以把导入 ssh 公钥的操作从命令行里转移到 playbook 中,这将在设置新主机的时候提供很大的方便,甚至让新主机直接可以运行一个 playbook。为了演示,我们把我们之前的公钥例子放进一个 playbook 里: + + --- + - hosts: SUSEBased + remote_user: mike + sudo: yes + tasks: + - authorized_key: user=root key="{{ lookup('file', '/home/mike/.ssh/id_rsa.pub') }}" path=/root/.ssh/authorized_keys manage_dir=no + - hosts: RHELBased + remote_user: mdonlon + sudo: yes + tasks: + - authorized_key: user=root key="{{ lookup('file', '/home/mike/.ssh/id_rsa.pub') }}" path=/root/.ssh/authorized_keys manage_dir=no + +除此之外还有很多可以做的事情,比如在启动的时候把公钥配置好,或者引入其他的流程来让你按需配置一些机器。不过只要 SSH 被配置成接受密码登陆,这些几乎可以用在所有的流程中。在你准备开始写太多 playbook 之前,另一个值得考虑的事情是,代码管理可以有效节省你的时间。机器需要不断变化,然而你并不需要在每次机器发生变化时都重新写一个 playbook,只需要更新相关的部分并提交这些修改。与此相关的另一个好处是,如同我之前所述,你可以从不同的地方管理你的整个基础结构。你只需要将你的 playbook 仓库 git clone 到新的机器上,就完成了管理所有东西的全部设置流程。 + +#### 现实中的 ansible 例子 #### + +我知道很多用户经常使用 pastebin 这样的服务,以及很多公司基于显而易见的理由配置了他们内部使用的类似东西。最近,我遇到了一个叫做 showterm 的程序,巧合之下我被一个客户要求配置它用于内部使用。这里我不打算赘述这个应用程序的细节,不过如果你感兴趣的话,你可以使用 Google 搜索 showterm。作为一个合理的现实中的例子,我将会试图配置一个 showterm 服务器,并且配置使用它所需要的客户端应用程序。在这个过程中我们还需要一个数据库服务器。现在我们从配置客户端开始: + + --- + - hosts: showtermClients + remote_user: root + tasks: + - yum: name=rubygems state=latest + - yum: name=ruby-devel state=latest + - yum: name=gcc state=latest + - gem: name=showterm state=latest user_install=no + +这部分很简单。下面是主服务器: + + --- + - hosts: showtermServers + remote_user: root + tasks: + - name: ensure packages are installed + yum: name={{item}} state=latest + with_items: + - postgresql + - postgresql-server + - postgresql-devel + - python-psycopg2 + - git + - ruby21 + - ruby21-passenger + - name: showterm server from github + git: repo=https://github.com/ConradIrwin/showterm.io dest=/root/showterm + - name: Initdb + command: service postgresql initdb + creates=/var/lib/pgsql/data/postgresql.conf + + - name: Start PostgreSQL and enable at boot + service: name=postgresql + enabled=yes + state=started + - gem: name=pg state=latest user_install=no + handlers: + - name: restart postgresql + service: name=postgresql state=restarted + + - hosts: showtermServers + remote_user: root + sudo: yes + sudo_user: postgres + vars: + dbname: showterm + dbuser: showterm + dbpassword: showtermpassword + tasks: + - name: create db + postgresql_db: name={{dbname}} + + - name: create user with ALL priv + postgresql_user: db={{dbname}} name={{dbuser}} password={{dbpassword}} priv=ALL + - hosts: showtermServers + remote_user: root + tasks: + - name: database.yml + template: src=database.yml dest=/root/showterm/config/database.yml + - hosts: showtermServers + remote_user: root + tasks: + - name: run bundle install + shell: bundle install + args: + chdir: /root/showterm + - hosts: showtermServers + remote_user: root + tasks: + - name: run rake db tasks + shell: 'bundle exec rake db:create db:migrate db:seed' + args: + chdir: /root/showterm + - hosts: showtermServers + remote_user: root + tasks: + - name: apache config + template: src=showterm.conf dest=/etc/httpd/conf.d/showterm.conf + +还凑合。请注意,从某种意义上来说这是一个任意选择的程序,然而我们现在已经可以持续地在任意数量的机器上部署它了,这便是配置管理的好处。此外,在大多数情况下这里的定义语法几乎是不言而喻的,wiki 页面也就不需要加入太多细节了。当然在我的观点里,一个有太多细节的 wiki 页面绝不会是一件坏事。 + +### 扩展配置 ### + +我们并没有涉及到这里所有的细节。Ansible 有许多选项可以用来配置你的系统。你可以在你的 hosts 文件中内嵌变量,而 ansible 将会把它们应用到远程节点。如: + + [RHELBased] + 10.50.1.33 http_port=443 + 10.50.1.47 http_port=80 ansible_ssh_user=mdonlon + + [SUSEBased] + 127.0.0.1 http_port=443 + +尽管这对于快速配置来说已经非常方便,你还可以将变量分成存放在 yaml 格式的多个文件中。在你的 hosts 文件路径里,你可以创建两个子目录 group_vars 和 host_vars。在这些路径里放置的任何文件,只要能对得上一个主机分组的名字,或者你的 hosts 文件中的一个主机名,它们都会在运行时被插入进来。所以前面的一个例子将会变成这样: + + ultrabook:/etc/ansible # pwd + /etc/ansible + ultrabook:/etc/ansible # tree + . + ├── group_vars + │ ├── RHELBased + │ └── SUSEBased + ├── hosts + └── host_vars + ├── 10.50.1.33 + └── 10.50.1.47 + +---------- + + 2 directories, 5 files + ultrabook:/etc/ansible # cat hosts + [RHELBased] + 10.50.1.33 + 10.50.1.47 + +---------- + + [SUSEBased] + 127.0.0.1 + ultrabook:/etc/ansible # cat group_vars/RHELBased + ultrabook:/etc/ansible # cat group_vars/SUSEBased + --- + http_port: 443 + ultrabook:/etc/ansible # cat host_vars/10.50.1.33 + --- + http_port: 443 + ultrabook:/etc/ansible # cat host_vars/10.50.1.47 + --- + http_port:80 + ansible_ssh_user: mdonlon + +### 改善 Playbooks ### + +组织 playbooks 也已经有很多种现成的方式。在前面的例子中我们用了一个单独的文件,因此这方面被大幅地简化了。组织这些文件的一个常用方式是创建角色。简单来说,你将一个主文件加载为你的 playbook,而它将会从其它文件中导入所有的数据,这些其他的文件便是角色。举例来说,如果你有了一个 wordpress 网站,你需要一个 web 前端,和一个数据库。web 前端将包括一个 web 服务器,应用程序代码,以及任何需要的模块。数据库有时候运行在同一台主机上,有时候运行在远程的主机上,这时候角色就可以派上用场了。你创建一个目录,并对每个角色创建对应的小 playbook。在这个例子中我们需要一个 apache 角色,mysql 角色,wordpress 角色,mod_php,以及 php 角色。最大的好处是,并不是每个角色都必须被应用到同一台机器上。在这个例子中,mysql 可以被应用到一台单独的机器。这同样为代码重用提供了可能,比如你的 apache 角色还可以被用在 python 和其他相似的 php 应用程序中。展示这些已经有些超出了本文的范畴,而且做一件事总是有很多不同的方式,我建议搜索一些 ansible 的 playbook 例子。有很多人在 github 上贡献代码,当然还有其他一些网站。 + +### 模块 ### + +在 ansible 中,对于所有完成的工作,幕后的工作都是由模块主导的。Ansible 有一个非常丰富的内置模块仓库,其中包括软件包安装,文件传输,以及我们在本文中做的所有事情。但是对一部分人来说,这些并不能满足他们的配置需求,ansible 也提供了方法让你添加自己的模块。Ansible 的 API 有一个非常棒的事情是,它并没有限制模块也必须用编写它的语言 Python 来编写,也就是说,你可以用任何语言来编写模块。Ansible 模块通过传递 JSON 数据来工作,因此你只需要用想用的语言生成一段 JSON 数据。我很确定任何脚本语言都可以做到这一点,因此你现在就可以开始写点什么了。在 Ansible 的网站上有很多的文档,包括模块的接口是如何工作的,以及 Github 上也有很多模块的例子。注意一些小众的语言可能没有很好的支持,不过那只可能是因为没有多少人在用这种语言贡献代码。试着写点什么,然后把你的结果发布出来吧! + +### 总结 ### + +总的来说,虽然在配置管理方面已经有很多解决方案,我希望本文能显示出 ansible 简单的设置过程,在我看来这是它最重要的一个要点。请注意,因为我试图展示做一件事的不同方式,所以并不是前文中所有的例子都是适用于你的个别环境或者对于普遍情况的最佳实践。这里有一些链接能让你对 ansible 的了解进入下一个层次: + +- [Ansible 项目][7]主页. +- [Ansible 项目文档][8]. +- [多级环境与 Ansible][9]. + + + + +-------------------------------------------------------------------------------- + +via: http://www.cyberciti.biz/python-tutorials/linux-tutorial-install-ansible-configuration-management-and-it-automation-tool/ + +作者:[Nix Craft][a] +译者:[felixonmars](https://github.com/felixonmars) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://www.cyberciti.biz/tips/about-us +[1]:http://www.cyberciti.biz/faq/fedora-sl-centos-redhat6-enable-epel-repo/ +[2]:http://www.cyberciti.biz/faq/rhel-centos-fedora-linux-yum-command-howto/ +[3]:http://www.cyberciti.biz/tips/linux-debian-package-management-cheat-sheet.html +[4]:http://www.cyberciti.biz/faq/debian-ubuntu-centos-rhel-linux-install-pipclient/ +[5]:http://www.cyberciti.biz/faq/noninteractive-shell-script-ssh-password-provider/ +[6]:http://www.cyberciti.biz/faq/noninteractive-shell-script-ssh-password-provider/ +[7]:http://www.ansible.com/ +[8]:http://docs.ansible.com/ +[9]:http://rosstuck.com/multistage-environments-with-ansible/ diff --git a/translated/tech/20140828 Setup Thin Provisioning Volumes in Logical Volume Management (LVM)--Part IV.md b/translated/tech/20140828 Setup Thin Provisioning Volumes in Logical Volume Management (LVM)--Part IV.md new file mode 100644 index 0000000000..63a86c598d --- /dev/null +++ b/translated/tech/20140828 Setup Thin Provisioning Volumes in Logical Volume Management (LVM)--Part IV.md @@ -0,0 +1,212 @@ +在逻辑卷管理中设置精简资源调配卷——第四部分 +================================================================================ +逻辑卷管理有许多特性,比如像快照和精简资源调配。在先前(第三部分中),我们已经介绍了如何为逻辑卷创建快照。在本文中,我们将了解如何在LVM中设置精简资源调配。 + +![Setup Thin Provisioning in LVM](http://www.tecmint.com/wp-content/uploads/2014/08/Setup-Thin-Provisioning-in-LVM.jpg) +在LVM中设置精简资源调配 + +### 精简资源调配是什么? ### +精简资源调配用于lvm以在精简池中创建虚拟磁盘。我们假定我服务器上有**15GB**的存储容量,而我已经有2个客户各自占去了5GB存储空间。你是第三个客户,你也请求5GB的存储空间。在以前,我们会提供整个5GB的空间(富卷)。然而,你可能只使用5GB中的2GB,其它3GB以后再去填满它。 + +而在精简资源调配中我们所做的是,在其中一个大卷组中定义一个精简池,再在精简池中定义一个精简卷。这样,不管你写入什么文件,它都会保存进去,而你的存储空间看上去就是5GB。然而,这所有5GB空间不会全部铺满整个硬盘。对其它客户也进行同样的操作,就像我说的,那儿已经有两个客户,你是第三个客户。 + +那么,让我们想想,我到底为客户分配了总计多少GB的空间呢?所有15GB的空间已经全部分配完了,如果现在有某个人来问我是否能提供5GB空间,我还可以分配给他么?答案是“可以”。在精简资源调配中,我可以为第四位客户分配5GB空间,即使我已经把那15GB的空间分配完了。 + +**警告**:从那15GB空间中,如果我们对资源调配超过15GB了,那就是过度资源调配了。 + +### 它是怎么工作的?我们又是怎样为客户提供存储空间的? ### + +我已经提供给你5GB空间,但是你可能只用了2GB,而其它3GB还空闲着。在富资源调配中,我们不能这么做,因为它一开始就分配了整个空间。 + +在精简资源调配中,如果我为你定义了5GB空间,它就不会在定义卷时就将整个磁盘空间全部分配,它会根据你的数据写入而增长,希望你看懂了!跟你一样,其它客户也不会使用全部卷,所以还是有机会为一个新客户分配5GB空间的,这称之为过度资源调配。 + +但是,必须对各个卷的增长情况进行监控,否则结局会是个灾难。在过度资源调配完成后,如果所有4个客户都极度地写入数据到磁盘,你将碰到问题了。因为这个动作会填满15GB的存储空间,甚至溢出,从而导致这些卷下线。 + +### 需求 ### + +注:此三篇文章如果发布后可换成发布后链接,原文在前几天更新中 + +- [使用LVM在Linux中创建逻辑卷——第一部分][1] +- [在Linux中扩展/缩减LVM——第二部分][2] +- [在LVM中创建/恢复逻辑卷快照——第三部分][3] + +#### 我的服务器设置 #### + + 操作系统 — 安装有LVM的CentOS 6.5 + 服务器IP — 192.168.0.200 + +### 步骤1: 设置精简池和卷 ### + +理论讲太多了,让我们还是来点实际的吧,我们一起来设置精简池和精简卷。首先,我们需要一个大尺寸的卷组。这里,我创建了一个**15GB**的卷组用于演示。现在,用下面的命令来列出卷组。 + + # vgcreate -s 32M vg_thin /dev/sdb1 + +![Listing Volume Group](http://www.tecmint.com/wp-content/uploads/2014/08/Listing-Volume-Group.jpg) +列出卷组 + +接下来,在创建精简池和精简卷之前,检查逻辑卷有多少空间可用。 + + # vgs + # lvs + +![Check Logical Volume](http://www.tecmint.com/wp-content/uploads/2014/08/check-Logical-Volume.jpg) +检查逻辑卷 + +我们可以在上面的lvs命令输出中看到,只显示了一些默认逻辑用于文件系统和交换分区。 + +### 创建精简池 ### + +使用以下命令在卷组(vg_thin)中创建一个15GB的精简池。 + + # lvcreate -L 15G --thinpool tp_tecmint_pool vg_thin + +- **-L** – 卷组大小 +- **–thinpool** – 创建精简池 +- **tp_tecmint_poolThin** - 精简池名称 +- **vg_thin** – 我们需要创建精简池的卷组名称 + +![Create Thin Pool](http://www.tecmint.com/wp-content/uploads/2014/08/Create-Thin-Pool.jpg) +创建精简池 + +使用‘lvdisplay’命令来查看详细信息。 + + # lvdisplay vg_thin/tp_tecmint_pool + +![Logical Volume Information](http://www.tecmint.com/wp-content/uploads/2014/08/Logical-Volume-Information.jpg) +逻辑卷信息 + +这里,我们还没有在该精简池中创建虚拟精简卷。在图片中,我们可以看到分配的精简池数据为**0.00%**。 + +### 创建精简卷 ### + +现在,我们可以在带有-V(Virtual)选项的‘lvcreate’命令的帮助下,在精简池中定义精简卷了。 + + # lvcreate -V 5G --thin -n thin_vol_client1 vg_thin/tp_tecmint_pool + +我已经在我的**vg_thin**卷组中的**tp_tecmint_pool**内创建了一个精简虚拟卷,取名为**thin_vol_client1**。现在,使用下面的命令来列出逻辑卷。 + + # lvs + +![List Logical Volumes](http://www.tecmint.com/wp-content/uploads/2014/08/List-Logical-Volumes.jpg) +列出逻辑卷 + +刚才,我们已经在上面创建了精简卷,这就是为什么没有数据,显示为**0.00%M**。 + +好吧,让我为其它2个客户再创建2个精简卷。这里,你可以看到在精简池(**tp_tecmint_pool**)下有3个精简卷了。所以,从这一点上看,我们开始明白,我已经使用所有15GB的精简池。 + +![Create Thin Volumes](http://www.tecmint.com/wp-content/uploads/2014/08/Create-Thin-Volumes.jpg) + +### 创建文件系统 ### + +现在,使用下面的命令为这3个精简卷创建挂载点并挂载,然后拷贝一些文件进去。 + + # mkdir -p /mnt/client1 /mnt/client2 /mnt/client3 + +列出创建的目录。 + + # ls -l /mnt/ + +![Creating Mount Points](http://www.tecmint.com/wp-content/uploads/2014/08/Creating-Mount-Points.jpg) +创建挂载点 + +使用‘mkfs’命令为这些创建的精简卷创建文件系统。 + + # mkfs.ext4 /dev/vg_thin/thin_vol_client1 && mkfs.ext4 /dev/vg_thin/thin_vol_client2 && mkfs.ext4 /dev/vg_thin/thin_vol_client3 + +![Create File System](http://www.tecmint.com/wp-content/uploads/2014/08/Create-File-System.jpg) +创建文件系统 + +使用‘mount’命令来挂载所有3个客户卷到创建的挂载点。 + + # mount /dev/vg_thin/thin_vol_client1 /mnt/client1/ && mount /dev/vg_thin/thin_vol_client2 /mnt/client2/ && mount /dev/vg_thin/thin_vol_client3 /mnt/client3/ + +使用‘df’命令来列出挂载点。 + + # df -h + +![Print Mount Points](http://www.tecmint.com/wp-content/uploads/2014/08/Print-Mount-Points.jpg) +打印挂载点 + +这里,我们可以看到所有3个客户卷已经挂载了,而每个客户卷只使用了3%的数据空间。那么,让我们从桌面添加一些文件到这3个挂载点,以填充一些空间。 + +![Add Files To Volumes](http://www.tecmint.com/wp-content/uploads/2014/08/Add-Files-To-Volumes.jpg) +添加文件到卷 + +现在列出挂载点,并查看每个精简卷使用的空间,然后列出精简池来查看池中已使用的大小。 + + # df -h + # lvdisplay vg_thin/tp_tecmint_pool + +![Check Mount Point Size](http://www.tecmint.com/wp-content/uploads/2014/08/Check-Mount-Point-Size.jpg) +检查挂载点大小 + +![Check Thin Pool Size](http://www.tecmint.com/wp-content/uploads/2014/08/Check-Thin-Pool-Size.jpg) +检查精简池大小 + +上面的命令显示了3个挂载点及其使用大小百分比。 + + 13% of datas used out of 5GB for client1 + 29% of datas used out of 5GB for client2 + 49% of datas used out of 5GB for client3 + +在查看精简池时,我们看到总共只有**30%**的数据被写入,这是上面3个客户虚拟卷的总使用量。 + +### 过度资源调配 ### + +现在,**第四个**客户来申请5GB的存储空间。我能给他吗?因为我已经把15GB的池分配给了3个客户。能不能再给另外一个客户分配5GB的空间呢?可以,这完全可能。在我们使用**过度资源调配**时,就可以实现。过度资源调配可以给我们比我们所拥有的更大的空间。 + +让我来为第四位客户创建5GB的空间,然后再验证一下大小吧。 + + # lvcreate -V 5G --thin -n thin_vol_client4 vg_thin/tp_tecmint_pool + # lvs + +![Create thin Storage](http://www.tecmint.com/wp-content/uploads/2014/08/Create-thin-Storage.jpg) +创建精简存储 + +在精简池中,我只有15GB大小的空间,但是我已经在精简池中创建了4个卷,其总量达到了20GB。如果4个客户都开始写入数据到他们的卷,并将空间填满,到那时我们将面对严峻的形势。如果不填满空间,那不会有问题。 + +现在,我已经创建在**thin_vol_client4**中创建了文件系统,然后挂载到了**/mnt/client4**下,并且拷贝了一些文件到里头。 + + # lvs + +![Verify Thin Storage](http://www.tecmint.com/wp-content/uploads/2014/08/Verify-Thing-Storage.jpg) +验证精简存储 + +我们可以在上面的图片中看到,新创建的client 4总计使用空间达到了**89.34%**,而精简池的已用空间达到了**59.19**。如果所有这些用户不在过度对卷写入,那么它就不会溢出,下线。要避免溢出,我们需要扩展精简池大小。 + +**重要**:精简池只是一个逻辑卷,因此,如果我们需要对其进行扩展,我们可以使用和扩展逻辑卷一样的命令,但我们不能缩减精简池大小。 + + # lvextend + +这里,我们可以看到怎样来扩展逻辑精简池(**tp_tecmint_pool**)。 + + # lvextend -L +15G /dev/vg_thin/tp_tecmint_pool + +![Extend Thin Storage](http://www.tecmint.com/wp-content/uploads/2014/08/Extend-Thin-Storage.jpg) +扩展精简存储 + +接下来,列出精简池大小。 + + # lvs + +![Verify Thin Storage](http://www.tecmint.com/wp-content/uploads/2014/08/Verify-Thin-Storage.jpg) +验证精简存储 + +前面,我们的**tp_tecmint_pool**大小为15GB,而在对第四个精简卷进行过度资源配置后达到了20GB。现在,它扩展到了30GB,所以我们的过度资源配置又回归常态,而精简卷也不会溢出,下线了。通过这种方式,我们可以添加更多的精简卷到精简池中。 + +在本文中,我们已经了解了怎样来使用一个大尺寸的卷组创建一个精简池,以及怎样通过过度资源配置在精简池中创建精简卷和扩着精简池。在下一篇文章中,我们将介绍怎样来移除逻辑卷。 + +-------------------------------------------------------------------------------- + +via: http://www.tecmint.com/setup-thin-provisioning-volumes-in-lvm/ + +作者:[Babin Lonston][a] +译者:[GOLinux](https://github.com/GOLinux) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://www.tecmint.com/author/babinlonston/ +[1]:http://www.tecmint.com/create-lvm-storage-in-linux/ +[2]:http://www.tecmint.com/extend-and-reduce-lvms-in-linux/ +[3]:http://www.tecmint.com/take-snapshot-of-logical-volume-and-restore-in-lvm/ diff --git a/translated/tech/20140829 6 Interesting Funny Commands of Linux (Fun in Terminal) – Part II.md b/translated/tech/20140829 6 Interesting Funny Commands of Linux (Fun in Terminal) – Part II.md new file mode 100644 index 0000000000..b42da05894 --- /dev/null +++ b/translated/tech/20140829 6 Interesting Funny Commands of Linux (Fun in Terminal) – Part II.md @@ -0,0 +1,108 @@ +6个有趣的命令行工具(终端中的乐趣) - 第二部分 +================================================================================ +在之前, 我们给出类一些有关有趣的 Linux 命令行命令的文章, 这些文章告诉我们, Linux 并不像看起来那样复杂, 如果我们知道如何使用的话, 反而会非常有趣. Linux 命令行可以简洁而完美地执行一些复杂的任务, 并且十分有趣. + +- [Linux命令及Linux终端的20个趣事][3] +- [Fun in Linux Terminal – Play with Word and Character Counts][2] + +![Funny Linux Commands](http://www.tecmint.com/wp-content/uploads/2014/08/Funny-Linux-Commands.png) +有趣的 Linux 命令 + +之前的一篇文章包含了 20 个有趣的 Linux 命令/脚本(和子命令), 得到了读者的高度赞扬. 而另一篇文章则包含了一些处理文字文件, 单词和字符串的命令/脚本和改进, 虽然没有之前那篇文章那么受欢迎. + +这篇文章介绍了一些新的有趣的命令和单行脚本. + +### 1. pv 命令 ### + +你也许曾经看见电影里的模仿文字, 它们好像是被实时打出来的. 如果我么能在终端里实现这样的效果, 那不是很好? + +这是可以做到的. 我们可以安装通过 '**apt**' 或者 '**yum**' 工具在 Linux 系统上安装 '**pv**' 命令. 安装命令如下? + + # yum install pv [在基于 RedHat 的系统上] + + # sudo apt-get install pv [在基于 Debian 的系统上] + +'**pv**' 命令安装成功之后, 我们尝试输入下面的命令来在终端查看实时文字输出的效果. + + $ echo "Tecmint[dot]com is a community of Linux Nerds and Geeks" | pv -qL 10 + +![pv command in action](http://www.tecmint.com/wp-content/uploads/2014/08/pv-command.gif) +正在运行的 pv 命令 + +**注意**: '**q**' 选项表示'安静'(没有其他输出信息), '**L**' 选项表示每秒转化的字节数上限. 数字变量(必须是整数)用来调整预设的文本模拟.(To be fixed: 这里翻译有问题) + +### 2. toilet 命令 ### + +用单行命令 '**toilet**' 在终端里显示有边框的文字值一个不错的主意. 同样, 你必须保证 '**toilet**' 已经安装在你的电脑上. 如果没有的话, 请使用 apt 或 yum 安装. (译者注: 'toilet' 并不在 Fedora 的官方仓库里, 你可以从 github 上下载源代码来安装) + + $ while true; do echo “$(date | toilet -f term -F border –Tecmint)”; sleep 1; done + +![toilet command in action](http://www.tecmint.com/wp-content/uploads/2014/08/toilet-command.gif) +正在运行的 toilet 命令 + +**注意**: 上面的脚本需要使用 **ctrl+z** 键来暂停. + +### 3. rig 命令 ### + +这个命令每次生成一个随机的身份信息和地址. 要运行这个命令, 你需要用 apt 或 yum 安装 '**rig**'. (译者注: 'rig' 不在 Fedora 的官方仓库中, 我只在 rpmseek 上找到了 Ubuntu 的 deb 包, 可以使用它来安装.) + + # rig + +![rig command in action](http://www.tecmint.com/wp-content/uploads/2014/08/rig-command.gif) +正在运行的 rig 命令 + +### 4. aview 命令 ### + +你认为在终端用 ASCII 格式显示图片怎么样? 我们必须用 apt 或 yum 安装软件包 '**aview**'. (译者注: 'avieww' 不在 Fedora 的官方仓库中, 可以从 aview 的[项目主页][4]上下载源代码来安装. ) 在当前文件夹下有一个名为 '**elephant.jpg**' 的图片, 我想用 ASCII 模式在终端查看. + + $ asciiview elephant.jpg -driver curses + +![aview command in action](http://www.tecmint.com/wp-content/uploads/2014/08/elephant.gif) +正在运行的 aview 命令 + +### 5. xeyes 命令 ### + +在上一篇文章中, 我们介绍了 '**oneko**' 命令, 它可以显示一个追随鼠标指针运动的小老鼠. '**xeyes**' 是一个类似的程序, 当你运行程序时, 你可以看见两个怪物的眼球追随鼠标的运动. + + $ xeyes + +![xeyes command in action](http://www.tecmint.com/wp-content/uploads/2014/08/xeyes.gif) +正在运行的 xeyes 命令 + +### 6. cowsay 命令 ### + +你是否还记得上一次我们介绍的这个命令? 它可以显示一段预先确定的文本和一个字符构成的奶牛. 如果你想使用其它动物来代替奶牛怎么办? 查看可用的动物列表: + + $ cowsay -l + +蟒蛇吃大象怎么样? + + $ cowsay -f elephant-in-snake Tecmint is Best + +![cowsay command in action](http://www.tecmint.com/wp-content/uploads/2014/08/cowsay.gif) +正在运行的 cowsay 命令 + +山羊怎么样? + + $ cowsay -f gnu Tecmint is Best + +![cowsay goat in action](http://www.tecmint.com/wp-content/uploads/2014/08/cowsay-goat.gif) +正在运行的 山羊cowsay 命令 + +今天就到这里吧. 我将带着另一篇有趣的文章回来. 跟踪 Tecmint 来获得最新消息. 不要忘记在下面的评论里留下你的有价值的回复. + +-------------------------------------------------------------------------------- + +via: http://www.tecmint.com/linux-funny-commands/ + +作者:[Avishek Kumar][a] +译者:[wangjiezhe](https://github.com/wangjiezhe) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://www.tecmint.com/author/avishek/ +[1]:http://www.tecmint.com/20-funny-commands-of-linux-or-linux-is-fun-in-terminal/ +[2]:http://www.tecmint.com/play-with-word-and-character-counts-in-linux/ +[3]:http://linux.cn/article-2831-1.html +[4]:http://aa-project.sourceforge.net/aview/ diff --git a/translated/tech/20140901 How to install and configure ownCloud on Debian.md b/translated/tech/20140901 How to install and configure ownCloud on Debian.md new file mode 100644 index 0000000000..84755fe8e1 --- /dev/null +++ b/translated/tech/20140901 How to install and configure ownCloud on Debian.md @@ -0,0 +1,209 @@ +如何在Debian上安装配置ownCloud +================================================================================ +据其官方网站,ownCloud可以让你通过一个网络接口或者WebDAV访问你的文件。它还提供了一个平台,可以轻松地查看、编辑和同步您所有设备的通讯录、日历和书签。尽管ownCloud与广泛使用Dropbox非常相似,但主要区别在于ownCloud是免费的,开源的,从而可以自己的服务器上建立与Dropbox类似的云存储服务。使用ownCloud你可以完整地访问和控制您的私人数据而对存储空间没有限制(除了硬盘容量)或者连客户端的连接数量。 + +ownCloud提供了社区版(免费)和企业版(面向企业的有偿支持)。预编译的ownCloud社区版可以提供了CentOS、Debian、Fedora、openSUSE、,SLE和Ubuntu版本。本教程将演示如何在Debian Wheezy上安装和在配置ownCloud社区版。 + +### 在Debian上安装 ownCloud ### + +进入官方网站:[http://owncloud.org][1],并点击‘Install’按钮(右上角)。 + +![](https://farm4.staticflickr.com/3885/14884771598_323f2fc01c_z.jpg) + +为当前的版本选择“Packages for auto updates”(下面的图是v7)。这可以让你轻松的让你使用的ownCloud与Debian的包管理系统保持一致,包是由ownCloud社区维护的。 + +![](https://farm6.staticflickr.com/5589/15071372505_298a796ff6_z.jpg) + +在下一屏职工点击继续: + +![](https://farm6.staticflickr.com/5589/14884818527_554d1483f9_z.jpg) + +在可用的操作系统列表中选择Debian 7 [Wheezy]: + +![](https://farm6.staticflickr.com/5581/14884669449_433e3334e0_z.jpg) + +加入ownCloud的官方Debian仓库: + + # echo 'deb http://download.opensuse.org/repositories/isv:/ownCloud:/community/Debian_7.0/ /' >> /etc/apt/sources.list.d/owncloud.list + +加入仓库密钥到apt中: + + # wget http://download.opensuse.org/repositories/isv:ownCloud:community/Debian_7.0/Release.key + # apt-key add - < Release.key + +继续安装ownCLoud: + + # aptitude update + # aptitude install owncloud + +打开你的浏览器并定位到你的ownCloud实例中,地址是http:///owncloud: + +![](https://farm4.staticflickr.com/3869/15071011092_f8f32ffe11_z.jpg) + +注意ownCloud可能会包一个Apache配置错误的警告。使用下面的步骤来解决这个错误来摆脱这些错误信息。 + +a) 编辑 the /etc/apache2/apache2.conf (设置 AllowOverride 为 All): + + + Options Indexes FollowSymLinks + AllowOverride All + Order allow,deny + Allow from all + + +b) 编辑 the /etc/apache2/conf.d/owncloud.conf + + + Options Indexes FollowSymLinks MultiViews + AllowOverride All + Order allow,deny + Allow from all + + +c) 重启web服务器: + + # service apache2 restart + +d) 刷新浏览器,确认安全警告已经消失 + +![](https://farm6.staticflickr.com/5562/14884771428_fc9c063418_z.jpg) + +### 设置数据库 ### + +是时候为ownCloud设置数据库了。 + +首先登录本地的MySQL/MariaDB数据库: + + $ mysql -u root -h localhost -p + +为ownCloud创建数据库和用户账户。 + + mysql> CREATE DATABASE owncloud_DB; + mysql> CREATE USER ‘owncloud-web’@'localhost' IDENTIFIED BY ‘whateverpasswordyouchoose’; + mysql> GRANT ALL PRIVILEGES ON owncloud_DB.* TO ‘owncloud-web’@'localhost'; + mysql> FLUSH PRIVILEGES; + +通过http:///owncloud 进入ownCloud页面,并选择‘Storage & database’ 选项。输入所需的信息(MySQL/MariaDB用户名,密码,数据库和主机名),并点击完成按钮。 + +![](https://farm6.staticflickr.com/5584/15071010982_b76c23c384_z.jpg) + +### 为ownCloud配置SSL连接 ### + +在你开始使用ownCloud之前,强烈建议你在ownCloud中启用SSL支持。使用SSL可以提供重要的安全好处,比如加密ownCloud流量并提供适当的验证。在本教程中,将会为SSL使用一个自签名的证书。 + +创建一个储存服务器密钥和证书的目录: + + # mkdir /etc/apache2/ssl + +创建一个证书(并有一个密钥来保护它),它有一年的有效期。 + + # openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout /etc/apache2/ssl/apache.key -out /etc/apache2/ssl/apache.crt + +![](https://farm6.staticflickr.com/5587/15068784081_f281b54b72_z.jpg) + +编辑/etc/apache2/conf.d/owncloud.conf 启用HTTPS。对于余下的NC、R和L重写规则的意义,你可以参考[Apache 文档][2]: + + Alias /owncloud /var/www/owncloud + + + RewriteEngine on + ReWriteCond %{SERVER_PORT} !^443$ + RewriteRule ^/(.*) https://%{HTTP_HOST}/$1 [NC,R,L] + + + + SSLEngine on + SSLCertificateFile /etc/apache2/ssl/apache.crt + SSLCertificateKeyFile /etc/apache2/ssl/apache.key + DocumentRoot /var/www/owncloud/ + + Options Indexes FollowSymLinks MultiViews + AllowOverride All + Order allow,deny + Allow from all + + + +启用重写模块并重启Apache: + + # a2enmod rewrite + # service apache2 restart + +打开你的ownCloud实例。注意一下,即使你尝试使用HTTP,你也会自动被重定向到HTTPS。 + +注意,即使你已经按照上述步骤做了,在你启动ownCloud你仍将看到一条错误消息,指出该证书尚未被受信的机构颁发(那是因为我们创建了一个自签名证书)。您可以放心地忽略此消息,但如果你考虑在生产服务器上部署ownCloud,你可以从一个值得信赖的公司购买证书。 + +### 创建一个账号 ### + +现在我们准备创建一个ownCloud管理员帐号了。 + +![](https://farm6.staticflickr.com/5587/15048366536_430b4fd64e.jpg) + +欢迎来自你的个人云!注意你可以安装一个桌面或者移动端app来同步你的文件、日历、通讯录或者更多了。 + +![](https://farm4.staticflickr.com/3862/15071372425_c391d912f5_z.jpg) + +在右上叫,点击你的用户名,会显示一个下拉菜单: + +![](https://farm4.staticflickr.com/3897/15071372355_3de08d2847.jpg) + +点击Personal来改变你的设置,比如密码,显示名,email地址、头像还有更多。 + +### ownCloud 使用案例:访问日历 ### + +让我开始添加一个事件到日历中并稍后下载。 + +点击左上角的下拉菜单并选择日历。 + +![](https://farm4.staticflickr.com/3891/15048366346_7dcc388244.jpg) + +添加一个时间并保存到你的日历中。 + +![](https://farm4.staticflickr.com/3882/14884818197_f55154fd91_z.jpg) + +通过 'Event and Tasks' -> 'Import...' -> 'Select file' 下载你的日历并添加到你的Thunderbird日历中: + +![](https://farm4.staticflickr.com/3840/14884818217_16a53400f0_z.jpg) + +![](https://farm4.staticflickr.com/3871/15048366356_a7f98ca63d_z.jpg) + +提示:你还需要设置你的时区以便在其他程序中成功地导入你的日历(默认情况下,日历程序将使用UTC+00:00时区)。要更改时区在左下角点击小齿轮图标,接着日历设置菜单就会出现,你就可以选择时区了: + +![](https://farm4.staticflickr.com/3858/14884669029_4e0cd3e366.jpg) + +### ownCloud 使用案例:上传一个文件 ### + +接下来,我们会从本机上传一个文件 + +进入文件菜单(左上角)并点击向上箭头来打开一个选择文件对话框。 + +![](https://farm4.staticflickr.com/3851/14884818067_4a4cc73b40.jpg) + +选择一个文件并点击打开。 + +![](https://farm6.staticflickr.com/5591/14884669039_5a9dd00ca9_z.jpg) + +接下来你就可以打开/编辑选中的文件,把它移到另外一个文件夹或者删除它了。 + +![](https://farm4.staticflickr.com/3909/14884771088_d0b8a20ae2_o.png) + +### 总结 ### + +ownCloud是一个灵活和强大的云存储,可以从其他供应商快速、简便、无痛的过渡。此外,它是开源软件,你只需要很少有时间和精力对其进行配置以满足你的所有需求。欲了解更多信息,可以随时参考[用户][3]、[管理][4]或[开发][5]手册。 + +-------------------------------------------------------------------------------- + +via: http://xmodulo.com/2014/08/install-configure-owncloud-debian.html + +作者:[Gabriel Cánepa][a] +译者:[geekpi](https://github.com/geekpi) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://www.gabrielcanepa.com.ar/ +[1]:http://owncloud.org/ +[2]:http://httpd.apache.org/docs/2.2/rewrite/flags.html +[3]:http://doc.owncloud.org/server/7.0/ownCloudUserManual.pdf +[4]:http://doc.owncloud.org/server/7.0/ownCloudAdminManual.pdf +[5]:http://doc.owncloud.org/server/7.0/ownCloudDeveloperManual.pdf \ No newline at end of file diff --git a/translated/tech/20140902 Photo Editing on Linux with Krita.md b/translated/tech/20140902 Photo Editing on Linux with Krita.md new file mode 100644 index 0000000000..f61e9bc7cc --- /dev/null +++ b/translated/tech/20140902 Photo Editing on Linux with Krita.md @@ -0,0 +1,76 @@ +在 Linux 下用 Krita 进行照片编辑 +================================================================================ +
+
图 1:侏儒山羊 Annabelle
+ +[Krita][1] 是一款很棒的绘图应用,同时也是很不错的照片编辑器。今天我们将学习如何给图片添加文字,以及如何有选择的锐化照片的某一部分。 + +### Krita 简介 ### + +与其他绘图/制图应用类似,Krita 内置了数百种工具和选项,以及多种处理手段。因此让我们来花点时间了解一下。 + +Krita 默认使用了暗色主题。我不太喜欢暗色主题,但幸运的是 Krita 还有其他很赞的主题,你可以在任何时候通过菜单里的“设置 > 主题”进行更改。 + +Krita 使用了窗口停靠样式的工具条。如果左右两侧面板的 Dock 工具条没有显示,检查一下“设置 > 显示工具条”选项,你也可以在“设置 > 工具条”中对工具条按你的偏好进行调整。不过隐藏的工具条也许会让你感到一些小小的不快,它们只会在一个狭小的压扁区域展开,你看不见其中的任何东西。你可以拖动他们至顶端或者 Krita 窗口的一侧,扩展或者收缩它们,甚至你可以把他们拖到 Krita 外,拖到你显示屏的任意位置。如果你把其中一个工具条拖到了另一个工具条上,它们会自动合并成一个工具条。 + +当你配置好比较满意的工作区后,你可以在“选择工作区”内保存它。你可以在笔刷工具条(通过“设置 > 显示工具条”开启显示)的右侧找到“选择工作区”。其中有对工作区的不同配置,当然你也可以创建自己的配置(图 2)。 + +
+
图 2:在“选择工作区”里保存用户定制的工作区。
+ +Krita 中有多重缩放控制手段。Ctrl + “=” 放大,Ctrl + “-” 缩小,Ctrl + “0” 重置为 100% 缩放画面。你也可以通过“视图 > 缩放”,或者右下角的缩放条进行控制。在缩放条的左侧还有一个下拉式的缩放菜单。 + +工具菜单位于窗口左部,其中包含了锐化和选择工具。你最好移动你的鼠标到每个工具上,查看一下标签。工具选项条总是显示当前正在使用的工具的选项,默认情况下工具选项条位于窗口右部。 + +### 裁切工具 ### + +当然,在工具菜单条中有裁切工具,并且非常易于使用。用矩形选取把你所要选择的区域圈定,使用拖拽的方式来调整选区,调整完毕后点击返回按钮。在工具选项条中,你可以选择对所有图层应用裁切,还是只对当前图层应用裁切,通过输入具体数值,或者是百分比调整尺寸。 + +### 添加文本 ### + +当你想在照片上添加标签或者说明这类简单文本的时候,Krita 也许会让你感到不知所措,因为它有太多的艺术字效果可供选择了。但 Krita 同时也支持添加简单的文字。点击文本工具条,你将会看到工具选项条如图 3 那样。 + +
+
图 3:文本选项。
+ +点击展开按钮。这将显示简单文本工具;首先绘制矩形文本框,接着在文本框内输入文字。工具选项条中有所有常用的文本格式选项:文本选择、文本尺寸、文字与背景颜色、边距,以及一系列图形风格。但你处理完文本后点击外观处理工具,外观处理工具的按钮是一个白色的箭头,在文本工具按钮旁边,通过外观处理工具你可以调整文字整体的尺寸、外观还有位置。外观处理工具的工具选项包括多种不同的线条、颜色还有边距。图 4 为我向蜗居在城市里的亲戚发送的带有愉快标题的照片。 + +
+
图 4:来这绿色农场吧。
+ +如何处理你的照片上已经存在的文字?点击外观处理工具,在文本区域内双击。这将使文本进入编辑模式,从文本框内出现的光标可以看出这一点。现在,你就可以开始选择文字、添加文字、更改格式,等等。 + +### 锐化选区 ### + +外观编辑上,Krita 有许多很棒的工具。在图 5 中我想要锐化 Annabelle 的脸和眼睛。(Annabelle 住在隔壁,但她很喜欢我的狗,在我这里呆了很长一段时间。我的狗却因为害怕她而跑了,但她却一点也不气馁。)首先通过“外形选区”工具选择一个区域。接着打开“滤镜 > 增强 > 虚边蒙板”。你可以调节三个变量:半长值、总量以及阈值。大多数图像编辑软件都有半径、总量和阀值的设置。半径是直径的一半,因此从技术上来说“半长值”是正确的,但却可能造成不必要的混乱。 + +
+
图 5:选取任意的区域进行编辑。
+ +半长值决定了锐化线条的粗细。你需要足够大的数值来产生较好的结果,但很明显,不要过大。 + +阀值决定了锐化时两个像素点之间的效果差异。“0”是锐化的最大值,“99”则表示不进行锐化。 + +总量控制着锐化强度;其值越高锐化程度越高。 + +锐化基本上是你处理照片的最后一步,因为它和你对照片所做的一切处理都有关:裁切、改变尺寸、颜色、色差...如果你先进行锐化再进行其他操作,你的锐化效果将变得一团糟。 + +接着,你要问,“虚化蒙板”是什么意思?这个名字来源于锐化技术:虚化蒙板滤镜在原始图像上覆盖一层模糊的蒙板,接着在上面分层进行虚化蒙板。这将使图像比直接锐化产生更加锐利清晰的效果。 + +今天要说的就这么多。有关 Krita 的很多,但很杂。你可以从 [Krita Tutorials][2] 开始学习,也可以在网上找寻相关的学习视频。 + +- [krita 官方网站][1] + +-------------------------------------------------------------------------------- + +via: http://www.linux.com/learn/tutorials/786040-photo-editing-on-linux-with-krita + +作者:[Carla Schroder][a] +译者:[SteveArcher](https://github.com/SteveArcher) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://www.linux.com/community/forums/person/3734 +[1]:https://krita.org/ +[2]:https://krita.org/learn/tutorials/ \ No newline at end of file diff --git a/translated/tech/20140904 Use LaTeX In Ubuntu 14.04 and Linux Mint 17 With Texmaker.md b/translated/tech/20140904 Use LaTeX In Ubuntu 14.04 and Linux Mint 17 With Texmaker.md new file mode 100644 index 0000000000..af974647be --- /dev/null +++ b/translated/tech/20140904 Use LaTeX In Ubuntu 14.04 and Linux Mint 17 With Texmaker.md @@ -0,0 +1,47 @@ +在Ubuntu 14.04和拥有Texmaker的Linux Mint 17(基于ubuntu和debian的Linux发行版)中使用LaTeX +================================================================================ +![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/09/texmaker_Ubuntu.jpeg) + +[LaTeX][1]是一种文本标记语言,也可以说是一种文档制作系统。经常在很多大学或者机构中作为一种标准来书写专业的科学文献,毕业论文或其他类似的文档。在这篇文章中,我们会看到如何在Ubuntu 14.04中使用LaTeX。 + +### 在Ubuntu 14.04或Linux Mint 17中安装Texmaker + +[Texmaker][2]是一款免费开源的LaTeX编辑器,它支持一些主流的桌面操作系统,比如Window,Linux和OS X。下面是Texmaker的主要特点: + +- 支持Unicode编码的编辑器 +- 拼写检查 +- 代码折叠 +- 自动补全 +- 快速导航 +- PDF查看器 +- 编译简单 +- 支持370个数学符号 +- LaTeX格式文本 +- 通过TeX4ht导出到html和odt文件 +- 支持正则表达式 + +在Ubuntu 14.04下,你可以通过下面的链接下载Texmaker的二进制包 + +- [下载Texmaker编辑器][3] + +你通过链接下载到的是一个.deb包,因此你在一些像Linux Mint,Elementary OS,Pinguy OS等等类Debain的发行版中可以使用相同的安装方式。 + +如果你想使用像Github类型的markdown编辑器,你可以试试[Remarkable编辑器][4]。 + +希望Texmaker能够在Ubuntu和Linux Mint中帮到你 + +-------------------------------------------------------------------------------- + +via: http://itsfoss.com/install-latex-ubuntu-1404/ + +作者:[Abhishek][a] +译者:[john](https://github.com/johnhoow) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://itsfoss.com/author/Abhishek/ +[1]:http://www.latex-project.org/ +[2]:http://www.xm1math.net/texmaker/index.html +[3]:http://www.xm1math.net/texmaker/download.html#linux +[4]:http://itsfoss.com/remarkable-markdown-editor-linux/ diff --git a/translated/tech/20140910 How to download GOG games from the command line on Linux.md b/translated/tech/20140910 How to download GOG games from the command line on Linux.md new file mode 100644 index 0000000000..8ed3e8e792 --- /dev/null +++ b/translated/tech/20140910 How to download GOG games from the command line on Linux.md @@ -0,0 +1,75 @@ +如何在Linux命令行中下载GOG游戏 +================================================================================ +如果你是一个玩家同时也是一个Linux用户,你可能很高兴在[GOG][1]在几个月前宣布它会在你最喜欢的操作系统上推出游戏。如果你之前从来没有听说过GOG,我鼓励你看看他们的产品目录中的“很棒的老游戏”,价格合理,无DRM限制,而且充满了很棒的东西。然而现在的Windows上的GOG存在了很长的时间按,正式的Linux版本却是无处可见。因此,你不想等待官方的正式版本,一个名为LGOGDownloader非官方的开放源码计划能让你在命令行中访问你的库。 + +![](https://farm4.staticflickr.com/3843/15121593356_b13309c70f_z.jpg) + +### 在Linux中安装 LGOGDownloader ### + +对于Ubuntu用户来说,[官方页面][2]建议您下载源代码并执行: + + $ sudo apt-get install build-essential libcurl4-openssl-dev liboauth-dev libjsoncpp-dev libhtmlcxx-dev libboost-system-dev libboost-filesystem-dev libboost-regex-dev libboost-program-options-dev libboost-date-time-dev libtinyxml-dev librhash-dev help2man + $ tar -xvzf lgogdownloader-2.17.tar.gz + $ cd lgogdownloader-2.17 + $ make release + $ sudo make install + +如果你是ArchLinux用户。有一个[AUR 包][2]等着你 + +### LGOGDownloader 的使用### + +一旦安装了该程序,你需要用下面的命令登录: + + $ lgogdownloader --login + +![](https://farm6.staticflickr.com/5593/15121593346_9c5d02d5ce_z.jpg) + +如果你需要配置文件,那它在这里:~/.config/lgogdownloader/config.cfg + +验证通过后,你可以列出你库中所有的游戏: + + $ lgogdownloader --list + +![](https://farm6.staticflickr.com/5581/14958040387_8321bb71cf.jpg) + +用下面的命令下载游戏: + + $ lgogdownloader --download --game [game name] + +![](https://farm6.staticflickr.com/5585/14958040367_b1c584a2d1_z.jpg) + +你可以注意到lgogdownloader允许你恢复之前中断的下载,这当下载的游戏并不小时是很有用的。 + +像每一个可敬的命令行实用程序,您可以添加各种选项: + +- **--platform [number]** 选择您的操作系统,1是 Windows, 4是Linux。 +- **--directory [destination]** 下载安装包到指定的目录。 +- **--language [number]** 下载特定的语言包 (根据你的语言查阅手册上对应的数字)。 +- **--limit-rate [speed]** 限制下载速度。 + +一个额外的福利,lgogdownloader同样可以检查GOG网站上的更新: + + $ lgogdownloader --update-check + +![](https://farm4.staticflickr.com/3882/14958035568_7889acaef0.jpg) + +结果将列出论坛上收到的私人邮件的数量以及更新的游戏数量。 + +最后,lgogdownloader是非常标准的命令行实用工具。我甚至可以说,它是清晰和连贯性的一个缩影。我们距离Steam Linux客户端的确还差的很远,但在另一方面,官方GOG Windows客户端不会做的比这个非官方的Linux版本更多。换句话说lgogdownloader是一个完美的替代品。我等不及要看到GOG上更多的Linux兼容游戏,尤其是在他们最近公告称会提供的无DRM电影,会有视频游戏的专题。希望在电影目录中有游戏库时能在客户端看到更新。 + +你觉得GOG怎么样?你会使用非官方的Linux客户端么?让我们在评论中知道你的想法。 + +-------------------------------------------------------------------------------- + +via: http://xmodulo.com/2014/09/download-gog-games-command-line-linux.html + +作者:[Adrien Brochard][a] +译者:[geekpi](https://github.com/geekpi) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://xmodulo.com/author/adrien +[1]:http://www.gog.com/ +[2]:https://sites.google.com/site/gogdownloader/home +[3]:https://aur.archlinux.org/packages/lgogdownloader/ \ No newline at end of file diff --git a/translated/tech/20140910 How to set up Nagios Remote Plugin Executor (NRPE) in Linux.md b/translated/tech/20140910 How to set up Nagios Remote Plugin Executor (NRPE) in Linux.md new file mode 100644 index 0000000000..611d69ad8c --- /dev/null +++ b/translated/tech/20140910 How to set up Nagios Remote Plugin Executor (NRPE) in Linux.md @@ -0,0 +1,236 @@ +如何在 Linux 环境下配置 Nagios Remote Plugin Executor (NRPE) +================================================================================ +就网络管理而言,Nagios 是最强大的工具之一。Nagios 可以监控远程主机的可访问性,以及其中正在运行的服务的状态。不过,如果我们想要监控远程主机中网络服务以外的东西呢?比方说,我们可能想要监控远程主机上的磁盘利用率或者 [CPU 处理器负载][1]。Nagios Remote Plugin Executor(NRPE)便是一个可以帮助你完成这些操作的工具。NRPE 允许你执行在远程主机上安装的 Nagios 插件,并且将它们集成到一个[已经存在的 Nagios 服务器][2]里。 + +本教程将会介绍如何在一个已经部署好的 Nagios 中配置 NRPE。本教程主要分为两部分: + +- 配置远程主机。 +- 配置 Nagios 监控服务器。 + +之后我们会以定义一些可以被 NRPE 使用的自定义命令来结束本教程。 + +### 为 NRPE 配置远程主机 ### + +#### 第一步:安装 NRPE 服务 #### + +你需要在你想要使用 NRPE 监控的每一台远程主机上安装 NRPE 服务。每一台远程主机上的 NRPE 服务守护进程将会与一台 Nagios 监控服务器进行通信。 + +取决于所在的平台, NRPE 服务所需要的软件包可以很容易地用 apt-get 或者 yum 来安装。对于 CentOS 来说,由于 NRPE 并不在 CentOS 的仓库中,我们需要[添加 Repoforge 仓库][3]。 + +**对于 Debian、Ubuntu 或者 Linux Mint:** + + # apt-get install nagios-nrpe-server + +**对于 CentOS、Fedora 或者 RHEL:** + + # yum install nagios-nrpe + +#### 第二步:准备配置文件 #### + +配置文件 /etc/nagios/nrpe.cfg 在基于 Debian 或者 RedHat 的系统中比较相近。让我们备份并修改配置文件: + + # vim /etc/nagios/nrpe.cfg + +---------- + + ## NRPE 服务端口是可以自定义的 ## + server_port=5666 + + ## 允许 Nagios 监控服务器访问 ## + ## 注意:逗号后面没有空格 ## + allowed_hosts=127.0.0.1,X.X.X.X-IP_v4_of_Nagios_server + + ## 下面的例子中我们硬编码了参数。 + ## 这些参数可以按需修改。 + + ## 注意:对于 CentOS 64 位用户,请使用 /usr/lib64 替代 /usr/lib ## + + command[check_users]=/usr/lib/nagios/plugins/check_users -w 5 -c 10 + command[check_load]=/usr/lib/nagios/plugins/check_load -w 15,10,5 -c 30,25,20 + command[check_hda1]=/usr/lib/nagios/plugins/check_disk -w 20% -c 10% -p /dev/hda1 + command[check_zombie_procs]=/usr/lib/nagios/plugins/check_procs -w 5 -c 10 -s Z + command[check_total_procs]=/usr/lib/nagios/plugins/check_procs -w 150 -c 200 + +现在配置文件已经准备好了,NRPE 服务已经可以启动了。 + +#### 第三步:初始化 NRPE 服务 #### + +对于基于 RedHat 的系统,NRPE 服务需要被添加为启动服务。 + +**对于 Debian、Ubuntu、Linux Mint:** + + # service nagios-nrpe-server restart + +**对于 CentOS、Fedora 或者 RHEL:** + + # service nrpe restart + # chkconfig nrpe on + +#### 第四步:验证 NRPE 服务状态 #### + +NRPE 守护进程的状态信息可以在系统日志中找到。对于基于 Debian 的系统,日志文件在 /var/log/syslog,而基于 RedHat 的系统的日志文件则是 /var/log/messages。下面提供一段样例日志以供参考: + + nrpe[19723]: Starting up daemon + nrpe[19723]: Listening for connections on port 5666 + nrpe[19723]: Allowing connections from: 127.0.0.1,X.X.X.X + +如果使用了防火墙,被 NRPE 守护进程使用的 TCP 端口 5666 应该被开启。 + + # netstat -tpln | grep 5666 + +---------- + + tcp 0 0 0.0.0.0:5666 0.0.0.0:* LISTEN 19885/nrpe + +### 为 NRPE 配置 Nagios 监控服务器 ### + +为 NRPE 配置已有的 Nagios 监控服务器的第一步是在服务器上安装 NRPE 插件。 + +#### 第一步:安装 NRPE 插件 #### + +当 Nagios 服务器运行在基于 Debian 的系统(Debian、Ubuntu 或者 Linux Mint)上时,需要的软件宝可以通过 apt-get 安装。 + + # apt-get install nagios-nrpe-plugin + +插件安装完成后,对随插件安装的 check_nrpe 命令稍作修改。 + + # vim /etc/nagios-plugins/config/check_nrpe.cfg + +---------- + + ## 默认命令会被覆盖 ## + define command{ + command_name check_nrpe + command_line /usr/lib/nagios/plugins/check_nrpe -H '$HOSTADDRESS$' -c '$ARG1$' + } + +如果 Nagios 服务器运行在基于 RedHat 的系统(CentOS、Fedora 或者 RHEL)上,你可以通过 yum 安装 NRPE 插件。对于 CentOS,[添加 Repoforge 仓库][4] 是必要的。 + + # yum install nagios-plugins-nrpe + +现在 NRPE 插件已经安装完成,继续下面的步骤以配置一台 Nagios 服务器。 + +#### 第二步:为 NRPE 插件定义 Nagios 命令 #### + +我们需要首先在 Nagios 中定义一个命令来使用 NRPE。 + + # vim /etc/nagios/objects/commands.cfg + +---------- + + ## 注意:对于 CentOS 64 位用户,请使用 /usr/lib64 替代 /usr/lib ## + define command{ + command_name check_nrpe + command_line /usr/lib/nagios/plugins/check_nrpe -H '$HOSTADDRESS$' -c '$ARG1$' + } + +#### 第三步:添加主机与命令定义 #### + +接下来定义远程主机以及我们将要在它们上面运行的命令。 + +下面的例子为一台远程主机定义了一个可以在上面执行的命令。一般来说,你的配置需要按照你的需求来改变。配置文件的路径在基于 Debian 和基于 RedHat 的系统上略有不同,不过文件的内容是完全一样的。 + +**对于 Debian、Ubuntu 或者 Linux Mint:** + + # vim /etc/nagios3/conf.d/nrpe.cfg + +**对于 CentOS、Fedora 或者 RHEL:** + + # vim /etc/nagios/objects/nrpe.cfg + +---------- + + define host{ + use linux-server + host_name server-1 + alias server-1 + address X.X.X.X-IPv4_address_of_remote_host + } + + define service { + host_name server-1 + service_description Check Load + check_command check_nrpe!check_load + check_interval 1 + use generic-service + } + +#### 第四步:重启 Nagios 服务 #### + +在重启 Nagios 之前,可以通过测试来验证配置。 + +**对于 Ubuntu、Debian 或者 Linux Mint:** + + # nagios3 -v /etc/nagios3/nagios.cfg + +**对于 CentOS、Fedora 或者 RHEL:** + + # nagios -v /etc/nagios/nagios.cfg + +如果一切正常,我们就可以重启 Nagios 服务了。 + + # service nagios restart + +![](https://farm8.staticflickr.com/7024/13330387845_0bde8b6db5_z.jpg) + +### 为 NRPE 配置自定义命令 ### + +#### 远程服务器上的配置 #### + +下面列出了一些可以用于 NRPE 的自定义命令。这些命令在远程服务器的 /etc/nagios/nrpe.cfg 文件中定义。 + + ## 当 1、5、15 分钟的平均负载分别超过 1、2、1 时进入警告状态 + ## 当 1、5、15 分钟的平均负载分别超过 3、5、3 时进入严重警告状态 + command[check_load]=/usr/lib/nagios/plugins/check_load -w 1,2,1 -c 3,5,3 + + ## 对于 /home 目录的可用空间设置了警告级别为 25%,以及严重警告级别为 10%。 + ## 可以定制为监控任何分区(比如 /dev/sdb1、/、/var、/home) + command[check_disk]=/usr/lib/nagios/plugins/check_disk -w 25% -c 10% -p /home + + ## 当 process_ABC 的实例数量超过 10 时警告,超过 20 时严重警告 ## + command[check_process_ABC]=/usr/lib/nagios/plugins/check_procs -w 1:10 -c 1:20 -C process_ABC + + ## 当 process_ABC 的实例数量跌到 1 以下时严重警告 ## + command[check_process_XYZ]=/usr/lib/nagios/plugins/check_procs -w 1: -c 1: -C process_XYZ + +#### Nagios 监控服务器上的配置 #### + +我们通过修改 Nagios 监控服务器里的服务定义来应用上面定义的自定义命令。服务定义可以写在所有服务被定义的地方(比如 /etc/nagios/objects/nrpe.cfg 或 /etc/nagios3/conf.d/nrpe.cfg) + + ## 示例 1:检查进程 XYZ ## + define service { + host_name server-1 + service_description Check Process XYZ + check_command check_nrpe!check_process_XYZ + check_interval 1 + use generic-service + } + + ## 示例 2:检查磁盘状态 ## + define service { + host_name server-1 + service_description Check Process XYZ + check_command check_nrpe!check_disk + check_interval 1 + use generic-service + } + +总而言之,NRPE 是 Nagios 的一个强大的扩展,它提供了高度可定制的远程服务器监控方案。使用 NRPE,我们可以监控系统的负载、运行的进程、已登录的用户、磁盘状态,以及其它的指标。 + +希望这些可以帮到你。 + +-------------------------------------------------------------------------------- + +via: http://xmodulo.com/2014/03/nagios-remote-plugin-executor-nrpe-linux.html + +作者:[Sarmed Rahman][a] +译者:[felixonmars](https://github.com/felixonmars) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://xmodulo.com/author/sarmed +[1]:http://xmodulo.com/2012/08/how-to-measure-average-cpu-utilization.html +[2]:http://xmodulo.com/2013/12/install-configure-nagios-linux.html +[3]:http://xmodulo.com/2013/01/how-to-set-up-rpmforge-repoforge-repository-on-centos.html +[4]:http://xmodulo.com/2013/01/how-to-set-up-rpmforge-repoforge-repository-on-centos.html diff --git a/translated/tech/20140915 Linux FAQs with Answers--How to capture TCP SYN, ACK and FIN packets with tcpdump.md b/translated/tech/20140915 Linux FAQs with Answers--How to capture TCP SYN, ACK and FIN packets with tcpdump.md new file mode 100644 index 0000000000..f0f638a7cd --- /dev/null +++ b/translated/tech/20140915 Linux FAQs with Answers--How to capture TCP SYN, ACK and FIN packets with tcpdump.md @@ -0,0 +1,41 @@ +Linux有问必答——如何使用tcpdump来捕获TCP SYN,ACK和FIN包 +================================================================================ +> **问题**:我想要监控TCP连接活动(如,建立连接的三次握手,以及断开连接的四次握手)。要完成此事,我只需要捕获TCP控制包,如SYN,ACK或FIN标记相关的包。我怎样使用tcpdump来仅仅捕获TCP SYN,ACK和/或FYN包? + +作为事实上的捕获工具,tcpdump提供了强大而又灵活的包过滤功能。作为tcpdump基础的libpcap包捕获引擎支持标准的包过滤规则,如基于5重包头的过滤(如基于源/目的IP地址/端口和IP协议类型)。 + +tcpdump/libpcap的包过滤规则也支持更多通用分组表达式,在这些表达式中,包中的任意字节范围都可以使用关系或二进制操作符进行检查。对于字节范围表达,你可以使用以下格式: + + proto [ expr : size ] + +“proto”可以是熟知的协议之一(如ip,arp,tcp,udp,icmp,ipv6),“expr”表示与指定的协议头开头相关的字节偏移量。有我们熟知的直接偏移量如tcpflags,也有取值常量如tcp-syn,tcp-ack或者tcp-fin。“size”是可选的,表示从字节偏移量开始检查的字节数量。 + +使用这种格式,你可以像下面这样过滤TCP SYN,ACK或FIN包。 + +只捕获TCP SYN包: + + # tcpdump -i "tcp[tcpflags] & (tcp-syn) != 0" + +只捕获TCP ACK包: + + # tcpdump -i "tcp[tcpflags] & (tcp-ack) != 0" + +只捕获TCP FIN包: + + # tcpdump -i "tcp[tcpflags] & (tcp-fin) != 0" + +之捕获TCP SYN或ACK包: + + # tcpdump -r "tcp[tcpflags] & (tcp-syn|tcp-ack) != 0" + +![](https://farm4.staticflickr.com/3923/15050566798_db14aea9a9_z.jpg) + +-------------------------------------------------------------------------------- + +via: http://ask.xmodulo.com/capture-tcp-syn-ack-fin-packets-tcpdump.html + +作者:[作者名][a] +译者:[GOLinux](https://github.com/GOLinux) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 diff --git a/translated/tech/20140915 Linux FAQs with Answers--How to create a new Amazon AWS access key.md b/translated/tech/20140915 Linux FAQs with Answers--How to create a new Amazon AWS access key.md new file mode 100644 index 0000000000..d872155a9c --- /dev/null +++ b/translated/tech/20140915 Linux FAQs with Answers--How to create a new Amazon AWS access key.md @@ -0,0 +1,49 @@ +Linux有问必答——如何创建新的亚马逊AWS访问密钥 +================================================================================ +> **问题**:我在配置一个需要访问我的亚马逊AWS帐号的应用时被要求提供**AWS访问密钥ID**和**秘密访问密钥**,我怎样创建一个新的AWS访问密钥呢? + +亚马逊AWS安全凭证用于验证你以及授权任何第三方应用访问你的AWS帐号,有各种不同的AWS安全凭证可用,如密码、访问密钥、多因素身份验证、X.509证书等。 + +如果你想要创建新的访问密钥(访问密钥ID和秘密访问密钥),请按一下步骤进行。 + +首先,登录到[AWS控制台][1]。 + +从顶部栏选择“安全凭证”菜单(图中红色方框所示)。 + +![](https://farm4.staticflickr.com/3855/14987093969_b106406596_o.png) + +在下一页中,选择“访问密钥(访问密钥ID和秘密访问密钥)”选项(图中红色方框所示)。 + +![](https://farm6.staticflickr.com/5584/15173842295_6110021f8f_z.jpg) + +在下一页中,你将看到一个现存访问密钥ID列表(如果有的话)。注意,你不能恢复现存访问密钥ID的“秘密访问密钥”。出于安全的原因,秘密访问密钥只能在你创建新访问密钥时才可见。 + +![](https://farm4.staticflickr.com/3897/15150859306_cd25d519be_o.png) + +点击“创建新访问密钥”(见图示),将会立即创建一个新的访问密钥ID和密码访问密钥对。 + +![](https://farm4.staticflickr.com/3919/14987346068_232e8c73cd_z.jpg) + +要么下载一个包含有新访问密钥的密钥文件,要么复制并粘贴新访问密钥信息。再次提请牢记,一旦你关闭该窗口,秘密访问密钥将不再可用,除非你下载一个密钥文件。 + +### 多用户AWS帐号 ### +如果你是作为公司身份创建的帐号,多个雇员共享这一公司帐号,你可能想要使用身份和访问管理(IAM)来创建并管理他们的访问密钥。 + +IAM是一个web服务,它允许一个公司管理多个用户及其与一个AWS帐号关联的安全凭证。使用IAM,多个用户可以作为不同身份登入单一的AWS帐号,并管理他们的安全凭证而不会相互干预对方的密钥。 + +要管理IAM用户,点击“安全凭证”页面上的“用户”菜单(见图示)。 + +![](https://farm6.staticflickr.com/5589/14987486468_a9120b1f8e_z.jpg) + +然后,你就可以创建一个新的IAM用户并管理他们的安全凭证,比如访问密钥之类的东西。 + +-------------------------------------------------------------------------------- + +via: http://ask.xmodulo.com/create-amazon-aws-access-key.html + +译者:[GOLinux](https://github.com/GOLinux) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[1]:http://aws.amazon.com/console/ diff --git a/translated/tech/20140915 Linux FAQs with Answers--How to expand an XFS file system.md b/translated/tech/20140915 Linux FAQs with Answers--How to expand an XFS file system.md new file mode 100644 index 0000000000..f56cc00ed6 --- /dev/null +++ b/translated/tech/20140915 Linux FAQs with Answers--How to expand an XFS file system.md @@ -0,0 +1,38 @@ +Linux有问必答——如何扩展XFS文件系统 +================================================================================ +> **问题**:我的磁盘上有额外的空间,所以我想要扩展其上创建的现存的XFS文件系统,以完全使用额外空间。怎样才是扩展XFS文件系统的正确途径? + +XFS是一个开源的(GPL)日子文件系统,最初由硅谷图形开发,现在被大多数的Linux发行版都支持。事实上,XFS已经被最新的CentOS/RHEL 7采用,成为其默认的文件系统。在其众多的特性中,包含了“在线调整大小”这一特性,使得现存的XFS文件系统在被挂载时可以进行扩展。然而,对于XFS文件系统的缩减确实不被支持的。 + +要扩展一个现存的XFS文件系统,你可以使用命令行工具xfs_growfs,这在大多数Linux发行版上都默认可用。由于XFS支持在线调整大小,目标文件系统可以挂在,也可以不挂载。 + +下面展示了**xfs_growfs**的基本用法: + +![](https://farm6.staticflickr.com/5551/14915082088_b4e29af3cf_z.jpg) + +作为目标XFS文件系统来扩展,你可以指定挂载点、磁盘分区或者逻辑卷(在使用LVM时),使用数据块数量来指定新的XFS文件系统的大小。你可以使用xfs_info命令行工具来检查数据块大小和数量: + +![](https://farm6.staticflickr.com/5584/14915075270_cd272d4468_z.jpg) + +要将XFS文件扩展到1986208: + + $ sudo xfs_growfs /dev/centos/root -D 1986208 + +如果你不使用“-D”选项来指定大小,xfs_growfs将会自动扩展XFS文件系统到最大的可用大小。 + + $ sudo xfs_growfs /dev/centos/root + +![](https://farm6.staticflickr.com/5569/14914950529_ddfb71c8dd_z.jpg) + +注意,当你扩展一个现存的XFS文件系统时,必须准备事先添加用于XFS文件系统扩展的空间。这虽然是十分明了的事,但是如果在潜在的分区或磁盘卷上没有空闲空间可用的话,xfs_growfs不会做任何事情。同时,如果你尝试扩展XFS文件系统大小到超过磁盘分区或卷的大小,xfs_growfs将会失败。 + +![](https://farm4.staticflickr.com/3870/15101281542_98a49a7c3a_z.jpg) + +-------------------------------------------------------------------------------- + +via: http://ask.xmodulo.com/expand-xfs-file-system.html + +译者:[GOLinux](https://github.com/GOLinux) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 diff --git a/translated/tech/20140919 How to install Arch Linux the easy way with Evo or Lution.md b/translated/tech/20140919 How to install Arch Linux the easy way with Evo or Lution.md new file mode 100644 index 0000000000..b217691ce0 --- /dev/null +++ b/translated/tech/20140919 How to install Arch Linux the easy way with Evo or Lution.md @@ -0,0 +1,73 @@ +Arch Linux安装捷径:Evo/Lution +================================================================================ +有些人只体验过Ubuntu或Mint的安装,却鼓起勇气想要安装Arch Linux,他们的学习道路是那样的陡峭和严峻,安装过程中半途而废的人数可能要比顺利过关的人多。如果你成功以有用的方式跑起并配置了Arch Linux,那么它已经把你培养成了一个饱经风霜的Linux用户。 + +即使有[有帮助的维基][1]可以为新手提供指南,对于那些想要征服Arch的人而言要求仍然太高。你需要至少熟悉诸如fdisk或mkfs之类的终端命令,并且听过mc、nano或chroot这些,并努力掌握它们。这让我回想起了10年前的Debian安装。 + +对于那些满怀抱负而又缺乏知识的生灵,有一个叫[Evo/Lution Live ISO][2]的ISO镜像格式安装器可以拯救他们。即便它貌似和自有发行版一样启动,但它也什么都没干,除了辅助安装Arch Linux准系统。Evo/Lution是一个项目,它旨在通过提供Arch的简单安装方式让Arch的用户基础多样化,就像为那些用户提供全面帮助和文档的社区一样。在这样一个组合中,Evo是Live CD(不可安装),而Lution是个安装器。项目创立者看到了Arch开发者和用户之间的巨大鸿沟及其衍生发行版,而想要在所有参与者之间构筑一个平等身份的社区。 + +![](https://farm6.staticflickr.com/5559/15067088008_ecb221408c_z.jpg) + +项目的软件部分是命令行安装器Lution-AIS,它解释了一个普通的纯净的Arch安装过程中的每一步。安装完毕后,你将获得Arch提供的没有从AUR添加任何东西的最新软件或其它任何自定义的包。 + +启动这个422MB大小的ISO镜像后,一个由显示在右边的带有选项快捷方式的Conky和一个左边等待运行安装器的LX-Terminal组成的工作区便呈现在我们眼前。 + +![](https://farm6.staticflickr.com/5560/15067056888_6345c259db_z.jpg) + +在通过右击桌面或使用ALT-i启动实际的安装器后,一个写满了16个等待运行的任务的列表就出现在你面前了。除非你有一个更好的了解,否则将这些命令全部运行一遍。你可以一次运行,也可以进行选择,如1 3 6,或者1-4,也可以一次将它们全部运行,输入1-16。大多数步骤需要‘y’,即yes,来确认,而下一个任务则等着你敲击回车来执行。在此期间,你有足够的时间来阅读安装指南,它可以通过ALT-g来打开。当然,你也可以出去溜达一圈再回来。 + +![](https://farm4.staticflickr.com/3868/15253227082_5e7219f72d_z.jpg) + +这16个步骤分成“基础安装”和“桌面安装”两组。第一个组安装主要关注本地化、分区,以及安装启动器。 + +安装器带领你穿越分区世界,你可以选择使用gparted、gdisk,以及cfdisk。 + +![](https://farm4.staticflickr.com/3873/15230603226_56bba60d28_z.jpg) + +![](https://farm4.staticflickr.com/3860/15253610055_e6a2a7a1cb_z.jpg) + +创建完分区后(如,像截图中所示,用gparted划分/dev/sda1用于root,/dev/sda2用于swap),你可以在10个文件系统中选择其中之一。在下一步中,你可以选择内核(最新或长期支持LTS)和基础系统。 + +![](https://farm6.staticflickr.com/5560/15253610085_aa5a9557fb_z.jpg) + +安装完你喜爱的启动加载器后,第一部分安装就完成了,这大约需要花费12分钟。这是在普通的Arch Linux中你第一次重启进入系统所处之处。 + +在Lution的帮助下,继续进入第二部分,在这一部分中将安装Xorg、声音和图形驱动,然后进入桌面环境。 + +![](https://farm4.staticflickr.com/3918/15066917430_c21e0f0a9e_z.jpg) + +安装器会检测是否在VirtualBox中安装,并且会自动为VM安装并加载正确的通用驱动,然后相应地设置**systemd**。 + +在下一步中,你可以选择KDE、Gnome、Cinnamon、LXDE、Englightenment、Mate或XFCE作为你的桌面环境。如果你不喜欢臃肿的桌面,你也可以试试这些窗口管理器:Awesome、Fluxbox、i3、IceWM、Openbox或PekWM。 + +![](https://farm4.staticflickr.com/3874/15253610125_26f913be20_z.jpg) + +在使用Cinnamon作为桌面环境的情况下,第二部分安装将花费不到10分钟的时间;而选择KDE的话,因为要下载的东西多得多,所以花费的时间也会更长。 + +Lution-AIS在Cinnamon和Awesome上像个妩媚的小妖精。在安装完成并提示重启后,它就带我进入了我所渴望的环境。 + +![](https://farm4.staticflickr.com/3885/15270946371_c2def59f37_z.jpg) + +我要提出两点非议:一是在安装器要我选择一个镜像列表时,另外一个是在创建fstab文件时。在这两种情况下,它都另外开了一个终端,给出了一些文本信息提示。这让我花了点时间才搞清楚,原来我得把它关了,安装器才会继续。在创建fstab后,它又会提示你,而你需要关闭终端,并在问你是否想要保存文件时回答‘是’。 + +![](https://farm4.staticflickr.com/3874/15067056958_3bba63da60_z.jpg) + +我碰到的第二个问题,可能与VirtualBox有关了。在启动的时候,你可以看到没有网络被检测到的提示信息。点击顶部左边的图标,将会打开wicd,这里所使用的网络管理器。点击“断开”,然后再点击“连接”并重启安装器,就可以让它自动检测到了。 + +Evo/Lution我以为是个有价值的项目,在这里Lution工作一切顺利,目前还没有什么可告诉社区的。他们开启了一个全新的网站、论坛和维基,需要填充内容进去啊。所以,如果你喜欢这主意,加入[他们的论坛][3]并告诉他们吧。本文中的ISO镜像可以从[此网站][4]下载。 + +-------------------------------------------------------------------------------- + +via: http://xmodulo.com/2014/09/install-arch-linux-easy-way-evolution.html + +作者:[Ferdinand Thommes][a] +译者:[GOLinux](https://github.com/GOLinux) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://xmodulo.com/author/ferdinand +[1]:https://wiki.archlinux.org/ +[2]:http://www.evolutionlinux.com/ +[3]:http://www.evolutionlinux.com/forums/ +[4]:http://www.evolutionlinux.com/downloads.html diff --git a/translated/tech/20140919 Linux FAQs with Answers--How to create a MySQL database from the command line.md b/translated/tech/20140919 Linux FAQs with Answers--How to create a MySQL database from the command line.md new file mode 100644 index 0000000000..f2c7e3186a --- /dev/null +++ b/translated/tech/20140919 Linux FAQs with Answers--How to create a MySQL database from the command line.md @@ -0,0 +1,116 @@ +数据库常见问题答案--如何使用命令行创建一个MySQL数据库 +=== + +> **问题**:在一个某处运行的MySQL服务器上,我该怎样通过命令行创建和安装一个MySQL数据库呢? + + +为了能通过命令行创建一个MySQL数据库,你可以使用mysql命令行客户端。下面是通过mysql命令行客户端创建和安装MySQL的步骤。 + +### 第一步:安装MySQL客户端 ### + +当然你得确保MySQL客户端已经安装完毕。如果没有的话,可以按照下面的方法。 + +在Debian,Ubuntu 或者 Linux Mint上: + + $ sudo apt-get install mysql-client + +在Fedora,CentOS 或者 RHEL上: + + $ sudo apt-get install mysql + +### 第二步:登陆到MySQL服务器 ### + +首先,你需要使用root用户登陆进你的MySQL数据库,如下: + + $ mysql -u root -h -p + +请注意:为了能登进远程的MySQL服务器,你需要[开启服务器上的远程访问][1],如果你想调用同一主机上的MySQL服务器,你可以省略 "-h " 参数 + + $ mysql -u root -p + +你将需要输入MySQL服务器的密码,如果认证成功,MySQL提示将会出现。 + +![](https://www.flickr.com/photos/xmodulo/15272971112/) + +### 第三步:创建一个MySQL数据库 ### + +在MySQL提示中输入命令之前,请记住所有的命令都是以分号结束的(否则将不会执行)。另外,考虑输入命令的时候使用大些字母,输入数据库对象使用小写字母。但那不是必须的,只是方便你的阅读。 + +现在,让我们创建一个叫做xmodulo_DB的数据库: + + mysql> CREATE DATABASE IF NOT EXISTS xmodulo_DB; + +![](https://farm4.staticflickr.com/3864/15086792487_8e2eaedbcd.jpg) + +### 第四步:创建一个数据库表 ### + +为了达到演示的目的,我们将会创建一个叫做posts_tbl的表,表里会存储关于文章的如下信息: + +- 文章的标题 +- 作者的第一个名字 +- 作者的最后一个名字 +- 文章可用或者不可用 +- 文章创建的日期 + +这个过程分两步执行: + +首先,选择我们需要使用的数据库: + + mysql> USE xmodulo_DB; + +然后,在数据库中创建新表: + + mysql> CREATE TABLE 'posts_tbl' ( + 'post_id' INT UNSIGNED NOT NULL AUTO_INCREMENT, + 'content' TEXT, + 'author_FirstName' VARCHAR(100) NOT NULL, + 'author_LastName' VARCHAR(50) DEFAULT NULL , + 'isEnabled' TINYINT(1) NOT NULL DEFAULT 1, + 'date' TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP , + PRIMARY KEY ( 'post_id' ) + ) TYPE = MYISAM; + +![](https://farm4.staticflickr.com/3870/15086654980_39d2d54d72.jpg) + +### 第五步:创建一个用户,并授予权限 ### + +当涉及到访问我们新创的数据库和表的时候,创建一个新用户是一个很好的主意。这样做就可以让用户在没有整个MySQL服务器权限的情况下,去访问那个数据库(而且只能是那个数据库) + +你可以创建新用户,授予权限,并且使改变生效: + + mysql> GRANT ALL PRIVILEGES ON xmodulo_DB.* TO 'new_user'@'%' IDENTIFIED BY 'new_password'; + mysql> FLUSH PRIVILEGES; + +'new_user'和'new_password'分别指的是新的用户名和他的密码。这条信息将会被保存在mysql.user表中,而且密码会被加密。 + +### 第六步:测试 ### + +让我们插入一个虚拟的记录到posts_tbl表: + + mysql> USE xmodulo_DB; + mysql> INSERT INTO posts_tbl (content, author_FirstName, author_Las tName) + VALUES ('Hi! This is some dummy text.', 'Gabriel', 'Canepa'); + +然后查看posts_tbl表中的所有记录: + + mysql> SELECT * FROM posts_tbl; + +![](https://farm4.staticflickr.com/3896/15086792527_39a987d8bd_z.jpg) + +注意:MySQL会在我们先前定义的地方自动插入适当的默认值(比如,'isEnabled'和'date')。 + +--- + +via: http://ask.xmodulo.com/create-mysql-database-command-line.html + +译者:[su-kaiyao](https://github.com/su-kaiyao) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linu +x中国](http://linux.cn/) 荣誉推出 + +[1]:http://xmodulo.com/2012/06/how-to-allow-remote-access-to-mysql.html + + + + diff --git a/translated/tech/20140919 Network Installation of Debian 7 (Whezzy) on Client Machines using DNSMASQ Network Boot Server.md b/translated/tech/20140919 Network Installation of Debian 7 (Whezzy) on Client Machines using DNSMASQ Network Boot Server.md new file mode 100644 index 0000000000..1d7ac429a0 --- /dev/null +++ b/translated/tech/20140919 Network Installation of Debian 7 (Whezzy) on Client Machines using DNSMASQ Network Boot Server.md @@ -0,0 +1,182 @@ +客户机通过DNSMASQ网络启动服务器网络安装“Debian 7(Wheezy)” +================================================================================ +本教程将指引你直接通过使用**DNSMASQ**作为**PXE服务器(预启动执行环境)**的网络位置安装**Debian 7(Wheezy)**,此种情况是假定你的服务器不提供任何CD/DVD/USB介质驱动器,或者它只能通过相连的监视器、键盘和鼠标操作。 + +![Debian 7 Network Installation on Client Machines](http://www.tecmint.com/wp-content/uploads/2014/09/Network-Debian-Instalaltion.png) + +客户机上的Debian 7网络安装 + +**DNSMASQ**是一个轻量级网络基础架构服务器,它可以通过内建的DNS、DHCP和TFTP服务器提供如DNS、DHCP和网络启动等关键服务。 + +一旦PXE服务器启动并运行,你可以指示你所有的客户机直接从网络启动,前提是你的客户机必须拥有一张支持网络启动的网卡,网络启动可以从BIOS的网络启动或启动服务选项中启用。 + +### 需求 ### + +- [Debian 7 (Wheezy)安装指南][1] + +### 步骤1: 安装及配置DNSMASQ服务器 ### + +**1.** 首先,在安装Debian服务器后,要确保你的系统使用的是**静态IP地址**。因为除了网络启动之外,也要为你的整个网段提供DHCP服务。设置好静态IP地址后,以root帐号或具有root权力的用户来运行以下命令,进行DNSMASQ服务器的安装。 + + # apt-get install dnsmasq + +![Install Dnsmasq Package](http://www.tecmint.com/wp-content/uploads/2014/09/Install-Dnsmasq-in-Debian.png) + +安装Dnsmasq包 + +**2.** 安装好DNSMASQ包后,你可以开始编辑配置文件。首先创建一个主配置文件的备份,然后使用下面的命令对**dnsmasq.conf**文件进行编辑。 + + # mv /etc/dnsmasq.conf /etc/dnsmasq.conf.backup + # nano /etc/dnsmasq.conf + +![Backup Dnsmasq Configuration](http://www.tecmint.com/wp-content/uploads/2014/09/Backup-dnsmasq-Configuration-file.png) + +备份Dnsmasq配置 + +**3.** 上面的备份过程适合重命名配置文件,所以新的文件应该是空,你可以使用以下下面描述的**DNSMASQ**配置文件节录。 + + interface=eth0 + domain=debian.lan + dhcp-range=192.168.1.3,192.168.1.253,255.255.255.0,1h + dhcp-boot=pxelinux.0,pxeserver,192.168.1.100 + pxe-prompt="Press F8 for menu.", 60 + #pxe-service types: x86PC, PC98, IA64_EFI, Alpha, Arc_x86, Intel_Lean_Client, IA32_EFI, BC_EFI, Xscale_EFI and X86-64_EFI + pxe-service=x86PC, "Install Debian 7 Linux from network server 192.168.1.100", pxelinux + enable-tftp + tftp-root=/srv/tftp + +![Configuration of Dnsmasq](http://www.tecmint.com/wp-content/uploads/2014/09/Configure-dnsmasq.png) + +Dnsmasq配置 + +- **interface** – 服务器监听的网络接口。 +- **domain** – 用你自己的域名替换。 +- **dhcp-range** – 用你自己的网络掩码定义的网络IP地址范围。 +- **dhcp-boot** – 保持默认,但使用你自己的服务器IP地址替换IP声明。 +- **pxe-prompt** – 保持默认 – 要求在**敲击F8键** 进入菜单时等待60秒。 +- **pxe=service** – 使用**x86PC**作为32位/64位架构,并进入引号字符串的菜单描述提示。其它值类型可能是:PC98,IA64_EFI,Alpha,Arc_x86,Intel_Lean_Client,IA32_EFI, BC_EFI,Xscale_EFI和 X86-64_EFI。 +- **enable-tftp** – 启用内建TFTP服务器。 +- **tftp-root** – 使用/srv/tftp作为Debian网络启动文件的存放位置。 + +### 步骤2: 下载Debian网络启动文件并打开防火墙连接 ### + +**4.** 现在,该下载Debian网络启动文件了。首先,修改你当前工作目录路径到**TFTP根目录**位置,此位置由最后的配置语句定义(**/srv/tftp**系统路径)。 + +转到[Debian网络安装][2] – [网络启动部分][3]的官方页面镜像,抓取以下文件,要抓取的文件取决于你想要安装到客户端的系统架构。 + +下载好**netboot.tar.gz**文件后,同时提取归档(该过程描述只适用于64位,但对于其它系统架构也基本相同)。 + + # cd /srv/tftp/ + # wget http://ftp.nl.debian.org/debian/dists/wheezy/main/installer-amd64/current/images/netboot/netboot.tar.gz + # tar xfz netboot.tar.gz + # wget http://ftp.nl.debian.org/debian/dists/wheezy/main/installer-amd64/current/images/SHA256SUMS + # wget http://ftp.nl.debian.org/debian/dists/wheezy/Release + # wget http://ftp.nl.debian.org/debian/dists/wheezy/Release.gpg + +同时,必须确保**TFTP**目录中的所有文件都可让TFTP服务器读取。 + + # chmod -R 755 /srv/tftp/ + +![Download Debian NetBoot Files](http://www.tecmint.com/wp-content/uploads/2014/09/Download-Debian-NetBoot-Files.png) + +下载Debian网络启动文件 + +使用以下变量用于**Debian网络安装**镜像和架构。 + + # wget http://"$YOURMIRROR"/debian/dists/wheezy/main/installer-"$ARCH"/current/images/netboot/netboot.tar.gz + # wget http://"$YOURMIRROR"/debian/dists/wheezy/main/installer-"$ARCH"/current/images/SHA256SUMS + # wget http://"$YOURMIRROR"/debian/dists/wheezy/Release + # wget http://"$YOURMIRROR"/debian/dists/wheezy/Release.gpg + +**5.** 下一步,启动或重启DNSMASQ守护进程,并运行netstat命令来获取服务器监听的端口列表。 + + # service dnsmasq restart + # netstat -tulpn | grep dnsmasq + +![Start Dnsmasq Service](http://www.tecmint.com/wp-content/uploads/2014/09/Start-Dnsmasq-Service.png) + +启动Dnsmasq服务 + +**6.** 基于Debian的发行版通常附带了**UFW防火墙**包。使用以下命令来打开需要的**DNSMASQ**端口号:**67**(Bootps),**69**(TFTP),**53**(DNS)**4011**(代理DHCP)udp和**53** tcp(DNS)。 + # ufw allow 69/udp + # ufw allow 4011/udp ## Only if you have a ProxyDHCP on the network + # ufw allow 67/udp + # ufw allow 53/tcp + # ufw allow 53/udp + +![Open Dnsmasq Ports](http://www.tecmint.com/wp-content/uploads/2014/09/Open-Dnsmasq-Ports-620x303.png) + +开启Dnsmasq端口 + +Now, the PXE loader located on your client network interface will load **pxelinux** configuration files from **/srv/tftp/pxelinux.cfg** directory using this order. +现在,位于你的客户机网络接口上的PXE加载器将使用按以下顺序从**/srv/tftp/pxelinux.cfg**目录加载**pxelinux**配置文件。 + +- GUID文件 +- MAC文件 +- 默认文件 + +### 步骤3: 配置客户端从网络启动 ### + +**7.** 要为你的客户端计算机启用网络启动,请进入系统**BIOS配置**(如何进入BIOS设置,请查阅硬件主板提供商的文档)。 + +转到**启动菜单**,然后选择**网络启动**作为**首要启动设备**(在某些系统上,你可以不用进入BIOS配置就能选择启动设备,只要在**BIOS自检**时按一个键就可以进行选择了)。 + +![Select BIOS Settings](http://www.tecmint.com/wp-content/uploads/2014/09/Select-BIOS-Settings.png) + +选择BIOS设置 + +**8。** 在编辑启动顺序后,通常按**F10**来保存BIOS设置。重启后,你的客户端计算机应该可以直接从网络启动了,应该会出第一个**PXE**提示,要求你按**F8**键进入菜单。 + +接下来,敲击**F8**键来进入,会出现一个新的提示。敲击**回车**键,屏幕上会出现**Debian安装器**主界面提示,如下图所示。 + +![Boot Menu Selection](http://www.tecmint.com/wp-content/uploads/2014/09/Boot-Menu-Selection.png) + +启动菜单选择 + +![Select Debian Installer Boot](http://www.tecmint.com/wp-content/uploads/2014/09/Select-Debian-Installer-Boot.png) + +选择Debian安装器启动 + +![Select Debian Install](http://www.tecmint.com/wp-content/uploads/2014/09/Select-Debian-Install.png) + +选择Debian安装 + +从这里开始,你可以使用Debian 7 Wheezy安装进程将Debian安装到你的机器上了(安装链接见上面)。然而,为了能够完成安装进程,你也需要确保你的机器上互联网连接已经激活。 + +### 步骤4: DNSMASQ服务器排障并在系统范围内启用 ### + +**9.** 要诊断服务器以查询最终是否发生问题或要查询其它提供给客户端的信息,运行以下命令来打开日志文件。 + + # tailf /var/log/daemon.log + +![Debug DNSMASQ Server](http://www.tecmint.com/wp-content/uploads/2014/09/Debbug-DNSMASQ-Server.png) + +DNSMASQ服务器排障 + +**10.** 如果服务器测试中已一切就绪,你现在可以在**sysv-rc-conf**包的帮助下,启用**DNSMASQ**守护进程自启动,以使该进程在系统重启后自动启动。 + + # apt-get install sysv-rc-conf + # sysv-rc-conf dnsmaq on + +![Enable DNSMASQ Daemon](http://www.tecmint.com/wp-content/uploads/2014/09/Enable-DNSMASQ-Daemon.png) + +启用DNSMASQ守护进程 + +到此为止吧!现在你的**PXE**服务器已经整装待发,随时准备好分配IP地址了(**DHCP**),并为你所有网段中的客户端提供需要的启动信息,这些信息配置用来从网络启动并安装Debian Wheezy。 + +使用PXE网络启动安装在服务器主机数量增长时很有优势,因为你可以在短时间内火同时设置整个网络基础架构,为版本升级提供了方便,也可以通过kickstart文件使整个安装的全自动化。 + +-------------------------------------------------------------------------------- + +via: http://www.tecmint.com/network-installation-of-debian-7-on-client-machines/ + +作者:[Matei Cezar][a] +译者:[GOLinux](https://github.com/GOLinux) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://www.tecmint.com/author/cezarmatei/ +[1]:http://www.tecmint.com/debian-gnulinux-7-0-code-name-wheezy-server-installation-guide/ +[2]:http://www.debian.org/distrib/netinst#netboot +[3]:http://ftp.nl.debian.org/debian/dists/wheezy/main/ diff --git a/translated/tech/20140922 How to Run Android Apps on Ubuntu using ARChon.md b/translated/tech/20140922 How to Run Android Apps on Ubuntu using ARChon.md new file mode 100644 index 0000000000..56d0e74b8d --- /dev/null +++ b/translated/tech/20140922 How to Run Android Apps on Ubuntu using ARChon.md @@ -0,0 +1,101 @@ +安卓应用乾坤大挪移,Ubuntu上的搬运工:ARChon +================================================================================ +![Android, Chrome, Ubuntu](http://www.omgubuntu.co.uk/wp-content/uploads/2014/09/android-ubuntu.jpg) + +Android, Chrome, Ubuntu + +**Google最近发布了首批[能在Chrome OS本地运行的安卓应用集][1],通过‘安卓运行时’扩展完成了该壮举。** + +现在,一位开发者已经[指明了将安卓应用带入桌面版Chrome的路][2]。 + +[弗拉德·菲利波夫][3]的[chromeos-apk脚本][4]和[ARChon安卓运行时扩展][5]手拉手一起开展工作,将安卓应用带进了Windows,Mac和Linux桌面上的Chrome中。 + +![IMDB, Flipboard and Twitter Android Apps running on Ubuntu 14.04 LTS](http://www.omgubuntu.co.uk/wp-content/uploads/2014/09/android-apps-on-linux.jpg) + +运行在Ubuntu 14.04 LTS上的安卓应用:IMDB,Flipboard和Twitter + +通过运行时运行的应用的性能不是很令人惊异,任何想要运行Dead Trigger 2或者其它图形密集型游戏的雄心壮志可以放到一边了。 + +同样地,作为官方运行时的非官方重构包并在Chrome OS之外运行,系统整合(如网络摄像头,扬声器等)可能不完整或者根本不可能。 + +下面的指南只是提供原样,并不保证一定成功。它只能作为高度实验性进行,里面遍布漏洞,很不稳定——甚至平出恶魔。只能出于好奇而尝试,不去高度寄予厚望,那么你就不会深受其困扰。 + +### 安卓应用转战Linux大法 ### + +要通过Chrome在Linux上运行安卓应用,很明显,你需要安装Chrome,要求的版本是37,或者更高。坦率地讲,如果你打算玩玩潜在不稳定的版本,那么你也可以下载并[为Linux安装不稳定的Google Chrome版本][6]。 + +已经安装了Chrome的某个版本?你可以通过命令行来安装开发版,命令如下: + + sudo apt-get install google-chrome-unstable + +接下来,你需要下载官方定制版,而不是Google或Chronium捐赠的版本——由弗拉德·菲利波夫创建的安卓运行时。这个版本和官方的有着诸多的不同,最突出的就是它可以运行在桌面版的浏览器上。 + +- [从BitBucket下载ARChon v1.0][7] + +下载好运行时后,你需要从.zip解压内容,并移动解压后的文件夹到你的Home文件夹。 + +要安装,打开Google Chrome,点击汉堡式菜单按钮,然后导航到扩展页。检查‘启用开发者模式’并点击‘加载解包的扩展’按钮。 + +![](http://www.omgubuntu.co.uk/wp-content/uploads/2014/09/chromeos-apk-extensions.jpg) + +运行时本身不会做太多事情,所以你需要从安卓应用创建兼容包。要完成这项工作,你需要‘[chromeos-apk][8]’[命令行Javascript工具][9],它可以从节点封装模块管理器安装。 + +首先运行: + + sudo apt-get install npm nodejs nodejs-legacy + +Ubuntu 64位用户?你也需要攫取以下库: + + sudo apt-get install lib32stdc++6 + +现在,运行命令来暗转脚本吧: + + npm install -g chromeos-apk + +根据你的配置,你可能需要过会儿使用sudo来运行。如果你不喜欢[通过sudo安装npm模块,你可以][10]玩玩鬼把戏。 + +![](http://www.omgubuntu.co.uk/wp-content/uploads/2014/09/chromeos-apk-npm.jpg) + +现在,你直接回家了。去Google找找你想要试试的应用的APK吧,请牢记**不是所有的安卓应用都会工作**,而**那些可以工作的也未必工作得很好**,或者缺少功能。 + +把你想要的安卓APK放到~/Home,然后回到终端中使用以下命令来转换,你可以将APK命名成任何你想要的名字: + + chromeos-apk replaceme.apk --archon + +该命令将花一点时间来完成这项工作,也许也就是一眨眼的时间。[实际上,不需要眨眼的时间][11] + +![](http://www.omgubuntu.co.uk/wp-content/uploads/2014/09/chromeos-apk-archon-750x184.jpg) + +现在,在你的Home文件夹内有个ARChon生成的Chrome APK extension-y folder-y这样的东西。所有剩下来要做的事,就是安装并查看它是否正常工作! + +回到chrome://extensions页面,再次轻敲‘加载解封装扩展’按钮,但这次选择上面脚本创建的文件夹。 + +应用应该会继续安装,不会有任何问题,但是它确实会没有问题吗?打开Chrome应用启动器或应用页面并启动它来看看是否有问题。 + +#### 深度探索 #### + +由于ARChon运行时支持不限数量的chrome化的APK,你可以反复进行该操作,你想做多少次都行。Chrome APK [subreddit][12]用于跟踪成功/失败情况,所以如果你感到很有用,一定要贴出你的结果。 + +-------------------------------------------------------------------------------- + +via: http://www.omgubuntu.co.uk/2014/09/install-android-apps-ubuntu-archon + +作者:[Joey-Elijah Sneddon][a] +译者:[GOLinux](https://github.com/GOLinux) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:https://plus.google.com/117485690627814051450/?rel=author +[1]:http://www.omgchrome.com/first-4-chrome-android-apps-released/ +[2]:http://www.omgchrome.com/run-android-apps-on-windows-mac-linux-archon/ +[3]:https://github.com/vladikoff/ +[4]:https://github.com/vladikoff/chromeos-apk +[5]:https://github.com/vladikoff/chromeos-apk/blob/master/archon.md +[6]:http://www.chromium.org/getting-involved/dev-channel +[7]:https://bitbucket.org/vladikoff/archon/get/v1.0.zip +[8]:https://github.com/vladikoff/chromeos-apk/blob/master/README.md +[9]:https://github.com/vladikoff/chromeos-apk/blob/master/README.md +[10]:http://stackoverflow.com/questions/19352976/npm-modules-wont-install-globally-without-sudo/21712034#21712034 +[11]:https://www.youtube.com/watch?v=jKXLkWrBo7o +[12]:http://www.reddit.com/r/chromeapks diff --git a/translated/tech/20140922 How to use logrotate to manage log files in Linux.md b/translated/tech/20140922 How to use logrotate to manage log files in Linux.md new file mode 100644 index 0000000000..c4f03e9dcc --- /dev/null +++ b/translated/tech/20140922 How to use logrotate to manage log files in Linux.md @@ -0,0 +1,199 @@ +Linux日志文件总管——logrotate +================================================================================ +日志文件包含了关于系统中发生的事件的有用信息,在排障过程中或者系统性能分析时经常被用到。对于忙碌的服务器,日志文件大小会快速增长,服务器会很快消耗磁盘空间,这成了个问题。除此之外,处理一个单个的庞大日志文件也常常是件十分棘手的事。 + +logrotate是个十分有用的工具,它可以自动对日志进行分解(或轮循)、压缩以及删除旧日志文件。例如,你可以设置logrotate,让/var/log/foo日志文件每30天轮循,并删除超过6个月的日志。配置完后,logrotate的运作完全自动化,不必进行任何进一步的认为干预。另外,旧日志也可以通过电子邮件发送,不过该选项超出了本教程的讨论范围。 + +主流Linux发行版上都默认安装有logrotate包,如果出于某种原因,logrotate没有出现在里头,你可以使用apt-get或yum命令来安装。 + +在Debian或Ubuntu上: + + # apt-get install logrotate cron + +在Fedora,CentOS或RHEL上: + + # yum install logrotate crontabs + +logrotate的配置文件是/etc/logrotate.conf,通常不需要对它进行修改。日志文件的轮循设置在独立的配置文件中,它(们)放在/etc/logrotate.d/目录下。 + +### 样例一 ### + +在第一个样例中,我们将创建一个10MB的日志文件/var/log/log-file。我们将展示怎样使用logrotate来管理该日志文件。 + +我们从创建一个日志文件开始吧,然后在其中填入一个10MB的随机比特流数据。 + + # touch /var/log/log-file + # head -c 10M < /dev/urandom > /var/log/log-file + +由于现在日志文件已经准备好,我们将配置logrotate来轮循该日志文件。让我们为该文件创建一个配置文件。 + + # vim /etc/logrotate.d/log-file + +---------- + + /var/log/log-file { + monthly + rotate 5 + compress + delaycompress + missingok + notifempty + create 644 root root + postrotate + /usr/bin/killall -HUP rsyslogd + endscript + } + +这里: + +- **monthly**: 日志文件将按月轮循。其它可用值为‘daily’,‘weekly’或者‘yearly’。 +- **rotate 5**: 一次将存储5个归档日志。对于第六个归档,时间最久的归档将被删除。 +- **compress**: 在轮循任务完成后,已轮循的归档将使用gzip进行压缩。 +- **delaycompress**: 总是与compress选项一起用,delaycompress选项指示logrotate不要将最近的归档压缩,压缩将在下一次轮循周期进行。这在你或任何软件仍然需要读取最新归档时很有用。 +- **missingok**: 在日志轮循其间,任何错误将被忽略,例如“文件无法找到”之类的错误。 +- **notifempty**: 如果日志文件为空,轮循不会进行。 +- **create 644 root root**: 以指定的权限创建全新的日志文件,同时logrotate也会重命名原始日志文件。 +- **postrotate/endscript**: 在所有其它指令完成后,postrotate和endscript之间指定的命令将被执行。在这种情况下,rsyslogd 进程将立即再次读取其配置并继续运行。 + +上面的模板是通用的,而配置参数则根据你的需求进行调整,不是所有的参数都是必要的。 + +### 样例二 ### + +在本例中,我们只想要轮循一个日志文件,然而日志文件大小会增长到50MB。 + + # vim /etc/logrotate.d/log-file + +---------- + + /var/log/log-file { + size=50M + rotate 5 + create 644 root root + postrotate + /usr/bin/killall -HUP rsyslogd + endscript + } + +### 样例三 ### + +我们想要让旧日志文件以创建日期命名,这可以通过添加dateext常熟实现。 + + # vim /etc/logrotate.d/log-file + +---------- + + /var/log/log-file { + monthly + rotate 5 + dateext + create 644 root root + postrotate + /usr/bin/killall -HUP rsyslogd + endscript + } + +这将导致归档文件在它们的文件名中包含日期信息。 + +### 排障 ### + +这里提供了一些logrotate设置的排障提示。 + +#### 1. 手动运行logrotate #### + +**logrotate**可以在任何时候从命令行手动调用。 + +要调用为/etc/lograte.d/下配置的所有日志调用**logrotate**: + + # logrotate /etc/logrotate.conf + +要为某个特定的配置调用logrotate: + + # logrotate /etc/logrotate.d/log-file + +#### 2. 演练 #### + +排障过程中的最佳选择是使用‘-d’选项以预演方式运行logrotate。要进行验证,不用实际轮循任何日志文件,可以模拟演练日志轮循并显示其输出。 + + # logrotate -d /etc/logrotate.d/log-file + +![](https://farm6.staticflickr.com/5561/15096836737_33d3cd1ccb_z.jpg) + +正如我们从上面的输出结果可以看到的,logrotate判断该轮循是不必要的。如果文件的时间小于一天,这就会发生了。 + +#### 3. 强制运行 #### + +即使轮循条件没有满足,我们也可以通过使用‘-f’选项来强制logrotate轮循日志文件,‘-v’参数提供了详细的输出。 + + # logrotate -vf /etc/logrotate.d/log-file + +---------- + + reading config file /etc/logrotate.d/log-file + reading config info for /var/log/log-file + + Handling 1 logs + + rotating pattern: /var/log/log-file forced from command line (5 rotations) + empty log files are rotated, old logs are removed + considering log /var/log/log-file + log needs rotating + rotating log /var/log/log-file, log->rotateCount is 5 + dateext suffix '-20140916' + glob pattern '-[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9]' + renaming /var/log/log-file.5.gz to /var/log/log-file.6.gz (rotatecount 5, logstart 1, i 5), + old log /var/log/log-file.5.gz does not exist + renaming /var/log/log-file.4.gz to /var/log/log-file.5.gz (rotatecount 5, logstart 1, i 4), + old log /var/log/log-file.4.gz does not exist + . . . + renaming /var/log/log-file.0.gz to /var/log/log-file.1.gz (rotatecount 5, logstart 1, i 0), + old log /var/log/log-file.0.gz does not exist + log /var/log/log-file.6.gz doesn't exist -- won't try to dispose of it + renaming /var/log/log-file to /var/log/log-file.1 + creating new /var/log/log-file mode = 0644 uid = 0 gid = 0 + running postrotate script + compressing log with: /bin/gzip + +#### 4. Logrotate记录日志 #### + +logrotate自身的日志通常存放于/var/lib/logrotate/status目录。如果处于排障目的,我们想要logrotate记录到任何指定的文件,我们可以指定像下面这样从命令行指定。 + + # logrotate -vf –s /var/log/logrotate-status /etc/logrotate.d/log-file + +#### 5. Logrotate定时任务 #### + +logrotate需要的**cron**任务应该在安装时就自动创建了,我把cron文件的内容贴出来,以供大家参考。 + + # cat /etc/cron.daily/logrotate + +---------- + + #!/bin/sh + + # Clean non existent log file entries from status file + cd /var/lib/logrotate + test -e status || touch status + head -1 status > status.clean + sed 's/"//g' status | while read logfile date + do + [ -e "$logfile" ] && echo "\"$logfile\" $date" + done >> status.clean + mv status.clean status + + test -x /usr/sbin/logrotate || exit 0 + /usr/sbin/logrotate /etc/logrotate.conf + +小结一下,logrotate工具对于防止因庞大的日志文件而耗尽存储空间是十分有用的。配置完毕后,进程是全自动的,可以长时间在不需要人为干预下运行。本教程重点关注几个使用logrotate的几个基本样例,你也可以定制它以满足你的需求。 + +希望本文对你有所帮助。 + +-------------------------------------------------------------------------------- + +via: http://xmodulo.com/2014/09/logrotate-manage-log-files-linux.html + +作者:[Sarmed Rahman][a] +译者:[GOLinux](https://github.com/GOLinux) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://xmodulo.com/author/sarmed diff --git a/translated/tech/20140922 Reset Unity and Compiz Settings in Ubuntu 14.04.md b/translated/tech/20140922 Reset Unity and Compiz Settings in Ubuntu 14.04.md new file mode 100644 index 0000000000..e51f3f79fc --- /dev/null +++ b/translated/tech/20140922 Reset Unity and Compiz Settings in Ubuntu 14.04.md @@ -0,0 +1,41 @@ +在Ubuntu 14.04中重置Unity和Compiz设置【小贴士】 +================================================================================ +如果你一直在试验你的Ubuntu系统,你可能最终以Unity和Compiz的一片混乱收场。在此贴士中,我们将看看怎样来重置Ubuntu 14.04中的Unity和Compiz。事实上,全部要做的事,仅仅是运行几个命令而已。 + +### 重置Ubuntu 14.04中的Unity和Compiz ### + +打开终端(Ctrl+Alt+T),并使用以下命令来重置compiz: + + dconf reset -f /org/compiz/ + +重置compiz后,重启Unity: + + setsid unity + +此外,如果你想将Unity图标也进行重置,试试以下的命令吧: + + unity --reset-icons + +### 可能的疑难解决方案: ### + +如果你在重置compiz时遇到如下错误: + +> error: GDBus.Error:org.gtk.GDBus.UnmappedGError.Quark._g_2dfile_2derror_2dquark.Code17: Cannot open dconf database: invalid gvdb header + +可能的原因是用户文件被搞乱了。备份dconf配置,并移除配置文件: + + mv ~/.config/dconf/ ~/.config/dconf.bak + +希望本贴士对你重置Ubuntu 14.04中Unity和compiz有所帮助,欢迎您随时提出问题和建议。 + +-------------------------------------------------------------------------------- + +via: http://itsfoss.com/reset-unity-compiz-settings-ubuntu-1404/ + +作者:[Abhishek][a] +译者:[GOLinux](https://github.com/GOLinux) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://itsfoss.com/author/Abhishek/ diff --git a/translated/tech/20140924 How To Install Vmware 10 On CentOS 7.md b/translated/tech/20140924 How To Install Vmware 10 On CentOS 7.md new file mode 100644 index 0000000000..bb1a63a96b --- /dev/null +++ b/translated/tech/20140924 How To Install Vmware 10 On CentOS 7.md @@ -0,0 +1,59 @@ +在CentOS 7上安装Vmware 10 +================================================================================ +在CentOS 7上安装Vmware 10.0.3,我将给你们我的经验。通常,这个版本上不能在CentOS 7工作的,因为它只能运行在比较低的内核版本3.10上。 + +1 - 以正常方式下载并安装(没有问题)。唯一的问题是在后来体验vmware程序的时候。 + +### 如何修复? ### + +**1 – 进入/usr/lib/vmware/modules/source。** + + cd /usr/lib/vmware/modules/source + +**2 – 解压vmnet.tar.** + + tar -xvf vmnet.tar + +**3 – 进入vmnet-only目录。** + + cd vmnet-only + +**4 – 编辑filter.c文件。** + + vi filter.c + +在206和259行,替换以下字符串: + + #if LINUX_VERSION_CODE < KERNEL_VERSION(3, 13, 0) + +为: + + #if LINUX_VERSION_CODE < KERNEL_VERSION(3, 0, 0) + +保存并退出。 + +**5 – 回到先前文件夹。** + + cd ../ + +**6 – 再次压缩文件夹。** + + tar -uvf vmnet.tar vmnet-only + +**7 – 移除旧目录。** + + rm -fr vmnet-only + +**8 – 启动vmware并体验。** + +![](http://180016988.r.cdn77.net/wp-content/uploads/2014/09/Selection_008.png) + +-------------------------------------------------------------------------------- + +via: http://www.unixmen.com/install-vmware-10-centos-7/ + +作者: M.el Khamlichi +译者:[GOLinux](https://github.com/GOLinux) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 diff --git a/translated/tech/20140924 How to delete recently opened files history in ubuntu 14.04.md b/translated/tech/20140924 How to delete recently opened files history in ubuntu 14.04.md new file mode 100644 index 0000000000..af595dedd3 --- /dev/null +++ b/translated/tech/20140924 How to delete recently opened files history in ubuntu 14.04.md @@ -0,0 +1,26 @@ +Ubuntu 14.04历史文件清理 +================================================================================ +这个简明教程对Ubuntu 14.04历史文件清理进行了说明,它用于初学者。 + +要从dash搜索删除历史记录,请遵循以下程序。 + +转到系统设置(System Settings)并打开安全与隐私(Security & Privacy)。 + +![](http://www.ubuntugeek.com/wp-content/uploads/2014/09/14.png) + +在文件与应用(Files and Applications)标签下,点击清除用户数据(Clear Usage Data)。 + +![](http://www.ubuntugeek.com/wp-content/uploads/2014/09/26.png) + +你也可以关闭“记录文件与应用使用(Record file and Application usage)以阻止系统记录你当前使用的文件和应用。 + +![](http://www.ubuntugeek.com/wp-content/uploads/2014/09/36.png) + +-------------------------------------------------------------------------------- + +via: http://www.ubuntugeek.com/how-to-delete-recently-opened-files-history-in-ubuntu-14-04.html + +译者:[GOLinux](https://github.com/GOLinux) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 diff --git a/translated/tech/20140924 How to use CloudFlare as a ddclient provider under Ubuntu.md b/translated/tech/20140924 How to use CloudFlare as a ddclient provider under Ubuntu.md new file mode 100644 index 0000000000..bd5f5a49ea --- /dev/null +++ b/translated/tech/20140924 How to use CloudFlare as a ddclient provider under Ubuntu.md @@ -0,0 +1,72 @@ +Ubuntu下使用CloudFlare作为ddclient提供商 +================================================================================ +DDclient是一个Perl客户端,用于更新动态DNS网络服务提供商帐号下的动态DNS条目。它最初是由保罗·巴利编写的,现在大多数是由维姆潘科在做。它能做的不仅仅是动态DNS,也可以通过几种不同的方式获取你的WAN口IP地址。 + +CloudFlare有一点已知的功能,它允许你通过API或叫做ddclient的命令行脚本更新你的DNS记录。不管哪一个,结果都一样,而且它是个免费软件。 + +不幸的是,ddclient并不能在CloudFlare中即开即用。它需要打补丁,这里就是要介绍怎样在Debian或Ubuntu上破解它,它也能在带有Raspberry Pi的Raspbian上工作。 + +### 需求 ### + +首先保证你有一个自有域名,然后登录到CloudFlare,添加你的域名。遵循指令操作,使用它给出的默认值就行了。你将让CloudFlare来托管你的域,所以你需要调整你的注册机构的设置。如果你想要使用子域名,请为它添加一条‘A’记录。目前,任何IP地址都可以。 + +### 在Ubuntu上安装ddclient ### + +打开终端,并运行以下命令 + + sudo apt-get install ddclient + +现在,你需要使用以下命令来安装补丁 + + sudo apt-get install curl sendmail libjson-any-perl libio-socket-ssl-perl + + curl -O http://blog.peter-r.co.uk/uploads/ddclient-3.8.0-cloudflare-22-6-2014.patch + + sudo patch /usr/sbin/ddclient < ddclient-3.8.0-cloudflare-22-6-2014.patch + +以上命令用来完成ddclient的安装和打补丁 + +### 配置ddclient ### + +你需要使用以下命令来编辑ddclient.conf文件 + + sudo vi /etc/ddclient.conf + +添加以下信息 + + ## + ### CloudFlare (cloudflare.com) + ### + ssl=yes + use=web, web=dyndns + protocol=cloudflare, \ + server=www.cloudflare.com, \ + zone=domain.com, \ + login=you@email.com, \ + password=api-key \ + host.domain.com + + Comment out: + + #daemon=300 + +来自CloudFlare帐号页面的api密钥 + +ssl=yes might already be in that file + +use=web, web=dyndns will use dyndns to check IP (useful for NAT) + +你已经搞定了。登录到https://www.cloudflare.com并检查列出的与你域名对应的IP地址是否匹配到了http://checkip.dyndns.com。 + +使用以下命令来验证你的设置 + + sudo ddclient -daemon=0 -debug -verbose -noquiet + +-------------------------------------------------------------------------------- + +via: http://www.ubuntugeek.com/how-to-use-cloudflare-as-a-ddclient-provider-under-ubuntu.html + +译者:[GOLinux](https://github.com/GOLinux) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 diff --git a/translated/tech/20140924 Unix----stat -- more than ls.md b/translated/tech/20140924 Unix----stat -- more than ls.md new file mode 100644 index 0000000000..d877492881 --- /dev/null +++ b/translated/tech/20140924 Unix----stat -- more than ls.md @@ -0,0 +1,130 @@ +Unix: stat -- 获取比 ls 更多的信息 +================================================================================ +> 厌倦了 ls 命令, 并且想查看更多有关你的文件的有趣的信息? 试一试 stat! + +![](http://www.itworld.com/sites/default/files/imagecache/large_thumb_150x113/stats.jpg) + +ls 命令可能是每一个 Unix 使用者第一个学习的命令之一, 但它仅仅显示了 stat 命令能给出的信息的一小部分. + +stat 命令从文件的索引节点获取信息. 正如你可能已经了解的那样, 每一个系统里的文件都存有三组日期和时间, 它们包括最近修改时间(即使用 ls -l 命令时显示的日期和时间), 最近状态改变时间(包括重命名文件)和最近访问时间. + +使用长列表模式查看文件信息, 你会看到类似下面的内容: + + $ ls -l trythis + -rwx------ 1 shs unixdweebs 109 Nov 11 2013 trythis + +使用 stat 命令, 你会看到下面这些: + + $ stat trythis + File: `trythis' + Size: 109 Blocks: 8 IO Block: 262144 regular file + Device: 18h/24d Inode: 12731691 Links: 1 + Access: (0700/-rwx------) Uid: ( 263/ shs) Gid: ( 100/ unixdweebs) + Access: 2014-09-09 19:27:58.000000000 -0400 + Modify: 2013-11-11 08:40:10.000000000 -0500 + Change: 2013-11-11 08:40:10.000000000 -0500 + +在上面的情形中, 文件的状态改变和文件修改的日期/时间是相同的, 而访问时间则是相当近的时间. 我们还可以看到文件使用了 8 个块, 以及两种格式显示的文件权限 -- 八进制(0700)格式和 rwx 格式. 在第三行显示的索引节点是 12731681. 文件没有其它的硬链接(Links: 1). 而且, 这个文件是一个常规文件. + +重命名文件, 你会看到状态改变时间发生变化. + +这里的 ctime 信息, 最早设计用来存储文件的创建日期和时间, 但之前的某个时间变为用来存储状态修改时间. + + $ mv trythis trythat + $ stat trythat + File: `trythat' + Size: 109 Blocks: 8 IO Block: 262144 regular file + Device: 18h/24d Inode: 12731691 Links: 1 + Access: (0700/-rwx------) Uid: ( 263/ shs) Gid: ( 100/ unixdweebs) + Access: 2014-09-09 19:27:58.000000000 -0400 + Modify: 2013-11-11 08:40:10.000000000 -0500 + Change: 2014-09-21 12:46:22.000000000 -0400 + +改变文件的权限也会改变 ctime 域. + +你也可以配合通配符来使用 stat 命令以列出一组文件的状态: + + $ stat myfile* + File: `myfile' + Size: 20 Blocks: 8 IO Block: 262144 regular file + Device: 18h/24d Inode: 12731803 Links: 1 + Access: (0640/-rw-r-----) Uid: ( 263/ shs) Gid: ( 100/ unixdweebs) + Access: 2014-08-23 03:00:36.000000000 -0400 + Modify: 2014-08-22 12:02:12.000000000 -0400 + Change: 2014-08-22 12:02:12.000000000 -0400 + File: `myfile2' + Size: 20 Blocks: 8 IO Block: 262144 regular file + Device: 18h/24d Inode: 12731806 Links: 1 + Access: (0640/-rw-r-----) Uid: ( 263/ shs) Gid: ( 100/ unixdweebs) + Access: 2014-08-23 03:00:36.000000000 -0400 + Modify: 2014-08-22 12:03:30.000000000 -0400 + Change: 2014-08-22 12:03:30.000000000 -0400 + File: `myfile3' + Size: 40 Blocks: 8 IO Block: 262144 regular file + Device: 18h/24d Inode: 12730533 Links: 1 + Access: (0640/-rw-r-----) Uid: ( 263/ shs) Gid: ( 100/ unixdweebs) + Access: 2014-08-23 03:00:36.000000000 -0400 + Modify: 2014-08-22 12:03:59.000000000 -0400 + Change: 2014-08-22 12:03:59.000000000 -0400 + +如果我们喜欢的话, 我们也可以通过其他命令来获取这些信息. + +向 ls -l 命令添加 "u" 选项, 你会获得下面的结果. 注意这个选项会显示最后访问时间, 而添加 "c" 选项则会显示状态改变时间(在本例中, 是我们重命名文件的时间). + + $ ls -lu trythat + -rwx------ 1 shs unixdweebs 109 Sep 9 19:27 trythat + $ ls -lc trythat + -rwx------ 1 shs unixdweebs 109 Sep 21 12:46 trythat + +stat 命令也可应用与文件夹. + +在这个例子中, 我们可以看到有许多的链接. + + $ stat bin + File: `bin' + Size: 12288 Blocks: 24 IO Block: 262144 directory + Device: 18h/24d Inode: 15089714 Links: 9 + Access: (0700/drwx------) Uid: ( 263/ shs) Gid: ( 100/ unixdweebs) + Access: 2014-09-21 03:00:45.000000000 -0400 + Modify: 2014-09-15 17:54:41.000000000 -0400 + Change: 2014-09-15 17:54:41.000000000 -0400 + +在这里, 我们查看一个文件系统. + + $ stat -f /dev/cciss/c0d0p2 + File: "/dev/cciss/c0d0p2" + ID: 0 Namelen: 255 Type: tmpfs + Block size: 4096Fundamental block size: 4096 + Blocks: Total: 259366 Free: 259337 Available: 259337 + Inodes: Total: 223834 Free: 223531 + +注意 Namelen (文件名长度)域, 如果文件名长于 255 个字符的话, 你会很幸运地在文件名处看到心形符号! + +stat 命令还可以一次显示所有我们想要的信息. 下面的例子中, 我们只想查看文件类型, 然后是硬连接数. + + $ stat --format=%F trythat + regular file + $ stat --format=%h trythat + 1 + +在下面的例子中, 我们查看了文件权限 -- 分别以两种可用的格式 -- 然后是文件的 SELinux 安全环境. + +译者注: 原文到这里就结束了, 但很明显缺少结尾. 最后一段的例子可以分别用 + + $ stat --format=%a trythat + $ stat --format=%A trythat + $ stat --format=%C trythat + +来实现. + +-------------------------------------------------------------------------------- + +via: http://www.itworld.com/operating-systems/437351/unix-stat-more-ls + +作者:[Sandra Henry-Stocker][a] +译者:[wangjiezhe](https://github.com/wangjiezhe) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://www.itworld.com/sandra-henry-stocker diff --git a/translated/tech/20140925 Linux FAQs with Answers--How to change a network interface name on CentOS 7.md b/translated/tech/20140925 Linux FAQs with Answers--How to change a network interface name on CentOS 7.md new file mode 100644 index 0000000000..10ba084f55 --- /dev/null +++ b/translated/tech/20140925 Linux FAQs with Answers--How to change a network interface name on CentOS 7.md @@ -0,0 +1,69 @@ +Linux有问必答 -- 如何在CentOS7上改变网络接口名 +================================================================================ +> **提问**: 在CentOS7,我想将分配的网络接口名更改为别的名字。有什么合适的方法来来重命名CentOS或RHEL7的网络接口? + +传统上,Linux的网络接口被枚举为eth[0123...],但这些名称并不一定符合实际的硬件插槽,PCI位置,USB接口数量等,这引入了一个不可预知的命名问题(例如,由于不确定的设备探测行为),这可能会导致不同的网络配置错误(例如,由无意的接口改名引起的禁止接口或者防火墙旁路)。基于MAC地址的udev规则在虚拟化的环境中并不有用,这里的MAC地址如端口数量一样无常。 + +CentOS/RHEL6还推出了[一致和可预测的网络设备命名][1]网络接口的方法。这些特性可以唯一地确定网络接口的名称以使定位和区分设备更容易,并且在这样一种方式下,它随着启动,时间和硬件改变的情况下是持久的。然而,这种命名规则并不是默认在CentOS/RHEL6上开启。 + +从CentOS/RHEL7起,可预见的命名规则变成了默认。根据这一规则,接口名称被自动基于固件,拓扑结构和位置信息来确定。现在,即使添加或移除网络设备,接口名称仍然保持固定,而无需重新枚举,和坏掉的硬件可以无缝替换。 + + * 基于接口类型的两个字母前缀: + * en -- 以太网 + * sl -- 串行线路IP (slip) + * wl -- wlan + * ww -- wwan + * + * Type of names: + * b -- BCMA总线和新书 + * ccw -- CCW总线组名 + * o -- 车载设备的索引号 + * s[f][d] -- 热插拔插槽索引号 + * x -- MAC 地址 + * [P]ps[f][d] + * -- PCI 位置 + * [P]ps[f][u][..]1[i] + * -- USB端口号链 + +新的命名方案的一个小的缺点是接口名称相比传统名称有点难以阅读。例如,你可能会发现像enp0s3名字。再者,你再也无法来控制接口名了。 + +![](https://farm4.staticflickr.com/3854/15294996451_fa731ce12c_z.jpg) + +如果由于某种原因,你喜欢旧的方式,并希望能够选择任意名称分配给CentOS/ RHEL7的设备,你需要重写默认的可预测的命名规则,定义基于MAC地址udev规则。 + +**下面是如何在CentOS或RHEL7命名网络接口。** + +首先,让我们来禁用该可预测命名规则。对于这一点,你可以在启动时传递“net.ifnames=0”的内核参数。这是通过编辑/etc/default/grub并加入“net.ifnames=0”到GRUB_CMDLINE_LINUX变量来实现的。 + +![](https://farm4.staticflickr.com/3898/15315687725_c82fbef5bc_z.jpg) + +然后运行这条命令来重新生成GRUB配置并更新内核参数。 + + $ sudo grub2-mkconfig -o /boot/grub2/grub.cfg + +![](https://farm4.staticflickr.com/3909/15128981250_72f45633c1_z.jpg) + +接下来,编辑(或创建)一个udev的网络命名规则文件(/etc/udev/rules.d/70-persistent-net.rules),并添加下面一行。更换成你自己的MAC地址和接口。 + + $ sudo vi /etc/udev/rules.d/70-persistent-net.rules + +---------- + + SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="08:00:27:a9:7a:e1", ATTR{type}=="1", KERNEL=="eth*", NAME="sushi" + +最后,重启电脑并验证新的接口名。 + +![](https://farm4.staticflickr.com/3861/15111594847_14e0c5a00d_z.jpg) + +请注意,配置重命名后的接口仍然是你的责任。如果网络配置(例如,IPv4设置,防火墙规则)是基于旧名称(变更前)的,则需要更新的网络配置以反映更改的名称。 + +-------------------------------------------------------------------------------- + +via: http://ask.xmodulo.com/change-network-interface-name-centos7.html + +译者:[geekpi](https://github.com/geekpi) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[1]:https://access.redhat.com/documentation/en-US/Red_Hat_Enterprise_Linux/6/html/Deployment_Guide/appe-Consistent_Network_Device_Naming.html \ No newline at end of file diff --git a/translated/tech/20140925 Linux FAQs with Answers--How to configure a static IP address on CentOS 7.md b/translated/tech/20140925 Linux FAQs with Answers--How to configure a static IP address on CentOS 7.md new file mode 100644 index 0000000000..e126b930f3 --- /dev/null +++ b/translated/tech/20140925 Linux FAQs with Answers--How to configure a static IP address on CentOS 7.md @@ -0,0 +1,77 @@ +Linux有问必答——如何为CentOS 7配置静态IP地址 +================================================================================ +> **问题**:在CentOS 7上,我想要将我其中一个网络接口从DHCP改为静态IP地址配置,如何才能永久为CentOS或RHEL 7上的网络接口分配静态IP地址? + +如果你想要为CentOS 7中的某个网络接口设置静态IP地址,有几种不同的方法,这取决于你是否想要使用网络管理器。 + +网络管理器是一个动态的网络控制与配置系统,它用于在网络设备可用时保持设备和连接开启并激活。默认情况下,CentOS/RHEL 7安装有网络管理器,并处于启用状态。 + +使用下面的命令来验证网络管理器服务的状态: + + $ systemctl status NetworkManager.service + +运行以下命令来检查受网络管理器管理的网络接口: + + $ nmcli dev status + +![](https://farm4.staticflickr.com/3861/15295802711_a102a3574d_z.jpg) + +如果某个接口的nmcli的输出结果是“已连接”(如本例中的enp0s3),这就是说该接口受网络管理器管理。你可以轻易地为某个特定接口禁用网络管理器,以便你可以自己为它配置一个静态IP地址。 + +下面将介绍**在CentOS 7上为网络接口配置静态IP地址的两种方式**,在例子中我们将对名为enp0s3的网络接口进行配置。 + +### 不使用网络管理配置静态IP地址 ### + +进入/etc/sysconfig/network-scripts目录,找到该接口的配置文件(ifcfg-enp0s3)。如果没有,请创建一个。 + +![](https://farm4.staticflickr.com/3911/15112399977_d3df8e15f5_z.jpg) + +打开配置文件并编辑以下变量: + +![](https://farm4.staticflickr.com/3880/15112184199_f4cbf269a6.jpg) + +在上图中,“NM_CONTROLLED=no”表示该接口将通过该配置进行设置,而不是通过网络管理器进行管理。“ONBOOT=yes”告诉我们,系统将在启动时开启该接口。 + +保存修改并使用以下命令来重启网络服务: + + # systemctl restart network.service + +现在验证接口是否配置正确: + + # ip add + +![](https://farm6.staticflickr.com/5593/15112397947_ac69a33fb4_z.jpg) + +### 使用网络管理器配置静态IP地址 ### +如果你想要使用网络管理器来管理该接口,你可以使用nmtui(网络管理器文本用户界面),它提供了在终端环境中配置配置网络管理器的方式。 + +在使用nmtui之前,首先要在/etc/sysconfig/network-scripts/ifcfg-enp0s3中设置“NM_CONTROLLED=yes”。 + +现在,请按以下方式安装nmtui。 + + # yum install NetworkManager-tui + +然后继续去编辑enp0s3接口的网络管理器配置: + + # nmtui edit enp0s3 + +在下面的屏幕中,我们可以手动输入与/etc/sysconfig/network-scripts/ifcfg-enp0s3中所包含的内容相同的信息。 + +使用箭头键在屏幕中导航,按回车选择值列表中的内容(或填入想要的内容),最后点击屏幕底部右侧的确定按钮。 + +![](https://farm4.staticflickr.com/3878/15295804521_4165c97828_z.jpg) + +最后,重启网络服务。 + + # systemctl restart network.service + +好了,现在一切就绪。 + +-------------------------------------------------------------------------------- + +via: http://ask.xmodulo.com/configure-static-ip-address-centos7.html + +译者:[GOLinux](https://github.com/GOLinux) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 diff --git a/translated/tech/20140925 Linux FAQs with Answers--How to embed all fonts in a PDF document generated with LaTex.md b/translated/tech/20140925 Linux FAQs with Answers--How to embed all fonts in a PDF document generated with LaTex.md new file mode 100644 index 0000000000..29b98ab3d4 --- /dev/null +++ b/translated/tech/20140925 Linux FAQs with Answers--How to embed all fonts in a PDF document generated with LaTex.md @@ -0,0 +1,39 @@ +Linux有问必答-- 如何在PDF中嵌入LaTex中的所有字体 +================================================================================ +> **提问**: 我通过编译LaTex源文件生成了一份PDF文档。然而,我注意到,并不是所有字体都嵌入到了PDF文档中。我怎样才能确保所有的字体嵌入在由LaTex生成的PDF文档中? + +当你创建一个PDF文件时,在PDF文件中嵌入字体是一个好主意。如果你不嵌入字体,PDF浏览器可以在计算机上没有字体的情况下使用其他东西代替。这将导致文件被在不同的PDF浏览器或操作系统平台上呈现不同的样式。当你打印出来的文档时,缺少的字体是一个问题。 + +当你从LaTex中生成PDF文档时(例如用pdflatex或dvipdfm),可能并不是所有的字体都嵌入在PDF文档中。例如,[pdffonts][1]下面的输出中提示PDF文档中有缺少的字体(如Helvetica)。 + +![](https://farm3.staticflickr.com/2944/15344704481_d691f66e75_z.jpg) + +为了避免这样的问题,下面是如何在LaTex编译时嵌入所有的字体。 + + $ latex document.tex + $ dvips -Ppdf -G0 -t letter -o document.ps document.dvi + $ ps2pdf -dPDFSETTINGS=/prepress \ + -dCompatibilityLevel=1.4 \ + -dAutoFilterColorImages=false \ + -dAutoFilterGrayImages=false \ + -dColorImageFilter=/FlateEncode \ + -dGrayImageFilter=/FlateEncode \ + -dMonoImageFilter=/FlateEncode \ + -dDownsampleColorImages=false \ + -dDownsampleGrayImages=false \ + document.ps document.pdf + +现在你可以看到所有的字体都被嵌入到PDF中了。 + +![](https://farm4.staticflickr.com/3890/15161184500_15ec673dca_z.jpg) + +-------------------------------------------------------------------------------- + +via: http://ask.xmodulo.com/embed-all-fonts-pdf-document-latex.html + +译者:[geekpi](https://github.com/geekpi) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[1]:http://ask.xmodulo.com/check-which-fonts-are-used-pdf-document.html \ No newline at end of file diff --git a/translated/tech/20140926 How To Reset Root Password On CentOS 7.md b/translated/tech/20140926 How To Reset Root Password On CentOS 7.md new file mode 100644 index 0000000000..d9da58dd6c --- /dev/null +++ b/translated/tech/20140926 How To Reset Root Password On CentOS 7.md @@ -0,0 +1,52 @@ +如何重置CentOS 7的Root密码 +=== + +重置Centos 7 Root密码的方式和Centos 6完全不同。让我来展示一下到底如何操作。 + +1 - 在启动grub菜单,选择编辑选项启动 + +![](http://180016988.r.cdn77.net/wp-content/uploads/2014/09/Selection_003.png) + +2 - 按键盘e键,来进入编辑界面 + +![](http://180016988.r.cdn77.net/wp-content/uploads/2014/09/Selection_005.png) + +3 - 找到Linux 16的那一行,将ro改为rw init=/sysroot/bin/ + +![](http://180016988.r.cdn77.net/wp-content/uploads/2014/09/Selection_006.png) + +4 - 现在按下 Control+x ,使用单用户模式启动 + +![](http://180016988.r.cdn77.net/wp-content/uploads/2014/09/Selection_007.png) + +5 - 现在,可以使用下面的命令访问系统 + + chroot /sysroot + +6 - 重置密码 + + passwd root + +7 - 更新系统信息 + + touch /.autorelabel + +8 - 退出chroot + + exit + +9 - 重启你的系统 + + reboot + +就是这样! + +--- + +via: http://www.unixmen.com/reset-root-password-centos-7/ + +作者:M.el Khamlichi +译者:[su-kaiyao](https://github.com/su-kaiyao) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 diff --git a/translated/tech/20140926 How to manage configurations in Linux with Puppet and Augeas.md b/translated/tech/20140926 How to manage configurations in Linux with Puppet and Augeas.md new file mode 100644 index 0000000000..17e7e21f5d --- /dev/null +++ b/translated/tech/20140926 How to manage configurations in Linux with Puppet and Augeas.md @@ -0,0 +1,152 @@ +如何用Puppet和Augeas管理Linux配置 +================================================================================ +虽然[Puppet][1](注:此文原文原文中曾今做过,文件名:“20140808 How to install Puppet server and client on CentOS and RHEL.md”,如果翻译发布过,可修改此链接为发布地址)是一个非常独特的和有用的工具,在有些情况下你可以使用一点不同的方法。要修改的配置文件已经在几个不同的服务器上且它们在这时是互补相同的。Puppet实验室的人也意识到了这一点并集成了一个伟大的工具,称之为[Augeas][2],它是专为这种使用情况而设计的。 + + +Augeas可被认为填补了Puppet能力的缺陷,其中一个特定对象的资源类型(如主机资源来处理/etc/hosts中的条目)还不可用。在这个文档中,您将学习如何使用Augeas来减轻你管理配置文件的负担。 + +### Augeas是什么? ### + +Augeas基本上就是一个配置编辑工具。它以他们原生的格式解析配置文件并且将它们转换成树。配置的更改可以通过操作树来完成,并可以以原生配置文件格式保存配置。 + +### 这篇教程要达成什么目的? ### + +我们会安装并配置Augeas用于我们之前构建的Puppet服务器。我们会使用这个工具创建并测试几个不同的配置文件,并学习如何适当地使用它来管理我们的系统配置。 + +### 先决条件 ### + +我们需要一台工作的Puppet服务器和客户端。如果你还没有,请先按照我先前的教程来。 + +Augeas安装包可以在标准CentOS/RHEL仓库中找到。不幸的是,Puppet用到的ruby封装的Augeas只在puppetlabs仓库中(或者[EPEL][4])中才有。如果你系统中还没有这个仓库,请使用下面的命令: + +在CentOS/RHEL 6.5上: + + # rpm -­ivh https://yum.puppetlabs.com/el/6.5/products/x86_64/puppetlabs­release­6­10.noarch.rpm + +在CentOS/RHEL 7上: + + # rpm -­ivh https://yum.puppetlabs.com/el/7/products/x86_64/puppetlabs­release­7­10.noarch.rpm + +在你成功地安装了这个仓库后,在你的系统中安装Ruby­Augeas: + + # yum install ruby­augeas + +或者如果你是从我的上一篇教程中继续的,使用puppet的方法安装这个包。在/etc/puppet/manifests/site.pp中修改你的custom_utils类,在packages这行中加入“ruby­augeas”。 + + class custom_utils { + package { ["nmap","telnet","vim­enhanced","traceroute","ruby­augeas"]: + ensure => latest, + allow_virtual => false, + } + } + +### 不带Puppet的Augeas ### + +如我先前所说,最初Augeas并不是来自Puppet实验室,这意味着即使没有Puppet本身我们仍然可以使用它。这种方法可在你将它们部署到Puppet环境之前,验证你的修改和想法是否是正确的。要做到这一点,你需要在你的系统中安装一个额外的软件包。请执行以下命令: + + # yum install augeas + +### Puppet Augeas 示例 ### + +用于演示,这里有几个Augeas使用案例。 + +#### 管理 /etc/sudoers 文件 #### + +1. 给wheel组加上sudo权限。 + +这个例子会向你战士如何在你的GNU/Linux系统中为%wheel组加上sudo权限。 + + # 安装sudo包 + package { 'sudo': + ensure => installed, # 确保sudo包已安装 + } + + # 允许用户属于wheel组来使用sudo + augeas { 'sudo_wheel': + context => '/files/etc/sudoers', # 目标文件是 /etc/sudoers + changes => [ + # 允许wheel用户使用sudo + 'set spec[user = "%wheel"]/user %wheel', + 'set spec[user = "%wheel"]/host_group/host ALL', + 'set spec[user = "%wheel"]/host_group/command ALL', + 'set spec[user = "%wheel"]/host_group/command/runas_user ALL', + ] + } + +现在来解释这些代码做了什么:**spec**定义了/etc/sudoers中的用户段,**[user]**定义了数组中给定的用户,所有的定义的斜杠( / ) 后用户的子部分。因此在典型的配置中这个可以这么表达: + + user host_group/host host_group/command host_group/command/runas_user + +这个将被转换成/etc/sudoers下的这一行: + + %wheel ALL = (ALL) ALL + +2. 添加命令别称 + +下面这部分会向你展示如何定义命令别名,他可以在你的sudoer文件中使用。 + + # 创建新的SERVICE别名,包含了一些基本的特权命令。 + augeas { 'sudo_cmdalias': + context => '/files/etc/sudoers', # The target file is /etc/sudoers + changes => [ + "set Cmnd_Alias[alias/name = 'SERVICES']/alias/name SERVICES", + "set Cmnd_Alias[alias/name = 'SERVICES']/alias/command[1] /sbin/service", + "set Cmnd_Alias[alias/name = 'SERVICES']/alias/command[2] /sbin/chkconfig", + "set Cmnd_Alias[alias/name = 'SERVICES']/alias/command[3] /bin/hostname", + "set Cmnd_Alias[alias/name = 'SERVICES']/alias/command[4] /sbin/shutdown", + ] + } + +sudo命令别名的语法很简单:**Cmnd_Alias**定义了命令别名字段,**[alias/name]**绑定所有给定的别名,/alias/name **SERVICES** 定义真实的别名以及alias/command 是所有命令的数组,每条命令是这个别名的一部分。 + + Cmnd_Alias SERVICES = /sbin/service , /sbin/chkconfig , /bin/hostname , /sbin/shutdown + +关于/etc/sudoers的更多信息,请访问[官方文档][5]。 + +#### 向一个组中加入用户 #### + +要使用Augeas向组中添加用户,你有也许要添加一个新用户,无论是在gid字段后或者在最后一个用户后。我们在这个例子中使用组SVN。这可以通过下面的命令达成: + +在Puppet中: + + augeas { 'augeas_mod_group: + context => '/files/etc/group', # The target file is /etc/group + changes => [ + "ins user after svn/*[self::gid or self::user][last()]", + "set svn/user[last()] john", + ] + } + +使用 augtool: + + augtool> ins user after /files/etc/group/svn/*[self::gid or self::user][last()] augtool> set /files/etc/group/svn/user[last()] john + +### 总结 ### + +目前为止,你应该对如何在Puppet项目中使用Augeas有一个好想法了。随意地试一下,你肯定会经历官方的Augeas文档。这会帮助你了解如何在你的个人项目中正确地使用Augeas,并且它会想你展示你可以用它节省多少时间。 + +如有任何问题,欢迎在下面的评论中发布,我会尽力解答和向你建议。 + +### 有用的链接 ### + +- [http://www.watzmann.net/categories/augeas.html][6]: contains a lot of tutorials focused on Augeas usage. +- [http://projects.puppetlabs.com/projects/1/wiki/puppet_augeas][7]: Puppet wiki with a lot of practical examples. + +-------------------------------------------------------------------------------- + +via: http://xmodulo.com/2014/09/manage-configurations-linux-puppet-augeas.html + +作者:[Jaroslav Štěpánek][a] +译者:[geekpi](https://github.com/geekpi) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://xmodulo.com/author/jaroslav +[1]:http://xmodulo.com/2014/08/install-puppet-server-client-centos-rhel.html +[2]:http://augeas.net/ +[3]:http://xmodulo.com/manage-configurations-linux-puppet-augeas.html +[4]:http://xmodulo.com/2013/03/how-to-set-up-epel-repository-on-centos.html +[5]:http://augeas.net/docs/references/lenses/files/sudoers-aug.html +[6]:http://www.watzmann.net/categories/augeas.html +[7]:http://projects.puppetlabs.com/projects/1/wiki/puppet_augeas \ No newline at end of file diff --git a/translated/tech/20140926 How to monitor user login history on CentOS with utmpdump.md b/translated/tech/20140926 How to monitor user login history on CentOS with utmpdump.md new file mode 100644 index 0000000000..1fcfaa5f55 --- /dev/null +++ b/translated/tech/20140926 How to monitor user login history on CentOS with utmpdump.md @@ -0,0 +1,120 @@ +CentOS监控用户登录历史之utmpdump +================================================================================ +保留、维护和分析日志(如某个特定时期内发生过的,或正在发生的帐号事件),是Linux系统管理员最基础和最重要的任务之一。对于用户管理,检查用户的登入和登出日志(不管是失败的,还是成功的)可以让我们对任何潜在的安全隐患或未经授权使用系统的情况保持警惕。例如,工作时间之外或例假期间的来自未知IP地址或帐号的远程登录应当发出红色警报。 + +在CentOS系统上,用户登录历史存储在以下这些文件中: + +- /var/run/utmp(用于记录当前打开的会话)who和w工具用来记录当前有谁登录以及他们正在做什么,而uptime用来记录系统启动时间。 +- /var/log/wtmp (用于存储系统连接历史记录)last工具用来记录最后登录的用户的列表。 +- /var/log/btmp(记录失败的登录尝试)lastb工具用来记录最后失败的登录尝试的列表。 + +![](https://farm4.staticflickr.com/3871/15106743340_bd13fcfe1c_o.png) + +在本帖中,我将介绍如何使用utmpdump,这个小程序来自sysvinit-tools包,可以用于转储二进制日志文件到文本格式的文件以便检查。此工具默认在CentOS 6和7家族上可用。utmpdump收集到的信息比先前提到过的工具的输出要更全面,这让它成为一个胜任该工作的很不错的工具。除此之外,utmpdump可以用于修改utmp或wtmp。如果你想要修复二进制日志中的任何损坏条目,它会很有用。 + +### Utmpdump的使用及其输出说明 ### + +正如我们之前提到的,这些日志文件,与我们大多数人熟悉的其它日志相比(如/var/log/messages,/var/log/cron,/var/log/maillog),是以二进制格式存储的,因而我们不能使用像less或more这样的文件命令来查看它们的内容。那样看来,utmpdump拯救了世界。 + +为了要显示/var/run/utmp的内容,请运行以下命令: + + # utmpdump /var/run/utmp + +![](https://farm6.staticflickr.com/5595/15106696599_60134e3488_z.jpg) + +同样要显示/var/log/wtmp的内容: + + # utmpdump /var/log/wtmp + +![](https://farm6.staticflickr.com/5591/15106868718_6321c6ff11_z.jpg) + +最后,对于/var/log/btmp: + + # utmpdump /var/log/btmp + +![](https://farm6.staticflickr.com/5562/15293066352_c40bc98ca4_z.jpg) + +正如你所能看到的,三种情况下的输出结果是一样的,除了utmp和btmp的记录是按时间排序,而wtmp的顺序是颠倒的这个原因外。 + +每个日志行格式化成了多列,说明如下。第一个字段显示了会话识别符,而第二个字段则是PID。第三个字段可以是以下值:~~(表示运行等级改变或系统重启),bw(启动守候进程),数字(表示TTY编号),或者字符和数字(表示伪终端)。第四个字段可以为空或用户名、重启或运行级别。第五个字段是主TTY或PTY(伪终端),如果此信息可获得的话。第六个字段是远程主机名(如果是本地登录,该字段为空,运行级别信息除外,它会返回内核版本)。第七个字段是远程系统的IP地址(如果是本地登录,该字段为0.0.0.0)。如果没有提供DNS解析,第六和第七字段会显示相同的信息(远程系统的IP地址)。最后一个(第八)字段指明了记录创建的日期和时间。 + +### Utmpdump使用样例 ### + +下面提供了一些utmpdump的简单使用情况。 + +1. 检查8月18日到9月17日之间某个特定用户(如gacanepa)的登录次数。 + + # utmpdump /var/log/wtmp | grep gacanepa + +![](https://farm4.staticflickr.com/3857/15293066362_fb2dd566df_z.jpg) + +如果你需要回顾先前日期的登录信息,你可以检查/var/log下的wtmp-YYYYMMDD(或wtmp.[1...N])和btmp-YYYYMMDD(或btmp.[1...N])文件,这些是由[logrotate][1]生成的旧wtmp和btmp的归档文件。 + +2. 统计来自IP地址192.168.0.101的登录次数。 + + # utmpdump /var/log/wtmp | grep 192.168.0.101 + +![](https://farm4.staticflickr.com/3842/15106743480_55ce84c9fd_z.jpg) + +3. 显示失败的登录尝试。 + + # utmpdump /var/log/btmp + +![](https://farm4.staticflickr.com/3858/15293065292_e1d2562206_z.jpg) + +在/var/log/btmp输出中,每个日志行都与一个失败的登录尝试相关(如使用不正确的密码,或者一个不存在的用户ID)。上面图片中高亮部分显示了使用不存在的用户ID登录,这警告你有人尝试猜测常用帐号名来闯入系统。这在使用tty1的情况下是个极其严重的问题,因为这意味着某人对你机器上的终端具有访问权限(该检查一下谁拿到了进入你数据中心的钥匙了,也许吧?) + +4. 显示每个用户会话的登入和登出信息 + + # utmpdump /var/log/wtmp + +![](https://farm4.staticflickr.com/3835/15293065312_c762360791_z.jpg) + +在/var/logwtmp中,一次新的登录事件的特征是,第一个字段为‘7’,第三个字段是一个终端编号(或伪终端id),第四个字段为用户名。相关的登出事件会在第一个字段显示‘8’,第二个字段显示与登录一样的PID,而终端编号字段空白。例如,仔细观察上面图片中PID 1463的行。 + +- On [Fri Sep 19 11:57:40 2014 ART] the login prompt appeared in tty1. +- On [Fri Sep 19 12:04:21 2014 ART], user root logged on. +- On [Fri Sep 19 12:07:24 2014 ART], root logged out. + +旁注:第四个字段的LOGIN意味着出现了一次登录到第五字段指定的终端的提示。 + +到目前为止,我介绍一些有点琐碎的例子。你可以将utmpdump和其它一些文本处理工具,如awk、sed、grep或cut组合,来产生过滤和加强的输出。 + +例如,你可以使用以下命令来列出某个特定用户(如gacanepa)的所有登录事件,并发送输出结果到.csv文件,它可以用像LibreOffice Calc或Microsoft Excel之类的文字或工作簿应用程序打开查看。让我们只显示PID、用户名、IP地址和时间戳: + + # utmpdump /var/log/wtmp | grep -E "\[7].*gacanepa" | awk -v OFS="," 'BEGIN {FS="] "}; {print $2,$4,$7,$8}' | sed -e 's/\[//g' -e 's/\]//g' + +![](https://farm4.staticflickr.com/3851/15293065352_91e1c1e4b6_z.jpg) + +就像上面图片中三个块描绘的那样,过滤逻辑操作是由三个管道步骤组成的。第一步用于查找由用户gacanepa触发的登录事件([7]);第二步和第三部用于选择期望的字段,移除utmpdump输出的方括号并设置输出字段分隔符为逗号。 + +当然,如果你想要在以后打开来看,你需要重定向上面的命令输出到文件(添加“>[文件名].csv”到命令后面)。 + +![](https://farm4.staticflickr.com/3889/15106867768_0e37881a25_z.jpg) + +在更为复杂的例子中,如果你想要知道在特定时间内哪些用户(在/etc/passwd中列出)没有登录,你可以从/etc/passwd中提取用户名,然后运行grep命令来获取/var/log/wtmp输出中对应用户的列表。就像你看到的那样,有着无限可能。 + +在进行总结之前,让我们简要地展示一下utmpdump的另外一种使用情况:修改utmp或wtmp。由于这些都是二进制日志文件,你不能像编辑文件一样来编辑它们。取而代之是,你可以将其内容输出成为文本格式,并修改文本输出内容,然后将修改后的内容导入回二进制日志中。如下: + + # utmpdump /var/log/utmp > tmp_output + + # utmpdump -r tmp_output > /var/log/utmp + +这在你想要移除或修复二进制日志中的任何伪造条目时很有用。 + +下面小结一下,utmpdump通过转储详细的登录事件到utmp、wtmp和btmp日志文件,也可以是轮循的旧归档文件,来补充如who,w,uptime,last,lastb之类的标准工具的不足,这也使得它成为一个很棒的工具。 + +你可以随意添加评论以加强本帖的含金量。 + +-------------------------------------------------------------------------------- + +via: http://xmodulo.com/2014/09/monitor-user-login-history-centos-utmpdump.html + +作者:[Gabriel Cánepa][a] +译者:[GOLinux](https://github.com/GOLinux) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://xmodulo.com/author/gabriel +[1]:http://xmodulo.com/2014/09/logrotate-manage-log-files-linux.html diff --git a/translated/tech/20140928 How to Use Systemd Timers.md b/translated/tech/20140928 How to Use Systemd Timers.md new file mode 100644 index 0000000000..bcbe1a1bec --- /dev/null +++ b/translated/tech/20140928 How to Use Systemd Timers.md @@ -0,0 +1,111 @@ +如何使用系统定时器 +================================================================================ +我最近在写一些运行备份的脚本,我决定使用[systemd timers][1]而不是对我而已更熟悉的[cron jobs][2]来管理它们。 + +在我使用时,出现了很多问题需要我去各个地方找资料,这个过程非常麻烦。因此,我想要把我目前所做的记录下来,方便自己的记忆,也方便读者不必像我这样,满世界的找资料了。 + +在我下面提到的步骤中有其他的选择,但是这边是最简单的方法。在此之前,查看**systemd.service**, **systemd.timer**,和**systemd.target**的帮助页面(man),学习你能用它们做些什么。 + +### 运行一个简单的脚本 ### + +假设你有一个脚本叫:**/usr/local/bin/myscript** ,你想要每隔一小时就运行一次。 + +#### Service 文件 #### + +第一步,创建一个service文件,根据你Linux的发行版本放到相应的系统目录(在Arch中,这个目录是**/etc/systemd/system/** 或 **/usr/lib/systemd/system**) + +myscript.service + + [Unit] + Description=MyScript + + [Service] + Type=simple + ExecStart=/usr/local/bin/myscript + +注意,务必将**Type**变量的值设置为"simple"而不是"oneshot"。使用"oneshot"使得脚本只在第一次运行,之后系统会认为你不想再次运行它,从而关掉我们接下去创建的定时器(Timer)。 + +#### Timer 文件 #### + +第二步,创建一个timer文件,把它放在第一步中service文件放置的目录。 + +myscript.timer + + [Unit] + Description=Runs myscript every hour + + [Timer] + # Time to wait after booting before we run first time + OnBootSec=10min + # Time between running each consecutive time + OnUnitActiveSec=1h + Unit=myscript.service + + [Install] + WantedBy=multi-user.target + +#### 授权 / 运行 #### + +授权并运行的是timer文件,而不是service文件。 + + # Start timer, as root + systemctl start myscript.timer + # Enable timer to start at boot + systemctl enable myscript.timer + +### 在同一个Timer上运行多个脚本 ### + +现在我们假设你在相同时间想要运行多个脚本。这种情况,你需要在上面的文件中做适当的修改。 + +#### Service 文件 #### + +像我[之前说过的][3]那样创建你的service文件来运行你的脚本,但是在每个service 文件最后都要包含下面的内容: + + [Install] + WantedBy=mytimer.target + +如果在你的service 文件中有一些规则,确保你使用**Description**字段中的值具体化**After=something.service**和**Before=whatever.service**中的参数。 + +另外的一种选择是(或许更加简单),创建一个包装者脚本来使用正确的规则运行合理的命令,并在你的service文件中使用这个脚本。 + +#### Timer 文件 #### + +你只需要一个timer文件,创建**mytimer.timer**,像我在[上面指出的](4)。 + +#### target 文件 #### + +你可以创建一个以上所有的脚本依赖的target文件。 + +mytimer.target + + [Unit] + Description=Mytimer + # Lots more stuff could go here, but it's situational. + # Look at systemd.unit man page. + +#### 授权 / 启动 #### + +你需要将所有的service文件和timer文件授权。 + + systemctl enable script1.service + systemctl enable script2.service + ... + systemctl enable mytimer.timer + systemctl start mytimer.service + +Good luck. + +-------------------------------------------------------------------------------- + +via: http://jason.the-graham.com/2013/03/06/how-to-use-systemd-timers/#enable--start-1 + +作者:Jason Graham +译者:[译者ID](https://github.com/johnhoow) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[1]:https://fedoraproject.org/wiki/User:Johannbg/QA/Systemd/Systemd.timer +[2]:https://en.wikipedia.org/wiki/Cron +[3]:http://jason.the-graham.com/2013/03/06/how-to-use-systemd-timers/#service-file +[4]:http://jason.the-graham.com/2013/03/06/how-to-use-systemd-timers/#timer-file-1 diff --git a/translated/tech/20140928 How to turn your CentOS box into an OSPF router using Quagga.md b/translated/tech/20140928 How to turn your CentOS box into an OSPF router using Quagga.md new file mode 100644 index 0000000000..bfa2898e8c --- /dev/null +++ b/translated/tech/20140928 How to turn your CentOS box into an OSPF router using Quagga.md @@ -0,0 +1,224 @@ +如何使用Quagga将CentOS放入OSPF路由器中 +================================================================================ +[Quagga][1]是一个可以将Linux放入支持如RIP、OSPF、BGP和IS-IS等主要路由协议的路由器的一个开源路由软件套件。它具有对IPv4和IPv6的完整规定,并支持路由/前缀过滤。Quagga可以是你生命中的救星,以防你的生产路由器一旦宕机,而你没有备用的设备而只能等待更换。通过适当的配置,Quagga甚至可以作为生产路由器。 + +本教程中,我们将连接两个假设之间具有专线连接的分支机构网络(例如,192.168.1.0/24和172.17.1.0/24)。 + +![](https://farm4.staticflickr.com/3861/15172727969_13cb7f037f_b.jpg) + +我们的CentOS位于所述专用链路的两端。两台主机名分别设置为“site-A-RTR”和“site-B-RTR'。下面是IP地址的详细信息。 + +- **Site-A**: 192.168.1.0/24 +- **Site-B**: 172.16.1.0/24 +- **Peering between 2 Linux boxes**: 10.10.10.0/30 + +Quagga包括了几个协同工作的守护进程。在本教程中,我们将重点建立以下守护进程。 + +1. **Zebra**: 核心守护进程,负责内核接口和静态路由。 +1. **Ospfd**: IPv4 OSPF 守护进程. + +### 在CentOS上安装Quagga ### + +我们使用yum安装Quagga。 + + # yum install quagga + +在CentOS7,SELinux默认会阻止quagga将配置文件写到/usr/sbin/zebra。这个SELinux策略会干涉我们接下来要介绍的安装过程,所以我们要禁用此策略。对于这一点,无论是[关闭SELinux][2](这里不推荐),还是如下启用“zebra_write_config'。如果你使用的是CentOS 6的请跳过此步骤。 + + # setsebool -P zebra_write_config 1 + +如果没有这个改变,在我们尝试在Quagga命令行中保存配置的时候看到如下错误。 + + Can't open configuration file /etc/quagga/zebra.conf.OS1Uu5. + +安装完Quagga后,我们要配置必要的对等IP地址,并更新OSPF设置。Quagga自带了一个命令行称为vtysh。vtysh里面用到的Quagga命令与主要的路由器厂商如思科和Juniper是相似的。 + +### 步骤 1: 配置 Zebra ### + +我们首先创建Zebra配置文件,并启用Zebra守护进程。 + + # cp /usr/share/doc/quagga-XXXXX/zebra.conf.sample /etc/quagga/zebra.conf + # service zebra start + # chkconfig zebra on + +启动vtysh命令行: + + # vtysh + +首先,我们为Zebra被指日志文件。输入下面的命令进入vtysh的全局配置模式: + + site-A-RTR# configure terminal + +指定日志文件位置,接着退出模式: + + site-A-RTR(config)# log file /var/log/quagga/quagga.log + site-A-RTR(config)# exit + +永久保存配置: + + site-A-RTR# write + +接下来,我们要确定可用的接口并按需配置它们的IP地址。 + + site-A-RTR# show interface + +---------- + + Interface eth0 is up, line protocol detection is disabled + . . . . . + Interface eth1 is up, line protocol detection is disabled + . . . . . + +配置eth0参数: + + site-A-RTR# configure terminal + site-A-RTR(config)# interface eth0 + site-A-RTR(config-if)# ip address 10.10.10.1/30 + site-A-RTR(config-if)# description to-site-B + site-A-RTR(config-if)# no shutdown + +继续配置eth1参数: + + site-A-RTR(config)# interface eth1 + site-A-RTR(config-if)# ip address 192.168.1.1/24 + site-A-RTR(config-if)# description to-site-A-LAN + site-A-RTR(config-if)# no shutdown + +现在验证配置: + + site-A-RTR(config-if)# do show interface + +---------- + + Interface eth0 is up, line protocol detection is disabled + . . . . . + inet 10.10.10.1/30 broadcast 10.10.10.3 + . . . . . + Interface eth1 is up, line protocol detection is disabled + . . . . . + inet 192.168.1.1/24 broadcast 192.168.1.255 + . . . . . + +---------- + + site-A-RTR(config-if)# do show interface description + +---------- + + Interface Status Protocol Description + eth0 up unknown to-site-B + eth1 up unknown to-site-A-LAN + +永久保存配置: + + site-A-RTR(config-if)# do write + +在site-B上重复上面配置IP地址的步骤。 + +如果一切顺利,你应该可以在site-A的服务器上ping通site-B上的对等IP地址10.10.10.2了。 + +注意一旦Zebra的守护进程启动了,在vtysh命令行中的任何改变都会立即生效。因此没有必要在更改配置后重启Zebra守护进程。 + +### 步骤 2: 配置OSPF ### + +我们首先创建OSPF配置文件,并启动OSPF守护进程: + + # cp /usr/share/doc/quagga-XXXXX/ospfd.conf.sample /etc/quagga/ospfd.conf + # service ospfd start + # chkconfig ospfd on + +现在启动vtysh命令行来继续OSPF配置: + + # vtysh + +输入路由配置模式: + + site-A-RTR# configure terminal + site-A-RTR(config)# router ospf + +可选配置路由id: + + site-A-RTR(config-router)# router-id 10.10.10.1 + +添加在OSPF中的网络: + + site-A-RTR(config-router)# network 10.10.10.0/30 area 0 + site-A-RTR(config-router)# network 192.168.1.0/24 area 0 + +永久保存配置: + + site-A-RTR(config-router)# do write + +在site-B上重复和上面相似的OSPF配置: + + site-B-RTR(config-router)# network 10.10.10.0/30 area 0 + site-B-RTR(config-router)# network 172.16.1.0/24 area 0 + site-B-RTR(config-router)# do write + +OSPF的邻居现在应该启动了。只要ospfd在运行,通过vtysh的任何OSPF相关配置的改变都会立即生效而不必重启ospfd。 + +下一章节,我们会验证我们的Quagga设置。 + +### 验证 ### + +#### 1. 通过ping测试 #### + +首先你应该可以从site-A ping同site-B的LAN子网。确保你的防火墙没有阻止ping的流量。 + + [root@site-A-RTR ~]# ping 172.16.1.1 -c 2 + +#### 2. 检查路由表 #### + +必要的路由应该同时出现在内核与Quagga理由表中。 + + [root@site-A-RTR ~]# ip route + +---------- + + 10.10.10.0/30 dev eth0 proto kernel scope link src 10.10.10.1 + 172.16.1.0/30 via 10.10.10.2 dev eth0 proto zebra metric 20 + 192.168.1.0/24 dev eth1 proto kernel scope link src 192.168.1.1 + +---------- + + [root@site-A-RTR ~]# vtysh + site-A-RTR# show ip route + +---------- + + Codes: K - kernel route, C - connected, S - static, R - RIP, O - OSPF, + I - ISIS, B - BGP, > - selected route, * - FIB route + + O 10.10.10.0/30 [110/10] is directly connected, eth0, 00:14:29 + C>* 10.10.10.0/30 is directly connected, eth0 + C>* 127.0.0.0/8 is directly connected, lo + O>* 172.16.1.0/30 [110/20] via 10.10.10.2, eth0, 00:14:14 + C>* 192.168.1.0/24 is directly connected, eth1 + +#### 3. 验证OSPF邻居和路由 #### + +在vtysh命令行中,你可以检查必要的邻居是否在线与是否已经学习了合适的路由。 + + [root@site-A-RTR ~]# vtysh + site-A-RTR# show ip ospf neighbor + +![](https://farm3.staticflickr.com/2943/15160942468_d348241bd5_z.jpg) + +本教程中,我们将重点放在使用Quagga配置基本的OSPF。在一般情况下,Quagga能让我们能够轻松在一台普通的Linux机器上配置动态路由协议,如OSPF、RIP或BGP。启用了Quagga的机器可以与你网络中的其他路由器进行通信和交换路由信息。由于它支持主要的开放标准的路由协议,它或许是许多情况下的首选。更重要的是,Quagga的命令行界面与主要路由器厂商如思科和Juniper几乎是相同的,这使得部署和维护Quagga机器变得非常容易。 + + +希望这些对你们有帮助。 + +-------------------------------------------------------------------------------- + +via: http://xmodulo.com/turn-centos-box-into-ospf-router-quagga.html + +作者:[Sarmed Rahman][a] +译者:[geekpi](https://github.com/geekpi) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://xmodulo.com/author/sarmed +[1]:http://www.nongnu.org/quagga/ +[2]:http://xmodulo.com/how-to-disable-selinux.html \ No newline at end of file diff --git a/translated/tech/20140928 How to use xargs command in Linux.md b/translated/tech/20140928 How to use xargs command in Linux.md new file mode 100644 index 0000000000..5f5e5e120d --- /dev/null +++ b/translated/tech/20140928 How to use xargs command in Linux.md @@ -0,0 +1,116 @@ +如何在Linux里使用xargs命令 +================================================================================ +你是否遇到过这样的情况,需要一遍又一遍地对多个文件执行同样的操作?如果有过,那你肯定会深有感触这是多么的无聊和效率低下。还好有种简单的方式,可以在类Unix操作系统中使用xargs命令解决这个烦恼。通过这个命令你可以有效地处理多个文件,节省你的时间和精力。在这篇教程中,你可以学到如何一次性对多个文件执行命令或脚本操作,再也不用担心像单独处理无数个日志或数据文件那样吓人的任务了。 + +xargs命令有两个要点。第一,你必须列出目标文件。第二,你必须指定对每个文件需要执行的命令或脚本。 + +这篇教程会涉及三个应用场景,xargs命令被用来处理分布在不同目录下的文件: + +1. 计算所有文件的行数 +1. 打印指定文件的第一行 +1. 对每个文件执行一个自定义脚本 + +请看下面这个叫xargstest的目录(用tree命令以及-i和-f选项显示了目录树结构,这样可以避免缩进显示而且每个文件都会带有完整路径): + + $ tree -if xargstest/ + +![](https://farm3.staticflickr.com/2942/15334985981_ce1a192def.jpg) + +这六个文件的内容分别如下: + +![](https://farm4.staticflickr.com/3882/15346287662_a3084a8e4f_o.png) + +这个**xargstest**目录,以及它包含的子目录和文件将用在下面的例子中。 + +### 场景1:计算所有文件的行数 ### + +就像之前提到的,使用xargs命令的第一个要点是一个用来运行命令或脚本的文件列表。我们可以用find命令来确定和列出目标文件。选项**-name 'file??'**指定了xargstest目录下那些名字以"file"开头并跟随两个任意字符的文件才是匹配的。这个搜索默认是递归的,意思是find命令会在xargstest和它的子目录下搜索匹配的文件。 + + $ find xargstest/ -name 'file??' + +---------- + + xargstest/dir3/file3B + xargstest/dir3/file3A + xargstest/dir1/file1A + xargstest/dir1/file1B + xargstest/dir2/file2B + xargstest/dir2/file2A + +我们可以通过管道把结果发给sort命令让文件名按顺序排列: + + $ find xargstest/ -name 'file??' | sort + +---------- + + xargstest/dir1/file1A + xargstest/dir1/file1B + xargstest/dir2/file2A + xargstest/dir2/file2B + xargstest/dir3/file3A + xargstest/dir3/file3B + +然后我们需要第二个部分,就是需要执行的命令。我们使用带有-l选项的wc命令来计算每个文件包含的换行符数目(会在输出的每一行的前面打印出来): + + $ find xargstest/ -name 'file??' | sort | xargs wc -l + +---------- + + 1 xargstest/dir1/file1A + 2 xargstest/dir1/file1B + 3 xargstest/dir2/file2A + 4 xargstest/dir2/file2B + 5 xargstest/dir3/file3A + 6 xargstest/dir3/file3B + 21 total + +可以看到,不用对每个文件手动执行一次wc -l命令,而xargs命令可以让你在一步里完成所有操作。那些之前看起来无法完成的任务,例如单独处理数百个文件,现在可以轻松进行了。 + +### 场景2:打印指定文件的第一行 ### + +既然对xargs命令的使用已经有一点基础了,你可以自由选择执行什么命令。有时,你也许希望只对一部分文件执行操作而忽略其他的。在这种情况下,你可以使用find命令的-name选项以及?通配符(匹配任意单个字符)来选中特定文件并通过管道输出给xargs命令。举个例子,如果你想打印以“B”字符结尾的文件而忽略以“A”结尾的文件的第一行,可以使用下面的find、xargs和head命令组合来完成(head -n1会打印一个文件的第一行): + + $ find xargstest/ -name 'file?B' | sort | xargs head -n1 + +---------- + + ==> xargstest/dir1/file1B <== + one + + ==> xargstest/dir2/file2B <== + one + + ==> xargstest/dir3/file3B <== + one + +你将看到只有以“B”结尾的文件会被处理,而所有以“A”结尾的文件都被忽略了。 + +### 场景3:对每个文件执行一个自定义脚本 ### + +最后,你也许希望对一些文件执行一个自定义脚本(例如Bash、Python或是Perl)。要做到这个,只要简单地把你的自定义脚本名字替换掉之前例子中的wc和head命令就好了: + + $ find xargstest/ -name 'file??' | xargs myscript.sh + +自定义脚本**myscript.sh**需要写成接受一个文件名作为参数并处理这个文件。上面的命令将为find命令找到的每个文件分别调用脚本。 + +注意一下上面的例子中的文件名并没有包含空格。通常来说,在Linux环境下操作没有空格的文件名会舒服很多。如果你实在是需要处理名字中带有空格的文件,上边的命令就不能用了,需要稍微处理一下来让它可以被接受。这可以通过find命令的-print0选项(它会打印完整的文件名到标准输出,并以空字符结尾),以及xargs命令的-0选项(它会以空字符作为字符串结束标记)来实现,就像下面的例子: + + $ find xargstest/ -name 'file*' -print0 | xargs -0 myscript.sh + +注意一下,-name选项所跟的参数已经改为'file\*',意思是所有以"file"开头而结尾可以是任意字符的文件都会被选中。 + +### 总结 ### + +在看完这篇教程后你应该会理解xargs命令的作用,以及如何应用到自己的工作中。很快你就可以有时间享受这个命令所带来的高效率,而不哟给你花时间在一些重复的任务上了。想了解更详细的信息以及更多的选项,你可以在终端中输入'man xargs'命令来查看xargs的文档。 + +-------------------------------------------------------------------------------- + +via: http://xmodulo.com/xargs-command-linux.html + +作者:[Joshua Reed][a] +译者:[zpl1025](https://github.com/zpl1025) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://xmodulo.com/author/joshua diff --git a/translated/tech/20140929 Git Rebase Tutorial--Going Back in Time with Git Rebase.md b/translated/tech/20140929 Git Rebase Tutorial--Going Back in Time with Git Rebase.md new file mode 100644 index 0000000000..ad1938d8ca --- /dev/null +++ b/translated/tech/20140929 Git Rebase Tutorial--Going Back in Time with Git Rebase.md @@ -0,0 +1,109 @@ +Git Rebase教程: 用Git Rebase让时光倒流 +================================================================================ +![](https://www.gravatar.com/avatar/7c148ace0d63306091cc79ed9d9e77b4?d=mm&s=200) + +Christoph Burgdorf自10岁时就是一名程序员,他是HannoverJS Meetup网站的创始人,并且一直活跃在AngularJS社区。他也是非常了解gti的内内外外,在那里他举办一个[thoughtram][1]的工作室来帮助初学者掌握该技术。 + +下面的教程最初发表在他的[blog][2]。 + +---------- + +### 教程: Git Rebase ### + +想象一下你正在开发一个激进的新功能。这将是很灿烂的但它需要一段时间。您这几天也许是几个星期一直在做这个。 + +你的功能分支已经超前master有6个提交了。你是一个优秀的开发人员并做了有意义的语义提交。但有一件事情:你开始慢慢意识到,这个野兽仍需要更多的时间才能真的做好准备被合并回主分支。 + + m1-m2-m3-m4 (master) + \ + f1-f2-f3-f4-f5-f6(feature) + +你也知道的是,一些地方实际上是少耦合的新功能。它们可以更早地合并到主分支。不幸的是,你想将部分合并到主分支的内容存在于你六个提交中的某个地方。更糟糕的是,它也包含了依赖于你的功能分支的之前的提交。有人可能会说,你应该在第一处地方做两次提交,但没有人是完美的。 + + m1-m2-m3-m4 (master) + \ + f1-f2-f3-f4-f5-f6(feature) + ^ + | + mixed commit + +在你准备提交的时间,你没有预见到,你可能要逐步把该功能合并入主分支。哎呀!你不会想到这件事会有这么久。 + +你需要的是一种方法可以回溯历史,把它并分成两次提交,这样就可以把代码都安全地分离出来,并可以移植到master分支。 + +用图说话,就是我们需要这样。 + + m1-m2-m3-m4 (master) + \ + f1-f2-f3a-f3b-f4-f5-f6(feature) + +在将工作分成两个提交后,我们就可以cherry-pick出前面的部分到主分支了。 + +原来Git自带了一个功能强大的命令git rebase -i ,它可以让我们这样做。它可以让我们改变历史。改变历史可能会产生问题,并作为一个经验法应尽快避免历史与他人共享。在我们的例子中,虽然我们只是改变我们的本地功能分支的历史。没有人会受到伤害。这这么做了! + +好吧,让我们来仔细看看f3提交究竟修改了什么。原来我们共修改了两个文件:userService.js和wishlistService.js。比方说,userService.js的更改可以直接合入主分支而wishlistService.js不能。因为wishlistService.js甚至没有在主分支存在。这根据的是f1提交中的介绍。 + +>>专家提示:即使是在一个文件中更改,git也可以搞定。但这篇博客中我们要让事情变得简单。 + +我们已经建立了一个[公众演示仓库][3],我们将使用这个来练习。为了便于跟踪,每一个提交信息的前缀是在上面的图表中使用的假的SHA。以下是git在分开提交f3时的分支图。 + +![](https://s3.amazonaws.com/codementor_content/2014-Sep-week3/git1.png) + +现在,我们要做的第一件事就是使用git的checkout功能checkout出我们的功能分支。用git rebase -i master开始做rebase。 + +现在接下来git会用配置的编辑器打开(默认为Vim)一个临时文件。 + +![](https://s3.amazonaws.com/codementor_content/2014-Sep-week3/git2.png) + +该文件为您提供一些rebase选择,它带有一个提示(蓝色文字)。对于每一个提交,我们可以选择的动作有pick、rwork、edit、squash、fixup和exec。每一个动作也可以通过它的缩写形式p、r、e、s、f和e引用。描述每一个选项超出了本文范畴,所以让我们专注于我们的具体任务。 + +我们要为f3提交选择编辑选项,因此我们把内容改变成这样。 + +现在我们保存文件(在Vim中是按下后输入:wq,最后是按下回车)。接下来我们注意到git在编辑选项中选择的提交处停止了rebase。 + +这意味这git开始为f1、f2、f3生效仿佛它就是常规的rebase但是在f3**之后**停止。事实上,我们可以看一眼停止的地方的日志就可以证明这一点。 + +要将f3分成两个提交,我们所要做的是重置git的指针到先前的提交(f2)而保持工作目录和现在一样。这就是git reset在混合模式在做的。由于混合模式是git reset的默认模式,我们可以直接用git reset head~1。就这么做并在运行后用git status看下发生了什么。 + +git status告诉我们userService.js和wishlistService.js被修改了。如果我们与行git diff 我们就可以看见在f3里面确切地做了哪些更改。 + +如果我们看一眼日志我们会发现f3已经消失了。 + +现在我们有了准备提交的先前的f3提交而原先的f3提交已经消失了。记住虽然我们仍旧在rebase的中间过程。我们的f4、f5、f6提交还没有缺失,它们会在接下来回来。 + + +让我们创建两个新的提交:首先让我们为可以提交到主分支的userService.js创建一个提交。运行git add userService.js 接着运行 git commit -m "f3a: add updateUser method"。 + +太棒了!让我们为wishlistService.js的改变创建另外一个提交。运行git add wishlistService.js,接着运行git commit -m "f3b: add addItems method". + +让我们在看一眼日志。 + +这就是我们想要的除了f4、f5、f6仍旧缺失。这是因为我们仍在rebase交互的中间,我们需要告诉git继续rebase。用下面的命令继续:git rebase --continue。 + +让我们再次检查一下日志。 + +就是这样。我们现在已经得到我们想要的历史了。先前的f3提交现在已经被分割成两个提交f3a和f3b。剩下的最后一件事是cherry-pick出f3a提交到主分支上。 + +为了完成最后一步,我们首先切换到主分支。我们用git checkout master。现在我们就可以用cherry-pick命令来拾取f3a commit了。本例中我们可以用它的SHA值bd47ee1来引用它。 + +现在f3a这个提交i就在主分支的最上面了。这就是我们需要的! + +这篇文章的长度看起来需要花费很大的功夫,但实际上对于一个git高级用户而言这只是一会会。 + +>注:Christoph目前正在与Pascal Precht写一本关于[Git rebase][4]的书,您可以在leanpub订阅它并在准备出版时获得通知。 + +-------------------------------------------------------------------------------- + +via: https://www.codementor.io/git-tutorial/git-rebase-split-old-commit-master + +作者:[cburgdorf][a] +译者:[geekpi](https://github.com/geekpi) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:https://www.codementor.io/cburgdorf +[1]:http://thoughtram.io/ +[2]:http://blog.thoughtram.io/posts/going-back-in-time-to-split-older-commits/ +[3]:https://github.com/thoughtram/interactive-rebase-demo +[4]:https://leanpub.com/rebase-the-complete-guide-on-rebasing-in-git \ No newline at end of file diff --git a/translated/tech/20140930 How to Boot Linux ISO Images Directly From Your Hard Drive.md b/translated/tech/20140930 How to Boot Linux ISO Images Directly From Your Hard Drive.md new file mode 100644 index 0000000000..3dcc1a95c3 --- /dev/null +++ b/translated/tech/20140930 How to Boot Linux ISO Images Directly From Your Hard Drive.md @@ -0,0 +1,94 @@ +直接从硬盘启动Linux ISO镜像 +================================================================================ +![](data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAooAAAEsAgMAAAA5t3pxAAAABGdBTUEAALGPC/xhBQAAAAxQTFRFAAAALAAeqKio/v7+NGqafgAABflJREFUeNrt3L1u4zgQB/DU7q+/8qCnuJegBQcQVLlY98RWhoKrDu4V4LZaHCAgp/chUuYpWAY6DofUh6PdtXcVcZL8ZUSmaSf5mSKHY0rJzQ22RbbflPTtTxhhhBFGGGGEEUYYYYQRRhhhhBFGGGH8zrY9e/xpVycxHup6X+/pvnWltp4zHlztrdvfe+Mu1BzqtYz1vvFGkrJ27jVK7em9NNHI35HSWO8P9Zf6UFPbfamjiPZU29bU9qsa1T9sVGMjy7f+HbgKFrk91e5COYVx6I+hTdU2tN7WtyXvyah8+dCsZbxv7r3D3avYjvu6dT3vU2/kHsj7ttk53Y5GzIr98T72x3owuiPvWi8a9/51vK/VLpTXNLrROmtU+2isg24w1usam2BshjFz6xX1yHjr3f2YabjbrhbD9xRp4j2PGYo5tfs6NBxl2ubW1bUNx55tfdhT+YD5GkYYYYQRRhhhhBFGGGGEEUYYYfyhsewEbm/RKPAYlzDCCCOMML4zoxFvNJqNBYy/aHwy9NW5vVyj1fRVKMlGvsEIo5gxY73RSjVW5slUrh1zt8d8DSOM78Y4Hs99Oe+r8j7BNImM5ayxGBlj1rZOFjdndL941qhEGSmC+0hON81RvTMlR3dDJiqtlWl+Y762RnMWSWWeHelYc51SZLJ6rUzz2zmFor0vcw0b+egWo/rXzz7mjJ1rRXe8qS19eWo8RqNKaaTfqg23mVHnxtzIN9I4F2G0peJxcz5muB8OxjUyzXljpV2c8fFniD0um7SVoTqOPWa1TPPS+Trl6sp7MiI3+2DG2U6pkxin8bjo9/lZTWVKs8YK4K8Y3WykUhmti9XPluIz52EUyTvfYs/+mVhDc00+ys7XNRr9WMRcsQizNZWo9rGINSmNT5qN47n5hdH3x86kM3bWGxUbO3vsjfRMrKH30D3nicaMUWOjO6Kmb0fl29HX+GxSpTZqy0alz41KJzdyf1TlZMzkL8eMM6aKj5V5LHyGqGlNgiINfUIgIz0Ta6rwOTbxXKilzoXDVqVMG5GbwfgT+eOwXRIp9WKx55r8cWosZ346xfnOZUyle1ysbOT88XttmYefWfr1DkpSljJelz9yjKJX0/pk3j/ycd5Hr8/uZsIaR76Y8Zr8UYXZ02paa8n7Ryyin0DHmuasJY3X5Y88mMLvZ2NYpxwb3SvNssZr8kf6riOtUzpJZQfj0Rs7y8YhT0qRP/qxYWgVsD/WYZ3St6OKRv1KxkvyRw57L41KT41maeMV+WO/gk5Gm49WTidjht7xgrHnuvwxRhvjemOlKxse8dqlpVe4vbvv7JIx/Lr88bqjpxc3XpI/Js/DkZt9AKMRbvRnjUbjIfcPS7+nKLL2J7FLjKU/769DjORMI7VRm+l56c/KTYHOVggzjs9L5zTZ+jzaG5UEY3l2rtK5vNF44/ENGHMj5VhPjZSpunzW56tKyzQq345K0Jihc9bj89JkLDmNFWSs9Pi8tMsJ/ed3STEcOQWMMP6EUcs20nwyGFNEmwvi46QdU0TtS4x05VG81lGqka+A5PXHFBnjBf2xzyn8WkqCjPGSduz4ejiaqZNkjBcd634lNk3GeL1R8pgxIXuUHHvcvZYaw5FTLGDcttK2/2B8XWPWPog23kyMd5u77C6TZswyMsbtoc1O2UmWkUx32e/Z15b2Mo1//EumzYlsm5M3ttKMf58yf3P90bffQ/uXOOPXLDvdbMh4t2HjQyayHdvsFPthbE9x/XFiFDmuszBmNlKNFMMp6rjY7W0yYzhyigWMyMM/mHF8HUcu0mhGLr5qqEi6DvnN9cfeqFS8+jHVWsC8sVRPhkXWUrkz8oy5sjoaqRzaUcky8t/l0nWGVGbjUaCRr4UcjKnWIX9kNCOj0jKP9dho5BnDX9nLNHaW/hdAFf4rAZXpyh5ZMRw5BYwwwggjjDDCCCOMMMIII4wwwggjjDDCCCOMMMIII4wwwggjjDDCCCOMMMIII4wwwggjjDDCCCOMMMIII4wwwggjjDDCCCOMMMIIo3TjG9j+B4tUkGfI5p/jAAAAAElFTkSuQmCC) + +Linux的GRUB2启动加载器可以直接从硬盘启动Linux ISO文件,可以启动Live CD,甚至可以不用烧录到磁盘来安装Linux到另外一个硬盘分区或从USB驱动启动。 + +我们在Ubuntu 14.04上实施了该过程——Ubuntu及基于Ubuntu的Linux版本对此支持良好。[其它Linux发行版][1]上的工作原理也类似。 + +### 获取Linux ISO文件 ### + +这一密技需要你的硬盘驱动器上安装有Linux系统,你的计算机必须使用[GRUB2启动加载器][2],这是大多数Linux系统的标准启动加载器。不好意思,你是不能使用Windows启动加载器来直接启动一个Linux ISO文件的。 + +下载你想要使用的ISO文件,并放到你的Linux分区中。GRUB2应该支持大多数Linux系统的。如果你想要在live环境中使用它们,而不想将它们安装到硬盘驱动器上,请确认你下载的是各个Linux ISO的“[live CD][3]”版本。很多基于Linux的可启动工具盘也应该可以工作。 + +### 检查ISO文件内容 ### + +你可能需要检查ISO文件来明确确定指定的文件在哪里。例如,你可以通过使用Ubuntu及其它基于GNOME的桌面环境中的归档管理器/File Roller文件管理器这些图形化应用程序来打开ISO文件来完成此项工作。在Nautilus文件管理器中,右击ISO文件并选择使用归档管理器打开。 + +定位内核文件和initrd映像。如果你正在使用Ubuntu ISO文件,你会在卡斯帕文件夹中找到这些文件——vmlinuz文件时Linux内核,而initrd文件是initrd映像。后面,你需要知道它们在ISO文件中所处的位置。 + +![](http://cdn8.howtogeek.com/wp-content/uploads/2014/09/650x350xvmlinuz-and-initrd-file-locations.png.pagespeed.ic.hB1yMlHMr2.png) + +### 检查硬盘分区路径 ### + +GRUB使用与Linux不同的“设备命名”结构。在Linux系统中,/dev/sda0是硬盘上的第一个分区——**a**是指第一个硬盘,而**0**是指第一个分区。在GRUB中,与/dev/sda0相对应的是(hd0,1)。**0**指第一个硬盘,而**1**则指它上面的第一个分区。换句话说,在GRUB设备名中,磁盘编号从0开始计数,而分区编号则从1开始计数——是啊,这真是突然令人困惑。例如,(hd3,6)是指第四磁盘上的第六分区。 + +你可以使用**fdisk -l**命令来查看该信息。在Ubuntu上,打开终端并运行以下命令: + + sudo fdisk -l + +你将看到一个Linux设备路径列表,你可以自行将它们转成GRUB设备名。例如,在下面的图片中,我们可以看到有个系统分区是/dev/sda1——那么,对于GRUB而言,它就是(hd0,1)。 + +![](http://cdn8.howtogeek.com/wp-content/uploads/2014/09/650x410xfdisk-l-command.png.pagespeed.ic.yW7uP1_G0C.png) + +### 创建GRUB2启动条目 ### + +添加自定义启动条目的最简单的方式是编辑/etc/grub.d/40_custom脚本,该文件设计用于用户自行添加启动条目。在编辑该文件后,/etc/defaults/grub文件和/etc/grub.d/脚本的内容将合成创建/boot/grub/grub.cfg文件——你不应该手工编辑该文件。它设计用于通过你在其它文件指定的设置自动生成。 + +你需要以root特权打开/etc/grub.d/40_custom文件来编辑。在Ubuntu上,你可以通过打开终端窗口,并运行以下命令来完成: + + sudo gedit /etc/grub.d/40_custom + +放轻松点,你可以用你喜爱的文本编辑打开该文件。例如,你可以替换命令中“gedit”为“nano”,在[Nano文本编辑器][4]中打开它。 + +除非你已经添加了其它自定义启动条目,否则你应当看到的是一个几乎空的文件。你需要在[注释][5]行下添加一个或多个ISO启动部分。 + +![](http://cdn8.howtogeek.com/wp-content/uploads/2014/09/650x300xadd-custom-boot-menu-entries-to-grub.png.pagespeed.ic.uUT-Yls8xf.png) + +这里为你展示了怎样来从ISO文件启动Ubuntu或基于Ubuntu的发行版,我们在Ubuntu 14.04下作了测试: + + menuentry “Ubuntu 14.04 ISO” { + set isofile=”/home/name/Downloads/ubuntu-14.04.1-desktop-amd64.iso” + loopback loop (hd0,1)$isofile + linux (loop)/casper/vmlinuz.efi boot=casper iso-scan/filename=${isofile} quiet splash + initrd (loop)/casper/initrd.lz + } + +自定义启动条目以包含你期望的菜单的条目名称,计算机上到ISO文件的正确路径,以及包含ISO文件的硬盘和分区设备名。如果vmlinuz和initrd文件的名称或路径不同,请为这些文件指定正确的路径。 + +(如果你有一个独立的/home/分区,忽略/home位,像这样:**set isofile=”/name/Downloads/${isoname}”**)。 + +**重要说明**:不同的Linux版本要求带有不同启动选项的不同的启动条目,GRUB Live ISO多启动项目提供了[用于不同Linux发行版的菜单条目][6]的各种不同类型。你应当可以为你想要启动的ISO文件调整这些示例菜单条目。你也可以仅仅从网页搜索你想要启动的Linux发行版的名称和发行编号,并附带关键词“在GRUB中从ISO启动”,以获取更多信息。 + +![](http://cdn8.howtogeek.com/wp-content/uploads/2014/09/650x392xadd-a-linux-iso-file-to-grub-boot-loader.png.pagespeed.ic.2FR0nOtugC.png) + +如果你想要添加更多ISO启动选项,请为该文件添加额外章节。 + +完成后保存文件,返回终端窗口并运行以下命令: + + sudo update-grub + +![](http://cdn8.howtogeek.com/wp-content/uploads/2014/09/650x249xgenerate-grub.cfg-on-ubuntu.png.pagespeed.ic.5I70sH4ZRs.png) + +再次启动计算机时,你将看到ISO启动条目,你可以选择它来启动ISO文件。在启动时,你可能需要按Shift键来显示GRUB菜单。 + +如果在尝试启动ISO文件时你看见错误信息或黑屏,那么你的启动条目配置不管怎么说配置错误了。即使ISO文件路径和设备名是正确的,ISO文件上的vmlinuz和initrd文件的路径可能是不正确的,或者你启动Linux系统可能需要不同的选项。 + +-------------------------------------------------------------------------------- + +via: http://www.howtogeek.com/196933/how-to-boot-linux-iso-images-directly-from-your-hard-drive/ + +作者:[Chris Hoffman][a] +译者:[GOLinux](https://github.com/GOLinux) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://www.howtogeek.com/author/chrishoffman/ +[1]:http://www.howtogeek.com/191207/10-of-the-most-popular-linux-distributions-compared/ +[2]:http://www.howtogeek.com/196655/how-to-configure-the-grub2-boot-loaders-settings/ +[3]:http://www.howtogeek.com/172810/take-a-secure-desktop-everywhere-everything-you-need-to-know-about-linux-live-cds-and-usb-drives/ +[4]:http://www.howtogeek.com/howto/42980/the-beginners-guide-to-nano-the-linux-command-line-text-editor/ +[5]:http://www.howtogeek.com/118389/how-to-comment-out-and-uncomment-lines-in-a-configuration-file/ +[6]:http://git.marmotte.net/git/glim/tree/grub2 diff --git a/translated/tech/How to configure SNMPv3 on ubuntu 14.04 server.md b/translated/tech/How to configure SNMPv3 on ubuntu 14.04 server.md new file mode 100644 index 0000000000..ee8af99cca --- /dev/null +++ b/translated/tech/How to configure SNMPv3 on ubuntu 14.04 server.md @@ -0,0 +1,97 @@ +在ubuntu14.04上配置SNMPv3 +============================================ +简单网络管理协议(SNMP)是用于IP网络设备管理的标准协议。典型的支持SNMP协议的设备有路由器、交换机、服务器、工作站、打印机及数据机柜等等。SNMP一般被网络管理系统用于监视网络附加设备,令行政注意(译者注:这个不太明白...按字面意思翻了,麻烦校对更正)。SNMP是因特网协议套件中的一个组成部分,它由IETF机构定义。它包含一系列的网络管理标准,其中有一个应用层协议,一个数据库架构以及一组数据对象。[2] + +SNMP将管理数据以变量的形式暴露出来,这些变量描述了系统配置。同时这些变量可以被管理应用查询(或者被设置)。 + +### 为什么需要使用SNMPv3 ### + +尽管SNMPv3所增加的加密功能并不影响协议层面,但是新的文本惯例、概念及术语使得它看起来很不一样。 + +SNMPv3在SNMP的基础之上增强了安全性以及远程配置功能。 + +最初,SNMP最大的缺点就是安全性弱。SNMP的第一与第二个版本中,身份验证仅仅是在管理员与代理间传送一个明文的密码而已。[1]目前每一个SNMPv3的信息都包含了被编码成8进制的安全参数。这些安全参数的具体意义由所选用的安全模型决定。 + +SNMPv3提供了重要的安全特征: + +保密性 -- 加密数据包以防止未经授权的源监听。 + +完整性 -- 数据完整性特性确保数据在传输的时候没有被干扰,并且包含了课选的数据响应保护机制。 + +身份验证 -- 检查数据是否来自一个合法的源 + +### 在ubuntu中安装SNMP服务器及客户端 ### + +打开终端运行下列命令 + + sudo apt-get install snmpd snmp + +安装完成后需要做如下改变。 + +###配置SNMPv3### + +获得守护进程的权限 + +默认的安装仅提供本地的访问权限,如果想要获得外部访问权限的话编辑文件 /etc/default/snmpd。 + + sudo vi /etc/default/snmpd + +改变下列内容 + +将 + + SNMPDOPTS='-Lsd -Lf /dev/null -u snmp -g snmp -I -smux,mteTrigger,mteTriggerConf -p /var/run/snmpd.pid' + +改为 + + SNMPDOPTS='-Lsd -Lf /dev/null -u snmp -I -smux -p /var/run/snmpd.pid -c /etc/snmp/snmpd.conf' + +最后重启 snmpd + + sudo /etc/init.d/snmpd restart + +###定义 SNMPv3 用户,身份验证以及加密参数 ### + +“securityLevel”参数使得SNMPv3有多种不同的用途。 + +noAuthNoPriv -- 没有授权,加密以及任何安全保护!authNoPriv -- 需要身份认证,但是不对数据进行加密。 autoPriv -- 最健壮的模式。需要身份认证以及数据会被加密。 + +snmpd 的配置以及设置都保存在文件 /etc/snmp/snmpd.conf。使用编辑器编辑文件: + + sudo vi /etc/snmp/snmpd.conf + +在文件末尾添加以下内容: + + # + createUser user1 + createUser user2 MD5 user2password + createUser user3 MD5 user3password DES user3encryption + # + rouser user1 noauth 1.3.6.1.2.1.1 + rouser user2 auth 1.3.6.1.2.1 + rwuser user3 priv 1.3.6.1.2.1 + +注:如果你需要使用自己的用户名/密码对的话,请注意密码及加密短语的最小长度是8个字符。 + +同时,你需要做如下的配置以便snmp可以监听来自任何接口的连接请求。 + +将 + + #agentAddress udp:161,udp6:[::1]:161 + +改为 + + agentAddress udp:161,udp6:[::1]:161 + +保存改变后的snmpd.conf文件并且重启守护进程: + + sudo /etc/init.d/snmpd restart + +-------------------------------------------------------------------------------- + +via: http://www.ubuntugeek.com/how-to-configure-snmpv3-on-ubuntu-14-04-server.html + +译者:[SPccman](https://github.com/SPccman) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 diff --git a/translated/tech/How to create a site-to-site IPsec VPN tunnel using Openswan in Linux.md b/translated/tech/How to create a site-to-site IPsec VPN tunnel using Openswan in Linux.md new file mode 100644 index 0000000000..2a340add61 --- /dev/null +++ b/translated/tech/How to create a site-to-site IPsec VPN tunnel using Openswan in Linux.md @@ -0,0 +1,215 @@ +在Linux中使用Openswan搭建站点到站点IPsec VPN 隧道 +================================================================================ +虚拟私有网络(VPN)隧道通过Internet隧道技术将两个不同地理位置的网络安全的连接起来。当这两个网络是使用私有IP地址的私有局域网络时,那么两个网络之间是不能相互访问的,这时使用隧道技术就可以使得子网间的主机进行通讯。例如,VPN隧道技术经常被用于大型机构中不同办公区域子网的连接。 + +有时,使用VPN隧道仅仅是因为它很安全。服务提供商与公司会使用这样一种方式设网络,他们将重要的服务器(如,数据库,VoIP,银行服务器)放置到一个子网内,仅仅让有权限的用户通过VPN隧道进行访问。如果需要搭建一个安的VPN隧道,通常会选用[IPsec][1],因为IPsec VPN隧道被多重安全层所保护。 + +这篇指导文章将会告诉你如何构建站点到站点的 VPN隧道。 + +### 拓扑结构 ### + +这边指导文章将按照以下的拓扑结构来构建一个IPsec 隧道。 + +![](https://farm4.staticflickr.com/3838/15004668831_fd260b7f1e_z.jpg) + +![](https://farm6.staticflickr.com/5559/15004668821_36e02ab8b0_z.jpg) + +![](https://farm6.staticflickr.com/5571/14821245117_3f677e4d58_z.jpg) + +### 安装软件包以及准备VPN服务器 ### + +一般情况下,你仅能管理A点,但是根据需求,你可能需要同时管理A点与B点。我们从安装Openswan软件开始。 + +基于Red Hat的系统(CentOS,Fedora,或RHEL): + + # yum install openswan lsof + +在基于Debian的系统(Debian,Ubuntu或Linux Mint): + + # apt-get install openswan + +现在禁用VPN的重定向功能,如果有服务器,可以执行下列命令: + + # for vpn in /proc/sys/net/ipv4/conf/*; + # do echo 0 > $vpn/accept_redirects; + # echo 0 > $vpn/send_redirects; + # done + +接下来,允许IP转发并且禁重定向功能。 + + # vim /etc/sysctl.conf + +---------- + + net.ipv4.ip_forward = 1 + net.ipv4.conf.all.accept_redirects = 0 + net.ipv4.conf.all.send_redirects = 0 + +重加载 /etc/sysctl.conf文件: + + # sysctl -p + +在防火墙中启用所需的端口,并保证不与系统当前的规则冲突。 + + # iptables -A INPUT -p udp --dport 500 -j ACCEPT + # iptables -A INPUT -p tcp --dport 4500 -j ACCEPT + # iptables -A INPUT -p udp --dport 4500 -j ACCEPT + +最后,我们为NAT创建防火墙规则。 + + # iptables -t nat -A POSTROUTING -s site-A-private-subnet -d site-B-private-subnet -j SNAT --to site-A-Public-IP +确保防火墙规则的健壮性。 + +#### 注意: #### + +- 你可以使用MASQUERAD替代SNAT(iptables).理论上说它也能正常工作,但是有可能会与VPS发生冲突,所以我任然建议使用SNAT. +- 如果你同时在管理B点,那么在B点也设置同样的规则。 +- 直连路由则不需要SNAT。 + +### 准配置文件 ### + +我们将要用配置的第一个文件是ipsec.conf。不论你将要配置哪一台服务器,总是将你这端的服务器看成是左边的,而将远端的看作是右边的。以下配置是在站点A的VPN服务器做的。 + + # vim /etc/ipsec.conf + +---------- + + ## general configuration parameters ## + + config setup + plutodebug=all + plutostderrlog=/var/log/pluto.log + protostack=netkey + nat_traversal=yes + virtual_private=%v4:10.0.0.0/8,%v4:192.168.0.0/16,%v4:172.16.0.0/16 + ## disable opportunistic encryption in Red Hat ## + oe=off + + ## disable opportunistic encryption in Debian ## + ## Note: this is a separate declaration statement ## + include /etc/ipsec.d/examples/no_oe.conf + + ## connection definition in Red Hat ## + conn demo-connection-redhat + authby=secret + auto=start + ike=3des-md5 + ## phase 1 ## + keyexchange=ike + ## phase 2 ## + phase2=esp + phase2alg=3des-md5 + compress=no + pfs=yes + type=tunnel + left= + leftsourceip= + leftsubnet=/netmask + ## for direct routing ## + leftsubnet=/32 + leftnexthop=%defaultroute + right= + rightsubnet=/netmask + + ## connection definition in Debian ## + conn demo-connection-debian + authby=secret + auto=start + ## phase 1 ## + keyexchange=ike + ## phase 2 ## + esp=3des-md5 + pfs=yes + type=tunnel + left= + leftsourceip= + leftsubnet=/netmask + ## for direct routing ## + leftsubnet=/32 + leftnexthop=%defaultroute + right= + rightsubnet=/netmask + +有许多方式实现身份验证。这里使用预共享密钥,并将它添加到文件 file /etc/ipsec.secrets。 + + # vim /etc/ipsec.secrets + +---------- + + siteA-public-IP siteB-public-IP: PSK "pre-shared-key" + ## in case of multiple sites ## + siteA-public-IP siteC-public-IP: PSK "corresponding-pre-shared-key" + +### 启动服务并排除故障 ### + +目前,服务器已经可以创建站点到站点的VPN隧道了。如果你可以管理B站点,请确认已经为B服务器配置了所需的参数。对于基于Red Hat的系统,使用chkconfig命令以确定这项服务以设置为开机自启动。 + + # /etc/init.d/ipsec restart + +如果所有服务器没有问题的话,那么可以打通隧道了。注意以下内容后,你可以使用ping命令来测试隧道。 + +1.A点不可达B点的子网,当隧道没有启动时ping无效。 +1.隧道启动后,在A点直接ping B点的子网IP。是可以ping通的。 + +并且,到达目的子网的路由也会出现在服务器的路由表中。(译者:子网指的是site-B,服务器指的是site-A) + + # ip route + +---------- + + [siteB-private-subnet] via [siteA-gateway] dev eth0 src [siteA-public-IP] + default via [siteA-gateway] dev eth0 + +另外,我们可以使用命令来检测隧道的状态。 + + # service ipsec status + +---------- + + IPsec running - pluto pid: 20754 + pluto pid 20754 + 1 tunnels up + some eroutes exist + +---------- + + # ipsec auto --status + +---------- + + ## output truncated ## + 000 "demo-connection-debian": myip=; hisip=unset; + 000 "demo-connection-debian": ike_life: 3600s; ipsec_life: 28800s; rekey_margin: 540s; rekey_fuzz: 100%; keyingtries: 0; nat_keepalive: yes + 000 "demo-connection-debian": policy: PSK+ENCRYPT+TUNNEL+PFS+UP+IKEv2ALLOW+SAREFTRACK+lKOD+rKOD; prio: 32,28; interface: eth0; + + ## output truncated ## + 000 #184: "demo-connection-debian":500 STATE_QUICK_R2 (IPsec SA established); EVENT_SA_REPLACE in 1653s; newest IPSEC; eroute owner; isakmp#183; idle; import:not set + + ## output truncated ## + 000 #183: "demo-connection-debian":500 STATE_MAIN_I4 (ISAKMP SA established); EVENT_SA_REPLACE in 1093s; newest ISAKMP; lastdpd=-1s(seq in:0 out:0); idle; import:not set + +日志文件/var/log/pluto.log记录了关于身份验证,密钥交换以及隧道处于不同时期的一些信息。如果你的隧道无法启动了,可以查看这个文档。 + +如果你确信所有配置都是正确的,但是你的隧道任然无法启动,那么你需要检查以下的事件。 + +1.很多ISP会过滤IPsec端口。确认你的网络ISP允许使用UDP 500, TCP/UDP 4500端口。你可以试着在远端通过talnet连接服务器的IPsec端口。 +1.确认所用的端口在服务器防火墙规则中是允许的。 +1.确认两端服务器的预共享密钥是一致的。 +1.左边和右边的参数应该正确配置在两端的服务器上 +1.如果你遇到的是NAT问题,试着使用SNAT替换MASQUERADING。 + +总结,这篇指导重点在于使用Openswa搭建站点到站点IPsec VPN的流程。管理员可以使用VPN使得一些重要的资源仅能通过隧道来获取,这对于加强安全性很有效果。同时VPN确保数据不被监听以及截。 + +希望对你有帮助。让我知道你的意。 + +via: http://xmodulo.com/2014/08/create-site-to-site-ipsec-vpn-tunnel-openswan-linux.html + +作者:[Sarmed Rahman][a] +译者:[SPccman](https://github.com/SPccman) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://xmodulo.com/author/sarmed +[1]:http://en.wikipedia.org/wiki/IPsec +[2]:https://www.openswan.org/ diff --git a/translated/tech/How to sniff HTTP traffic from the command line on Linux.md b/translated/tech/How to sniff HTTP traffic from the command line on Linux.md new file mode 100644 index 0000000000..c45d3e3215 --- /dev/null +++ b/translated/tech/How to sniff HTTP traffic from the command line on Linux.md @@ -0,0 +1,103 @@ +使用Linux命令行嗅探HTTP流量 +================================================================================ +假设由于某种原因,你需要嗅探HTTP站点的流量(如HTTP请求与响应)。举个例子,你可能在测试一个web服务器的实验性功能,或者 你在为某个web应用或RESTful服务排错,又或者你正在为PAC排错或寻找某个站点下载的恶意软件。不论什么原因,在这些情况下,进行HTTP流量嗅探对于系统管理、开发者、甚至最终用户来说都是很有帮助的。 + +数据包嗅工具tcpdump被广泛用于实时数据包的导出,但是你需要设置过滤规则来捕获HTTP流量,甚至它的原始输出通常不能方便的停 在HTTP协议层。实时web服务器日志解析器如[ngxtop][3]提供可读的实时web流量跟踪痕迹,但这仅适用于可完全访问live web服务器日志的情况。 + +要是有一个仅用于抓取HTTP流量的类tcpdump的数据包嗅探工具就非常好了。事实上,[httpry][4]就是:**HTTP包嗅探工具**。httpry捕获HTTP数据包,并且将HTTP协议层的数据内容以可读形式列举出来。通过这篇指文章,让我们了解如何使用httpry工具嗅探HTTP流 量。 + +###在Linux上安装httpry### + +在基于Debian系统(Ubuntu 或 LinuxMint),基础仓库中没有httpry安装包(译者注:本人ubuntu14.04,仓库中已有包,可直接安装)。所以我们需要通过源码安装: + + $ sudo apt-get install gcc make git libpcap0.8-dev + $ git clone https://github.com/jbittel/httpry.git + $ cd httpry + $ make + $ sudo make install + +在Fedora,CentOS 或 RHEL系统,可以使用如下yum命令安装httpry。在CentOS/RHEL系统上,运行yum之前使能[EPEL repo][5]。 + + $ sudo yum install httpry + +如果逆向通过源码来构httpry的话,你可以通过这几个步骤实现: + + $ sudo yum install gcc make git libpcap-devel + $ git clone https://github.com/jbittel/httpry.git + $ cd httpry + $ make + $ sudo make install + +###httpry的基本用法### + +以下是httpry的基本用法 + + $ sudo httpry -i + +httpry就会监听指定的网络接口,并且实时的显示捕获到的HTTP 请求/响。 + +![](https://farm4.staticflickr.com/3883/14985851635_7b94787c6d_z.jpg) + +在大多数情况下,由于发送与接到的数据包过多导致刷屏很快,难以分析。这时候你肯定想将捕获到的数据包保存下来以离线分析。可以使用'b'或'-o'选项保存数据包。'-b'选项将数据包以二进制文件的形式保存下来,这样可以使用httpry软件打开文件以浏览。另 一方面,'-o'选项将数据以可读的字符文件形式保存下来。 + +以二进制形式保存文件: + + $ sudo httpry -i eth0 -b output.dump + +浏览所保存的HTTP数据包文件: + + $ httpry -r output.dump + +注意,不需要根用户权限就可以使用'-r'选项读取数据文件。 + +将httpry数据以字符文件保存: + + $ sudo httpry -i eth0 -o output.txt + +###httpry 的高级应用### + +如果你想监视指定的HTTP方法(如:GET,POST,PUT,HEAD,CONNECT等),使用'-m'选项: + + $ sudo httpry -i eth0 -m get,head + +![](https://farm6.staticflickr.com/5551/14799184220_3b449d422c_z.jpg) + +如果你下载了httpry的源码,你会发现源码下有一系Perl脚本,这些脚本用于分析httpry输出。脚本位于目录httpry/scripts/plugins。如果你想写一个定制的httpry输出分析器,则这些脚可以作为很好的例子。其中一些有如下的功能: + +- **hostnames**: 显示唯一主机名列表. +- **find_proxies**: 探测web代理. +- **search_terms**: 查找及计算输入检索服务的检索词。 +- **content_analysis**: 查找含有指定关键的URL。 +- **xml_output**: 将输出转换为XML形式。 +- **log_summary**: 生成日志摘要。 +- **db_dump**: 将日志文件数据保存数据库。 + +在使用这些脚本之前,首先使用'-o'选项运行httpry。当获取到输出文件后,立即使用如下命令执行脚本: + + $ cd httpry/scripts + $ perl parse_log.pl -d ./plugins + +你可能在使用插件的时候遇到警告。比如,如果你没有安装带有DBI接口的MySQL数据库那么使用db_dump插件时可能会失败。如果一个 插件初始化失败的话,那么这个插件不能使用。所以你可以忽略那些警告。 + +当parse_log.pl完成后,你将在httpry/scripts 目录下看到数个分析结果。例如,log_summary.txt 与如下内容类似。 + +![](https://farm4.staticflickr.com/3845/14799162189_b85abdf21d_z.jpg) + +总结,当你要分析HTTP数据包的时候,httpry非常有用。它可能并不被大多Linux使用着所熟知,但会用总是有好处的。你对这个工具有什么看法呢? + +-------------------------------------------------------------------------------- + +via: http://xmodulo.com/2014/08/sniff-http-traffic-command-line-linux.html + +作者:[Dan Nanni][a] +译者:[DoubleC](https://github.com/DoubleC) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://xmodulo.com/author/nanni +[1]:http://xmodulo.com/2012/12/how-to-set-up-proxy-auto-config-on-ubuntu-desktop.html +[2]:http://xmodulo.com/2012/11/what-are-popular-packet-sniffers-on-linux.html +[3]:http://xmodulo.com/2014/06/monitor-nginx-web-server-command-line-real-time.html +[4]:http://dumpsterventures.com/jason/httpry/ +[5]:http://xmodulo.com/2013/03/how-to-set-up-epel-repository-on-centos.html diff --git a/translated/tech/Linux FAQs with Answers--How to build a RPM or DEB package from the source with CheckInstall.md b/translated/tech/Linux FAQs with Answers--How to build a RPM or DEB package from the source with CheckInstall.md new file mode 100644 index 0000000000..372030e6d0 --- /dev/null +++ b/translated/tech/Linux FAQs with Answers--How to build a RPM or DEB package from the source with CheckInstall.md @@ -0,0 +1,86 @@ +Linux 常见问题解答 --怎么用checkinstall从源码创建一个RPM或DEB包 +================================================================================ +> **问题**:我想要从源码创建安装的软件程序。有没有一种方式来创建并且从源码安装包,而不是运行“make install”?那样,以后如果我想,我可以容易的卸载程序。 + +如果你已经从从它的源码运行“make install”安装了linux程序。想完整移除它将变得真的很麻烦,除非程序的创造者在Makefile里提供卸载的目标。你会有在你系统里文件的完整列表来和从源码安装之后比较,然后手工移除所有在制作安装过程中加入的文件 + + +这时候Checkinstall就可以派上使用。Checkinstall保留命令行创建或修改的所有文件的路径(例如:“make install”“make install_modules”等)并建立一个标准的二进制包,让你能用你发行版的标准包管理系统安装或卸载它,(例子:Red Hat的yum或者Debian的apt-get命令) It has been also known to work with Slackware, SuSe, Mandrake and Gentoo as well, as per the official documentation. [official documentation][1]. + +在这篇文章中,我们只集中在红帽子和Debian为基础的发行版,并展示怎样从源码使用Checkinstall创建一个RPM和DEB软件包 + +### 在linux上安装Checkinstall ### + +在Debian衍生上安装Checkinstall: + + # aptitude install checkinstall + +在红帽子的发行版上安装Checkinstall,你需要下载一个预先建立的Checkinstall rpm(例如:从 [http://rpm.pbone.net][2]),他已经从Repoforge库里删除。对于Cent OS6这个rpm包也可在Cent OS7里工作。 + + # wget ftp://ftp.pbone.net/mirror/ftp5.gwdg.de/pub/opensuse/repositories/home:/ikoinoba/CentOS_CentOS-6/x86_64/checkinstall-1.6.2-3.el6.1.x86_64.rpm + # yum install checkinstall-1.6.2-3.el6.1.x86_64.rpm + +一旦checkinstall安装,你可以用下列格式创建一个特定的软件包 + + # checkinstall + +如果没有参数,默认安装命令“make install”将被使用 + +### 用Checkinstall创建一个RPM或DEB包 ### + +在这个例子里,我们将创建一个htop包,对于linux交互式文本模式进程查看器(就像上面的 steroids) + + +首先,让我们从项目的官方网站下载源代码,一个最佳的练习,我们存储源码到/usr/local/src,并解压它 + + # cd /usr/local/src + # wget http://hisham.hm/htop/releases/1.0.3/htop-1.0.3.tar.gz + # tar xzf htop-1.0.3.tar.gz + # cd htop-1.0.3 + +让我们找出htop安装命令,那样我们就能调用Checkinstall命令,下面展示了,htop用“make install”命令安装 + + # ./configure + # make install + +因此,创建一个htop包,我们可以调用checkinstall不带任何参数安装,这将使用“make install”命令创建一个包。随着这个过程 checkinstall命令会问你一个连串的问题。 + +总之,这个命令会创建一个htop包: **htop**: + + # ./configure + # checkinstall + +回答“Y”“我会创建一个默认设置的包文件?” + +![](https://farm6.staticflickr.com/5577/15118597217_1fdd0e0346_z.jpg) + +你可以输入一个包的简短描述,然后按两次ENTER + +![](https://farm4.staticflickr.com/3898/15118442190_604b71d9af.jpg) + +输入一个数值修改下面的任何值或ENTER前进 + +![](https://farm4.staticflickr.com/3898/15118442180_428de59d68_z.jpg) + +然后checkinstall将自动地创建一个.rpm或者.deb包,根据你的linux系统是什么: + +在CentOS7: + +![](https://farm4.staticflickr.com/3921/15282103066_5d688b2217_z.jpg) + +在Debian 7: + +![](https://farm4.staticflickr.com/3905/15118383009_4909a7c17b_z.jpg) + +-------------------------------------------------------------------------------- + +via: http://ask.xmodulo.com/build-rpm-deb-package-source-checkinstall.html + +译者:[luoyutiantang](https://github.com/译者ID) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[1]:http://checkinstall.izto.org/docs/README +[2]:http://rpm.pbone.net/ +[3]:http://ask.xmodulo.com/install-htop-centos-rhel.html diff --git a/sources/tech/20140911 Linux Performance Monitoring with Vmstat and Iostat Commands.md b/translated/tech/Linux Performance Monitoring with Vmstat and Iostat Commands 翻译完成.md similarity index 68% rename from sources/tech/20140911 Linux Performance Monitoring with Vmstat and Iostat Commands.md rename to translated/tech/Linux Performance Monitoring with Vmstat and Iostat Commands 翻译完成.md index 5a1183ef28..97325f964b 100644 --- a/sources/tech/20140911 Linux Performance Monitoring with Vmstat and Iostat Commands.md +++ b/translated/tech/Linux Performance Monitoring with Vmstat and Iostat Commands 翻译完成.md @@ -1,42 +1,39 @@ -translating by cvsher -Linux Performance Monitoring with Vmstat and Iostat Commands -================================================================================ -This is our on-going series of commands and performance monitoring in **Linux**. **Vmstat** and **Iostat** both commands are available on all major **Unix-like (Linux/Unix/FreeBSD/Solaris)** Operating Systems. +使用Vmstat和Iostat命令进行Linux性能监控 +================================================================ +这是我们正在进行的**Linux**命令和性能监控系列的一部分。**Vmstat**和**Iostat**两个命令都适用于所有主要的类**unix**系统(**Linux/unix/FreeBSD/Solaris**)。 +如果**vmstat**和**iostat**命令在你的系统中不可用,请安装**sysstat**软件包。**vmstat**,**sar**和**iostat**命令都包含在**sysstat**(系统监控工具)软件包中。iostat命令生成**CPU**和所有设备的统计信息。你可以从连接[sysstat][1]中下载源代码包编译安装sysstat,但是我们建议通过**YUM**命令进行安装。 -If **vmstat** and **iostat** commands are not available on your box, please install **sysstat** package. The **vmstat**, **sar** and **iostat** commands are the collection of package included in **sysstat** – the system monitoring tools. The iostat generates reports of **CPU** & all device statistics. You may download and install **sysstat** using source tarball from link [sysstat][1], but we recommend installing through **YUM** command. +![使用Vmstat和Iostat命令进行Linux性能监控](http://www.tecmint.com/wp-content/uploads/2012/09/Linux-VmStat-Iostat-Commands.png) -![Linux Performance Monitoring with Vmstat and Iostat](http://www.tecmint.com/wp-content/uploads/2012/09/Linux-VmStat-Iostat-Commands.png) +使用Vmstat和Iostat命令进行Linux性能监控 -Linux Performance Monitoring with Vmstat and Iostat +###在Linux系统中安装sysstat### -### Install Sysstat in Linux ### + #yum -y install sysstat - # yum -y install sysstat +- **vmstat** - 内存,进程和分页等的简要信息。 +- **iostat** - CPU统计信息,设备和分区的输入/输出统计信息。 -- **vmstat** – Summary information of Memory, Processes, Paging etc. -- **iostat** – Central Processing Unit (CPU) statistics and input/output statistics for devices and partitions. +### Linux下vmstat命令的6个范例### -### 6 Vmstat Command Examples in Linux ### +####1. 列出活动和非活动的内存#### -#### 1. List Active and Inactive Memory #### +如下范例中输出6列。**vmstat**的man页面中解析的每一列的意义。最重要的是内存中的**free**属性和交换分区中是**si**和**so**属性。 -In the below example, there are six columns. The significant of the columns are explained in man page of **vmstat** in details. Most important fields are **free** under memory and **si**, **so** under swap column. + [root@tecmint ~]# vmstat -a - [root@tecmint ~]# vmstat -a - - procs -----------memory---------- ---swap-- -----io---- --system-- -----cpu----- + procs -----------memory---------- ---swap-- -----io---- --system-- -----cpu----- r b swpd free inact active si so bi bo in cs us sy id wa st 1 0 0 810420 97380 70628 0 0 115 4 89 79 1 6 90 3 0 -- **Free** – Amount of free/idle memory spaces. -- **si** – Swaped in every second from disk in Kilo Bytes. -- **so** – Swaped out every second to disk in Kilo Bytes. +- **Free** – 空闲的内存空间 +- **si** – 每秒从磁盘中交换进内存的数据量(以KB为单位)。 +- **so** – 每秒从内存中交换出磁盘的数据量(以KB为单位)。 -**Note**: If you run **vmstat** without parameters it’ll displays summary report since system boot. +**注意**:如果你不带参数的执行**vmstat**命令,它会输出自系统启动以来的总结报告。 -#### 2. Execute vmstat ‘X’ seconds and (‘N’number of times) #### - -With this command, **vmstat** execute every two seconds and stop automatically after executing six intervals. +####2. 每X秒执行vmstat,共执行N次#### +下面命令将会每2秒中执行一次**vmstat**,执行6次后自动停止执行。 [root@tecmint ~]# vmstat 2 6 @@ -49,9 +46,10 @@ With this command, **vmstat** execute every two seconds and stop automatically a 0 0 0 810412 22064 101368 0 0 0 0 17 35 0 0 100 0 0 0 0 0 810412 22064 101368 0 0 0 0 18 36 0 1 100 0 0 -#### 3. Vmstat with timestamps #### +####3. 带时间戳的vmstat命令#### + +带**-t**参数执行**vmstat**命令,该命令将会在每一行输出后都带一个时间戳,如下所示。 -**vmstat** command with **-t** parameter shows timestamps with every line printed as shown below. [tecmint@tecmint ~]$ vmstat -t 1 5 @@ -63,9 +61,10 @@ With this command, **vmstat** execute every two seconds and stop automatically a 0 0 0 631780 24992 192244 0 0 0 0 156 524 0 5 95 0 0 2012-09-02 14:57:21 IST 1 0 0 631656 24992 192244 0 0 0 0 189 592 0 5 95 0 0 2012-09-02 14:57:22 IST -#### 4. Statistics of Various Counter #### +####4. 统计各种计数器#### + +**vmstat**命令的**-s**参数,将输出各种事件计数器和内存的统计信息。 -**vmstat** command and -s switch displays summary of various event counters and memory statistics. [tecmint@tecmint ~]$ vmstat -s @@ -96,9 +95,9 @@ With this command, **vmstat** execute every two seconds and stop automatically a 1346574857 boot time 2309 forks -#### 5. Disks Statistics #### +####5. 磁盘统计信息#### -**vmstat** with **-d** option display all disks statistics. +**vmstat**的**-d**参数将会输出所有磁盘的统计信息。 [tecmint@tecmint ~]$ vmstat -d @@ -133,9 +132,9 @@ With this command, **vmstat** execute every two seconds and stop automatically a dm-0 11578 0 659242 1113017 32163 0 257384 8460026 0 126 dm-1 324 0 2592 3845 0 0 0 0 0 2 -#### 6. Display Statistics in Megabytes #### +####6. 以MB为单位输出统计信息#### -The **vmstat** displays in **Megabytes** with parameters **-S** and **M**(Uppercase & megabytes). By default **vmstat** displays statistics in kilobytes. +**vmstat**的**-S**和**-M**参数(大写和MB)将会以MB为单位输出。**vmstat**默认以KB为单位输出统计信息。 [root@tecmint ~]# vmstat -S M 1 5 @@ -147,11 +146,11 @@ The **vmstat** displays in **Megabytes** with parameters **-S** and **M**(Upperc 0 0 0 346 53 476 0 0 0 0 15 13 0 0 100 0 0 0 0 0 346 53 476 0 0 0 0 34 61 0 1 99 0 0 -### 6 Iostat Command Examples in Linux ### +###linux下的Iostat命令的6个范例### -#### 7. Display CPU and I/O statistics #### +####1. 输出CPU和输入/输出(I/O)的统计信息#### -**iostat** without arguments displays **CPU** and **I/O** statistics of all partitions as shown below. +不带参数的**iostat**命令将会输出**CPU**和每个分区的**输出/输出**的统计信息,如下所示。 [root@tecmint ~]# iostat @@ -165,9 +164,9 @@ The **vmstat** displays in **Megabytes** with parameters **-S** and **M**(Upperc dm-0 5.76 159.71 13.47 1077154 90864 dm-1 0.05 0.38 0.00 2576 0 -#### 8. Shows only CPU Statistics #### +####2. 只输出CPU的统计信息#### -**iostat** with **-c** arguments displays only **CPU** statistics as shown below. +**iostat**命令的**-c**参数仅输出**CPU**的统计信息,如下所示。 [root@tecmint ~]# iostat -c @@ -176,9 +175,9 @@ The **vmstat** displays in **Megabytes** with parameters **-S** and **M**(Upperc avg-cpu: %user %nice %system %iowait %steal %idle 0.12 0.01 1.47 1.98 0.00 96.42 -#### 9. Shows only Disks I/O Statistics #### +####3. 只输出磁盘的输入/输出统计信息#### -**iostat** with **-d** arguments displays only disks **I/O** statistics of all partitions as shown. +**iostat**命令的**-d**参数仅输出磁盘的所有分区的**输入/输出**的统计信息,如下所示。 [root@tecmint ~]# iostat -d @@ -189,9 +188,9 @@ The **vmstat** displays in **Megabytes** with parameters **-S** and **M**(Upperc dm-0 5.37 148.59 12.65 1077154 91728 dm-1 0.04 0.36 0.00 2576 0 -#### 10. Shows I/O statistics only of a single device. #### +####4. 只输出某个磁盘的输入/输出统计信息#### -By default it displays statistics of all partitions, with **-p** and device name arguments displays only disks **I/O** statistics for specific device only as shown. +在默认情况下iostat命令会输出所有分区的统计信息,但是若在iostat命令后加上**-p**参数和磁盘设备名,该命令将会仅输出列出的磁盘的输入/输出统计信息,如下所示。 [root@tecmint ~]# iostat -p sda @@ -205,9 +204,9 @@ By default it displays statistics of all partitions, with **-p** and device name sda1 0.07 0.56 0.00 4120 18 sda2 3.22 147.79 12.55 1080650 91752 -#### 11. Display LVM Statistics #### +####5. 输出逻辑卷管理(LVM)的统计信息#### -With **-N** (Uppercase) parameter displays only **LVM** statistics as shown. +iostat命令的**-N**(大写)参数将会输出**LVM**(LCTT译注:[LVM][2]是linux环境下对磁盘分区进行管理的一种机制,是磁盘分区和文件系统间的一个逻辑层)的统计信息,如下所示。 [root@tecmint ~]# iostat -N @@ -221,26 +220,27 @@ With **-N** (Uppercase) parameter displays only **LVM** statistics as shown. vg_tecmint-lv_root 5.13 141.68 12.16 1077154 92448 vg_tecmint-lv_swap 0.04 0.34 0.00 2576 0 -#### 12. iostat version. #### +####6. iostat版本信息#### -With **-V** (Uppercase) parameter displays version of **iostat** as shown. +iostat的**-V**(大写)参数将会输出**iostat**的版本信息,如下所示。 [root@tecmint ~]# iostat -V sysstat version 9.0.4 (C) Sebastien Godard (sysstat orange.fr) -**Note**: **vmstat** and **iostat** contains number of columns and flags which may not possible to explain in details. If you want to know more about it you may refer man page of **vmstat** and **iostat**. Please share it if you find this article is useful through our comment box below. +**注意**:**vmstat**和**iostat**的输出中包含多列的数据和标志,限于篇幅无法在本文中进行详细的解析。如果你想知道更多的信息,请查看**vmstat**和**iostat**的man帮助手册。如果你觉得本文对你有价值,请在下面的评论框中与你的朋友分享。 -------------------------------------------------------------------------------- via: http://www.tecmint.com/linux-performance-monitoring-with-vmstat-and-iostat-commands/ 作者:[Ravi Saive][a] -译者:[译者ID](https://github.com/译者ID) +译者:[cvsher](https://github.com/cvsher) 校对:[校对者ID](https://github.com/校对者ID) 本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 [a]:http://www.tecmint.com/author/admin/ [1]:http://sebastien.godard.pagesperso-orange.fr/download.html +[2]:http://en.wikipedia.org/wiki/Logical_Volume_Manager_(Linux) diff --git a/translated/tech/Sysstat – All-in-One System Performance and Usage Activity Monitoring Tool For Linux.md b/translated/tech/Sysstat – All-in-One System Performance and Usage Activity Monitoring Tool For Linux.md new file mode 100644 index 0000000000..2c28c2c7d2 --- /dev/null +++ b/translated/tech/Sysstat – All-in-One System Performance and Usage Activity Monitoring Tool For Linux.md @@ -0,0 +1,122 @@ +集所有功能与一身的Linux系统性能和使用活动监控工具-Sysstat +=========================================================================== +**Sysstat**是一个非常方便的工具,它带有众多的系统资源监控工具,用于监控系统的性能和使用情况。我们在日常使用的工具中有相当一部分是来自sysstat工具包的。同时,它还提供了一种使用cron表达式来制定性能和活动数据的收集计划。 + +![Install Sysstat in Linux](http://www.tecmint.com/wp-content/uploads/2014/08/sysstat.png) + +在Linux系统中安装Sysstat + +下表是包含在sysstat包中的工具 + +- [**isstat**][1]: 输出CPU的统计信息和所有I/O设备的输入输出(I/O)统计信息。 +- **mpstat**: 关于多有CPU的详细信息(单独输出或者分组输出)。 +- **pidstat**: 关于运行中的进程/任务、CPU、内存等的统计信息。 +- **sar**: 保存并输出不同系统资源(CPU、内存、IO、网络、内核、等。。。)的详细信息。 +- **sadc**: 系统活动数据收集器,用于手机sar工具的后端数据。 +- **sa1**: 系统手机并存储sadc数据文件的二进制数据,与sadc工具配合使用 +- **sa2**: 配合sar工具使用,产生每日的摘要报告。 +- **sadf**: 用于以不同的数据格式(CVS或者XML)来格式化sar工具的输出。 +- **Sysstat**: sysstat工具的man帮助页面。 +- **nfsiostat**: NFS(Network File System)的I/O统计信息。 +- **cifsiostat**: CIFS(Common Internet File System)的统计信息。 + +最近(在2014年6月17日),**sysstat 11.0.0**(稳定版)已经发布了,同时还新增了一些有趣的特性,如下: + +pidstat命令新增了一些新的选项:首先是“-R”选项,该选项将会输出有关策略和任务调度的优先级信息。然后是“**-G**”选项,通过这个选项我们可以使用名称搜索进程,然后列出所有匹配的线程。 + +sar、sadc和sadf命令在数据文件方面同样带来了一些功能上的增强。与以往只能使用“**saDD**”来命名数据文件。现在使用**-D**选项可以用“**saYYYYMMDD**”来重命名数据文件,同样的,现在的数据文件不必放在“**var/log/sa**”目录中,我们可以使用“SA_DIR”变量来定义新的目录,该变量将应用与sa1和sa2命令。 + +###在Linux系统中安装Sysstat#### + +在主要的linux发行版中,‘**Sysstat**’工具包可以在默认的程序库中安装。然而,在默认程序库中的版本通常有点旧,因此,我们将会下载源代码包,编译安装最新版本(**11.0.0**版本)。 + +首先,使用下面的连接下载最新版本的sysstat包,或者你可以使用**wget**命令直接在终端中下载。 + +- [http://sebastien.godard.pagesperso-orange.fr/download.html][2] + + # wget http://pagesperso-orange.fr/sebastien.godard/sysstat-11.0.0.tar.gz + +![Download Sysstat Package](http://www.tecmint.com/wp-content/uploads/2014/08/Download-Sysstat.png) + +下载Sysstat包 + +然后解压缩下载下来的包,进去该目录,开始编译安装 + + # tar -xvf sysstat-11.0.0.tar.gz + # cd sysstat-11.0.0/ + +这里,你有两种编译安装的方法: + +a).第一,你可以使用**iconfig**(这将会给予你很大的灵活性,你可以选择/输入每个参数的自定义值) + + # ./iconfig + +![Sysstat iconfig Command](http://www.tecmint.com/wp-content/uploads/2014/08/Sysstat-iconfig-Command.png) + +Sysstat的iconfig命令 + +b).第二,你可以使用标准的**configure**命令在当行中定义所有选项。你可以运行 **./configure –help 命令**来列出该命令所支持的所有限选项。 + + # ./configure --help + +![Sysstat Configure Help](http://www.tecmint.com/wp-content/uploads/2014/08/Configure-Help.png) + +Stsstat的cofigure -help + +在这里,我们使用标准的**./configure**命令来编译安装sysstat工具包。 + + # ./configure + # make + # make install + +![Configure Sysstat in Linux](http://www.tecmint.com/wp-content/uploads/2014/08/Configure-Sysstat.png) + +在Linux系统中配置sysstat + +在编译完成后,我们将会看到一些类似于上图的输出。现在运行如下命令来查看sysstat的版本。 + + # mpstat -V + + sysstat version 11.0.0 + (C) Sebastien Godard (sysstat orange.fr) + +###在Linux 系统中更新sysstat### + +默认的,sysstat使用“**/usr/local**”作为其目录前缀。因此,所有的二进制数据/工具都会安装在“**/usr/local/bin**”目录中。如果你的系统已经安装了sysstat 工具包,则上面提到的二进制数据/工具有可能在“**/usr/bin**”目录中。 + +因为“**$PATH**”变量不包含“**/usr/local/bin**”路径,你在更新时可能会失败。因此,确保“**/usr/local/bin**”路径包含在“$PATH”环境变量中,或者在更新前,在编译和卸载旧版本时将**-prefix**选项指定值为“**/usr**”。 + + # yum remove sysstat [On RedHat based System] + # apt-get remove sysstat [On Debian based System] + +---------- + + # ./configure --prefix=/usr + # make + # make install + +现在,使用‘mpstat’命令的‘**-V**’选项查看更新后的版本。 + + # mpstat -V + + sysstat version 11.0.0 + (C) Sebastien Godard (sysstat orange.fr) + +**参考**: 更多详细的信息请到 [Sysstat Documentation][3] + +在我的下一篇文章中,我将会展示一些sysstat命令使用的实际例子,敬请关注更新。别忘了在下面评论框中留下您宝贵的意见。 + +-------------------------------------------------------------------------------- + +via: http://www.tecmint.com/install-sysstat-in-linux/ + +作者:[Kuldeep Sharma][a] +译者:[cvsher](https://github.com/cvsher) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://www.tecmint.com/author/kuldeepsharma47/ +[1]:http://www.tecmint.com/linux-performance-monitoring-with-vmstat-and-iostat-commands/ +[2]:http://sebastien.godard.pagesperso-orange.fr/download.html +[3]:http://sebastien.godard.pagesperso-orange.fr/documentation.html diff --git a/sources/tech/20140911 20 Useful Commands of 'Sysstat' Utilities (mpstat, pidstat, iostat and sar) for Linux Performance Monitoring.md b/translated/tech/[翻译完成]20 Useful Commands of ‘Sysstat’ Utilities (mpstat, pidstat, iostat and sar) for Linux Performance Monitoring.md similarity index 71% rename from sources/tech/20140911 20 Useful Commands of 'Sysstat' Utilities (mpstat, pidstat, iostat and sar) for Linux Performance Monitoring.md rename to translated/tech/[翻译完成]20 Useful Commands of ‘Sysstat’ Utilities (mpstat, pidstat, iostat and sar) for Linux Performance Monitoring.md index 244ab29ddf..2b4ec54a39 100644 --- a/sources/tech/20140911 20 Useful Commands of 'Sysstat' Utilities (mpstat, pidstat, iostat and sar) for Linux Performance Monitoring.md +++ b/translated/tech/[翻译完成]20 Useful Commands of ‘Sysstat’ Utilities (mpstat, pidstat, iostat and sar) for Linux Performance Monitoring.md @@ -1,19 +1,18 @@ -20 Useful Commands of ‘Sysstat’ Utilities (mpstat, pidstat, iostat and sar) for Linux Performance Monitoring -================================================================================ -In our last article, we have learned about installing and upgrading the **sysstat** package and understanding briefly about the utilities which comes with the package. +‘Sysstat’工具包中20个实用的Linux性能监控工具(包括mpstat, pidstat, iostat 和sar) +=============================================================== +在我们上一篇文章中,我们已经学习了如何去安装和更新**sysstat**,并且了解了包中的一些实用工具。 -注:此文一并附上,在同一个原文更新中 +注:此文一并附上,在同一个原文中更新 - [Sysstat – Performance and Usage Activity Monitoring Tool For Linux][1] ![20 Sysstat Commands for Linux Monitoring](http://www.tecmint.com/wp-content/uploads/2014/09/sysstat-commands.png) -20 Sysstat Commands for Linux Monitoring +Linux系统监控的20个Sysstat命令 +今天,我们将会通过一些有趣的实例来学习**mpstat**, **pidstat**, **iostat**和**sar**等工具,这些工具可以帮组我们找出系统中的问题。这些工具都包含了不同的选项,这意味着你可以根据不同的工作使用不同的选项,或者根据你的需求来自定义脚本。我们都知道,系统管理员都会有点懒,他们经常去寻找一些更简单的方法来完成他们的工作。 -Today, we are going to work with some interesting practical examples of **mpstat, pidstat, iostat** and **sar** utilities, which can help us to identify the issues. We have different options to use these utilities, I mean you can fire the commands manually with different options for different kind of work or you can create your customized scripts according to your requirements. You know Sysadmins are always bit Lazy, and always tried to find out the easy way to do the things with minimum efforts. +### mpstat - 处理器统计信息 ### -### mpstat – Processors Statistics ### - -1.Using mpstat command without any option, will display the Global Average Activities by All CPUs. +1.不带任何参数的使用mpstat命令将会输出所有CPU的平均统计信息 tecmint@tecmint ~ $ mpstat @@ -22,7 +21,7 @@ Today, we are going to work with some interesting practical examples of **mpstat 12:23:57 IST CPU %usr %nice %sys %iowait %irq %soft %steal %guest %gnice %idle 12:23:57 IST all 37.35 0.01 4.72 2.96 0.00 0.07 0.00 0.00 0.00 54.88 -2.Using mpstat with option ‘**-P**‘ (Indicate Processor Number) and ‘ALL’, will display statistics about all CPUs one by one starting from 0. 0 will the first one. +2.使用‘**-p**’(处理器编码)和‘ALL’参数将会从0开始独立的输出每个CPU的统计信息,0表示第一个cpu。 tecmint@tecmint ~ $ mpstat -P ALL @@ -33,7 +32,7 @@ Today, we are going to work with some interesting practical examples of **mpstat 12:29:26 IST 0 37.90 0.01 4.96 2.62 0.00 0.03 0.00 0.00 0.00 54.48 12:29:26 IST 1 36.75 0.01 4.19 2.54 0.00 0.11 0.00 0.00 0.00 56.40 -3.To display the statistics for **N** number of iterations after n seconds interval with average of each cpu use the following command. +3.要进行‘**N**’次,平均每次间隔n秒的输出CPU统计信息,如下所示。 tecmint@tecmint ~ $ mpstat -P ALL 2 5 @@ -54,11 +53,13 @@ Today, we are going to work with some interesting practical examples of **mpstat 12:36:27 IST 0 34.34 0.00 4.04 0.00 0.00 0.00 0.00 0.00 0.00 61.62 12:36:27 IST 1 32.82 0.00 6.15 0.51 0.00 0.00 0.00 0.00 0.00 60.51 -4.The option ‘**I**‘ will print total number of interrupt statistics about per processor. +(LCTT译注: 上面命令中‘2’ 表示每2秒执行一次‘mpstat -P ALL’命令, ‘5’表示共执行5次) + +4.使用‘**I**’参数将会输出每个处理器的中断统计信息 tecmint@tecmint ~ $ mpstat -I - Linux 3.11.0-23-generic (tecmint.com) Thursday 04 September 2014 _i686_ (2 CPU) + Linux 3.11.0-23-generic (tecmint.com) Thursday 04 September 2014 _i686_ (2 CPU) 12:39:56 IST CPU intr/s 12:39:56 IST all 651.04 @@ -71,11 +72,11 @@ Today, we are going to work with some interesting practical examples of **mpstat 12:39:56 IST 0 0.00 116.49 0.05 0.27 7.33 0.00 1.22 10.44 0.13 37.47 12:39:56 IST 1 0.00 111.65 0.05 0.41 7.07 0.00 56.36 9.97 0.13 41.38 -5.Get all the above information in one command i.e. equivalent to “**-u -I ALL -p ALL**“. +5.使用‘**A**’参数将会输出上面提到的所有信息,等同于‘**-u -I All -p ALL**’。 tecmint@tecmint ~ $ mpstat -A - Linux 3.11.0-23-generic (tecmint.com) Thursday 04 September 2014 _i686_ (2 CPU) + Linux 3.11.0-23-generic (tecmint.com) Thursday 04 September 2014 _i686_ (2 CPU) 12:41:39 IST CPU %usr %nice %sys %iowait %irq %soft %steal %guest %gnice %idle 12:41:39 IST all 38.70 0.01 4.47 2.01 0.00 0.06 0.00 0.00 0.00 54.76 @@ -95,19 +96,19 @@ Today, we are going to work with some interesting practical examples of **mpstat 12:41:39 IST 0 0.00 116.96 0.05 0.26 7.12 0.00 1.24 10.42 0.12 36.99 12:41:39 IST 1 0.00 112.25 0.05 0.40 6.88 0.00 55.05 9.93 0.13 41.20 -### pidstat – Process and Kernel Threads Statistics ### +###pidstat - 进程和内核线程的统计信息### -This is used for process monitoring and current threads, which are being managed by kernel. pidstat can also check the status about child processes and threads. +该命令是用于监控进程和当前受内核管理的线程。pidstat还可以检查子进程和线程的状态。 -#### Syntax #### +#### 语法 #### # pidstat [INTERVAL] [COUNT] -6.Using pidstat command without any argument, will display all active tasks. +6.不带任何参数使用pidstat将会输出所有活跃的任务。 - tecmint@tecmint ~ $ pidstat + tecmint@tecmint ~ $ pidstat - Linux 3.11.0-23-generic (tecmint.com) Thursday 04 September 2014 _i686_ (2 CPU) + Linux 3.11.0-23-generic (tecmint.com) Thursday 04 September 2014 _i686_ (2 CPU) 12:47:24 IST UID PID %usr %system %guest %CPU CPU Command 12:47:24 IST 0 1 0.01 0.12 0.00 0.13 1 init @@ -125,11 +126,11 @@ This is used for process monitoring and current threads, which are being managed 12:47:24 IST 0 365 0.01 0.00 0.00 0.01 0 systemd-udevd 12:47:24 IST 0 476 0.00 0.00 0.00 0.00 0 kworker/u9:1 -7.To print all active and non-active tasks use the option ‘**-p**‘ (processes). +7.使用‘**-p**’(进程)参数输出所有活跃和非活跃的任务。 tecmint@tecmint ~ $ pidstat -p ALL - Linux 3.11.0-23-generic (tecmint.com) Thursday 04 September 2014 _i686_ (2 CPU) + Linux 3.11.0-23-generic (tecmint.com) Thursday 04 September 2014 _i686_ (2 CPU) 12:51:55 IST UID PID %usr %system %guest %CPU CPU Command 12:51:55 IST 0 1 0.01 0.11 0.00 0.12 1 init @@ -150,11 +151,11 @@ This is used for process monitoring and current threads, which are being managed 12:51:55 IST 0 19 0.00 0.00 0.00 0.00 0 writeback 12:51:55 IST 0 20 0.00 0.00 0.00 0.00 1 kintegrityd -8.Using pidstat command with ‘**-d 2**‘ option, we can get I/O statistics and 2 is interval in seconds to get refreshed statistics. This option can be handy in situation, where your system is undergoing heavy I/O and you want to get clues about the processes consuming high resources. +8.使用‘**-d 2**’参数,我们可以看到I/O统计信息,2表示以秒为单位对统计信息进行刷新。这个参数可以方便的知道当系统在进行繁重的I/O时,那些进行占用大量的资源。 tecmint@tecmint ~ $ pidstat -d 2 - Linux 3.11.0-23-generic (tecmint.com) Thursday 04 September 2014 _i686_ (2 CPU) + Linux 3.11.0-23-generic (tecmint.com) Thursday 04 September 2014 _i686_ (2 CPU) 03:26:53 EDT PID kB_rd/s kB_wr/s kB_ccwr/s Command @@ -168,11 +169,12 @@ This is used for process monitoring and current threads, which are being managed 03:27:03 EDT 25100 0.00 6.00 0.00 sendmail 03:27:03 EDT 30829 0.00 6.00 0.00 java -9.To know the cpu statistics along with all threads about the process id **4164** at interval of **2** sec for **3** times use the following command with option ‘-t‘ (display statistics of selected process). +9.想要每间隔**2**秒对进程**4164**的cpu统计信息输出**3**次,则使用如下带参数‘**-t**’(输出某个选定进程的统计信息)的命令。 + tecmint@tecmint ~ $ pidstat -t -p 4164 2 3 - Linux 3.11.0-23-generic (tecmint.com) Thursday 04 September 2014 _i686_ (2 CPU) + Linux 3.11.0-23-generic (tecmint.com) Thursday 04 September 2014 _i686_ (2 CPU) 01:09:06 IST UID TGID TID %usr %system %guest %CPU CPU Command 01:09:08 IST 1000 4164 - 22.00 1.00 0.00 23.00 1 firefox @@ -185,11 +187,11 @@ This is used for process monitoring and current threads, which are being managed 01:09:08 IST 1000 - 4176 0.00 0.00 0.00 0.00 1 |__gdbus 01:09:08 IST 1000 - 4177 0.00 0.00 0.00 0.00 1 |__gmain -10.Use the ‘**-rh**‘ option, to know the about memory utilization of processes which are frequently varying their utilization in **2** second interval. +10.使用‘**-rh**’参数,将会输出进程的内存使用情况。如下命令每隔2秒刷新经常的内存使用情况。 tecmint@tecmint ~ $ pidstat -rh 2 3 - Linux 3.11.0-23-generic (tecmint.com) Thursday 04 September 2014 _i686_ (2 CPU) + Linux 3.11.0-23-generic (tecmint.com) Thursday 04 September 2014 _i686_ (2 CPU) # Time UID PID minflt/s majflt/s VSZ RSS %MEM Command 1409816695 1000 3958 3378.22 0.00 707420 215972 5.32 cinnamon @@ -208,21 +210,21 @@ This is used for process monitoring and current threads, which are being managed 1409816699 1000 4164 599.00 0.00 1261944 476664 11.74 firefox 1409816699 1000 6676 168.00 0.00 4436 1020 0.03 pidstat -11.To print all the process of containing string “**VB**“, use ‘**-t**‘ option to see threads as well. +11.要使用‘**-G**’参数可以输出包含某个特定字符串的进程信息。如下命令输出所有包含‘**VB**’字符串的进程的统计信息,使用‘**-t**’参数将线程的信息也进行输出。 tecmint@tecmint ~ $ pidstat -G VB - Linux 3.11.0-23-generic (tecmint.com) Thursday 04 September 2014 _i686_ (2 CPU) + Linux 3.11.0-23-generic (tecmint.com) Thursday 04 September 2014 _i686_ (2 CPU) - 01:09:06 IST UID PID %usr %system %guest %CPU CPU Command - 01:09:08 IST 1000 1492 22.00 1.00 0.00 23.00 1 VBoxService - 01:09:08 IST 1000 1902 4164 20.00 0.50 0.00 20.50 VBoxClient - 01:09:08 IST 1000 1922 4171 0.00 0.00 0.00 0.00 VBoxClient + 01:09:06 IST UID PID %usr %system %guest %CPU CPU Command + 01:09:08 IST 1000 1492 22.00 1.00 0.00 23.00 1 VBoxService + 01:09:08 IST 1000 1902 4164 20.00 0.50 0.00 20.50 VBoxClient + 01:09:08 IST 1000 1922 4171 0.00 0.00 0.00 0.00 VBoxClient ---------- tecmint@tecmint ~ $ pidstat -t -G VB - Linux 2.6.32-431.el6.i686 (tecmint) 09/04/2014 _i686_ (2 CPU) + Linux 2.6.32-431.el6.i686 (tecmint) 09/04/2014 _i686_ (2 CPU) 03:19:52 PM UID TGID TID %usr %system %guest %CPU CPU Command 03:19:52 PM 0 1479 - 0.01 0.12 0.00 0.13 1 VBoxService @@ -237,32 +239,32 @@ This is used for process monitoring and current threads, which are being managed 03:19:52 PM 0 1933 - 0.04 0.89 0.00 0.93 0 VBoxClient 03:19:52 PM 0 - 1936 0.04 0.89 0.00 0.93 1 |__X11-NOTIFY -12.To get realtime priority and scheduling information use option ‘**-R**‘ . +12.使用‘**-R**’参数输出实时的进程优先级和调度信息。 tecmint@tecmint ~ $ pidstat -R - Linux 3.11.0-23-generic (tecmint.com) Thursday 04 September 2014 _i686_ (2 CPU) + Linux 3.11.0-23-generic (tecmint.com) Thursday 04 September 2014 _i686_ (2 CPU) - 01:09:06 IST UID PID prio policy Command - 01:09:08 IST 1000 3 99 FIFO migration/0 - 01:09:08 IST 1000 5 99 FIFO migration/0 - 01:09:08 IST 1000 6 99 FIFO watchdog/0 + 01:09:06 IST UID PID prio policy Command + 01:09:08 IST 1000 3 99 FIFO migration/0 + 01:09:08 IST 1000 5 99 FIFO migration/0 + 01:09:08 IST 1000 6 99 FIFO watchdog/0 -Here, I am not going to cover about Iostat utility, as we are already covered it. Please have a look on “[Linux Performance Monitoring with Vmstat and Iostat][2]注:此文也一并附上在同一个原文更新中” to get all details about iostat. +因为我们已经学习过Iostat命令了,因此在本文中不在对其进行赘述。若想查看Iostat命令的详细信息,请参看“[使用Iostat和Vmstat进行Linux性能监控][2]注:此文也一并附上在同一个原文更新中” -### sar – System Activity Reporter ### +###sar - 系统活动报告### -Using “**sar**” command, we can get the reports about whole system’s performance. This can help us to locate the system bottleneck and provide the help to find out the solutions to these annoying performance issues. +我们可以使用‘**sar**’命令来获得整个系统性能的报告。这有助于我们定位系统性能的瓶颈,并且有助于我们找出这些烦人的性能问题的解决方法。 -The Linux Kernel maintains some counter internally, which keeps track of all requests, their completion time and I/O block counts etc. From all these information, sar calculates rates and ratio of these request to find out about bottleneck areas. +Linux内核维护者一些内部计数器,这些计数器包含了所有的请求及其完成时间和I/O块数等信息,sar命令从所有的这些信息中计算出请求的利用率和比例,以便找出瓶颈所在。 -The main thing about the sar is that, it reports all activities over a period if time. So, make sure that sar collect data on appropriate time (not on Lunch time or on weekend.:) +sar命令主要的用途是生成某段时间内所有活动的报告,因此,必需确保sar命令在适当的时间进行数据采集(而不是在午餐时间或者周末。) -13.Following is a basic command to invoke sar. It will create one file named “**sarfile**” in your current directory. The options ‘**-u**‘ is for CPU details and will collect **5** reports at an interval of **2** seconds. +13.下面是执行sar命令的基本用法。它将会在当前目录下创建一个名为‘**sarfile**’的文件。‘**-u**’参数表示CPU详细信息,**5**表示生产5次报告,**2**表示每次报告的时间间隔为2秒。 tecmint@tecmint ~ $ sar -u -o sarfile 2 5 - Linux 3.11.0-23-generic (tecmint.com) Thursday 04 September 2014 _i686_ (2 CPU) + Linux 3.11.0-23-generic (tecmint.com) Thursday 04 September 2014 _i686_ (2 CPU) 01:42:28 IST CPU %user %nice %system %iowait %steal %idle 01:42:30 IST all 36.52 0.00 3.02 0.00 0.00 60.45 @@ -272,26 +274,26 @@ The main thing about the sar is that, it reports all activities over a period if 01:42:38 IST all 50.75 0.00 3.75 0.00 0.00 45.50 Average: all 46.30 0.00 3.93 0.00 0.00 49.77 -14.In the above example, we have invoked sar interactively. We also have an option to invoke it non-interactively via cron using scripts **/usr/local/lib/sa1** and **/usr/local/lib/sa2** (If you have used **/usr/local** as prefix during installation time). +14.在上面的例子中,我们交互的执行sar命令。sar命令提供了使用cron进行非交互的执行sar命令的方法,使用**/usr/local/lib/sa1**和**/usr/local/lib/sa2**脚本(如果你在安装时使用了**/usr/local**作为前缀) -- **/usr/local/lib/sa1** is a shell script that we can use for scheduling cron which will create daily binary log file. -- **/usr/local/lib/sa2** is a shell script will change binary log file to human-readable form. +- **/usr/local/lib/sa1**是一个可以使用cron进行调度生成二进制日志文件的shell脚本。 +- **/usr/local/lib/sa2**是一个可以将二进制日志文件转换为用户可读的编码方式。 -Use the following Cron entries for making this non-interactive: +使用如下Cron项目来将sar命令非交互化。 - # Run sa1 shell script every 10 minutes for collecting data + # 每10分钟运行sa1脚本来采集数据 */2 * * * * /usr/local/lib/sa/sa1 2 10 - # Generate a daily report in human readable format at 23:53 + #在每天23:53时生成一个用户可读的日常报告 53 23 * * * /usr/local/lib/sa/sa2 -A -At the back-end sa1 script will call **sadc** (System Activity Data Collector) utility for fetching the data at a particular interval. **sa2** will call sar for changing binary log file to human readable form. +在sa1脚本执行后期,sa1脚本会调用**sabc**(系统活动数据收集器,System Activity Data Collector)工具采集特定时间间隔内的数据。**sa2**脚本会调用sar来将二进制日志文件转换为用户可读的形式。 -15.Check run queue length, total number of processes and load average using ‘**-q**‘ option. +15.使用‘**-q**’参数来检查运行队列的长度,所有进程的数量和平均负载 tecmint@tecmint ~ $ sar -q 2 5 - Linux 3.11.0-23-generic (tecmint.com) Thursday 04 September 2014 _i686_ (2 CPU) + Linux 3.11.0-23-generic (tecmint.com) Thursday 04 September 2014 _i686_ (2 CPU) 02:00:44 IST runq-sz plist-sz ldavg-1 ldavg-5 ldavg-15 blocked 02:00:46 IST 1 431 1.67 1.22 0.97 0 @@ -301,11 +303,11 @@ At the back-end sa1 script will call **sadc** (System Activity Data Collector) u 02:00:54 IST 0 431 1.64 1.23 0.97 0 Average: 2 431 1.68 1.23 0.97 0 -16.Check statistics about the mounted file systems using ‘**-F**‘. - +16.使用‘**-F**’参数查看当前挂载的文件系统统计信息 + tecmint@tecmint ~ $ sar -F 2 4 - Linux 3.11.0-23-generic (tecmint.com) Thursday 04 September 2014 _i686_ (2 CPU) + Linux 3.11.0-23-generic (tecmint.com) Thursday 04 September 2014 _i686_ (2 CPU) 02:02:31 IST MBfsfree MBfsused %fsused %ufsused Ifree Iused %Iused FILESYSTEM 02:02:33 IST 1001 449 30.95 1213790475088.85 18919505 364463 1.89 /dev/sda1 @@ -322,11 +324,11 @@ At the back-end sa1 script will call **sadc** (System Activity Data Collector) u Summary MBfsfree MBfsused %fsused %ufsused Ifree Iused %Iused FILESYSTEM Summary 1001 449 30.95 1213790475088.86 18919505 364463 1.89 /dev/sda1 -17.View network statistics using ‘**-n DEV**‘. +17.使用‘**-n DEV**’参数查看网络统计信息 tecmint@tecmint ~ $ sar -n DEV 1 3 | egrep -v lo - Linux 3.11.0-23-generic (tecmint.com) Thursday 04 September 2014 _i686_ (2 CPU) + Linux 3.11.0-23-generic (tecmint.com) Thursday 04 September 2014 _i686_ (2 CPU) 02:11:59 IST IFACE rxpck/s txpck/s rxkB/s txkB/s rxcmp/s txcmp/s rxmcst/s 02:12:00 IST wlan0 8.00 10.00 1.23 0.92 0.00 0.00 0.00 @@ -334,11 +336,11 @@ At the back-end sa1 script will call **sadc** (System Activity Data Collector) u 02:12:00 IST eth0 0.00 0.00 0.00 0.00 0.00 0.00 0.00 02:12:00 IST vmnet1 0.00 0.00 0.00 0.00 0.00 0.00 0.00 -18.View block device statistics like iostat using ‘**-d**‘. +18.使用‘**-d**’参数查看块设备统计信息(与iostat类似)。 tecmint@tecmint ~ $ sar -d 1 3 - Linux 3.11.0-23-generic (tecmint.com) Thursday 04 September 2014 _i686_ (2 CPU) + Linux 3.11.0-23-generic (tecmint.com) Thursday 04 September 2014 _i686_ (2 CPU) 02:13:17 IST DEV tps rd_sec/s wr_sec/s avgrq-sz avgqu-sz await svctm %util 02:13:18 IST dev8-0 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 @@ -349,11 +351,11 @@ At the back-end sa1 script will call **sadc** (System Activity Data Collector) u 02:13:19 IST DEV tps rd_sec/s wr_sec/s avgrq-sz avgqu-sz await svctm %util 02:13:20 IST dev8-0 7.00 32.00 80.00 16.00 0.11 15.43 15.43 10.80 -19.To print memory statistics use ‘**-r**‘ option. +19.使用‘**-r**’参数输出内存统计信息。 tecmint@tecmint ~ $ sar -r 1 3 - Linux 3.11.0-23-generic (tecmint.com) Thursday 04 September 2014 _i686_ (2 CPU) + Linux 3.11.0-23-generic (tecmint.com) Thursday 04 September 2014 _i686_ (2 CPU) 02:14:29 IST kbmemfree kbmemused %memused kbbuffers kbcached kbcommit %commit kbactive kbinact kbdirty 02:14:30 IST 1465660 2594840 63.90 133052 1549644 3710800 45.35 1133148 1359792 392 @@ -361,7 +363,7 @@ At the back-end sa1 script will call **sadc** (System Activity Data Collector) u 02:14:32 IST 1469112 2591388 63.82 133060 1550036 3705288 45.28 1130252 1360168 804 Average: 1469165 2591335 63.82 133057 1549824 3710531 45.34 1129739 1359987 677 -20.Using ‘**sadf -d**‘, we can extract data in format which can be processed using databases. +20.使用‘**sadf -d**’参数可以将数据导出为数据库可以使用的格式。 tecmint@tecmint ~ $ safd -d /var/log/sa/sa20140903 -- -n DEV | grep -v lo @@ -381,24 +383,24 @@ At the back-end sa1 script will call **sadc** (System Activity Data Collector) u tecmint;2;2014-09-03 12:00:10 UTC;eth0;0.50;0.50;0.03;0.04;0.00;0.00;0.00;0.00 tecmint;2;2014-09-03 12:00:12 UTC;eth0;1.00;0.50;0.12;0.04;0.00;0.00;0.00;0.00 -You can also save this to a csv and then can draw chart for presentation kind of stuff as below. +你也可以将这些数据存储在一个csv文档中,然后绘制成图表展示方式,如下所示 ![Network Graph](http://www.tecmint.com/wp-content/uploads/2014/09/sar-graph.png) -Network Graph +网络信息图表 -That’s it for now, you can refer man pages for more information about each option and don’t forget to tell about article with your valuable comments. +现在,你可以参考man手册来后去每个参数的更多详细信息,并且请在文章下留下你宝贵的评论。 -------------------------------------------------------------------------------- via: http://www.tecmint.com/sysstat-commands-to-monitor-linux/ 作者:[Kuldeep Sharma][a] -译者:[译者ID](https://github.com/译者ID) +译者:[cvsher](https://github.com/cvsher) 校对:[校对者ID](https://github.com/校对者ID) 本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 [a]:http://www.tecmint.com/author/kuldeepsharma47/ [1]:http://www.tecmint.com/install-sysstat-in-linux/ -[2]:http://www.tecmint.com/linux-performance-monitoring-with-vmstat-and-iostat-commands/ \ No newline at end of file +[2]:http://www.tecmint.com/linux-performance-monitoring-with-vmstat-and-iostat-commands/ diff --git a/translated/tech/[翻译完成]20140929 Learning Vim in 2014--Working with Files.md b/translated/tech/[翻译完成]20140929 Learning Vim in 2014--Working with Files.md new file mode 100644 index 0000000000..0a1eb2a3f3 --- /dev/null +++ b/translated/tech/[翻译完成]20140929 Learning Vim in 2014--Working with Files.md @@ -0,0 +1,113 @@ +2014年学习如何使用vim处理文件工作 +================================================================================ + +作为一名开发者你不能够只化时间去写你想要的代码。其中最难以处理的部分是我的工作只使用vim来处理文本。我感觉到很无语与无比的蛋疼,vim没有自己额外文件查看系统与内部打开与切换文件功能。因此,继vim之后,我主要使用Eclipse 和 Sublime Text. + +就此,我非常欣赏深度定制的vim文件管理功能。在工作环境上我已经装配了这些工具,甚至比起那些视觉编辑器好很多。因为这个是纯键盘操作,促使我可以更加快地移动我的代码。第一篇文章使我明白这个vim内建功能只是处理文件的另一选择。在这篇文章里我会带你去认识vim文件管理功能与使用更高级的插件。 + +### 基础篇:打开新文件 ### + +学习vim其中最大的一个障碍是缺少可视提示,不像现在的GUI图形编辑器,当你在终端打开一个新的vim是没有明显的提示去提醒你去走什么,所有事情都是靠键盘输入,同时也没有更多更好的界面交互,vim新手需要习惯如何靠自己去查找一些基本的操作指令。好吧,让我开始学习基础吧。 + +创建新文件的命令是**:e 或:e** 打开一个新缓冲区保存文件内容。如果文件不存在它会开辟一个缓冲区去保存与修改你指定文件。缓冲区是vim是术语,意为"保存文本块到内存"。文本是否能够与存在的文件关联,要看是否每个你打开的文件都对应一个缓冲区。 + + +打开文件与修改文件之后,你可以使用**:w**命令来保存在缓冲区的文件内容到文件里面,如果缓冲区不能关联你的文件或者你想保存到另外一个地方,你需要使用**:w **来保存指定地方。 + +这些是vim处理文件的基本知识,很多的开发者都掌握了这些命令,这些技巧你都需要掌握。vim提供了很多技巧让人去深挖。 + + +### 缓冲区管理 ### + +基础掌握了,就让我来说更多关于缓冲区得东西,vim处理打开文件与其他编辑器有一点不同,打开的文件不会作为一个标签留在一个可视地方,而是只允许你同时只有一个文件在缓冲区打开,vim允许你多个缓存打开。一些会显示出来,另外一些就不会,你需要用**:ls**来查看已经打开的缓存,这个命令会显示每个打开的缓存区,同时会有它们的序码,你可以通过这些序码实用**:b **来切换或者使用循序移动命令**:bnext** 和 **:bprevious** 也可以使用它们的缩写**:bn**和**:bp**。 + +这些命令是vim管理文件缓冲区的一个基础,我发现他们不会按照我的思维去映射出来。我不想关心缓冲区的顺序,我只想按照我的思维去到那个文件或者想在当前这个文件.因此必需了解vim更深的缓存模式,我不是推荐你必须内部命令来作为主要的文件管理方案。但这些的确是很强大可行的选择。 + +![](http://benmccormick.org/content/images/2014/Jul/skitch.jpeg) + +### 分屏 ### + +分屏是vim其中一个最好用的管理文件功能,在vim +你可以在当前窗同时分开2个窗口,可以按照你喜欢的配置去重设大小和分配,这个很特别可以在不同地方同时打开6文件每个文件都拥有自己的窗口大少 + +你可以通过命令**:sp **来新建水平分割窗口或者 **:vs **垂直分割窗口。你可以使用这些关键命令去重置你想要的窗口, +老实说,我喜欢用鼠标处理vim任务,因为鼠标能够给我更加准确的两列的宽度而不需要猜大概的宽度。 + +创建新的分屏后,你需要使用**ctrl-w +[h|j|k|l]**来向后向前切换。这个有少少笨拙,但这个确实很重要很普遍很容易很高效的操作.如果你经常使用分屏,我建议你去.vimrc使用以下代码q去设置别名为**ctrl-h** **ctrl-j** 等等。 + + nnoremap "Ctrl-j to move down a split + nnoremap "Ctrl-k to move up a split + nnoremap "Ctrl-l to move right a split + nnoremap "Ctrl-h to move left a split + +### 跳转表 ### + +分屏是解决多个关联文件同时查看问题,但我们仍然不能满足打开文件与隐藏文件之间快速移动。这时跳转表是一个能够解决的工具。 + +跳转表是众多插件中看其来奇怪而且很少使用。vim能够追踪每一步命令还有切换你正在修改的文件。每次从一个分屏窗口跳到另外一个,vim都会添加记录到跳转表里面。这个记录你去过的地方,这样就不需要担心之前的文件在哪里,你可以使用快捷键去快速追溯你的踪迹。**Ctrl-o**允许你返回你上一次地方。重复操作几次就能够返回到你最先编写的代码段地方。你可以使用**ctrl-i**来向前返回。当你在调试多个文件或两个文件之间切换能够发挥极大的快速移动功能。 + + +### 插件 ### + +如果你想vim像Sublime Text 或者Atom一样,我就让你认清一下,这里有很好的机会让你看到一些难懂,可怕和低效的事情。例如大家会发出"当Sublime有了模糊查找功能,为什么我一定要输入全路径才能够打开文件" "没有侧边栏显示目录树我怎样查看项目结构" 。但vim有了解决方案。这些方案不需要破坏vim的核心。我只需要经常修改vim配置与添加一些最新的插件,这里有3个有用的插件可以让你像Sublime管理文件 + +- [CtrlP][1] 是一个跟Sublime的"Go to Anything"栏一样模糊查找文件.它快如闪电并且非常可配置性。我使用它最主要打开文件。我只需知道部分的文件名字不需要记住整个项目结构就可以查找了 + +- [The NERDTree][2] + 这个一个文件管理夹插件,它重复了很多编辑器的有的侧边文件管理夹功能。我实际上很少用它,对于我模糊查找会更加快。对于你接手一个项目,尝试学习项目结构与了解什么可以用是非常方便的,NERDTree是可以自己定制配置,安装它能够代替vim内置的目录工具。 + + +- [Ack.vim][3] 是一个专为vim的代码搜索插件,它允许你跨项目搜索文本。通过Ack 或 Ag 去高亮查找 + [第二个极其好用的搜索工具][4],允许你在任何时候在你项目之间快速搜索跳转 + + +在vim核心与它的插件生态系统之间,vim 提供足够的工具允许你构建你想要得工作环境。文件管理是软件开发系统的最核心部分并且你值得拥有体验的权利 + + +开始是需要通过很长的时间去理解它们,然后才找到你感觉舒服的工作流程之后才开始添加工具在上面。但依然值得你去使用,当你不需要头爆去理解如何去使用就能够轻易编写你的代码。 + + +### 更多插件资源 ### + +- [Seamlessly Navigate Vim & Tmux Splits][5] 这个插件需要每一个想使用它的人都要懂得实用[tmux][6],这个跟vim的splits 一样简单好用 + + +- [Using Tab Pages][7] 它是一个vim的标签功能插件,虽然它的名字用起来有一点疑惑,但我不能说它是文件管理器。 + 对如何在有多个工作可视区使用"tab + pages" 在vim wiki 网站上有更好的概述 + +- [Vimcasts: The edit command][8] 一般来说 Vimcasts + 是大家学习vim的一个好资源。这个屏幕截图与一些内置工作流程是很好描述之前说得文件操作方面的知识 + + +### 订阅 ### + +这篇文章通过第三个方面介绍如何通过一些好的手法学习vim。如果你喜欢这篇文章你可以通过[feed][8]来订阅或email我[mailing +list][10]。在这个星期javascript小插曲之后,下星期我会继续介绍vim的配置方面的东西,你可以先看基础篇:使用vim +看我前2篇系列文章和vim与vi的语言 + +-------------------------------------------------------------------------------- + +via: http://benmccormick.org/2014/07/07/learning-vim-in-2014-working-with-files/ + +作者:[Ben McCormick][a] +译者:[译者ID](https://github.com/haimingfg) +校对:[校对者ID](https://github.com/校对者ID) + +本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出 + +[a]:http://benmccormick.org/2014/07/07/learning-vim-in-2014-working-with-files/ +[1]:https://github.com/kien/ctrlp.vim +[2]:https://github.com/scrooloose/nerdtree +[3]:https://github.com/mileszs/ack.vim +[4]:http://benmccormick.org/2013/11/25/a-look-at-ack/ +[5]:http://robots.thoughtbot.com/seamlessly-navigate-vim-and-tmux-splits +[6]:http://tmux.sourceforge.net/ +[7]:http://vim.wikia.com/wiki/Using_tab_pages +[8]:http://vimcasts.org/episodes/the-edit-command/ +[9]:http://feedpress.me/benmccormick +[10]:http://eepurl.com/WFYon +[11]:http://benmccormick.org/2014/07/14/learning-vim-in-2014-configuring-vim/ +[12]:http://benmccormick.org/2014/06/30/learning-vim-in-2014-the-basics/ +[13]:http://benmccormick.org/2014/07/02/learning-vim-in-2014-vim-as-language/