<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Neo&#039;s notes &#187; 系统管理</title>
	<atom:link href="http://www.neocanable.com/category/system-admin/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.neocanable.com</link>
	<description>记录一些琐碎的技术问题&#124;发泄胸中的各种不满</description>
	<lastBuildDate>Tue, 17 Jan 2012 05:37:27 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.1</generator>
		<item>
		<title>linux top 使用方法</title>
		<link>http://www.neocanable.com/linux-top/</link>
		<comments>http://www.neocanable.com/linux-top/#comments</comments>
		<pubDate>Sun, 20 Mar 2011 15:37:50 +0000</pubDate>
		<dc:creator>Neo</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[系统管理]]></category>
		<category><![CDATA[linux]]></category>

		<guid isPermaLink="false">http://www.neocanable.com/?p=294</guid>
		<description><![CDATA[LINUX性能监控工具 1.top各个列的含义 最顶行:三个数值分别为 1分钟、5分钟、15分钟前到现在的平均值。 a PID 进程id &#160; b PPID 父进程id &#160; c RUSER Real user name &#160; d UID 进程所有者的用户id &#160; e USER 进程所有者的用户名 &#160; f GROUP 进程所有者的组名 &#160; g TTY 启动进程的终端名。不是从终端启动的进程则显示为 ? &#160; h PR 优先级 &#160; i NI nice值。负值表示高优先级，正值表示低优先级 &#160; j P 最后使用的CPU，仅在多CPU环境下有意义 &#160; k %CPU 上次更新到现在的CPU时间占用百分比 &#160; l TIME 进程使用的CPU时间总计，单位秒 &#160; [...]]]></description>
			<content:encoded><![CDATA[<p>LINUX性能监控工具</p>
<p>1.top各个列的含义</p>
<p>      最顶行:三个数值分别为 1分钟、5分钟、15分钟前到现在的平均值。</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">a PID 进程<span style="color: #c20cb9; font-weight: bold;">id</span> &nbsp;<br />
b PPID 父进程<span style="color: #c20cb9; font-weight: bold;">id</span> &nbsp;<br />
c RUSER Real user name &nbsp;<br />
d UID 进程所有者的用户<span style="color: #c20cb9; font-weight: bold;">id</span> &nbsp;<br />
e USER 进程所有者的用户名 &nbsp;<br />
f GROUP 进程所有者的组名 &nbsp;<br />
g TTY 启动进程的终端名。不是从终端启动的进程则显示为 ? &nbsp;<br />
h PR 优先级 &nbsp;<br />
i NI <span style="color: #c20cb9; font-weight: bold;">nice</span>值。负值表示高优先级，正值表示低优先级 &nbsp;<br />
j P 最后使用的CPU，仅在多CPU环境下有意义 &nbsp;<br />
k <span style="color: #000000; font-weight: bold;">%</span>CPU 上次更新到现在的CPU时间占用百分比 &nbsp;<br />
l TIME 进程使用的CPU时间总计，单位秒 &nbsp;<br />
m TIME+ 进程使用的CPU时间总计，单位<span style="color: #000000;">1</span><span style="color: #000000; font-weight: bold;">/</span><span style="color: #000000;">100</span>秒 &nbsp;<br />
n <span style="color: #000000; font-weight: bold;">%</span>MEM 进程使用的物理内存百分比 &nbsp;<br />
o VIRT 进程使用的虚拟内存总量，单位kb。<span style="color: #007800;">VIRT</span>=SWAP+RES &nbsp;<br />
p SWAP 进程使用的虚拟内存中，被换出的大小，单位kb。 &nbsp;<br />
q RES 进程使用的、未被换出的物理内存大小，单位kb。<span style="color: #007800;">RES</span>=CODE+DATA &nbsp;<br />
r CODE 可执行代码占用的物理内存大小，单位kb &nbsp;<br />
s DATA 可执行代码以外的部分<span style="color: #7a0874; font-weight: bold;">&#40;</span>数据段+栈<span style="color: #7a0874; font-weight: bold;">&#41;</span>占用的物理内存大小，单位kb &nbsp;<br />
t SHR 共享内存大小，单位kb &nbsp;<br />
u nFLT 页面错误次数 &nbsp;<br />
v nDRT 最后一次写入到现在，被修改过的页面数。 &nbsp;<br />
<span style="color: #c20cb9; font-weight: bold;">w</span> S 进程状态。 <br />
<span style="color: #007800;">D</span>=不可中断的睡眠状态 <br />
<span style="color: #007800;">R</span>=运行 <br />
<span style="color: #007800;">S</span>=睡眠 <br />
<span style="color: #007800;">T</span>=跟踪<span style="color: #000000; font-weight: bold;">/</span>停止 <br />
<span style="color: #007800;">Z</span>=僵尸进程 &nbsp;<br />
x COMMAND 命令名<span style="color: #000000; font-weight: bold;">/</span>命令行 &nbsp;<br />
y WCHAN 若该进程在睡眠，则显示睡眠中的系统函数名</div></div>
<p>2.交互式</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">t : cpu和任务数量的总结性信息是否显示<br />
m : 是否显示内存的使用情况<br />
A : 分屏,可以分四个屏,用来监控不同的参数<br />
&nbsp; &nbsp; -或者<span style="color: #ff0000;">&quot;_&quot;</span> : 否显示当前窗口和是否显示所有<br />
&nbsp; &nbsp; G : 选择操作的窗口<br />
&nbsp; &nbsp; <br />
&nbsp; &nbsp; <br />
<br />
z : 关闭颜色显示<br />
Z : 设置颜色,<span style="color: #000000;">0</span>-<span style="color: #000000;">7</span><br />
B : 使用加粗显示<br />
b : 配合x,y使用，能公将当前排序列加粗<br />
f : 设置需要选择的那些列<br />
o : 设置列的显示顺序,例如地一列显示内存的使用，第二列显示cpu的使用<br />
&nbsp; &nbsp; &nbsp;.... <span style="color: #7a0874; font-weight: bold;">shift</span>+字母<span style="color: #000000; font-weight: bold;">/</span>字母调整顺序<br />
<br />
F<span style="color: #000000; font-weight: bold;">/</span>O : 设置排序的列<br />
<br />
R : 将结果倒排序<span style="color: #7a0874; font-weight: bold;">&#40;</span>reverse<span style="color: #7a0874; font-weight: bold;">&#41;</span><br />
c : 显示进程是用什么命令运行的<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #7a0874; font-weight: bold;">command</span> line<span style="color: #7a0874; font-weight: bold;">&#41;</span><br />
i : 空闲的任务<br />
u : 设置显示某个用户的进程,什么都不填是所有用户的<br />
n 或者 <span style="color: #666666; font-style: italic;"># : 设置显示的进程数量,0是不限 </span><br />
k : 杀死某个进程，需要给出进程的<span style="color: #c20cb9; font-weight: bold;">id</span><br />
r : <span style="color: #c20cb9; font-weight: bold;">nice</span>和renice<br />
W : 写到配置文件中 <br />
l : 是否显示load average<br />
s : 改变刷屏的时间间隔<br />
<span style="color: #000000; font-weight: bold;">&lt;</span>或者<span style="color: #000000; font-weight: bold;">&gt;</span> : 替换排序的列</div></div>
<p>3 运行参数</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">&nbsp; &nbsp;<span style="color: #660033;">-d</span> 设置刷屏的时间 &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #666666; font-style: italic;"># top -d 2</span><br />
&nbsp; &nbsp;<span style="color: #660033;">-p</span> 指定需要监控的进程<span style="color: #c20cb9; font-weight: bold;">id</span> &nbsp; <span style="color: #666666; font-style: italic;"># top -p 1122</span><br />
&nbsp; &nbsp;<span style="color: #660033;">-s</span> 安全模式，这个不太懂<br />
&nbsp; &nbsp;<span style="color: #660033;">-i</span> 不显示闲置和僵死的进程<br />
&nbsp; &nbsp;<span style="color: #660033;">-c</span> 显示全部命令参数</div></div>
]]></content:encoded>
			<wfw:commentRss>http://www.neocanable.com/linux-top/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>linux ssh</title>
		<link>http://www.neocanable.com/linux-ssh/</link>
		<comments>http://www.neocanable.com/linux-ssh/#comments</comments>
		<pubDate>Sun, 20 Mar 2011 15:33:52 +0000</pubDate>
		<dc:creator>Neo</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[系统管理]]></category>
		<category><![CDATA[linux]]></category>

		<guid isPermaLink="false">http://www.neocanable.com/?p=291</guid>
		<description><![CDATA[1.ssh -l username remoteip 或者 ssh username@remoteip ssh -l meng -p 22 192.168.254.50 ssh默认的端口是22，所以remote address的ssh server 如果没有修改ssh的端口的话会默认为22 neo@ubuntu:~$ ssh -l meng 192.168.254.50 Last login: Fri Mar 11 12:14:48 2011 from 192.168.254.102 [meng@ddkan ~]$ 2.ssh server绑定ip地址 ListenAddress 192.168.0.11 # 只允许192.168.0.11这个ip登录上来 3.修改ssh端口 Port 2222 修改ssh服务的端口为2222 4.修改ssh协议的版本 Protocol 2 # 可以为1和2这两个版本 5.不允许root登录 PermitRootLogin no 详细：http://blog.lizhigang.net/archives/249]]></description>
			<content:encoded><![CDATA[<p>1.ssh -l username remoteip 或者 ssh username@remoteip<br />
 ssh -l meng -p 22 192.168.254.50<br />
 ssh默认的端口是22，所以remote address的ssh server 如果没有修改ssh的端口的话会默认为22<br />
neo@ubuntu:~$ ssh -l meng 192.168.254.50<br />
Last login: Fri Mar 11 12:14:48 2011 from 192.168.254.102<br />
[meng@ddkan ~]$ </p>
<p>2.ssh server绑定ip地址<br />
ListenAddress 192.168.0.11 # 只允许192.168.0.11这个ip登录上来</p>
<p>3.修改ssh端口<br />
Port 2222 修改ssh服务的端口为2222</p>
<p>4.修改ssh协议的版本<br />
Protocol 2  # 可以为1和2这两个版本</p>
<p>5.不允许root登录<br />
PermitRootLogin no</p>
<p>详细：<a href="http://blog.lizhigang.net/archives/249">http://blog.lizhigang.net/archives/249</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.neocanable.com/linux-ssh/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>linux tar 打包方法</title>
		<link>http://www.neocanable.com/linux-tar/</link>
		<comments>http://www.neocanable.com/linux-tar/#comments</comments>
		<pubDate>Sun, 20 Mar 2011 15:32:24 +0000</pubDate>
		<dc:creator>Neo</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[系统管理]]></category>
		<category><![CDATA[linux]]></category>

		<guid isPermaLink="false">http://www.neocanable.com/?p=288</guid>
		<description><![CDATA[1.创建tar包 tar cvf demo.tar demo/ # 打包 tar xvf demo.tar &#160; &#160; &#160; # 解包 c : 创建归档文件 v : 显示被打包的文件 f : 使用文件归档 tar czvf demo.tar.gz demo/ # 打包并且压缩 tar xzvf demo.tar.gz &#160; &#160; &#160; # 解压缩 z : 压缩，用gzip note: tgz == tar.gz tar cjvf demo.tar.bz2 demo/ # 用gzip2压缩 tar xjvf demo.tar.bz2 &#160; [...]]]></description>
			<content:encoded><![CDATA[<p>1.创建tar包</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #c20cb9; font-weight: bold;">tar</span> cvf demo.tar demo<span style="color: #000000; font-weight: bold;">/</span> <span style="color: #666666; font-style: italic;"># 打包</span><br />
<span style="color: #c20cb9; font-weight: bold;">tar</span> xvf demo.tar &nbsp; &nbsp; &nbsp; <span style="color: #666666; font-style: italic;"># 解包</span></div></div>
<p>c : 创建归档文件<br />
v : 显示被打包的文件<br />
f : 使用文件归档</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #c20cb9; font-weight: bold;">tar</span> czvf demo.tar.gz demo<span style="color: #000000; font-weight: bold;">/</span> <span style="color: #666666; font-style: italic;"># 打包并且压缩</span><br />
<span style="color: #c20cb9; font-weight: bold;">tar</span> xzvf demo.tar.gz &nbsp; &nbsp; &nbsp; <span style="color: #666666; font-style: italic;"># 解压缩</span></div></div>
<p>z : 压缩，用gzip<br />
note: tgz == tar.gz</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #c20cb9; font-weight: bold;">tar</span> cjvf demo.tar.bz2 demo<span style="color: #000000; font-weight: bold;">/</span> <span style="color: #666666; font-style: italic;"># 用gzip2压缩</span><br />
<span style="color: #c20cb9; font-weight: bold;">tar</span> xjvf demo.tar.bz2 &nbsp; &nbsp; &nbsp; <span style="color: #666666; font-style: italic;"># 解压</span></div></div>
<p>j : bzip2解压<br />
note: tbz和.tb2 等同于tar.bz2</p>
<p>2.查看tar包里面的东西(listing a tar file)</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #c20cb9; font-weight: bold;">tar</span> tvf demo.tar &nbsp; &nbsp; <span style="color: #666666; font-style: italic;"># 查看一个tar文件</span><br />
<span style="color: #c20cb9; font-weight: bold;">tar</span> tzvf demo.tar.gz <span style="color: #666666; font-style: italic;"># 查看tar.gz/tgz文件</span><br />
<span style="color: #c20cb9; font-weight: bold;">tar</span> tjvf demo.tar.bz2 <span style="color: #666666; font-style: italic;"># 查看bz2/tb2/tbz等类型的文件</span></div></div>
<p>3.解压单独文件或者目录</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #c20cb9; font-weight: bold;">tar</span> xvf demo.tar .<span style="color: #000000; font-weight: bold;">/</span><span style="color: #c20cb9; font-weight: bold;">file</span> &nbsp; &nbsp; &nbsp; <span style="color: #666666; font-style: italic;"># 将file从demo.tar中解压出来</span><br />
<span style="color: #c20cb9; font-weight: bold;">tar</span> xzvf demo.tar.gz .<span style="color: #000000; font-weight: bold;">/</span><span style="color: #c20cb9; font-weight: bold;">file</span> &nbsp; <span style="color: #666666; font-style: italic;"># 将file从demo.tar.gz中解压出来</span><br />
<span style="color: #c20cb9; font-weight: bold;">tar</span> xjvf demo.tar.bz2 .<span style="color: #000000; font-weight: bold;">/</span><span style="color: #c20cb9; font-weight: bold;">file</span> &nbsp;<span style="color: #666666; font-style: italic;"># 将file从demo.tar.bz2中解压出来</span></div></div>
<p>5.解压出一种类型的文件</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #c20cb9; font-weight: bold;">tar</span> xvf demo.tar <span style="color: #660033;">--wildcards</span> ‘<span style="color: #000000; font-weight: bold;">*</span>.rb’ <span style="color: #666666; font-style: italic;"># 解压demo.tar包中所有的rb文件</span></div></div>
<p>6.将文件或者目录推到tar里面</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #c20cb9; font-weight: bold;">tar</span> rvf demo.tar demo<span style="color: #000000; font-weight: bold;">/</span> &nbsp; &nbsp; <span style="color: #666666; font-style: italic;"># 将demo/ 目录打包到demo.tar中</span><br />
<span style="color: #c20cb9; font-weight: bold;">tar</span> rvf demo.tar demo.file <span style="color: #666666; font-style: italic;"># 将demo.file打包到demo.tar中</span></div></div>
<p>other tips</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #c20cb9; font-weight: bold;">tar</span> cjvf back-$<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #c20cb9; font-weight: bold;">date</span> +<span style="color: #000000; font-weight: bold;">%</span>Y<span style="color: #000000; font-weight: bold;">%</span>m<span style="color: #000000; font-weight: bold;">%</span>d<span style="color: #7a0874; font-weight: bold;">&#41;</span>.tar.bz2 to_backup<span style="color: #000000; font-weight: bold;">/</span> <span style="color: #666666; font-style: italic;"># 按照日期备份</span></div></div>
]]></content:encoded>
			<wfw:commentRss>http://www.neocanable.com/linux-tar/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>linux grep 使用方法</title>
		<link>http://www.neocanable.com/linux-grep/</link>
		<comments>http://www.neocanable.com/linux-grep/#comments</comments>
		<pubDate>Sun, 20 Mar 2011 15:29:54 +0000</pubDate>
		<dc:creator>Neo</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[系统管理]]></category>
		<category><![CDATA[linux]]></category>

		<guid isPermaLink="false">http://www.neocanable.com/?p=285</guid>
		<description><![CDATA[1.在一个文件内搜索某个字符串 grep 'match_word' file 2.在多个文件内搜索某个字符串 grep 'match_word' file file2 grep 'match_word' *.rb &#160; &#160; &#160;# 后面可以跟正则\ 3.不区分大小写 grep -i 'match_word' file 4.正则表达式 grep 'regular' file &#160;# 放一个正则表达式也是ok的 5.全字匹配 grep -w 'the' file &#160; # 会匹配the，但是不会匹配there 6.匹配前后几行(match with A/B/C) grep -A 3 'the' file # 匹配出现the的那行并且也输出后面的三行 grep -B 3 'the' file # 匹配出现the的那行并且也输出前面的三行 grep -C 3 [...]]]></description>
			<content:encoded><![CDATA[<p>1.在一个文件内搜索某个字符串</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #c20cb9; font-weight: bold;">grep</span> <span style="color: #ff0000;">'match_word'</span> <span style="color: #c20cb9; font-weight: bold;">file</span></div></div>
<p>2.在多个文件内搜索某个字符串</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #c20cb9; font-weight: bold;">grep</span> <span style="color: #ff0000;">'match_word'</span> <span style="color: #c20cb9; font-weight: bold;">file</span> file2<br />
<span style="color: #c20cb9; font-weight: bold;">grep</span> <span style="color: #ff0000;">'match_word'</span> <span style="color: #000000; font-weight: bold;">*</span>.rb &nbsp; &nbsp; &nbsp;<span style="color: #666666; font-style: italic;"># 后面可以跟正则\</span></div></div>
<p>3.不区分大小写</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #c20cb9; font-weight: bold;">grep</span> <span style="color: #660033;">-i</span> <span style="color: #ff0000;">'match_word'</span> <span style="color: #c20cb9; font-weight: bold;">file</span></div></div>
<p>4.正则表达式</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #c20cb9; font-weight: bold;">grep</span> <span style="color: #ff0000;">'regular'</span> <span style="color: #c20cb9; font-weight: bold;">file</span> &nbsp;<span style="color: #666666; font-style: italic;"># 放一个正则表达式也是ok的</span></div></div>
<p>5.全字匹配</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #c20cb9; font-weight: bold;">grep</span> <span style="color: #660033;">-w</span> <span style="color: #ff0000;">'the'</span> <span style="color: #c20cb9; font-weight: bold;">file</span> &nbsp; <span style="color: #666666; font-style: italic;"># 会匹配the，但是不会匹配there</span></div></div>
<p>6.匹配前后几行(match with A/B/C)</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #c20cb9; font-weight: bold;">grep</span> <span style="color: #660033;">-A</span> <span style="color: #000000;">3</span> <span style="color: #ff0000;">'the'</span> <span style="color: #c20cb9; font-weight: bold;">file</span> <span style="color: #666666; font-style: italic;"># 匹配出现the的那行并且也输出后面的三行</span><br />
<span style="color: #c20cb9; font-weight: bold;">grep</span> <span style="color: #660033;">-B</span> <span style="color: #000000;">3</span> <span style="color: #ff0000;">'the'</span> <span style="color: #c20cb9; font-weight: bold;">file</span> <span style="color: #666666; font-style: italic;"># 匹配出现the的那行并且也输出前面的三行</span><br />
<span style="color: #c20cb9; font-weight: bold;">grep</span> <span style="color: #660033;">-C</span> <span style="color: #000000;">3</span> <span style="color: #ff0000;">'the'</span> <span style="color: #c20cb9; font-weight: bold;">file</span> <span style="color: #666666; font-style: italic;"># 匹配出现the的那行并且也输出前后三行</span></div></div>
<p>7.搜索目录下的文件</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #c20cb9; font-weight: bold;">grep</span> <span style="color: #660033;">-r</span> <span style="color: #ff0000;">'the'</span> .<span style="color: #000000; font-weight: bold;">/</span> &nbsp;<span style="color: #666666; font-style: italic;"># 搜索目录下面的文件里面报行the的文件</span><br />
<span style="color: #c20cb9; font-weight: bold;">grep</span> <span style="color: #660033;">-R</span> <span style="color: #ff0000;">'the'</span> .<span style="color: #000000; font-weight: bold;">/</span> &nbsp;<span style="color: #666666; font-style: italic;"># 递归搜索</span></div></div>
<p>8.反向匹配</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #c20cb9; font-weight: bold;">grep</span> <span style="color: #660033;">-v</span> <span style="color: #ff0000;">'the'</span> <span style="color: #c20cb9; font-weight: bold;">file</span> <span style="color: #666666; font-style: italic;"># 找不不含有the的行</span></div></div>
<p>9.反向匹配多个字符</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #c20cb9; font-weight: bold;">grep</span> <span style="color: #660033;">-v</span> <span style="color: #660033;">-e</span> <span style="color: #ff0000;">'the'</span> <span style="color: #660033;">-e</span> <span style="color: #ff0000;">'this'</span> <span style="color: #660033;">-e</span> <span style="color: #ff0000;">'find'</span> <span style="color: #666666; font-style: italic;"># 匹配不包含the、this、find的行</span></div></div>
<p>10.找到匹配的数量</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #c20cb9; font-weight: bold;">grep</span> <span style="color: #660033;">-c</span> <span style="color: #ff0000;">'the'</span> <span style="color: #c20cb9; font-weight: bold;">file</span> <span style="color: #666666; font-style: italic;"># 找出字符the的行数的数量</span></div></div>
<p>11.显示匹配的的行号</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #c20cb9; font-weight: bold;">grep</span> <span style="color: #660033;">-n</span> <span style="color: #ff0000;">'the'</span> <span style="color: #c20cb9; font-weight: bold;">file</span> <span style="color: #666666; font-style: italic;"># 找出file内匹配the的行，并且显示行号</span></div></div>
<p>12.仅仅显示匹配的文件名称</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #c20cb9; font-weight: bold;">grep</span> <span style="color: #660033;">-l</span> <span style="color: #ff0000;">'the'</span> <span style="color: #000000; font-weight: bold;">*</span>.rb &nbsp;<span style="color: #666666; font-style: italic;"># 所有包含字符the的文件名称</span></div></div>
<p>13.仅仅显示匹配的字符串</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #c20cb9; font-weight: bold;">grep</span> <span style="color: #660033;">-o</span> <span style="color: #ff0000;">'the'</span> <span style="color: #c20cb9; font-weight: bold;">file</span> &nbsp;<span style="color: #666666; font-style: italic;"># &nbsp;仅仅显示每行的the</span></div></div>
<p>14.多颜色显示</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #c20cb9; font-weight: bold;">grep</span> <span style="color: #660033;">-v</span> <span style="color: #ff0000;">'the'</span> <span style="color: #c20cb9; font-weight: bold;">file</span> <span style="color: #660033;">--color</span></div></div>
<p>或者</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #7a0874; font-weight: bold;">export</span> <span style="color: #007800;">GREP_OPTIONS</span>=<span style="color: #ff0000;">'--color=auto'</span> <span style="color: #007800;">GREP_COLOR</span>=<span style="color: #ff0000;">'100;8'</span> ; <br />
<span style="color: #c20cb9; font-weight: bold;">grep</span> <span style="color: #ff0000;">'the'</span> <span style="color: #c20cb9; font-weight: bold;">file</span></div></div>
]]></content:encoded>
			<wfw:commentRss>http://www.neocanable.com/linux-grep/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>uninitialized constant MysqlCompat::MysqlRes</title>
		<link>http://www.neocanable.com/uninitialized-constant-mysqlcompat-mysqlres/</link>
		<comments>http://www.neocanable.com/uninitialized-constant-mysqlcompat-mysqlres/#comments</comments>
		<pubDate>Mon, 04 Oct 2010 15:43:54 +0000</pubDate>
		<dc:creator>Neo</dc:creator>
				<category><![CDATA[Ruby On Rails]]></category>
		<category><![CDATA[系统管理]]></category>

		<guid isPermaLink="false">http://www.neocanable.com/?p=193</guid>
		<description><![CDATA[export ARCHFLAGS=&#8221;-arch i386 -arch x86_64&#8243; ;sudo gem install &#8211;no-rdoc &#8211;no-ri -v=2.7 mysql &#8212; &#8211;with-mysql-dir=/usr/local/mysql &#8211;with-mysql-config=/usr/local/mysql/bin/mysql_config 64位的系统安装方法，装的时候其实主要找到mysql_config这个东西,我这里装的是2.7的gem]]></description>
			<content:encoded><![CDATA[<p>export ARCHFLAGS=&#8221;-arch i386 -arch x86_64&#8243; ;sudo gem install &#8211;no-rdoc &#8211;no-ri<br />
-v=2.7 mysql &#8212; &#8211;with-mysql-dir=/usr/local/mysql<br />
&#8211;with-mysql-config=/usr/local/mysql/bin/mysql_config</p>
<p>64位的系统安装方法，装的时候其实主要找到mysql_config这个东西,我这里装的是2.7的gem</p>
]]></content:encoded>
			<wfw:commentRss>http://www.neocanable.com/uninitialized-constant-mysqlcompat-mysqlres/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>redhat部署rails(phusion passenger)</title>
		<link>http://www.neocanable.com/rails-deploy-on-redhat/</link>
		<comments>http://www.neocanable.com/rails-deploy-on-redhat/#comments</comments>
		<pubDate>Tue, 01 Jun 2010 15:02:28 +0000</pubDate>
		<dc:creator>Neo</dc:creator>
				<category><![CDATA[Ruby On Rails]]></category>
		<category><![CDATA[系统管理]]></category>

		<guid isPermaLink="false">http://www.neocanable.com/?p=144</guid>
		<description><![CDATA[1.Install ruby wget ftp://ftp.ruby-lang.org/pub/ruby/1.8/ruby-1.8.7-p248.tar.gz tar xzvf ruby-1.8.7-p248.tar.gz cd ruby-1.8.7-p248 ./configure make &#38;&#38; make install 2.install rubygem wget http://production.cf.rubygems.org/rubygems/rubygems-1.3.6.tgz tar xzvf rubygems-1.3.6.tgz cd ruby-gems-1.3.6 ruby setup.rb 3.install ImageRmagic wget ftp://gd.tuwien.ac.at/pub/graphics/ImageMagick/ImageMagick-6.6.1-7.tar.gz ftp://gd.tuwien.ac.at/pub/graphics/ImageMagick/ImageMagick-6.6.1-9.tar.gz &#160; tar xzvf ImageMagick-6.6.1-7.tar.gz cd ImageMagick-6.6.1-7 ./configure make &#38;&#38; make install 4.mysql-libs and mysql-devel http://rpms.famillecollet.com/enterprise/5/remi/x86_64/mysql-libs-5.1.46-1.el5.remi.x86_64.rpm http://dev.mysql.com/pub/Downloads/MySQL-5.1/MySQL-client-community-5.1.46-1.rhel5.x86_64.rpm http://rpms.famillecollet.com/enterprise/5/remi/x86_64/mysql-libs-5.1.46-1.el5.remi.x86_64.rpm http://rpms.famillecollet.com/enterprise/5/remi/x86_64/mysql-libs-5.1.46-1.el5.remi.x86_64.rpm 上面那些连接备用 5.1安装mysql-libs wget http://rpms.famillecollet.com/enterprise/5/remi/x86_64/mysql-libs-5.1.46-1.el5.remi.x86_64.rpm rpm -ivh mysql-libs-5.1.46-1.el5.remi.x86_64.rpm [...]]]></description>
			<content:encoded><![CDATA[<p>1.Install ruby</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">wget ftp://ftp.ruby-lang.org/pub/ruby/1.8/ruby-1.8.7-p248.tar.gz<br />
tar xzvf ruby-1.8.7-p248.tar.gz<br />
cd ruby-1.8.7-p248<br />
./configure<br />
make &amp;&amp; make install</div></div>
<p>2.install rubygem</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">wget http://production.cf.rubygems.org/rubygems/rubygems-1.3.6.tgz<br />
tar xzvf rubygems-1.3.6.tgz<br />
cd ruby-gems-1.3.6<br />
ruby setup.rb</div></div>
<p>3.install ImageRmagic</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">wget ftp://gd.tuwien.ac.at/pub/graphics/ImageMagick/ImageMagick-6.6.1-7.tar.gz<br />
ftp://gd.tuwien.ac.at/pub/graphics/ImageMagick/ImageMagick-6.6.1-9.tar.gz<br />
<br />
&nbsp;<br />
tar xzvf ImageMagick-6.6.1-7.tar.gz<br />
cd ImageMagick-6.6.1-7<br />
./configure<br />
make &amp;&amp; make install</div></div>
<p>4.mysql-libs and mysql-devel</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">http://rpms.famillecollet.com/enterprise/5/remi/x86_64/mysql-libs-5.1.46-1.el5.remi.x86_64.rpm<br />
http://dev.mysql.com/pub/Downloads/MySQL-5.1/MySQL-client-community-5.1.46-1.rhel5.x86_64.rpm<br />
http://rpms.famillecollet.com/enterprise/5/remi/x86_64/mysql-libs-5.1.46-1.el5.remi.x86_64.rpm<br />
http://rpms.famillecollet.com/enterprise/5/remi/x86_64/mysql-libs-5.1.46-1.el5.remi.x86_64.rpm</div></div>
<p>上面那些连接备用</p>
<p>5.1安装mysql-libs</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">wget http://rpms.famillecollet.com/enterprise/5/remi/x86_64/mysql-libs-5.1.46-1.el5.remi.x86_64.rpm<br />
rpm -ivh mysql-libs-5.1.46-1.el5.remi.x86_64.rpm</div></div>
<p>5.2 安装mysql-devel</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">wget http://dev.mysql.com/pub/Downloads/MySQL-5.1/MySQL-devel-community-5.1.46-1.rhel5.x86_64.rpm<br />
rpm -ivh MySQL-devel-community-5.1.46-1.rhel5.x86_64.rpm[cc]<br />
<br />
&nbsp;<br />
6.Subversion[cc]<br />
wget http://dag.wieers.com/rpm/packages/subversion/subversion-1.4.6-0.1.el5.rf.x86_64.rpm<br />
rpm -ivh subversion-1.4.6-0.1.el5.rf.x86_64.rpm</div></div>
<p>这个subversion的版本比较老了<br />
7.Smbfs(这个不安装也可以)</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">wget ftp://195.220.108.108/linux/Mandriva/devel/cooker/x86_64/media/main/release/mount-cifs-3.5.2-1mdv2010.1.x86_64.rpm<br />
&nbsp;<br />
rpm -ivh mount-cifs-3.5.2-1mdv2010.1.x86_64.rpm</div></div>
<p>8.安装rails</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">gem install rails -v=2.3.2 --no-ri --no-rdoc<br />
gem install mysql rmagick --no-ri --no-rdoc<br />
gem install passenger</div></div>
<p>9.安装passenger和nginx</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">passenger-install-nginx-module</div></div>
<p>passenger 安装nginx模块绝对是个傻瓜式的安装,顺着提示一步一步来就可以了</p>
<p>接下来就是checkout出来我们的项目,跑起nginx服务就行了</p>
]]></content:encoded>
			<wfw:commentRss>http://www.neocanable.com/rails-deploy-on-redhat/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>curl 使用(原创)</title>
		<link>http://www.neocanable.com/curl-usage/</link>
		<comments>http://www.neocanable.com/curl-usage/#comments</comments>
		<pubDate>Tue, 25 May 2010 22:51:19 +0000</pubDate>
		<dc:creator>Neo</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[系统管理]]></category>

		<guid isPermaLink="false">http://www.neocanable.com/?p=132</guid>
		<description><![CDATA[1.访问http页面内容，输出到标准输出 curl http://www.neocanable.com 2.生成文件 curl -o index.html http://www.neocanable.com 以远程文件名保存 curl -O http://www.neocanable.com 参数-o为输出到某个文件，上面的命令等同于wget http://www.neocanable.com或者curl http://www.neocanable.com > index.html 3.添加proxy curl -x xxx.xxx.xxx.xxx http://www.neocanable.com 通过代理ip访问网页 4.添加浏览器信息 通常服务器的日志会记录客户端浏览器的信息 curl -A &#8220;浏览器信息&#8221; http://www.neocanable.com 5.批量下载文件 curl http://www.xxx.com/action/[1-100].html > /dev/null 这个最适合爬自己网站的缓存了 文件下载后重新命名和类正则使用,下载后的文件是demo1-001.html curl -o #1_#2 http://www.xxx.com/~{demo1,demo2}/[1-100].html 创建需要的目录 curl -o &#8211;create-dirs http://www.xxx.com/~{demo1,demo2}/[1-100].html 6.分块下载 curl -r 0-1024 http://www.xxx.com/aa.zip curl -r 1025- http://www.xxx.com/aa.zip 先下1M,然后再下剩下的 [...]]]></description>
			<content:encoded><![CDATA[<p>1.访问http页面内容，输出到标准输出</p>
<p>curl http://www.neocanable.com</p>
<p>2.生成文件</p>
<p>curl -o index.html http://www.neocanable.com<br />
以远程文件名保存<br />
curl -O http://www.neocanable.com</p>
<p>参数-o为输出到某个文件，上面的命令等同于wget http://www.neocanable.com或者curl http://www.neocanable.com > index.html</p>
<p>3.添加proxy</p>
<p>curl -x xxx.xxx.xxx.xxx http://www.neocanable.com<br />
通过代理ip访问网页</p>
<p>4.添加浏览器信息</p>
<p>通常服务器的日志会记录客户端浏览器的信息<br />
curl -A &#8220;浏览器信息&#8221; http://www.neocanable.com</p>
<p>5.批量下载文件</p>
<p>curl http://www.xxx.com/action/[1-100].html > /dev/null<br />
这个最适合爬自己网站的缓存了</p>
<p>文件下载后重新命名和类正则使用,下载后的文件是demo1-001.html<br />
curl -o #1_#2 http://www.xxx.com/~{demo1,demo2}/[1-100].html<br />
创建需要的目录<br />
curl -o &#8211;create-dirs http://www.xxx.com/~{demo1,demo2}/[1-100].html </p>
<p>6.分块下载</p>
<p>curl -r 0-1024 http://www.xxx.com/aa.zip<br />
curl -r 1025- http://www.xxx.com/aa.zip<br />
先下1M,然后再下剩下的</p>
<p>7.curl ftp</p>
<p>访问ftp地址<br />
curl -u username:password ftp://www.xxx.com<br />
curl -u ftp://www.xxx.com<br />
添加端口<br />
curl -u username:password -P8899 ftp://www.xxx.com</p>
<p>上传文件到ftp<br />
curl -T /home/neo/demo.jpg -u username:password ftp://www.xxx.com</p>
<p>8.测试参数</p>
<p>测试站点相应时间<br />
curl -o /dev/null -s -w %{time_connect}:%{time_starttransfer}:%{time_total} www.google.com<br />
查看http_code<br />
curl -o /dev/null -s -w %{http_code} http://www.neocanable.com<br />
网页或文件大小<br />
curl -o /dev/null -s -w %{size_header} http://www.neocanable.com</p>
<p>http_code:http返回类似404,200,500等<br />
time_total:总相应时间<br />
time_namelookup:域名解析时间<br />
time_connect:连接到目标地址耗费的时间<br />
time_pretransfer:从执行到开始传输文件的时间间隔<br />
time_starttransfer:从执行到开始传输文件的时间间隔<br />
size_download:下载网页或文件大小<br />
size_upload:上传文件大小<br />
size_header:响应头<br />
size_request:发送请求参数大小<br />
speed_download：传输速度<br />
speed_upload:平均上传速度<br />
content_type:下载文件类型. (Added in 7.9.5)</p>
<p>9.post和get请求</p>
<p>get请求<br />
curl &#8220;param1=name&#038;params2=pass&#8221; http://www.xxx.com<br />
post请求<br />
curl -d &#8220;param1=name&#038;params2=pass&#8221; http://www.xxx.com</p>
<p>10.响应超时</p>
<p>curl -m 40 http://www.xxx.com<br />
curl &#8211;timeout 40 http://www.xxx.com</p>
<p>11.破解网站的防盗链</p>
<p>curl -e &#8220;http://www.a.net&#8221; http://www.b.net/acion</p>
<p>12.网站头部信息</p>
<p>curl -I http://www.neocanable.com</p>
<p>13.更总url跳转</p>
<p>curl -L http://url.cn/2yQFfd</p>
<p>14.正确的给url编码</p>
<p>curl &#8211;data-urlencode http://www.xxx.com/action?name=张三&#038;sex=男</p>
<p>15.限制url的传输速度</p>
<p>curl &#8211;limit-rate http://www.xxx.com/action</p>
<p>16.限制下载文件大小</p>
<p>curl &#8211;max-filesize 1024 http://www.xxx.com/action<br />
超过1M将不执行操作，并且返回出错</p>
<p>17.curl错误代码</p>
<p>1:未支持的协议。此版cURL不支持这一协议。<br />
2:初始化失败。<br />
3:URL格式错误。语法不正确。<br />
5:无法解析代理。无法解析给定代理主机。<br />
6:无法解析主机。无法解析给定的远程主机。<br />
7:无法连接到主机。<br />
8:FTP非正常的服务器应答。cURL无法解析服务器发送的数据。<br />
9:FTP访问被拒绝。服务器拒绝登入或无法获取您想要的特定资源或目录。最有可能的是您试图进入一个在此服务器上不存在的目录。<br />
11:FTP 非正常的PASS回复。cURL无法解析发送到PASS请求的应答。<br />
13:FTP 非正常的的PASV应答，cURL无法解析发送到PASV请求的应答。<br />
14:FTP非正常的227格式。cURL无法解析服务器发送的227行。<br />
15:FTP无法连接到主机。无法解析在227行中获取的主机IP。<br />
17:FTP无法设定为二进制传输。无法改变传输方式到二进制。<br />
18:部分文件。只有部分文件被传输。<br />
19:FTP不能下载/访问给定的文件， RETR (或类似)命令失败。<br />
21:FTP quote错误。quote命令从服务器返回错误。<br />
22:HTTP 找不到网页。找不到所请求的URL或返回另一个HTTP 400或以上错误。此返回代码只出现在使用了-f/&#8211;fail选项以后。<br />
23:写入错误。cURL无法向本地文件系统或类似目的写入数据。<br />
25:FTP 无法STOR文件。服务器拒绝了用于FTP上传的STOR操作。<br />
26:读错误。各类读取问题。<br />
27:内存不足。内存分配请求失败。<br />
28:操作超时。到达指定的超时期限条件。<br />
30:FTP PORT失败。PORT命令失败。并非所有的FTP服务器支持PORT命令，请尝试使用被动(PASV)传输代替！<br />
31:FTP无法使用REST命令。REST命令失败。此命令用来恢复的FTP传输。<br />
33:HTTP range错误。range &#8220;命令&#8221;不起作用。<br />
34:HTTP POST错误。内部POST请求产生错误。<br />
35:SSL连接错误。SSL握手失败。<br />
36:FTP 续传损坏。不能继续早些时候被中止的下载。<br />
37:文件无法读取。无法打开文件。权限问题？<br />
38:LDAP 无法绑定。LDAP绑定(bind)操作失败。<br />
39:LDAP 搜索失败。<br />
41:功能无法找到。无法找到必要的LDAP功能。<br />
42:由回调终止。应用程序告知cURL终止运作。<br />
43:内部错误。由一个不正确参数调用了功能。<br />
45:接口错误。指定的外发接口无法使用。<br />
47:过多的重定向。cURL达到了跟随重定向设定的最大限额跟<br />
48:指定了未知TELNET选项。<br />
49:不合式的telnet选项。<br />
51:peer的SSL证书或SSH的MD5指纹没有确定。<br />
52:服务器无任何应答，该情况在此处被认为是一个错误。<br />
53:找不到SSL加密引擎。<br />
54:无法将SSL加密引擎设置为默认。<br />
55:发送网络数据失败。<br />
56:在接收网络数据时失败。<br />
58:本地证书有问题。<br />
59:无法使用指定的SSL密码。<br />
60:peer证书无法被已知的CA证书验证。<br />
61:无法辨识的传输编码。<br />
62:无效的LDAP URL。<br />
63:超过最大文件尺寸。<br />
64:要求的FTP的SSL水平失败。<br />
65:发送此数据需要的回卷(rewind)失败。<br />
66:初始化SSL引擎失败。<br />
67:用户名、密码或类似的信息未被接受，cURL登录失败。<br />
68:在TFTP服务器上找不到文件。<br />
69:TFTP服务器权限有问题。<br />
70:TFTP服务器磁盘空间不足。<br />
71:非法的TFTP操作。<br />
72:未知TFTP传输编号(ID)。<br />
73:文件已存在(TFTP) 。<br />
74:无此用户(TFTP) 。<br />
75:字符转换失败。<br />
76:需要字符转换功能。<br />
77:读SSL证书出现问题(路径？访问权限？ ) 。<br />
78:URL中引用的资源不存在。<br />
79:SSH会话期间发生一个未知错误。<br />
80:未能关闭SSL连接。<br />
82:无法加载CRL文件，丢失或格式不正确(在7.19.0版中增加 ) 。<br />
83:签发检查失败(在7.19.0版中增加 ) 。<br />
XX</p>
<p>参考</p>
<p><a href="http://www.cs.sunysb.edu/documentation/curl/index.html">http://www.cs.sunysb.edu/documentation/curl/index.html</a><br />
<a href="http://www.cs.sunysb.edu/documentation/curl/index.html">http://linux.about.com/od/commands/l/blcmdl1_curl.htm</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.neocanable.com/curl-usage/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>libmysqlclient_r.so.16.0.0 permition deneid</title>
		<link>http://www.neocanable.com/libmysqlclientr-so-16-0-0permition-deneid/</link>
		<comments>http://www.neocanable.com/libmysqlclientr-so-16-0-0permition-deneid/#comments</comments>
		<pubDate>Fri, 21 May 2010 19:46:47 +0000</pubDate>
		<dc:creator>Neo</dc:creator>
				<category><![CDATA[MySQL]]></category>
		<category><![CDATA[系统管理]]></category>

		<guid isPermaLink="false">http://www.neocanable.com/?p=125</guid>
		<description><![CDATA[libmysqlclient_r.so.16.0.0 permition deneid SELinux is preventing sysbench from loading /usr/local/mysql/lib/libmysqlclient_r.so.16.0.0 which requires text relocation. chcon -t textrel_shlib_t &#8216;/usr/local/mysql/lib/libmysqlclient_r.so.16.0.0&#8242; 网上的大部分使用chcon -t textrel_shlib_t /usr/local/mysql/lib/libmysqlclient_r.so.16.0.0, 这个方法在fedora 10上是不管用的（其他版本没有机会测试），必须加上单引号]]></description>
			<content:encoded><![CDATA[<p>libmysqlclient_r.so.16.0.0 permition deneid</p>
<p>SELinux is preventing sysbench from loading<br />
/usr/local/mysql/lib/libmysqlclient_r.so.16.0.0 which requires text relocation.</p>
<p>chcon -t textrel_shlib_t &#8216;/usr/local/mysql/lib/libmysqlclient_r.so.16.0.0&#8242;</p>
<p>网上的大部分使用chcon -t textrel_shlib_t /usr/local/mysql/lib/libmysqlclient_r.so.16.0.0,<br />
这个方法在fedora 10上是不管用的（其他版本没有机会测试），必须加上单引号</p>
]]></content:encoded>
			<wfw:commentRss>http://www.neocanable.com/libmysqlclientr-so-16-0-0permition-deneid/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>RPM使用详解(转)</title>
		<link>http://www.neocanable.com/how-to-use-rpm/</link>
		<comments>http://www.neocanable.com/how-to-use-rpm/#comments</comments>
		<pubDate>Fri, 21 May 2010 19:45:06 +0000</pubDate>
		<dc:creator>Neo</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[系统管理]]></category>

		<guid isPermaLink="false">http://www.neocanable.com/?p=122</guid>
		<description><![CDATA[　　在Linux操作系统中，有一个系统软件包，它的功能类似于Windows里面的“添加/删除程序”，但是功能又比“添加/删除程序”强很多，它就是Red Hat Package Manager(简称RPM)。此工具包最先是由Red Hat公司推出的，后来被其他Linux开发商所借用。由于它为Linux使用者省去了很多时间，所以被广泛应用于在Linux下安装、删除软件。下面就给大家介绍一下它的具体使用方法。 　　1.我们得到一个新软件，在安装之前，一般都要先查看一下这个软件包里有什么内容，假设这个文件是：Linux-1.4-6.i368.rpm，我们可以用这条命令查看： 　　rpm -qpi Linux-1.4-6.i368.rpm 　　系统将会列出这个软件包的详细资料，包括含有多少个文件、各文件名称、文件大小、创建时间、编译日期等信息。 　　2.上面列出的所有文件在安装时不一定全部安装，就像Windows下程序的安装方式分为典型、完全、自定义一样，Linux也会让你选择安装方式，此时我们可以用下面这条命令查看软件包将会在系统里安装哪些部分，以方便我们的选择： 　　rpm -qpl Linux-1.4-6.i368.rpm 　　3.选择安装方式后，开始安装。我们可以用rpm-ivh Linux-1.4-6.i368.rpm命令安装此软件。在安装过程中，若系统提示此软件已安装过或因其他原因无法继续安装，但若我们确实想执行安装命令，可以在 -ivh后加一参数“-replacepkgs”： 　　rpm -ivh -replacepkgs Linux-1.4-6.i368.rpm 　　4.有时我们卸载某个安装过的软件，只需执行rpm-e 命令即可。 　　5.对低版本软件进行升级是提高其功能的好办法，这样可以省去我们卸载后再安装新软件的麻烦，要升级某个软件，只须执行如下命令：rpm -uvh ，注意：此时的文件名必须是要升级软件的升级补丁 　　6.另外一个安装软件的方法可谓是Linux的独到之处，同时也是RMP强大功能的一个表现：通过FTP站点直接在线安装软件。当找到含有你所需软件的站点并与此网站连接后，执行下面的命令即可实现在线安装，譬如在线安装Linux-1.4-6.i368.rpm，可以用命令： 　　rpm -i ftp://ftp.pht.com/pub/linux/redhat/***.rpm 　　7.在我们使用电脑过程中，难免会有误操作，若我们误删了几个文件而影响了系统的性能时，怎样查找到底少了哪些文件呢?RPM软件包提供了一个查找损坏文件的功能，执行此命令：rpm -Va即可，Linux将为你列出所有损坏的文件。你可以通过Linux的安装光盘进行修复。 　　8.Linux系统中文件繁多，在使用过程中，难免会碰到我们不认识的文件，在Windows下我们可以用“开始/查找”菜单快速判断某个文件属于哪个文件夹，在Linux中，下面这条命令行可以帮助我们快速判定某个文件属于哪个软件包： 　　rpm -qf 　　9.当每个软件包安装在Linux系统后，安装文件都会到RPM数据库中“报到”，所以，我们要查询某个已安装软件的属性时，只需到此数据库中查找即可。注意：此时的查询命令不同于1和8介绍的查询，这种方法只适用于已安装过的软件包！命令格式： 　　rpm -参数]]></description>
			<content:encoded><![CDATA[<p>　　在Linux操作系统中，有一个系统软件包，它的功能类似于Windows里面的“添加/删除程序”，但是功能又比“添加/删除程序”强很多，它就是Red Hat Package Manager(简称RPM)。此工具包最先是由Red Hat公司推出的，后来被其他Linux开发商所借用。由于它为Linux使用者省去了很多时间，所以被广泛应用于在Linux下安装、删除软件。下面就给大家介绍一下它的具体使用方法。</p>
<p>　　1.我们得到一个新软件，在安装之前，一般都要先查看一下这个软件包里有什么内容，假设这个文件是：Linux-1.4-6.i368.rpm，我们可以用这条命令查看：<br />
　　rpm -qpi Linux-1.4-6.i368.rpm<br />
　　系统将会列出这个软件包的详细资料，包括含有多少个文件、各文件名称、文件大小、创建时间、编译日期等信息。</p>
<p>　　2.上面列出的所有文件在安装时不一定全部安装，就像Windows下程序的安装方式分为典型、完全、自定义一样，Linux也会让你选择安装方式，此时我们可以用下面这条命令查看软件包将会在系统里安装哪些部分，以方便我们的选择：<br />
　　rpm -qpl Linux-1.4-6.i368.rpm</p>
<p>　　3.选择安装方式后，开始安装。我们可以用rpm-ivh Linux-1.4-6.i368.rpm命令安装此软件。在安装过程中，若系统提示此软件已安装过或因其他原因无法继续安装，但若我们确实想执行安装命令，可以在 -ivh后加一参数“-replacepkgs”：<br />
　　rpm -ivh -replacepkgs Linux-1.4-6.i368.rpm</p>
<p>　　4.有时我们卸载某个安装过的软件，只需执行rpm-e <文件名>命令即可。</p>
<p>　　5.对低版本软件进行升级是提高其功能的好办法，这样可以省去我们卸载后再安装新软件的麻烦，要升级某个软件，只须执行如下命令：rpm -uvh <文件名>，注意：此时的文件名必须是要升级软件的升级补丁</p>
<p>　　6.另外一个安装软件的方法可谓是Linux的独到之处，同时也是RMP强大功能的一个表现：通过FTP站点直接在线安装软件。当找到含有你所需软件的站点并与此网站连接后，执行下面的命令即可实现在线安装，譬如在线安装Linux-1.4-6.i368.rpm，可以用命令：<br />
　　rpm -i ftp://ftp.pht.com/pub/linux/redhat/***.rpm</p>
<p>　　7.在我们使用电脑过程中，难免会有误操作，若我们误删了几个文件而影响了系统的性能时，怎样查找到底少了哪些文件呢?RPM软件包提供了一个查找损坏文件的功能，执行此命令：rpm -Va即可，Linux将为你列出所有损坏的文件。你可以通过Linux的安装光盘进行修复。</p>
<p>　　8.Linux系统中文件繁多，在使用过程中，难免会碰到我们不认识的文件，在Windows下我们可以用“开始/查找”菜单快速判断某个文件属于哪个文件夹，在Linux中，下面这条命令行可以帮助我们快速判定某个文件属于哪个软件包：<br />
　　rpm -qf <文件名></p>
<p>　　9.当每个软件包安装在Linux系统后，安装文件都会到RPM数据库中“报到”，所以，我们要查询某个已安装软件的属性时，只需到此数据库中查找即可。注意：此时的查询命令不同于1和8介绍的查询，这种方法只适用于已安装过的软件包！命令格式：<br />
　　rpm -参数<文件名></p>
]]></content:encoded>
			<wfw:commentRss>http://www.neocanable.com/how-to-use-rpm/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>yum使用详解</title>
		<link>http://www.neocanable.com/yum-usage/</link>
		<comments>http://www.neocanable.com/yum-usage/#comments</comments>
		<pubDate>Wed, 12 May 2010 17:40:29 +0000</pubDate>
		<dc:creator>Neo</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[系统管理]]></category>

		<guid isPermaLink="false">http://www.neocanable.com/?p=116</guid>
		<description><![CDATA[yum是什么 * yum = Yellow dog Updater, Modified * 主要功能是更方便的添加/删除/更新RPM包. * 它能自动解决包的倚赖性问题. * 它能便于管理大量系统的更新问题 yum特点 * 可以同时配置多个资源库(Repository) * 简洁的配置文件(/etc/yum.conf * 自动解决增加或删除rpm包时遇到的倚赖性问题 * 使用方便 * 保持与RPM数据库的一致性 yum安装 * CentOS自带(yum-*.noarch.rpm) $rpm -ivh yum-*.noarch.rpm * 在第一次启用yum之前首先需要导入系统的RPM-GPG-KEY： $rpm &#8211;import /usr/share/doc/centos-release-3(4)/RPM-GPG-KEY-CentOS-3(4) yum指令 * 注:当第一次使用yum或yum资源库有更新时,yum会自动下载所有所需的headers放置于/var/cache/yum目录下,所需时间可能较长. rpm包的更新 * 检查可更新的rpm包 $yum check-update * 更新所有的rpm包 $yum update * 更新指定的rpm包,如更新kernel和kernel source $yum update kernel kernel-source [...]]]></description>
			<content:encoded><![CDATA[<p>yum是什么</p>
<p>    * yum = Yellow dog Updater, Modified<br />
    * 主要功能是更方便的添加/删除/更新RPM包.<br />
    * 它能自动解决包的倚赖性问题.<br />
    * 它能便于管理大量系统的更新问题</p>
<p>yum特点</p>
<p>    * 可以同时配置多个资源库(Repository)<br />
    * 简洁的配置文件(/etc/yum.conf<br />
    * 自动解决增加或删除rpm包时遇到的倚赖性问题<br />
    * 使用方便<br />
    * 保持与RPM数据库的一致性</p>
<p>yum安装</p>
<p>    * CentOS自带(yum-*.noarch.rpm)</p>
<p>$rpm -ivh yum-*.noarch.rpm</p>
<p>    * 在第一次启用yum之前首先需要导入系统的RPM-GPG-KEY：</p>
<p>$rpm &#8211;import /usr/share/doc/centos-release-3(4)/RPM-GPG-KEY-CentOS-3(4)</p>
<p>yum指令</p>
<p>    * 注:当第一次使用yum或yum资源库有更新时,yum会自动下载所有所需的headers放置于/var/cache/yum目录下,所需时间可能较长.</p>
<p>rpm包的更新</p>
<p>    * 检查可更新的rpm包</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">$yum check-update</div></div>
<p>* 更新所有的rpm包</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">$yum update</div></div>
<p>* 更新指定的rpm包,如更新kernel和kernel source</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">$yum update kernel kernel-source</div></div>
<p>* 大规模的版本升级,与yum update不同的是,连旧的淘汰的包也升级</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">$yum upgrade</div></div>
<p>rpm包的安装和删除</p>
<p>    * 安装rpm包,如xmms-mp3</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">$yum install xmms-mp3</div></div>
<p>* 删除rpm包,包括与该包有倚赖性的包</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">$yum remove licq</div></div>
<p>* 注:同时会提示删除licq-gnome,licq-qt,licq-text</p>
<p>yum暂存(/var/cache/yum/)的相关参数</p>
<p>    * 清除暂存中rpm包文件</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">$yum clean packages</div></div>
<p>* 清除暂存中rpm头文件</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">$yum clearn headers</div></div>
<p>* 清除暂存中旧的rpm头文件</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">$yum clean oldheaders</div></div>
<p>* 清除暂存中旧的rpm头文件和包文件</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">$yum clearn 或$yum clearn all</div></div>
<p>* 注:相当于yum clean packages + yum clean oldheaders</p>
<p>包列表</p>
<p>    * 列出资源库中所有可以安装或更新的rpm包</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">$yum list</div></div>
<p>* 列出资源库中特定的可以安装或更新以及已经安装的rpm包</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">$yum list mozilla<br />
$yum list mozilla*</div></div>
<p>* 注:可以在rpm包名中使用匹配符,如列出所有以mozilla开头的rpm包</p>
<p>    * 列出资源库中所有可以更新的rpm包</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">$yum list updates</div></div>
<p>* 列出已经安装的所有的rpm包</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">$yum list installed</div></div>
<p>* 列出已经安装的但是不包含在资源库中的rpm包</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">$yum list extras</div></div>
<p>* 注:通过其它网站下载安装的rpm包</p>
<p>rpm包信息显示(info参数同list)</p>
<p>    * 列出资源库中所有可以安装或更新的rpm包的信息</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">$yum info</div></div>
<p>* 列出资源库中特定的可以安装或更新以及已经安装的rpm包的信息</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">$yum info mozilla<br />
$yum info mozilla*</div></div>
<p>* 注:可以在rpm包名中使用匹配符,如列出所有以mozilla开头的rpm包的信息</p>
<p>    * 列出资源库中所有可以更新的rpm包的信息</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">$yum info updates</div></div>
<p>* 列出已经安装的所有的rpm包的信息</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">$yum info installed</div></div>
<p>* 列出已经安装的但是不包含在资源库中的rpm包的信息</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">$yum info extras</div></div>
<p>* 注:通过其它网站下载安装的rpm包的信息</p>
<p>搜索rpm包</p>
<p>    * 搜索匹配特定字符的rpm包</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">$yum search mozilla</div></div>
<p>* 注:在rpm包名,包描述等中搜索</p>
<p>    * 搜索有包含特定文件名的rpm包</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">$yum provides realplay</div></div>
<p>增加资源库</p>
<p>    * 例如:增加rpm.livna.org作为资源库</p>
<p>    * 安装Livna.org rpms GPG key</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">$rpm --import http://rpm.livna.org/RPM-LIVNA-GPG-KEY</div></div>
<p>* 检查GPG Key</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">$ rpm -qa gpg-pubkey*</div></div>
<p>* 显示Key信息</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">$rpm -qi gpg-pubkey-a109b1ec-3f6e28d5</div></div>
<p>* (注:如果要删除Key,使用$rpm -e gpg-pubkey-a109b1ec-3f6e28d5)</p>
]]></content:encoded>
			<wfw:commentRss>http://www.neocanable.com/yum-usage/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

