<?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>FireFore &#187; 学习笔记</title>
	<atom:link href="http://firefore.com/category/mystudy/feed" rel="self" type="application/rss+xml" />
	<link>http://firefore.com</link>
	<description>不积硅步无以至千里</description>
	<lastBuildDate>Mon, 14 May 2012 04:44:26 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Shaking form</title>
		<link>http://firefore.com/2010/11/shaking-form.html</link>
		<comments>http://firefore.com/2010/11/shaking-form.html#comments</comments>
		<pubDate>Sun, 21 Nov 2010 15:07:37 +0000</pubDate>
		<dc:creator>FireFore</dc:creator>
				<category><![CDATA[学习笔记]]></category>
		<category><![CDATA[JavaScript]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://firefore.com/?p=1306</guid>
		<description><![CDATA[前几天登入Wordpress后台，输错了账号密码，发现其整个表单会左右晃动，好比是人在摇头，感觉特别有意思。于是看了一下该页的源代码，剥离出其摇动的代码来，全浏览器兼容呢，贴在这里... ]]></description>
			<content:encoded><![CDATA[<p>前几天登入Wordpress后台，输错了账号密码，发现其整个表单会左右晃动，好比是人在摇头，感觉特别有意思。于是看了一下该页的源代码，剥离出其摇动的代码来，全浏览器兼容呢，贴在这里分享了。</p>
<p><span id="more-1306"></span>
<p>本人不懂编程也不懂代码，所以只能做原始的剥离了。哈哈哈。</p>
<p><a  href="http://firefore.com/doc/shake.html" target="_blank">例子可以点这里看DIV晃动演示页</a></p>
<p>首先，在页面的&lt;head&gt;&lt;/head&gt;中插入下面的JS代码：</p>

<div class="wp_syntax"><div class="code"><pre class="javascript" style="font-family:monospace;"><span style="color: #339933;">&lt;</span>script type<span style="color: #339933;">=</span><span style="color: #3366CC;">&quot;text/javascript&quot;</span><span style="color: #339933;">&gt;</span>
addLoadEvent <span style="color: #339933;">=</span> <span style="color: #003366; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span>func<span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span><span style="color: #000066; font-weight: bold;">if</span><span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">typeof</span> jQuery<span style="color: #339933;">!=</span><span style="color: #3366CC;">&quot;undefined&quot;</span><span style="color: #009900;">&#41;</span>jQuery<span style="color: #009900;">&#40;</span>document<span style="color: #009900;">&#41;</span>.<span style="color: #660066;">ready</span><span style="color: #009900;">&#40;</span>func<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>else <span style="color: #000066; font-weight: bold;">if</span><span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">typeof</span> wpOnload<span style="color: #339933;">!=</span><span style="color: #3366CC;">'function'</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span>wpOnload<span style="color: #339933;">=</span>func<span style="color: #339933;">;</span><span style="color: #009900;">&#125;</span><span style="color: #000066; font-weight: bold;">else</span><span style="color: #009900;">&#123;</span><span style="color: #003366; font-weight: bold;">var</span> oldonload<span style="color: #339933;">=</span>wpOnload<span style="color: #339933;">;</span>wpOnload<span style="color: #339933;">=</span><span style="color: #003366; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span>oldonload<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>func<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><span style="color: #009900;">&#125;</span><span style="color: #009900;">&#125;</span><span style="color: #009900;">&#125;</span><span style="color: #339933;">;</span>
<span style="color: #003366; font-weight: bold;">function</span> s<span style="color: #009900;">&#40;</span>id<span style="color: #339933;">,</span>pos<span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span>g<span style="color: #009900;">&#40;</span>id<span style="color: #009900;">&#41;</span>.<span style="color: #660066;">left</span><span style="color: #339933;">=</span>pos<span style="color: #339933;">+</span><span style="color: #3366CC;">'px'</span><span style="color: #339933;">;</span><span style="color: #009900;">&#125;</span>
<span style="color: #003366; font-weight: bold;">function</span> g<span style="color: #009900;">&#40;</span>id<span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span><span style="color: #000066; font-weight: bold;">return</span> document.<span style="color: #660066;">getElementById</span><span style="color: #009900;">&#40;</span>id<span style="color: #009900;">&#41;</span>.<span style="color: #660066;">style</span><span style="color: #339933;">;</span><span style="color: #009900;">&#125;</span>
<span style="color: #003366; font-weight: bold;">function</span> shake<span style="color: #009900;">&#40;</span>id<span style="color: #339933;">,</span>a<span style="color: #339933;">,</span>d<span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span>c<span style="color: #339933;">=</span>a.<span style="color: #660066;">shift</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>s<span style="color: #009900;">&#40;</span>id<span style="color: #339933;">,</span>c<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>if<span style="color: #009900;">&#40;</span>a.<span style="color: #660066;">length</span><span style="color: #339933;">&gt;</span><span style="color: #CC0000;">0</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span>setTimeout<span style="color: #009900;">&#40;</span><span style="color: #003366; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span>shake<span style="color: #009900;">&#40;</span>id<span style="color: #339933;">,</span>a<span style="color: #339933;">,</span>d<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><span style="color: #009900;">&#125;</span><span style="color: #339933;">,</span>d<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><span style="color: #009900;">&#125;</span><span style="color: #000066; font-weight: bold;">else</span><span style="color: #009900;">&#123;</span><span style="color: #000066; font-weight: bold;">try</span><span style="color: #009900;">&#123;</span>g<span style="color: #009900;">&#40;</span>id<span style="color: #009900;">&#41;</span>.<span style="color: #660066;">position</span><span style="color: #339933;">=</span><span style="color: #3366CC;">'static'</span><span style="color: #339933;">;</span>wp_attempt_focus<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><span style="color: #009900;">&#125;</span><span style="color: #000066; font-weight: bold;">catch</span><span style="color: #009900;">&#40;</span>e<span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span><span style="color: #009900;">&#125;</span><span style="color: #009900;">&#125;</span><span style="color: #009900;">&#125;</span>
addLoadEvent<span style="color: #009900;">&#40;</span><span style="color: #003366; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span> <span style="color: #003366; font-weight: bold;">var</span> p<span style="color: #339933;">=</span><span style="color: #003366; font-weight: bold;">new</span> Array<span style="color: #009900;">&#40;</span><span style="color: #CC0000;">15</span><span style="color: #339933;">,</span><span style="color: #CC0000;">30</span><span style="color: #339933;">,</span><span style="color: #CC0000;">15</span><span style="color: #339933;">,</span><span style="color: #CC0000;">0</span><span style="color: #339933;">,-</span><span style="color: #CC0000;">15</span><span style="color: #339933;">,-</span><span style="color: #CC0000;">30</span><span style="color: #339933;">,-</span><span style="color: #CC0000;">15</span><span style="color: #339933;">,</span><span style="color: #CC0000;">0</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>p<span style="color: #339933;">=</span>p.<span style="color: #660066;">concat</span><span style="color: #009900;">&#40;</span>p.<span style="color: #660066;">concat</span><span style="color: #009900;">&#40;</span>p<span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>var i<span style="color: #339933;">=</span>document.<span style="color: #660066;">forms</span><span style="color: #009900;">&#91;</span><span style="color: #CC0000;">0</span><span style="color: #009900;">&#93;</span>.<span style="color: #660066;">id</span><span style="color: #339933;">;</span>g<span style="color: #009900;">&#40;</span>i<span style="color: #009900;">&#41;</span>.<span style="color: #660066;">position</span><span style="color: #339933;">=</span><span style="color: #3366CC;">'relative'</span><span style="color: #339933;">;</span>shake<span style="color: #009900;">&#40;</span>i<span style="color: #339933;">,</span>p<span style="color: #339933;">,</span><span style="color: #CC0000;">20</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #339933;">&lt;/</span>script<span style="color: #339933;">&gt;</span></pre></div></div>

<p>其次，在页面底部的&lt;/body&gt;之前插入第二段JS代码：</p>

<div class="wp_syntax"><div class="code"><pre class="javascript" style="font-family:monospace;"><span style="color: #339933;">&lt;</span>script type<span style="color: #339933;">=</span><span style="color: #3366CC;">&quot;text/javascript&quot;</span><span style="color: #339933;">&gt;</span>
<span style="color: #003366; font-weight: bold;">function</span> wp_attempt_focus<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span>
setTimeout<span style="color: #009900;">&#40;</span> <span style="color: #003366; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span> <span style="color: #000066; font-weight: bold;">try</span><span style="color: #009900;">&#123;</span>
d <span style="color: #339933;">=</span> document.<span style="color: #660066;">getElementById</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'loginform'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
d.<span style="color: #660066;">value</span> <span style="color: #339933;">=</span> <span style="color: #3366CC;">''</span><span style="color: #339933;">;</span>
d.<span style="color: #000066;">focus</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span> <span style="color: #000066; font-weight: bold;">catch</span><span style="color: #009900;">&#40;</span>e<span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span><span style="color: #009900;">&#125;</span>
<span style="color: #009900;">&#125;</span><span style="color: #339933;">,</span> <span style="color: #CC0000;">200</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span>
<span style="color: #000066; font-weight: bold;">if</span><span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">typeof</span> wpOnload<span style="color: #339933;">==</span><span style="color: #3366CC;">'function'</span><span style="color: #009900;">&#41;</span>wpOnload<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #339933;">&lt;/</span>script<span style="color: #339933;">&gt;</span></pre></div></div>

<p>请注意要晃动的那个form中一定要加上ID哦。</p>
<p><a  href="http://firefore.com/doc/shake.html.txt" target="_blank">点这里可以看到例子页面的源代码</a></p>
<p>然后现在页面一旦载入，form的内容就会左右摇晃。哈哈。</p>
<p>如果想实现Wordpress那种输入错误才会摇晃的表现方式，则可以查看Wordpress目录下wp-login.php文件，其用<span class='wp_keywordlink_affiliate'><a href="http://firefore.com/bq/php" title="查看 PHP 中的全部文章" target="_blank">PHP</a></span>代码做了个判断。</p>
<hr /><small><p>&#26412;&#20316;&#21697;&#30001;<a  0="xmlns:cc="http://creativecommons.org/ns#"" href="http://firefore.com" property="cc:attributionName" rel="cc:attributionURL">shiweiyu</a>&#21019;&#20316;&#65292;&#37319;&#29992;<a  rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/">&#30693;&#35782;&#20849;&#20139;&#32626;&#21517;-&#30456;&#21516;&#26041;&#24335;&#20849;&#20139; 3.0 Unported&#35768;&#21487;&#21327;&#35758;</a>&#36827;&#34892;&#35768;&#21487;&#12290;<br />
Copyright &copy; 2010 <a  href="http://firefore.com">FireFore.com</a> (数字指纹： woaiwojia_weiyu (38.107.179.213) )</small></p>]]></content:encoded>
			<wfw:commentRss>http://firefore.com/2010/11/shaking-form.html/feed</wfw:commentRss>
		<slash:comments>16</slash:comments>
		</item>
		<item>
		<title>两晋南北朝历史年表简版</title>
		<link>http://firefore.com/2010/10/20101010.html</link>
		<comments>http://firefore.com/2010/10/20101010.html#comments</comments>
		<pubDate>Sat, 09 Oct 2010 16:09:50 +0000</pubDate>
		<dc:creator>FireFore</dc:creator>
				<category><![CDATA[学习笔记]]></category>

		<guid isPermaLink="false">http://firefore.com/2010/10/20101010.html</guid>
		<description><![CDATA[国庆期间，抽空读了本两晋南北朝历史的书籍。 好久没这么认真和兴趣的阅读一本书了。前面的整整一年都在看IT类的书。这篇文章仅作为阅读笔记吧。尽管历史年表网络上到处都有，我还是... ]]></description>
			<content:encoded><![CDATA[<p>国庆期间，抽空读了本两晋南北朝历史的书籍。</p>
<p>好久没这么认真和兴趣的阅读一本书了。前面的整整一年都在看IT类的书。这篇文章仅作为阅读笔记吧。尽管历史年表网络上到处都有，我还是自己收藏了一份于此。</p>
<p> <span id="more-1283"></span>
</p>
<blockquote><p>265年      <br />八月，司马昭死，子司马炎继相国、晋王位。       <br />十二月，废魏主，称帝，为晋武帝司马炎，国号晋，都洛阳。大封宗室诸王。 </p>
<p>266年      <br />西晋罢农官，所统悉属郡县。至此，曹魏屯田前后七十年。 </p>
<p>268年      <br />扶南、林邑遣使至西晋。 </p>
<p>275年      <br />中原大疫，洛阳死者以万数 </p>
<p>279年      <br />晋以贾充为大都督，大举分道伐吴。 </p>
<p>280年      <br />晋灭吴，统一全国。 </p>
<p>290年      <br />晋惠帝立，立贾充之女贾南风为皇后（贾后），武帝杨皇后父杨骏辅政。以刘渊为匈奴五部大都督。 </p>
<p>291年      <br />贾后杀杨骏，又杀汝南王亮及楚王玮；八王之乱开始。 </p>
<p>296年      <br />氐人齐万年起兵于关中。 </p>
<p>298年      <br />关中连年饥荒，巴賨豪酋李特率流民入蜀。 </p>
<p>299年      <br />江统着《徙戎论》，提出将氐、羌等族徙离关中。 </p>
<p>300年      <br />赵王伦杀贾后。 </p>
<p>301年      <br />张轨据河西，求为凉州刺史。       <br />赵王伦废惠帝自立，齐王冏等起兵杀伦，惠帝复位，冏专政。       <br />秦雍六郡流民起义爆发。流民推李特为首，起兵于绵竹，进攻成都。 </p>
<p>303年      <br />李特入成都，旋为益州刺史罗尚所杀。特侄李雄再攻下成都。       <br />张昌、石冰起义爆发。五月，张昌起义于安陆石岩山，后据江夏，攻襄阳，别帅石冰东进。 </p>
<p>304年      <br />李雄称成都王，建成汉。       <br />匈奴刘渊即汉王位，建国号曰汉。十六国开始。       <br />河间王颙将领张方逼惠帝西迁长安。 </p>
<p>305年      <br />张敏于历阳起兵称楚公，为陶侃所败。 </p>
<p>306年      <br />东海王越将领祁弘挟惠帝还洛阳。惠帝中毒死，弟炽继位，是为晋怀帝司马炽。八王之乱结束。 </p>
<p>310年      <br />刘渊死，太子刘和继位。刘聪杀刘和自立。 </p>
<p>311年      <br />汉刘曜攻下洛阳，杀吏民三万余人，史称“永嘉之乱”。刘曜挟怀帝至匈奴汉国的都城平阳。 </p>
<p>313年      <br />刘聪杀怀帝，秦王司马邺在长安即位，是为晋愍帝司马邺。 </p>
<p>315年      <br />晋封拓跋猗卢为代王 </p>
<p>316年      <br />刘曜贡献长安城，愍帝降，被送至平阳，同年12月被刘聪杀，西晋亡。 </p>
<p>317年      <br />琅邪王司马睿即晋王位，史称东晋。       <br />祖逖北伐 </p>
<p>318年      <br />晋王睿称帝，是为晋元帝司马睿       <br />刘聪病死，太子粲继位，旋为靳准所杀，汉亡。刘曜发兵攻准，自立为皇帝。 </p>
<p>319年      <br />刘曜徙都长安，改国号赵，史称前赵。       <br />石勒自称赵王，定都襄国，史称后赵。 </p>
<p>322年      <br />王敦起兵武昌，攻入建康，还屯武昌，遥制朝政。元帝懮愤死，明帝即位，王导辅政。 </p>
<p>324年      <br />明帝下令讨伐王敦，敦以兄含为元帅攻建康，敦病死，兵众溃散。 </p>
<p>327年      <br />苏峻、祖约之乱爆发 </p>
<p>329年      <br />后赵出兵攻占上邽，杀太子熙，前赵亡。 </p>
<p>330年      <br />东晋始行度田收租制，亩税三升       <br />后赵石勒称帝 </p>
<p>335年      <br />后赵迁都于邺 </p>
<p>337年      <br />鲜卑慕容皝称燕王，建燕国，史称前燕。 </p>
<p>338年      <br />鲜卑拓跋什翼犍继代王位，建代，定法律。       <br />大成国李寿自立，改国号为汉。史称成汉。 </p>
<p>341年      <br />晋诏王公以下至庶人皆正土断、白籍。 </p>
<p>347年      <br />桓温灭成汉。 </p>
<p>349年      <br />后赵石虎称帝。       <br />谪戍凉州的东宫卫士十余万人在高力督梁犊领导下于雍城起义。 </p>
<p>350年      <br />冉闵灭后赵，自立为帝，国号大魏，史称冉魏。下达“杀胡令”。 </p>
<p>351年      <br />苻健在长安称天王、大单于，国号大秦，史称前秦。 </p>
<p>352年      <br />前燕慕容 灭冉魏，遂在蓟称帝。 </p>
<p>354年      <br />桓温北伐前秦，军至灞上，逼近长安，因缺粮退兵。 </p>
<p>356年      <br />桓温第二次北伐，入洛阳，留兵戍守而还。 </p>
<p>357年      <br />前秦苻坚即位，称大秦天王，汉人王猛辅政。       <br />前燕迁都于邺。 </p>
<p>361年      <br />桓温派兵破燕军，取许昌。 </p>
<p>362年      <br />晋减田租，亩收二升 </p>
<p>369年      <br />桓温率军五万北伐前燕，至枋头粮尽撤退大败。 </p>
<p>370年      <br />前秦灭前燕。 </p>
<p>376年      <br />前秦灭前凉、灭代       <br />晋废度田收租之制，王公以下口税米三斛，在役者免。 </p>
<p>377年      <br />晋建北府兵。 </p>
<p>383年      <br />晋秦肥水之战，前秦大败，内部分崩。       <br />晋增收口税米，每口五石。 </p>
<p>384年      <br />鲜卑慕容垂在荥阳称燕王，后燕始此。       <br />慕容泓称济北王，西燕始此。       <br />羌族姚苌在渭北起兵，称万年秦王，史称后秦。 </p>
<p>385年      <br />西燕慕容冲称帝，入长安。       <br />乞伏国仁自称大单于，筑勇士城为都，史称西秦。       <br />后燕慕容垂定都中山。 </p>
<p>386年      <br />鲜卑拓跋珪称代王，都盛乐，改称魏，北魏始此。       <br />后秦姚苌入长安，称帝。       <br />吕光称凉州牧、酒泉公，都姑臧，后凉始此。 </p>
<p>394年      <br />后燕慕容垂攻破长子，杀慕容永，西燕亡。       <br />前秦苻登为后秦姚兴所杀，前秦亡。 </p>
<p>395年      <br />北魏在参合陂大败后燕。 </p>
<p>397年      <br />鲜卑秃发乌孤称西平王，筑廉川堡为都，南凉始此。 </p>
<p>398年      <br />慕容德自立为燕王，史称南燕。 </p>
<p>398年      <br />拓跋珪迁都平城，称帝，是为魏道武帝拓跋珪。 </p>
<p>399年      <br />晋征发浙东诸郡免奴为客者为兵，引起反对，孙恩起义爆发。       <br />名僧法显从长安出发，西行往天竺求经。 </p>
<p>400年      <br />李暠自称凉公，都敦煌，西凉始此。 </p>
<p>401年      <br />沮渠蒙逊杀段业，自称凉州牧，史称北凉。       <br />后秦姚兴迎鸠摩罗什至长安。 </p>
<p>402年      <br />孙恩攻临海，败死。妹夫卢循继统其众。 </p>
<p>403年      <br />桓玄废晋安帝，自称帝，国号楚。       <br />后凉降于后秦。 </p>
<p>404年      <br />刘裕自京口起兵讨桓玄，桓玄挟安帝还江陵，后败死。 </p>
<p>405年      <br />刘毅破江陵，迎安帝还建康。 </p>
<p>407年      <br />赫连勃勃称大夏天王，夏始此。 </p>
<p>409年      <br />后燕亡。冯跋建立北燕。       <br />刘裕北伐南燕，围广固。 </p>
<p>410年      <br />刘裕破广固，南燕亡。       <br />卢循、徐道覆北进，攻长沙、豫章等郡，进逼建康，为刘裕所败。 </p>
<p>411年-      <br />卢循败死，至此，孙恩、卢循起义遂告结束。 </p>
<p>412年      <br />法显航海回国，次年至建康，着有《佛国记》。 </p>
<p>413年      <br />刘裕主持&quot;义熙土断&quot; </p>
<p>414年      <br />西秦袭取乐都，秃发 檀降，南凉亡。 </p>
<p>417年      <br />刘裕北伐入长安，后秦亡。 </p>
<p>418年      <br />赫连勃勃陷长安，称帝。 </p>
<p>420年      <br />刘裕废晋恭帝自立，是为宋武帝刘裕，国号宋，史称刘宋，南朝始此。 </p>
<p>421年      <br />宋武帝死，太子义符立，是为宋少帝刘义符。       <br />北凉沮渠蒙逊攻破敦煌，西凉亡。 </p>
<p>423年      <br />北魏太武帝信用道士寇谦之，于平城起天师道场，道教大盛。       <br />魏筑长城，东西二千余里，以防柔然。 </p>
<p>424年      <br />宋少帝被废杀，宜都王刘义隆立，是为宋文帝刘义隆。 </p>
<p>431年      <br />夏灭西秦，北魏攻夏，夏主赫连定西迁，为吐谷浑所俘送魏，夏亡。 </p>
<p>436年      <br />北魏灭北燕 </p>
<p>439年      <br />魏太武帝拓跋焘灭北凉，北魏统一北方，十六国结束，北朝始此。 </p>
<p>444年      <br />太武帝禁私养沙门、巫觋，不得私立学校。 </p>
<p>445年      <br />盖吴起义。 </p>
<p>446年      <br />·太武帝纳崔浩言，禁佛教，毁经像、塔寺，坑杀僧人。 </p>
<p>449年      <br />太武帝大破柔然，收人户畜产百余万，柔然从此衰落。 </p>
<p>450年      <br />太武帝以修史&quot;暴扬国恶&quot;的罪名，杀司徒崔浩。       <br />太武帝率大军南进瓜步，扬言渡江，建康大震。 </p>
<p>453年      <br />太子劭杀宋文帝自立。刘骏立为孝武帝，杀劭。 </p>
<p>457年      <br />宋实行土断，流寓之人编入当地户籍。 </p>
<p>460年      <br />柔然攻高昌，以阚伯周为高昌王，高昌称王始此。       <br />云冈石窟约从本年起开凿，至太和十八年完成。 </p>
<p>462年      <br />祖冲之奏上《大明历》 </p>
<p>465年      <br />魏献文帝即位，十二岁，丞相乙浑专权。 </p>
<p>466年      <br />冯太后临朝称制，立郡学，置博士、助教、生员。 </p>
<p>471年      <br />太子拓跋宏即位，是为孝文帝。 </p>
<p>476年      <br />魏冯太后称太皇太后，再次临朝称制。 </p>
<p>479年      <br />萧道成迫宋顺帝禅位，宋亡。道成称帝，是为齐高帝萧道成，国号齐。 </p>
<p>482年      <br />齐高帝死，太子赜即位，是为齐武帝萧赜。 </p>
<p>484年      <br />魏始&quot;班禄&quot;，每户增调帛三匹、谷二斛九斗，以供百官之禄；另增调外帛二匹。给禄之后，赃满一匹者死。 </p>
<p>485年      <br />唐寓之暴动。 </p>
<p>485年      <br />北魏颁行均田制。 </p>
<p>486年      <br />唐寓之攻占钱塘，称帝，国号吴。       <br />改宗主督护为三长制。 </p>
<p>494年      <br />孝文帝发平城，迁都洛阳。诏禁士民胡服。       <br />洛阳龙门石窟约从本年起开凿。 </p>
<p>495年      <br />魏禁在朝廷讲鲜卑语；禁迁洛代人还葬北方。在洛阳立国子、太学、四门、小学。 </p>
<p>496年      <br />魏定族姓，改拓跋氏为元氏，其余鲜卑诸姓均改为汉姓。鲜卑八姓与汉四大姓同等。 </p>
<p>497年      <br />高昌王马儒为部下所杀，立麹嘉为王。高昌麹氏政权始此。 </p>
<p>500年      <br />雍州刺史萧衍在襄阳起兵。       <br />祖冲之死，生前首次把圆周率准确数值推算到小数点后七位数。 </p>
<p>501年      <br />齐南康王宝融在江陵即位，是为和帝。       <br />萧衍入建康。 </p>
<p>502年      <br />萧衍为梁公、梁王，杀齐明帝诸子，称帝，是为梁武帝萧衍，国号梁，齐亡。 </p>
<p>506年      <br />梁魏大战。 </p>
<p>507年      <br />范缜发表《神灭论》 </p>
<p>515年      <br />孝明帝立，胡太后临朝称制。 </p>
<p>516年      <br />梁筑浮山堰城，引淮水灌寿阳。秋，堰坏，沿淮城戍村落十余万口漂流入海。 </p>
<p>523年      <br />怀荒镇民起义。破六韩拔陵率沃野镇兵民起义，杀镇将，六镇起义始此。 </p>
<p>528年      <br />尔朱氏之乱。 </p>
<p>531年      <br />高欢起兵讨尔朱氏，立元郎为帝，是为后废帝。 </p>
<p>532年      <br />高欢废节闵帝及后废帝，立元修为帝，是为孝武帝，自为大丞相。 </p>
<p>534年      <br />高欢举兵向洛阳，孝武帝奔关中，依宇文泰。高欢入洛阳，立元善见为帝，是为东魏孝静帝，魏从此分东西。东魏迁都于邺       <br />闰十二月，宇文泰毒杀孝武帝，立元宝炬为帝，是为西魏文帝，都长安。 </p>
<p>535年      <br />西魏丞相宇文泰定新制二十四条。苏绰制定公文格式及计帐、户籍之法。 </p>
<p>541年      <br />宇文泰颁布六条诏书。 </p>
<p>547年      <br />东魏高欢死，子澄嗣。孝静帝被澄幽禁 。       <br />阳衒之撰《洛阳伽蓝记》 </p>
<p>548年      <br />侯景之乱。侯景于寿阳起兵反梁，渡江直入建康，围台城。 </p>
<p>549年      <br />侯景陷台城，梁武帝萧衍死，侯景立萧纲为帝，是为简文帝。 </p>
<p>550年      <br />高洋废东魏孝静帝，自立，是为齐文宣帝高洋，国号齐，都邺，史称北齐。       <br />北齐始立九等之户。       <br />西魏宇文泰创立府兵制。 </p>
<p>551年      <br />侯景废简文帝，立萧栋，又废栋自立，国号汉。 </p>
<p>552年      <br />王僧辩、陈霸先克建康，侯景东逃。       <br />萧绎在江陵即位，是为梁元帝。 </p>
<p>553年      <br />西魏攻占益州。 </p>
<p>554年      <br />西魏陷江陵。 </p>
<p>555年      <br />萧詧在江陵称帝，称藩西魏，史称后梁。 </p>
<p>556年      <br />西魏仿《周礼》建六官。宇文泰死，世子觉嗣，侄护统理军国事，岁末宇文护迫魏恭帝禅位，西魏亡。 </p>
<p>557年      <br />宇文觉称天王，是为孝闵帝，北周建国。宇文护废觉，立宇文毓为天王，是为明帝。       <br />陈霸先代梁称帝，是为陈高祖陈霸先，国号陈。 </p>
<p>560年      <br />宇文护废明帝，立宇文邕为帝，是为周武帝宇文邕。 </p>
<p>561年      <br />北周上番服役由八番改为十二番。 </p>
<p>564年      <br />北齐颁新律令。又重新颁布均田令。 </p>
<p>574年      <br />周武帝禁佛、道两教，毁经、像，命沙门、道士还俗。 </p>
<p>575年      <br />周大举攻齐，连战皆捷，旋退。 </p>
<p>577年      <br />周武帝率兵入邺，北齐亡。 </p>
<p>579年      <br />周宣帝传位于太子阐，是为静帝。 </p>
<p>580年      <br />杨坚总国政，先后平定起兵反抗他的相州总管尉迟迥、郧州总管司马消难、益州总管王谦难。</p>
</blockquote>
<p>从网络上收集的，感谢前人整理。我只是在几个地方自己做了修改而已。仅此作为收藏。</p>
<hr /><small><p>&#26412;&#20316;&#21697;&#30001;<a  0="xmlns:cc="http://creativecommons.org/ns#"" href="http://firefore.com" property="cc:attributionName" rel="cc:attributionURL">shiweiyu</a>&#21019;&#20316;&#65292;&#37319;&#29992;<a  rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/">&#30693;&#35782;&#20849;&#20139;&#32626;&#21517;-&#30456;&#21516;&#26041;&#24335;&#20849;&#20139; 3.0 Unported&#35768;&#21487;&#21327;&#35758;</a>&#36827;&#34892;&#35768;&#21487;&#12290;<br />
Copyright &copy; 2010 <a  href="http://firefore.com">FireFore.com</a> (数字指纹： woaiwojia_weiyu (38.107.179.213) )</small></p>]]></content:encoded>
			<wfw:commentRss>http://firefore.com/2010/10/20101010.html/feed</wfw:commentRss>
		<slash:comments>13</slash:comments>
		</item>
		<item>
		<title>VMware Workstation实例二：单IP的虚拟机提供外网访问</title>
		<link>http://firefore.com/2010/06/vmware-2.html</link>
		<comments>http://firefore.com/2010/06/vmware-2.html#comments</comments>
		<pubDate>Sat, 12 Jun 2010 13:54:44 +0000</pubDate>
		<dc:creator>FireFore</dc:creator>
				<category><![CDATA[学习笔记]]></category>
		<category><![CDATA[Bridge]]></category>
		<category><![CDATA[NAT]]></category>
		<category><![CDATA[virtual network]]></category>
		<category><![CDATA[VMware]]></category>

		<guid isPermaLink="false">http://firefore.com/2010/06/vmware-2.html</guid>
		<description><![CDATA[2008年，我写了一篇如何设置VMware Workstation虚拟机的双网卡来实现让外网访问虚拟机，此后有不少朋友给我发邮件或是留言，询问单网卡局域网下或是单公网IP下如何实现类似功能。在我一一进... ]]></description>
			<content:encoded><![CDATA[<p name="1">2008年，我写了一篇如何<a  href="http://firefore.com/2008/04/vmware-1.html" target="_blank">设置VMware Workstation虚拟机的双网卡来实现让外网访问虚拟机</a>，此后有不少朋友给我发邮件或是留言，询问单网卡局域网下或是单公网IP下如何实现类似功能。在我一一进行答复后，心里头就想写一篇来解答朋友们的疑问。时隔两年多后，咱们来分享<span class='wp_keywordlink_affiliate'><a href="http://firefore.com/bq/vmware" title="查看 VMware 中的全部文章" target="_blank">VMware</a></span> Workstation虚拟机单网卡单公网IP下实现让外网访问虚拟机的方法。</p>
<p> <span id="more-1080"></span>
<ul>
<li><a  href="http://firefore.com/2010/06/vmware-2.html#2">网络拓扑</a> </li>
<li><a  href="http://firefore.com/2010/06/vmware-2.html#3">理清思路</a> </li>
<li><a  href="http://firefore.com/2010/06/vmware-2.html#4">单网卡机器VMware Workstation的NAT设置</a> </li>
<li><a  href="http://firefore.com/2010/06/vmware-2.html#5">Port Forwarding</a> </li>
<li><a  href="http://firefore.com/2010/06/vmware-2.html#6">路由器或是防火墙上设置端口映射</a> </li>
<li><a  href="http://firefore.com/2010/06/vmware-2.html#7">网络测试</a> </li>
</ul>
<h3><a name="2">网络拓扑</a></h3>
<p>首先呢，一般情况下，除了机房托管的机器外，单位或是个人家庭等的网络服务器一般会比较少直接分配公网IP，三种网络模式简图如下：</p>
<p><img style="border-right-width: 0px; display: block; float: none; border-top-width: 0px; border-bottom-width: 0px; margin-left: auto; border-left-width: 0px; margin-right: auto" title="3种常见网络模式" border="0" alt="3种常见网络模式" src="http://firefore.com/wp-content/uploads/2010/06/3_thumb.png" width="710" height="303" /></p>
<h3><a name="3">理清思路</a></h3>
<p>知道了以上的网络拓扑结构后，咱们要做的事情就很清晰了。首先，<a  href="http://tech.sina.com.cn/h/2008-12-10/0600906985.shtml" target="_blank">了解VMware三种网络模式的区别在哪里</a>。其次，根据不同的网络环境，使用不同的<span class='wp_keywordlink_affiliate'><a href="http://firefore.com/bq/vmware" title="查看 VMware 中的全部文章" target="_blank">VMware</a></span>网络设置：</p>
<p>家用和公司或单位，因为机器处于内部局域网，能用的IP地址比较多，因此可以采用默认的<strong><span class='wp_keywordlink_affiliate'><a href="http://firefore.com/bq/bridge" title="查看 Bridge 中的全部文章" target="_blank">Bridge</a></span>d</strong>方式，<strong><span class='wp_keywordlink_affiliate'><a href="http://firefore.com/bq/bridge" title="查看 Bridge 中的全部文章" target="_blank">Bridge</a></span>d</strong>方式一般无需设定，建立虚拟机的时候一路next，默认的就是<strong><span class='wp_keywordlink_affiliate'><a href="http://firefore.com/bq/bridge" title="查看 Bridge 中的全部文章" target="_blank">Bridge</a></span>d</strong>方式。如果要实现双网卡模式，可以参考我上一篇文章：《<a  href="http://firefore.com/2008/04/vmware-1.html" target="_blank">VMware Workstation虚拟机实例：让外网访问虚拟机</a>》。</p>
<p>本文重点，也是众多朋友询问过的：<strong>机房里单IP的服务器安装虚拟机给外网提供服务的模式</strong>。也就是上方图片中的模式3。这种模式下，由于IP地址唯一，无法使用<strong>Bridged</strong>方式了。<strong>Host-Only</strong>模式为全封闭的模式，只能访问到宿主（Host）,甚至连外网都无法连通，所以<strong>Host-Only</strong>模式排除掉。于是，我们眼里就剩下<strong><span class='wp_keywordlink_affiliate'><a href="http://firefore.com/bq/nat" title="查看 NAT 中的全部文章" target="_blank">NAT</a></span></strong>模式了。</p>
<h3><a name="4">单网卡机器VMware Workstation的NAT设置</a></h3>
<p>根据上面的分析，咱们的思路很明确。就是使用VMware 的<strong><span class='wp_keywordlink_affiliate'><a href="http://firefore.com/bq/nat" title="查看 NAT 中的全部文章" target="_blank">NAT</a></span></strong>网络模式。那么接下来主要有如下两个要点：</p>
<ul>
<li>调整建立的虚拟机的网卡的网络模式，选择使用<strong>NAT</strong>模式。如下图：       <br /><a  href="http://firefore.com/wp-content/uploads/2010/06/vm_nat_1.png" target="_blank"><img style="border-right-width: 0px; display: block; float: none; border-top-width: 0px; border-bottom-width: 0px; margin-left: auto; border-left-width: 0px; margin-right: auto" title="VMware workstation 网络设置NAT" border="0" alt="VMware workstation 网络设置NAT" src="http://firefore.com/wp-content/uploads/2010/06/vm_nat_1_thumb.png" width="645" height="229" /></a> </li>
<li>使用VMware的NAT Settings中的<strong>Port Forwarding</strong>功能来进行端口转发。 </li>
</ul>
<h3><a name="5">Port Forwarding</a></h3>
<ol>
<li>使用VMware的NAT网络模式后，找到虚拟机的IP地址。虚拟机的网卡为DHCP模式，请进入虚拟机内查到虚拟机的IP地址，比如本文中的例子是Ubuntu的虚拟机，下图中的红圈内的就是虚拟机的IP地址：      <br /><img style="border-right-width: 0px; display: block; float: none; border-top-width: 0px; border-bottom-width: 0px; margin-left: auto; border-left-width: 0px; margin-right: auto" title="虚拟机的IP信息" border="0" alt="虚拟机的IP信息" src="http://firefore.com/wp-content/uploads/2010/06/nat1.png" width="628" height="155" /> </li>
<li>在VMware Workstation主界面上点“编辑”-“编辑虚拟网络”，如下图：      <br /><img style="border-right-width: 0px; display: block; float: none; border-top-width: 0px; border-bottom-width: 0px; margin-left: auto; border-left-width: 0px; margin-right: auto" title="编辑虚拟网络" border="0" alt="编辑虚拟网络" src="http://firefore.com/wp-content/uploads/2010/06/nat1.jpg" width="292" height="154" /> </li>
<li>打开VMware Workstation的虚拟网卡编辑界面。      <br />找到模式是NAT的那张虚拟网卡，点中后，再点下面的NAT Settings… 如下图红圈位置：       <br /><img style="border-right-width: 0px; display: block; float: none; border-top-width: 0px; border-bottom-width: 0px; margin-left: auto; border-left-width: 0px; margin-right: auto" title="Virtual Network Editor" border="0" alt="Virtual Network Editor" src="http://firefore.com/wp-content/uploads/2010/06/nat2.png" width="594" height="502" /> </li>
<li>在NAT Settings的标签页中，找到<strong>Port Forwarding</strong>的内容，按如下图的红圈中的那个Add按钮开始添加：       <br /><img style="border-right-width: 0px; display: block; float: none; border-top-width: 0px; border-bottom-width: 0px; margin-left: auto; border-left-width: 0px; margin-right: auto" title="Port Forwarding Add" border="0" alt="Port Forwarding Add" src="http://firefore.com/wp-content/uploads/2010/06/nat3.png" width="497" height="273" /> </li>
<li>在弹出的标签中，从上到下填写和选择宿主监听的端口、端口协议类型、虚拟机的IP地址、虚拟机监听的端口、描述。设置好后，一路按OK回到虚拟机主界面即可。下图是我虚拟机对外开放HTTP服务的80端口的设置图：      <br /><img style="border-right-width: 0px; display: block; float: none; border-top-width: 0px; border-bottom-width: 0px; margin-left: auto; border-left-width: 0px; margin-right: auto" title="Map Incoming Port" border="0" alt="Map Incoming Port" src="http://firefore.com/wp-content/uploads/2010/06/nat4.png" width="360" height="220" /> </li>
<li>需要注意，如此设置的时候，Host port的端口必须是宿主并未监听的端口，否则会出错。 </li>
<li>设置成功后，使用netstat命令即可看到宿主已经监听了我们填写的端口，监听该端口的程序是vmnat.exe </li>
<li>如上设置后，剩下的就是测试了。如果是家庭或是企业，可能还需要在路由器或是防火墙上设置端口映射到宿主 </li>
<li>经过设置后，外网访问80端口的时候，NAT的Port Forward就会把访问请求转发到虚拟机上，大致如下图：      <br /><img style="border-right-width: 0px; display: block; float: none; border-top-width: 0px; border-bottom-width: 0px; margin-left: auto; border-left-width: 0px; margin-right: auto" title="NAT" border="0" alt="NAT" src="http://firefore.com/wp-content/uploads/2010/06/NAT.png" width="359" height="276" /> </li>
</ol>
<h3><a name="6">路由器或是防火墙上设置端口映射</a></h3>
<p>这个比较难说清楚，不同品牌的路由器、防火墙的设置方式都不一样。我这里给出D-Link DI-624的端口映射的截图：</p>
<p><a  href="http://firefore.com/wp-content/uploads/2010/06/DI624.png" target="_blank"><img style="border-right-width: 0px; display: block; float: none; border-top-width: 0px; border-bottom-width: 0px; margin-left: auto; border-left-width: 0px; margin-right: auto" title="DI-624" border="0" alt="DI-624" src="http://firefore.com/wp-content/uploads/2010/06/DI624_thumb.png" width="640" height="324" /></a> </p>
<p>关于这部分的设置，大家可以去百度和google上搜索看看，有很多的教程。至于防火墙，一般都有详细的说明书或是厂家提供技术支持。</p>
<h3><a name="7">网络测试</a></h3>
<p>配置好了之后，还需要进行网络测试。</p>
<ol>
<li>得知目前的外网IP地址（固定IP的用户可以胡略此步骤），打开 <a  href="http://www.ip138.com/" target="_blank">ip138</a>这个网站就可以知道自己当前的IP地址。 </li>
<li>请您网络上的朋友帮忙测试。 </li>
<li>使用网络上一些免费的网站状态检测服务，这可以从搜索引擎上找到不少。 </li>
</ol>
<p>结束语，时隔两年，炜煜自己电脑中使用的虚拟机已经从VMware Workstation6变为VMware Workstation7了。不少朋友问的就是VMware Workstation7的虚拟网卡设置，其实大家仔细看图的话，会发现虚拟网卡设置这部分变化不大。另外，这篇文章写得很粗浅，目的是为了帮助大家在最短的时间内实现目标，可以说只是一个治标的方法。但是炜煜个人能力有限，工作重心也不是这个，所以面对深层次的东西就无能为力了。如果对于文章内容有任何想法，欢迎留言或是发邮件讨论。</p>
<p>文章作者：<a  href="http://firefore.com">施炜煜</a></p>
<p>文章链接：<a  href="http://firefore.com/2010/06/vmware-2.html">http://firefore.com/2010/06/vmware-2.html</a></p>
<p>相关文章：<a  href="http://firefore.com/2008/04/vmware-1.html" target="_blank">VMware Workstation虚拟机实例：让外网访问虚拟机(双网卡<strong>Bridged</strong>模式)</a></p>
<hr /><h4>相关文章：</h4><ul><li><a  href="http://firefore.com/2008/04/vmware-1.html" rel="bookmark" title="Permanent Link: VMware Workstation虚拟机实例：让外网访问虚拟机">VMware Workstation虚拟机实例：让外网访问虚拟机</a></li></ul><hr /><small><p>&#26412;&#20316;&#21697;&#30001;<a  0="xmlns:cc="http://creativecommons.org/ns#"" href="http://firefore.com" property="cc:attributionName" rel="cc:attributionURL">shiweiyu</a>&#21019;&#20316;&#65292;&#37319;&#29992;<a  rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/">&#30693;&#35782;&#20849;&#20139;&#32626;&#21517;-&#30456;&#21516;&#26041;&#24335;&#20849;&#20139; 3.0 Unported&#35768;&#21487;&#21327;&#35758;</a>&#36827;&#34892;&#35768;&#21487;&#12290;<br />
Copyright &copy; 2010 <a  href="http://firefore.com">FireFore.com</a> (数字指纹： woaiwojia_weiyu (38.107.179.213) )</small></p>]]></content:encoded>
			<wfw:commentRss>http://firefore.com/2010/06/vmware-2.html/feed</wfw:commentRss>
		<slash:comments>17</slash:comments>
		</item>
		<item>
		<title>ubuntu安装eAccelerator</title>
		<link>http://firefore.com/2009/09/installing-eaccelerator-in-ubuntu-server.html</link>
		<comments>http://firefore.com/2009/09/installing-eaccelerator-in-ubuntu-server.html#comments</comments>
		<pubDate>Fri, 11 Sep 2009 15:57:30 +0000</pubDate>
		<dc:creator>FireFore</dc:creator>
				<category><![CDATA[学习笔记]]></category>
		<category><![CDATA[Apache]]></category>
		<category><![CDATA[eaccelerator]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[ubuntu]]></category>

		<guid isPermaLink="false">http://firefore.com/2009/09/installing-eaccelerator-in-ubuntu-server.html</guid>
		<description><![CDATA[今天给一台Ubuntu的机器安装了eAccelerator的扩展。写个小笔记如下： 首先，得安装一下php5-dev： sudo apt-get install php5-dev 下载eAccelerator：（具体下载地址可以访问官网，版本不同，地址也不同） wge... ]]></description>
			<content:encoded><![CDATA[<p>今天给一台Ubuntu的机器安装了eAccelerator的扩展。写个小笔记如下：</p>
<p>首先，得安装一下php5-dev：</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">sudo</span> <span style="color: #c20cb9; font-weight: bold;">apt-get</span> <span style="color: #c20cb9; font-weight: bold;">install</span> php5-dev</pre></div></div>

<p>下载eAccelerator：（具体下载地址可以访问官网，版本不同，地址也不同）</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">wget</span> http:<span style="color: #000000; font-weight: bold;">//</span>bart.eaccelerator.net<span style="color: #000000; font-weight: bold;">/</span>source<span style="color: #000000; font-weight: bold;">/</span>0.9.5.3<span style="color: #000000; font-weight: bold;">/</span>eaccelerator-0.9.5.3.tar.bz2</pre></div></div>

<p><span id="more-756"></span></p>
<p>解压缩eAccelerator：</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">tar</span> jxvf eaccelerator-0.9.5.3.tar.bz2</pre></div></div>

<p>进入eAccelerator的目录：</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #7a0874; font-weight: bold;">cd</span> eaccelerator-0.9.5.3<span style="color: #000000; font-weight: bold;">/</span></pre></div></div>

<p>运行如下几个指令（一行一个指令，等执行完了再输入下一个）：</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">phpize 
<span style="color: #c20cb9; font-weight: bold;">sudo</span> .<span style="color: #000000; font-weight: bold;">/</span>configure <span style="color: #660033;">--enable-eaccelerator</span>=shared
<span style="color: #c20cb9; font-weight: bold;">sudo</span> <span style="color: #c20cb9; font-weight: bold;">make</span> 
<span style="color: #c20cb9; font-weight: bold;">sudo</span> <span style="color: #c20cb9; font-weight: bold;">make</span> <span style="color: #c20cb9; font-weight: bold;">install</span></pre></div></div>

<p>安装好之后，屏幕会显示大概如下信息：</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">Installing shared extensions:     <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>lib<span style="color: #000000; font-weight: bold;">/</span>php5<span style="color: #000000; font-weight: bold;">/</span><span style="color: #000000;">20060613</span>+lfs<span style="color: #000000; font-weight: bold;">/</span></pre></div></div>

<p>接着修改php.ini：</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">sudo</span> <span style="color: #c20cb9; font-weight: bold;">vi</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>php5<span style="color: #000000; font-weight: bold;">/</span>apache2<span style="color: #000000; font-weight: bold;">/</span>php.ini</pre></div></div>

<p>在文档最后加上：</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;">zend_extension<span style="color: #339933;">=</span><span style="color: #0000ff;">&quot;/usr/lib/php5/20060613+lfs/eaccelerator.so&quot;</span> 
eaccelerator<span style="color: #339933;">.</span>shm_size<span style="color: #339933;">=</span><span style="color: #0000ff;">&quot;16&quot;</span> 
eaccelerator<span style="color: #339933;">.</span>cache_dir<span style="color: #339933;">=</span><span style="color: #0000ff;">&quot;/var/cache/eaccelerator&quot;</span> 
eaccelerator<span style="color: #339933;">.</span>enable<span style="color: #339933;">=</span><span style="color: #0000ff;">&quot;1&quot;</span> 
eaccelerator<span style="color: #339933;">.</span>optimizer<span style="color: #339933;">=</span><span style="color: #0000ff;">&quot;1&quot;</span> 
eaccelerator<span style="color: #339933;">.</span>check_mtime<span style="color: #339933;">=</span><span style="color: #0000ff;">&quot;1&quot;</span> 
eaccelerator<span style="color: #339933;">.</span>debug<span style="color: #339933;">=</span><span style="color: #0000ff;">&quot;0&quot;</span> 
eaccelerator<span style="color: #339933;">.</span>filter<span style="color: #339933;">=</span><span style="color: #0000ff;">&quot;&quot;</span> 
eaccelerator<span style="color: #339933;">.</span>shm_max<span style="color: #339933;">=</span><span style="color: #0000ff;">&quot;0&quot;</span> 
eaccelerator<span style="color: #339933;">.</span>shm_ttl<span style="color: #339933;">=</span><span style="color: #0000ff;">&quot;0&quot;</span> 
eaccelerator<span style="color: #339933;">.</span>shm_prune_period<span style="color: #339933;">=</span><span style="color: #0000ff;">&quot;0&quot;</span> 
eaccelerator<span style="color: #339933;">.</span>shm_only<span style="color: #339933;">=</span><span style="color: #0000ff;">&quot;0&quot;</span> 
eaccelerator<span style="color: #339933;">.</span>compress<span style="color: #339933;">=</span><span style="color: #0000ff;">&quot;1&quot;</span> 
eaccelerator<span style="color: #339933;">.</span>compress_level<span style="color: #339933;">=</span><span style="color: #0000ff;">&quot;9&quot;</span> 
eaccelerator<span style="color: #339933;">.</span>allowed_admin_path<span style="color: #339933;">=</span><span style="color: #0000ff;">&quot;/var/www/control.php&quot;</span></pre></div></div>

<p>这里解释一下，最后一行的<span class='wp_keywordlink_affiliate'><a href="http://firefore.com/bq/eaccelerator" title="查看 eaccelerator 中的全部文章" target="_blank">eaccelerator</a></span>.allowed_admin_path的意思是eAccelerator的在线控制文件的实际路径，这样一来就可以使用http://你的网址/control.php来控制eAccelerator了。</p>
<p>接下来建立cache目录（一行一个指令）：</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">sudo</span> <span style="color: #c20cb9; font-weight: bold;">mkdir</span> <span style="color: #000000; font-weight: bold;">/</span>var<span style="color: #000000; font-weight: bold;">/</span>cache<span style="color: #000000; font-weight: bold;">/</span>eaccelerator
<span style="color: #c20cb9; font-weight: bold;">sudo</span> <span style="color: #c20cb9; font-weight: bold;">chown</span> root:www-data <span style="color: #000000; font-weight: bold;">/</span>var<span style="color: #000000; font-weight: bold;">/</span>cache<span style="color: #000000; font-weight: bold;">/</span>eaccelerator
<span style="color: #c20cb9; font-weight: bold;">sudo</span> <span style="color: #c20cb9; font-weight: bold;">chmod</span> <span style="color: #007800;">u</span>=rwx,<span style="color: #007800;">g</span>=rwx,<span style="color: #007800;">o</span>= <span style="color: #000000; font-weight: bold;">/</span>var<span style="color: #000000; font-weight: bold;">/</span>cache<span style="color: #000000; font-weight: bold;">/</span>eaccelerator</pre></div></div>

<p>然后进入<span class='wp_keywordlink_affiliate'><a href="http://firefore.com/bq/eaccelerator" title="查看 eaccelerator 中的全部文章" target="_blank">eaccelerator</a></span>-0.9.5.3的目录里拷贝control.php到网站目录：</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">sudo</span> <span style="color: #c20cb9; font-weight: bold;">cp</span> control.php <span style="color: #000000; font-weight: bold;">/</span>var<span style="color: #000000; font-weight: bold;">/</span>www</pre></div></div>

<p>接着修改control.php里的$user和$pw的内容：</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">sudo</span> <span style="color: #c20cb9; font-weight: bold;">vi</span> <span style="color: #000000; font-weight: bold;">/</span>var<span style="color: #000000; font-weight: bold;">/</span>www<span style="color: #000000; font-weight: bold;">/</span>control.php</pre></div></div>

<p>因为当你用http://你的网址/control.php访问的时候，是需要输入账号密码的。$user是账号，$pw是密码。</p>
<p>最后用指令检查一下apache2的配置：</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">apache2ctl configtest</pre></div></div>

<p>没有错误出现后重新启动apache：</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">sudo</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>init.d<span style="color: #000000; font-weight: bold;">/</span>apache2 restart</pre></div></div>

<p>如此就大功告成了。</p>
<p>在phpinfo()里面应该就可以看到有如下：</p>

<div class="wp_syntax"><div class="code"><pre class="html4strict" style="font-family:monospace;">This program makes use of the Zend Scripting Language Engine: 
Zend Engine v2.2.0, Copyright (c) 1998-2008 Zend Technologies 
    with eAccelerator v0.9.5.3, Copyright (c) 2004-2006 eAccelerator, by eAccelerator</pre></div></div>

<p>参考网站：<a  title="http://eaccelerator.net/wiki/InstallFromSource" href="http://eaccelerator.net/wiki/InstallFromSource" target="_blank">http://eaccelerator.net/wiki/InstallFromSource</a></p>
<p>本日志作者：<a  href="http://firefore.com" target="_blank">施炜煜</a></p>
<p>原文地址：<a  href="http://firefore.com/2009/09/installing-eaccelerator-in-ubuntu-server.html" target="_blank">http://firefore.com/2009/09/installing-eaccelerator-in-ubuntu-server.html</a></p>
<hr /><h4>相关文章：</h4><ul><li><a  href="http://firefore.com/2010/01/ubuntu9-10-eaccelerator.html" rel="bookmark" title="Permanent Link: ubuntu9.10下的eAccelerator">ubuntu9.10下的eAccelerator</a></li><li><a  href="http://firefore.com/2007/12/onlinegame-server-requirement.html" rel="bookmark" title="Permanent Link: 浅谈我接触过的网络游戏的服务器需求">浅谈我接触过的网络游戏的服务器需求</a></li><li><a  href="http://firefore.com/2007/11/sql-server-2000-version.html" rel="bookmark" title="Permanent Link: 怎么查看SQL SERVER 2000是否打过SP4的补丁">怎么查看SQL SERVER 2000是否打过SP4的补丁</a></li></ul><hr /><small><p>&#26412;&#20316;&#21697;&#30001;<a  0="xmlns:cc="http://creativecommons.org/ns#"" href="http://firefore.com" property="cc:attributionName" rel="cc:attributionURL">shiweiyu</a>&#21019;&#20316;&#65292;&#37319;&#29992;<a  rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/">&#30693;&#35782;&#20849;&#20139;&#32626;&#21517;-&#30456;&#21516;&#26041;&#24335;&#20849;&#20139; 3.0 Unported&#35768;&#21487;&#21327;&#35758;</a>&#36827;&#34892;&#35768;&#21487;&#12290;<br />
Copyright &copy; 2010 <a  href="http://firefore.com">FireFore.com</a> (数字指纹： woaiwojia_weiyu (38.107.179.213) )</small></p>]]></content:encoded>
			<wfw:commentRss>http://firefore.com/2009/09/installing-eaccelerator-in-ubuntu-server.html/feed</wfw:commentRss>
		<slash:comments>10</slash:comments>
		</item>
		<item>
		<title>先图后文</title>
		<link>http://firefore.com/2008/07/notebook.html</link>
		<comments>http://firefore.com/2008/07/notebook.html#comments</comments>
		<pubDate>Wed, 09 Jul 2008 16:38:38 +0000</pubDate>
		<dc:creator>FireFore</dc:creator>
				<category><![CDATA[学习笔记]]></category>
		<category><![CDATA[dell]]></category>

		<guid isPermaLink="false">http://firefore.com/2008/07/notebook.html</guid>
		<description><![CDATA[图片模糊哦？因为用的是三星的D508在黄色的灯光下拍摄的，然后用Microsoft Office Picture Manager压缩成适合的大小再传上来的。 相关文章：我那不幸的Dell Latitude D630stormliv.exe&#26412;&#20316;&#21697;&#30001... ]]></description>
			<content:encoded><![CDATA[<p>图片模糊哦？因为用的是<a  href="http://baike.baidu.com/view/9536.htm" target="_blank">三星</a>的<a  href="http://baike.baidu.com/view/1237446.html" target="_blank">D508</a>在黄色的灯光下拍摄的，然后用<a  href="http://baike.baidu.com/view/1155690.htm" target="_blank">Microsoft Office Picture Manager</a>压缩成适合的大小再传上来的。</p>
<p><span id="more-339"></span>
<p><img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="340" alt="箱子1" src="http://firefore.com/wp-content/uploads/2008/07/photo-0181.jpg" width="424" border="0" />     <br /><img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="340" alt="打开后" src="http://firefore.com/wp-content/uploads/2008/07/photo-0182.jpg" width="424" border="0" />     <br /><img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="340" alt="上下两层" src="http://firefore.com/wp-content/uploads/2008/07/photo-0183.jpg" width="424" border="0" />     <br /><img style="border-right: 0px; border-top: 0px; border-left: 0px; border-bottom: 0px" height="340" alt="上面的那个箱子的内容" src="http://firefore.com/wp-content/uploads/2008/07/photo-0184.jpg" width="424" border="0" />     <br /><img style="border-right: 0px; border-top: 0px; border-left: 0px; border-bottom: 0px" height="340" alt="机器的上方视角" src="http://firefore.com/wp-content/uploads/2008/07/photo-0186.jpg" width="424" border="0" />     <br /><img style="border-right: 0px; border-top: 0px; border-left: 0px; border-bottom: 0px" height="340" alt="机器掀开之后" src="http://firefore.com/wp-content/uploads/2008/07/photo-0187.jpg" width="424" border="0" />     <br /><img style="border-right: 0px; border-top: 0px; border-left: 0px; border-bottom: 0px" height="340" alt="近一点拍摄" src="http://firefore.com/wp-content/uploads/2008/07/photo-0188.jpg" width="424" border="0" />     <br /><img style="border-right: 0px; border-top: 0px; border-left: 0px; border-bottom: 0px" height="340" alt="机器侧面" src="http://firefore.com/wp-content/uploads/2008/07/photo-0189.jpg" width="424" border="0" />     <br /><img style="border-right: 0px; border-top: 0px; border-left: 0px; border-bottom: 0px" height="340" alt="另外一个侧面" src="http://firefore.com/wp-content/uploads/2008/07/photo-0190.jpg" width="424" border="0" />     <br /><img style="border-right: 0px; border-top: 0px; border-left: 0px; border-bottom: 0px" height="254" alt="机器的屁屁" src="http://firefore.com/wp-content/uploads/2008/07/photo-0191.jpg" width="452" border="0" /></p>
<hr /><h4>相关文章：</h4><ul><li><a  href="http://firefore.com/2008/08/dell-latitude-d630.html" rel="bookmark" title="Permanent Link: 我那不幸的Dell Latitude D630">我那不幸的Dell Latitude D630</a></li><li><a  href="http://firefore.com/2008/07/stormilv-exe.html" rel="bookmark" title="Permanent Link: stormliv.exe">stormliv.exe</a></li></ul><hr /><small><p>&#26412;&#20316;&#21697;&#30001;<a  0="xmlns:cc="http://creativecommons.org/ns#"" href="http://firefore.com" property="cc:attributionName" rel="cc:attributionURL">shiweiyu</a>&#21019;&#20316;&#65292;&#37319;&#29992;<a  rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/">&#30693;&#35782;&#20849;&#20139;&#32626;&#21517;-&#30456;&#21516;&#26041;&#24335;&#20849;&#20139; 3.0 Unported&#35768;&#21487;&#21327;&#35758;</a>&#36827;&#34892;&#35768;&#21487;&#12290;<br />
Copyright &copy; 2010 <a  href="http://firefore.com">FireFore.com</a> (数字指纹： woaiwojia_weiyu (38.107.179.213) )</small></p>]]></content:encoded>
			<wfw:commentRss>http://firefore.com/2008/07/notebook.html/feed</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>RedHat 9 下 FTP的架設(vsftpd采用虚拟用户)</title>
		<link>http://firefore.com/2008/05/vsftpd.html</link>
		<comments>http://firefore.com/2008/05/vsftpd.html#comments</comments>
		<pubDate>Mon, 05 May 2008 04:44:14 +0000</pubDate>
		<dc:creator>FireFore</dc:creator>
				<category><![CDATA[学习笔记]]></category>
		<category><![CDATA[chinaunix]]></category>
		<category><![CDATA[FTP]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[RedHat]]></category>
		<category><![CDATA[vsftpd]]></category>

		<guid isPermaLink="false">http://firefore.com/2008/05/vsftpd.html</guid>
		<description><![CDATA[这篇文章是几年前因为工作需要，整理给同事分享的。后来我发布在于我之前的一个博客上（小施Blog）。原文在此：http://www.i0595.net/blog/read.php?13 因为那个博客已经不再更新了。加上有朋友需... ]]></description>
			<content:encoded><![CDATA[<p style="text-indent:2em">这篇文章是几年前因为工作需要，整理给同事分享的。后来我发布在于我之前的一个博客上（<a  href="http://www.i0595.net/blog/index.php" target="_blank">小施Blog</a><a  href="http://www.i0595.net/blog/index.php"></a>）。<br />原文在此：<a title="RedHat 9 下 FTP的架設(vsftpd)" href="http://www.i0595.net/blog/read.php?13" target="_blank">http://www.i0595.net/blog/read.php?13</a></p>
<p style="text-indent:2em">因为那个博客已经不再更新了。加上有朋友需要，我就给保存成PDF文档，转载在这里了。</p>
<p style="text-indent:2em">点这里下载：<a  href="http://firefore.com/wp-content/uploads/2008/05/redhat9_vsftpd.pdf" title="RedHat 9 下 FTP的架設(vsftpd采用虚拟用户)">RedHat 9 下 FTP的架設(vsftpd采用虚拟用户)FDF文档</a></p>
<p style="text-indent:2em">文章说得比较简单，<strong>重心都在VS<span class='wp_keywordlink_affiliate'><a href="http://firefore.com/bq/ftp" title="查看 FTP 中的全部文章" target="_blank">FTP</a></span>D的采用虚拟用户方式的配置上</strong>，至于其他的设置方法，文章并没有写上，也就是说，文章还是有局限性。</p>
<p style="text-indent:2em">如果想完全了解VS<span class='wp_keywordlink_affiliate'><a href="http://firefore.com/bq/ftp" title="查看 FTP 中的全部文章" target="_blank">FTP</a></span>D的架设配置方法。还是得看专业人士的文章，比如以下两个链接就是很好的指导材料：</p>
<p><a  href="http://linux.vbird.org/linux_server/0410vsftpd.php" target="_blank">http://linux.vbird.org/linux_server/0410vsftpd.php</a><br /><a  href="http://bbs.chinaunix.net/archiver/?tid-561183.html" target="_blank">http://bbs.chinaunix.net/archiver/?tid-561183.html</a></p>
<p>第一个链接就是来自非常出名的《<a  title="鳥哥的Linux私房菜" href="http://linux.vbird.org/" target="_blank">鳥哥的Linux私房菜</a>》。推荐想学习<span class='wp_keywordlink_affiliate'><a href="http://firefore.com/bq/linux" title="查看 Linux 中的全部文章" target="_blank">Linux</a></span>的朋友多去看看，里面的文章非常实用。 <br />第二个链接来自ChinaUnix论坛。</p>
<hr /><small><p>&#26412;&#20316;&#21697;&#30001;<a  0="xmlns:cc="http://creativecommons.org/ns#"" href="http://firefore.com" property="cc:attributionName" rel="cc:attributionURL">shiweiyu</a>&#21019;&#20316;&#65292;&#37319;&#29992;<a  rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/">&#30693;&#35782;&#20849;&#20139;&#32626;&#21517;-&#30456;&#21516;&#26041;&#24335;&#20849;&#20139; 3.0 Unported&#35768;&#21487;&#21327;&#35758;</a>&#36827;&#34892;&#35768;&#21487;&#12290;<br />
Copyright &copy; 2010 <a  href="http://firefore.com">FireFore.com</a> (数字指纹： woaiwojia_weiyu (38.107.179.213) )</small></p>]]></content:encoded>
			<wfw:commentRss>http://firefore.com/2008/05/vsftpd.html/feed</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>VMware Workstation虚拟机实例：让外网访问虚拟机</title>
		<link>http://firefore.com/2008/04/vmware-1.html</link>
		<comments>http://firefore.com/2008/04/vmware-1.html#comments</comments>
		<pubDate>Wed, 16 Apr 2008 17:20:37 +0000</pubDate>
		<dc:creator>FireFore</dc:creator>
				<category><![CDATA[学习笔记]]></category>
		<category><![CDATA[Bridge]]></category>
		<category><![CDATA[chinaunix]]></category>
		<category><![CDATA[Google]]></category>
		<category><![CDATA[virtual network]]></category>
		<category><![CDATA[VMware]]></category>

		<guid isPermaLink="false">http://firefore.com/2008/04/vmware-1.html</guid>
		<description><![CDATA[这几天在一台大内存的拥有双千兆网卡的服务器上搞了一个虚拟机做测试，目的是让虚拟机也能跟其他真实存在的机器一样成为一台服务器，为局域网和互联网提供服务。也就是说不止要让局... ]]></description>
			<content:encoded><![CDATA[<p style="text-indent:2em">这几天在一台大内存的拥有双千兆网卡的服务器上搞了一个虚拟机做测试，目的是让虚拟机也能跟其他真实存在的机器一样成为一台服务器，为局域网和互联网提供服务。也就是说不止要让局域网的其他机器能访问到，因为有分配了一个公网的IP地址，所以也要让外网访问虚拟机。嗯？有点枯燥？那咱们配图说话（点击图片看大图）：</p>
<table cellspacing="0" cellpadding="2" width="550" border="0" align="center">
<tbody>
<tr>
<td align="center" width="275"><a  href="http://firefore.com/wp-content/uploads/2008/04/p1.png" target="_blank"><img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="244" alt="现实物理上" src="http://firefore.com/wp-content/uploads/2008/04/p1-thumb.png" width="233" border="0" /></a> </td>
<td align="center" width="275"><a  href="http://firefore.com/wp-content/uploads/2008/04/p2.png" target="_blank"><img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="242" alt="逻辑上向实现的效果" src="http://firefore.com/wp-content/uploads/2008/04/p2-thumb.png" width="244" border="0" /></a> </td>
</tr>
</tbody>
</table>
<p style="text-indent:2em">这次安装虚拟机采用的是<a  title="访问VMware的官方网站" href="http://www.vmware.com/" target="_blank">VMware Workstation</a>。由于之前用虚拟机顶多就是在局域网内跑或是单机跑。所以从来都没怎么关注过<a  title="访问VMware的官方网站" href="http://www.vmware.com/" target="_blank">VMware Workstation</a>的网络类型。于是马上<a  title="Google一下" href="http://www.google.com" target="_blank">Google</a>和<a  title="百度一下" href="http://www.baidu.com" target="_blank">百度</a>分别来几下。搜索到了<a  title="全球最大的 Linux Unix 中文网站" href="http://www.chinaunix.net" target="_blank">ChinaUnix</a>论坛上的一篇帖子:<a  title="vmware 网络设置三：理解虚拟网络的类型" href="http://www.chinaunix.net/jh/4/376768.html" target="_blank">http://www.chinaunix.net/jh/4/376768.html</a></p>
<p style="text-indent:2em">感谢作者，图文并茂介绍了<a  title="访问VMware的官方网站" href="http://www.vmware.com/" target="_blank">VMware Workstation</a>的虚拟网络类型。经过学习之后，我决定采用<strong><span class='wp_keywordlink_affiliate'><a href="http://firefore.com/bq/bridge" title="查看 Bridge 中的全部文章" target="_blank">Bridge</a></span></strong>方式。因为这个方式很适合用来实现我想要的功能。</p>
<p style="text-indent:2em">逻辑上，我们在虚拟机上也建立两张网卡，再采用bridge的网络类型，把两张虚拟网卡桥接到实际存在的两张物理网卡上，再分别设置相对应的IP地址。即可。母机上的两张物理网卡，一张是接入内部交换机，网卡名字后面有#2。另外一张接入外网的路由器中。</p>
<p style="text-indent:2em">具体上如何操作呢？下面咱们也来图文并茂给大家介绍一下。<img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="132" alt="图三" src="http://firefore.com/wp-content/uploads/2008/04/p4.jpg" width="250" align="left" border="0" /> 首先，得建立虚拟机（感觉是废话），最好采用自定义建立，这样在选择网络的时候，选择<strong>Bridged</strong>方式（另外三个分别是<strong><em>NAT、</em></strong><strong><em>host-only、</em></strong>不是用任何网络），建立好之后，先别启动虚拟机。点选如（图三）所示（点击菜单栏的<em><strong>Edit</strong></em>后，再点<strong><em>Virtual Network Settings&#8230;</em></strong>） 点了之后会出现<strong>Virtual Network Editor</strong>的界面，点击<strong><em>Automatic Bridging</em></strong>，然后把那个勾勾取消掉。再点击<strong><em>Host Virtual Network Mapping</em></strong>的标签，进入如（图四）的界面。</p>
<p style="text-indent:2em"> 这里解释一下哦。因为我们需要虚拟两张网卡，然后采用的是bridge的方式，所以我们这里需要设置一下。把两张虚拟网卡桥接到母机的物理网卡上。如（图四），我们可以看到有VMnet0到VMnet9共10张虚拟网卡。其中，VMnet0默认是采用<span class='wp_keywordlink_affiliate'><a href="http://firefore.com/bq/bridge" title="查看 Bridge 中的全部文章" target="_blank">Bridge</a></span>是用的虚拟网卡，VMnet8是默认情况下NAT方式使用的虚拟网卡，VMnet1是默认采用host-only时使用的虚拟网卡。当然，这些虚拟网卡的用途，在<a  title="访问VMware的官方网站" href="http://www.vmware.com/" target="_blank">VMware Workstation</a>中都是可以变更的。</p>
<table cellspacing="0" cellpadding="2" width="580" border="0" align="center">
<tbody>
<tr>
<td align="center" width="275"><a  href="http://firefore.com/wp-content/uploads/2008/04/p6.jpg" target="_blank"><img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="224" alt="图四点击看大图" src="http://firefore.com/wp-content/uploads/2008/04/p6.thumbnail.jpg" width="270" border="0" /></a> </td>
<td align="center" width="275"><a  href="http://firefore.com/wp-content/uploads/2008/04/p10.jpg" target="_blank"><img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="270" alt="图五点击看大图" src="http://firefore.com/wp-content/uploads/2008/04/p10.thumbnail.jpg" width="270" border="0" /></a> </td>
</tr>
</tbody>
</table>
<p style="text-indent:2em">现在，我们把<em><strong>VMnet0</strong></em>的栏位选择我们的物理网卡#2。再把<em><strong>VMnet2</strong></em>的栏位选择我们的物理网卡（接外网的那张。）这样，<em><strong>VMnet0</strong></em>桥接到局域网的网卡上，<em><strong>VMnet2</strong></em>桥接到外网的网卡上了。</p>
<p style="text-indent:2em">接下来就是为新建立的虚拟机添加第二张虚拟网卡，点击<a  title="访问VMware的官方网站" href="http://www.vmware.com/" target="_blank">VMware Workstation</a>主菜单上的<em><strong>VM</strong></em>，出现的下拉菜单中再点击<em><strong>Settings&#8230;</strong></em> 或是按快捷键<strong>CTRL+D</strong>。然后在出现的虚拟机编辑界面中，点击<em><strong>add</strong></em>。会出现<strong><em>Add Hardware Wizard</em></strong>的界面。再点击<em><strong>Ethernet Adapter</strong></em>后按下一步，一直到出现如（图五）的界面 ，（图五）的界面就是选择网络类型，这里我们选择自定义（Custom），然后在下拉的虚拟网卡中，选择我们之前设置过桥接的VMnet2（因为建立VMnet0已经被第一张虚拟网卡使用了）。选好之后，点完成。这样就完成了整个虚拟机爽网卡的配置了。接下来就是挂载镜像，启动虚拟机。安装系统。系统安装完成之后，可以看到虚拟机系统也有双网卡了。然后在两张虚拟网卡上分别设置局域网IP地址和外网的IP地址。这里再跟大家解释一下：像我介绍的这样采用桥接方式之后，我们的虚拟机就跟母机在网络上处于对等地位，网络关系上是平等的。因为我这个虚拟机已经分配了一个公网的IP地址。所以。也就实现了文章开头的需要让虚拟机成为局域网中的一台服务器的功能。由于有公网的IP地址，所以以上设置完成之后，就可以使用设置在虚拟机的那个公网IP访问虚拟机了。而局域网的机器则可以采用设置在虚拟机上的局域网IP地址访问虚拟机。整个关系就变化成下图：</p>
<p align="center"><img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="383" alt="采用桥接方式示意图" src="http://firefore.com/wp-content/uploads/2008/04/p3.png" width="383" border="0" /></p>
<p>单网卡单IP的情况请查看：《<a  href="/2010/06/vmware-2.html">VMware Workstation实例二：单IP的虚拟机提供外网访问》</a></p>
<hr /><h4>相关文章：</h4><ul><li><a  href="http://firefore.com/2010/06/vmware-2.html" rel="bookmark" title="Permanent Link: VMware Workstation实例二：单IP的虚拟机提供外网访问">VMware Workstation实例二：单IP的虚拟机提供外网访问</a></li></ul><hr /><small><p>&#26412;&#20316;&#21697;&#30001;<a  0="xmlns:cc="http://creativecommons.org/ns#"" href="http://firefore.com" property="cc:attributionName" rel="cc:attributionURL">shiweiyu</a>&#21019;&#20316;&#65292;&#37319;&#29992;<a  rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/">&#30693;&#35782;&#20849;&#20139;&#32626;&#21517;-&#30456;&#21516;&#26041;&#24335;&#20849;&#20139; 3.0 Unported&#35768;&#21487;&#21327;&#35758;</a>&#36827;&#34892;&#35768;&#21487;&#12290;<br />
Copyright &copy; 2010 <a  href="http://firefore.com">FireFore.com</a> (数字指纹： woaiwojia_weiyu (38.107.179.213) )</small></p>]]></content:encoded>
			<wfw:commentRss>http://firefore.com/2008/04/vmware-1.html/feed</wfw:commentRss>
		<slash:comments>24</slash:comments>
		</item>
		<item>
		<title>Blog出了点毛病。请勿担心。已解决！</title>
		<link>http://firefore.com/2008/03/myblog-bug.html</link>
		<comments>http://firefore.com/2008/03/myblog-bug.html#comments</comments>
		<pubDate>Wed, 26 Mar 2008 07:24:46 +0000</pubDate>
		<dc:creator>FireFore</dc:creator>
				<category><![CDATA[学习笔记]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://firefore.com/2008/03/myblog-bug.html</guid>
		<description><![CDATA[今天才发现我昨天修改的那个搜索栏在IE下凄惨不堪。。有时间会调整一下。 还有，今天发现后台只要有提交数据，就会出现空白。正在寻找原因。 原因找到了，我心血来潮，把主题下的functio... ]]></description>
			<content:encoded><![CDATA[<p>今天才发现我昨天修改的那个搜索栏在IE下凄惨不堪。。有时间会调整一下。<br />
还有，今天发现后台只要有提交数据，就会出现空白。正在寻找原因。</p>
<p><font style="color:#FF0000">原因找到了，我心血来潮，把主题下的functions.php的文件编码修改为utf8。结果就出现以上两个问题了。我现在修改回ANSI的编码格式，就正常了。晕。 </font></p>
<p>原来是因为我保存为utf8。但是编辑器自动加入BOM。结果就不行了。后来去掉了BOM就OK了。呵呵。</p>
<hr /><h4>相关文章：</h4><ul><li><a  href="http://firefore.com/2007/11/xml-rpc-ping-services.html" rel="bookmark" title="Permanent Link: WordPress文档中的Ping Services">WordPress文档中的Ping Services</a></li></ul><hr /><small><p>&#26412;&#20316;&#21697;&#30001;<a  0="xmlns:cc="http://creativecommons.org/ns#"" href="http://firefore.com" property="cc:attributionName" rel="cc:attributionURL">shiweiyu</a>&#21019;&#20316;&#65292;&#37319;&#29992;<a  rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/">&#30693;&#35782;&#20849;&#20139;&#32626;&#21517;-&#30456;&#21516;&#26041;&#24335;&#20849;&#20139; 3.0 Unported&#35768;&#21487;&#21327;&#35758;</a>&#36827;&#34892;&#35768;&#21487;&#12290;<br />
Copyright &copy; 2010 <a  href="http://firefore.com">FireFore.com</a> (数字指纹： woaiwojia_weiyu (38.107.179.213) )</small></p>]]></content:encoded>
			<wfw:commentRss>http://firefore.com/2008/03/myblog-bug.html/feed</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>即食伊面！厦门泡面！</title>
		<link>http://firefore.com/2008/03/ji-shi-yi-mian.html</link>
		<comments>http://firefore.com/2008/03/ji-shi-yi-mian.html#comments</comments>
		<pubDate>Wed, 05 Mar 2008 03:11:50 +0000</pubDate>
		<dc:creator>FireFore</dc:creator>
				<category><![CDATA[学习笔记]]></category>

		<guid isPermaLink="false">http://firefore.com/2008/03/ji-shi-yi-mian.html</guid>
		<description><![CDATA[吃了20多年了吧。 很小的时候，刚刚上小学的时候，每天早晨都是即食伊面+鸡蛋。就这么吃到小学毕业，偶尔会吃更贵一点的其他牌子的泡面，但是我不喜欢，我还是喜欢厦门泡面。 也就是因... ]]></description>
			<content:encoded><![CDATA[<p style="text-indent:2em">吃了20多年了吧。</p>
<p style="text-indent:2em">很小的时候，刚刚上小学的时候，每天早晨都是即食伊面+鸡蛋。就这么吃到小学毕业，偶尔会吃更贵一点的其他牌子的泡面，但是我不喜欢，我还是喜欢厦门泡面。</p>
<p style="text-indent:2em">也就是因为我喜欢吃，爸爸就教我煮泡面，所以我只会煮泡面而已。</p>
<p style="text-indent:2em">一直到离开家去外面上初中高中，每次回到家里，肚子饿了，我也吃这个即食伊面。它没有其他牌子的泡面那么多料，面条本身也不是那么好吃。但是，汤！那包调味料！！！那味道！！！！绝了！！！！其他牌子的泡面根本无发跟它比！因为即食伊面的调味料太好了。那味道，我现在写这个日志，都在流口水！！！</p>
<p style="text-indent:2em">由于即食伊面便宜，现在我在大型超市买不到这个即食伊面，只能在小杂货铺里面才能买到，可能是因为利润太低了吧，超市都不肯卖了。还记得即食伊面在我小的时候一包4毛5，前几天买的时候是1块钱一包。在前几年，我极穷的时候，又不想向家里求助，那阶段，我吃最多的就是即食伊面了。</p>
<p style="text-indent:2em">直到每次吃着即食伊面，就会想起父亲母亲。小时候家境并不好，当时一包即食伊面的价格是4毛5。这4毛5在我们农村，那可以足够一家人吃一顿饭了。</p>
<p style="text-indent:2em">最后，即食伊面的冒牌货很多。咱们这里介绍一下。买的时候，注意看牌子，一定要“双山”牌的才是正宗的！切记啊！只有这个牌子的才正宗好吃，因为其调味料的沙嗲味道，其他厂家无法模仿！</p>
<hr /><small><p>&#26412;&#20316;&#21697;&#30001;<a  0="xmlns:cc="http://creativecommons.org/ns#"" href="http://firefore.com" property="cc:attributionName" rel="cc:attributionURL">shiweiyu</a>&#21019;&#20316;&#65292;&#37319;&#29992;<a  rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/">&#30693;&#35782;&#20849;&#20139;&#32626;&#21517;-&#30456;&#21516;&#26041;&#24335;&#20849;&#20139; 3.0 Unported&#35768;&#21487;&#21327;&#35758;</a>&#36827;&#34892;&#35768;&#21487;&#12290;<br />
Copyright &copy; 2010 <a  href="http://firefore.com">FireFore.com</a> (数字指纹： woaiwojia_weiyu (38.107.179.213) )</small></p>]]></content:encoded>
			<wfw:commentRss>http://firefore.com/2008/03/ji-shi-yi-mian.html/feed</wfw:commentRss>
		<slash:comments>9</slash:comments>
		</item>
		<item>
		<title>修改Microsoft SQL Server 排序规则的方法</title>
		<link>http://firefore.com/2008/02/microsoft-sql-server-sorting-rules.html</link>
		<comments>http://firefore.com/2008/02/microsoft-sql-server-sorting-rules.html#comments</comments>
		<pubDate>Thu, 21 Feb 2008 04:17:23 +0000</pubDate>
		<dc:creator>FireFore</dc:creator>
				<category><![CDATA[学习笔记]]></category>
		<category><![CDATA[Microsoft]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[Windows]]></category>

		<guid isPermaLink="false">http://firefore.com/2008/02/microsoft-sql-server-sorting-rules.html</guid>
		<description><![CDATA[注意：任何操作前，请务必备份数据库！此方法不一定适合您的环境，仅供参考。 操作方法：打开SQL 查询分析器 1、如果是数据库： ALTER DATABASE 数据库名 COLLATE 排列规则 例如： ALTER DATABASE 9NPC... ]]></description>
			<content:encoded><![CDATA[<p style="text-indent:2em">注意：任何操作前，请务必备份数据库！此方法不一定适合您的环境，仅供参考。</p>
<p style="text-indent:2em">操作方法：打开<a  href="http://www.baidu.com/baidu?tn=shiweiyu_pg&#038;word=SQL+%B2%E9%D1%AF%B7%D6%CE%F6%C6%F7" target="_blank">SQL 查询分析器</a><br />
1、如果是数据库：<br />
<strong>ALTER   DATABASE   数据库名   COLLATE  排列规则</strong><br />
例如：</p>

<div class="wp_syntax"><div class="code"><pre class="sql" style="font-family:monospace;"><span style="color: #993333; font-weight: bold;">ALTER</span> <span style="color: #993333; font-weight: bold;">DATABASE</span> 9NPC <span style="color: #993333; font-weight: bold;">COLLATE</span> Chinese_PRC_CI_AI</pre></div></div>

<p>2、如果是表中的字段：<br />
<strong>ALTER   TABLE   表名   ALTER   COLUMN   字段名   数据类型（长度）  COLLATE  排列规则</strong><br />
例如：</p>

<div class="wp_syntax"><div class="code"><pre class="sql" style="font-family:monospace;"><span style="color: #993333; font-weight: bold;">ALTER</span> <span style="color: #993333; font-weight: bold;">TABLE</span> Userinfo <span style="color: #993333; font-weight: bold;">ALTER</span> <span style="color: #993333; font-weight: bold;">COLUMN</span> name <span style="color: #993333; font-weight: bold;">VARCHAR</span><span style="color: #66cc66;">&#40;</span><span style="color: #cc66cc;">4</span><span style="color: #66cc66;">&#41;</span> <span style="color: #993333; font-weight: bold;">COLLATE</span> Chinese_PRC_CI_AI</pre></div></div>

</p>
<p style="text-indent:2em">关于<span class='wp_keywordlink_affiliate'><a href="http://firefore.com/bq/microsoft" title="查看 Microsoft 中的全部文章" target="_blank">Microsoft</a></span> <span class='wp_keywordlink_affiliate'><a href="http://firefore.com/bq/sql" title="查看 SQL 中的全部文章" target="_blank">SQL</a></span> Server 排序规则的简介，请看<br />
<a  href="http://hi.baidu.com/813318/blog/item/783e2ffb7e55f6156c22eb62.html" target="_blank">http://hi.baidu.com/813318/blog/item/783e2ffb7e55f6156c22eb62.html</a></p>
<p></p>
<hr /><h4>相关文章：</h4><ul><li><a  href="http://firefore.com/2007/11/sql-server-2000-version.html" rel="bookmark" title="Permanent Link: 怎么查看SQL SERVER 2000是否打过SP4的补丁">怎么查看SQL SERVER 2000是否打过SP4的补丁</a></li><li><a  href="http://firefore.com/2007/12/onlinegame-server-requirement.html" rel="bookmark" title="Permanent Link: 浅谈我接触过的网络游戏的服务器需求">浅谈我接触过的网络游戏的服务器需求</a></li><li><a  href="http://firefore.com/2011/02/tsmmc.html" rel="bookmark" title="Permanent Link: Tsmmc">Tsmmc</a></li></ul><hr /><small><p>&#26412;&#20316;&#21697;&#30001;<a  0="xmlns:cc="http://creativecommons.org/ns#"" href="http://firefore.com" property="cc:attributionName" rel="cc:attributionURL">shiweiyu</a>&#21019;&#20316;&#65292;&#37319;&#29992;<a  rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/">&#30693;&#35782;&#20849;&#20139;&#32626;&#21517;-&#30456;&#21516;&#26041;&#24335;&#20849;&#20139; 3.0 Unported&#35768;&#21487;&#21327;&#35758;</a>&#36827;&#34892;&#35768;&#21487;&#12290;<br />
Copyright &copy; 2010 <a  href="http://firefore.com">FireFore.com</a> (数字指纹： woaiwojia_weiyu (38.107.179.213) )</small></p>]]></content:encoded>
			<wfw:commentRss>http://firefore.com/2008/02/microsoft-sql-server-sorting-rules.html/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>【转】四种镜像实现方法和原理</title>
		<link>http://firefore.com/2008/01/mirror-elements.html</link>
		<comments>http://firefore.com/2008/01/mirror-elements.html#comments</comments>
		<pubDate>Fri, 25 Jan 2008 01:41:17 +0000</pubDate>
		<dc:creator>FireFore</dc:creator>
				<category><![CDATA[学习笔记]]></category>
		<category><![CDATA[好文章]]></category>
		<category><![CDATA[镜像]]></category>

		<guid isPermaLink="false">http://firefore.com/2008/01/mirror-elements.html</guid>
		<description><![CDATA[这个文章是转自梦游科技信息港的客服中心，因为我有有租用他们的空间，他们有提供镜像的服务。 1.最简单的方法: 一台做主服务器, 其它作镜像服务器, 数据库存在主服务器上, 镜像服务器使... ]]></description>
			<content:encoded><![CDATA[<p>这个文章是转自<a  href="http://www.meyu.net/">梦游科技信息港</a>的客服中心，因为我有有租用他们的空间，他们有提供<span class='wp_keywordlink_affiliate'><a href="http://firefore.com/bq/%e9%95%9c%e5%83%8f" title="查看 镜像 中的全部文章" target="_blank">镜像</a></span>的服务。</p>
<p>1.最简单的方法:<br />
一台做主服务器, 其它作<span class='wp_keywordlink_affiliate'><a href="http://firefore.com/bq/%e9%95%9c%e5%83%8f" title="查看 镜像 中的全部文章" target="_blank">镜像</a></span>服务器, 数据库存在主服务器上, <span class='wp_keywordlink_affiliate'><a href="http://firefore.com/bq/%e9%95%9c%e5%83%8f" title="查看 镜像 中的全部文章" target="_blank">镜像</a></span>服务器使用远程调用功能读取主服务器的数据库. 使用工具让主服务器上的网页文件和镜像服务器同步.</p>
<p>优点: 实现简单<br />
缺点: 远程调用效率低, 速度慢. 如果主服务器挂了就全部不行了.</p>
<p>2. 复杂的方法: 相当于集群, 一台做主服务器, 其它作镜像服务器, 让主服务器和镜像服务器数据同步, 包括网页和数据库. 当用户访问的时候, 可以直接读取主服务器或者镜像服务器的数据, 当需要写数据的时候, 通过镜像服务器传送数据直接写到主服务器上.</p>
<p>优点: 速度快<br />
缺点: 实现起来困难复杂. 花费巨大. 如果主服务器挂了就全部不行了. 主服务器和镜像服务器必须保持良好的连接让数据同步时间尽量减少.</p>
<p>3. 更复杂的方法: 相当于更高级的集群, 全部机器数据同步, 包括网页和数据库. 当用户访问的时候, 可以直接读取任何一个服务器的数据, 当需要写数据的时候, 写到正在访问的服务器上, 然后数据再传输到其它服务器. 其中一台当机后恢复的话自动从其它没当机的服务器上同步最新数据.</p>
<p>优点: 速度快, 就算其中某个服务器挂了也不影响正常使用.<br />
缺点: 实现起来非常困难非常复杂. 花费巨大.  主服务器和镜像服务器必须保持非常良好的连接让数据同步时间尽量减少, 不然可能会产生很多问题.</p>
<p>4. 不简单也不复杂的方法: 类似CDN的功能. 一台做主服务器, 其它作镜像服务器, 当用户访问镜像服务器的时候, 镜像服务器从主服务器读取数据返回给用户, 然后缓存数据. 当下一个用户访问同样的页面的时候, 直接返回缓存数据. 写数据的时候通过镜像服务器传送数据直接写到主服务器上.</p>
<p>优点: 实现简单. 花费小. 可以很容易地应用到不同网络不同地区的服务器或网站.<br />
缺点: 镜像服务器必须和主服务器有良好的网络连接, 不然会比较慢. 如果主服务器挂了就全部不行了. </p>
<hr /><small><p>&#26412;&#20316;&#21697;&#30001;<a  0="xmlns:cc="http://creativecommons.org/ns#"" href="http://firefore.com" property="cc:attributionName" rel="cc:attributionURL">shiweiyu</a>&#21019;&#20316;&#65292;&#37319;&#29992;<a  rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/">&#30693;&#35782;&#20849;&#20139;&#32626;&#21517;-&#30456;&#21516;&#26041;&#24335;&#20849;&#20139; 3.0 Unported&#35768;&#21487;&#21327;&#35758;</a>&#36827;&#34892;&#35768;&#21487;&#12290;<br />
Copyright &copy; 2010 <a  href="http://firefore.com">FireFore.com</a> (数字指纹： woaiwojia_weiyu (38.107.179.213) )</small></p>]]></content:encoded>
			<wfw:commentRss>http://firefore.com/2008/01/mirror-elements.html/feed</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>lower_case_table_names=1 让MySQL不区分大小写！</title>
		<link>http://firefore.com/2008/01/lower-case-table-names.html</link>
		<comments>http://firefore.com/2008/01/lower-case-table-names.html#comments</comments>
		<pubDate>Sat, 05 Jan 2008 04:59:46 +0000</pubDate>
		<dc:creator>FireFore</dc:creator>
				<category><![CDATA[学习笔记]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[Windows]]></category>
		<category><![CDATA[游戏]]></category>

		<guid isPermaLink="false">http://firefore.com/2008/01/lower-case-table-names.html</guid>
		<description><![CDATA[此前有款网络游戏的数据库是采用MySQL。操作系统是CentOS。部分服务器的操作系统又是Windows。 出现了一个小毛病。那就是MySQL大小写的问题。 在CentOS安装的MySQL的配置文件中(/etc/my.cnf)，是没有l... ]]></description>
			<content:encoded><![CDATA[<p>此前有款网络<span class='wp_keywordlink_affiliate'><a href="http://firefore.com/bq/%e6%b8%b8%e6%88%8f" title="查看 游戏 中的全部文章" target="_blank">游戏</a></span>的数据库是采用<a  href="http://www.mysql.com/" target="_blank">MySQL</a>。操作系统是<a  href="http://www.centos.org/" target="_blank">CentOS</a>。部分服务器的操作系统又是<a  href="http://www.microsoft.com/windows/default.mspx" target="_blank">Windows</a>。<br />
出现了一个小毛病。那就是<strong><a  href="http://www.mysql.com/" target="_blank">MySQL</a>大小写</strong>的问题。</p>
<p>在<a  href="http://www.centos.org/" target="_blank">CentOS</a>安装的<a  href="http://www.mysql.com/" target="_blank">MySQL</a>的配置文件中(/etc/my.cnf)，是没有lower_case_table_names=1这行的。<br />
在<a  href="http://www.microsoft.com/windows/default.mspx" target="_blank">Windows</a>安装的<a  href="http://www.mysql.com/" target="_blank">MySQL</a>的配置文件中(my.ini)，是有<strong>lower_case_table_names=1</strong>这行的。</p>
<p><strong>lower_case_table_names=1</strong>的用途是让<a  href="http://www.mysql.com/" target="_blank">MySQL</a>实现不区分大小写。</p>
<p>所以当时出了些毛病，后来才发现是这个的问题。连忙在<a  href="http://www.centos.org/" target="_blank">CentOS</a>中的my.cnf(/etc/my.cnf)的[mysqld]区段下增加:</p>

<div class="wp_syntax"><div class="code"><pre class="sql" style="font-family:monospace;">lower_case_table_names<span style="color: #66cc66;">=</span><span style="color: #cc66cc;">1</span></pre></div></div>

<hr /><h4>相关文章：</h4><ul><li><a  href="http://firefore.com/2010/03/how-to-transfer-domain-names-from-meyu-net-to-name-com.html" rel="bookmark" title="Permanent Link: 从meyu.net转移域名到name.com">从meyu.net转移域名到name.com</a></li><li><a  href="http://firefore.com/2008/08/360buy-aeneon.html" rel="bookmark" title="Permanent Link: 血泪教训之网络购物">血泪教训之网络购物</a></li><li><a  href="http://firefore.com/2008/02/microsoft-sql-server-sorting-rules.html" rel="bookmark" title="Permanent Link: 修改Microsoft SQL Server 排序规则的方法">修改Microsoft SQL Server 排序规则的方法</a></li></ul><hr /><small><p>&#26412;&#20316;&#21697;&#30001;<a  0="xmlns:cc="http://creativecommons.org/ns#"" href="http://firefore.com" property="cc:attributionName" rel="cc:attributionURL">shiweiyu</a>&#21019;&#20316;&#65292;&#37319;&#29992;<a  rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/">&#30693;&#35782;&#20849;&#20139;&#32626;&#21517;-&#30456;&#21516;&#26041;&#24335;&#20849;&#20139; 3.0 Unported&#35768;&#21487;&#21327;&#35758;</a>&#36827;&#34892;&#35768;&#21487;&#12290;<br />
Copyright &copy; 2010 <a  href="http://firefore.com">FireFore.com</a> (数字指纹： woaiwojia_weiyu (38.107.179.213) )</small></p>]]></content:encoded>
			<wfw:commentRss>http://firefore.com/2008/01/lower-case-table-names.html/feed</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>MYSQL 局域网或是远程连接速度慢的两种解决方法</title>
		<link>http://firefore.com/2008/01/skip-name-resolve.html</link>
		<comments>http://firefore.com/2008/01/skip-name-resolve.html#comments</comments>
		<pubDate>Sat, 05 Jan 2008 04:32:21 +0000</pubDate>
		<dc:creator>FireFore</dc:creator>
				<category><![CDATA[学习笔记]]></category>
		<category><![CDATA[SQL]]></category>

		<guid isPermaLink="false">http://firefore.com/2008/01/skip-name-resolve.html</guid>
		<description><![CDATA[配置服务器的MYSQL.发现局域网连接速度非常慢.每次都要等几秒钟.这样对于服务器来说可是致命的. 在my.ini的 [mysqld] 里面添加了 skip-name-resolve 了之后, 发现速度快了.但是localhost却无法登陆,只能... ]]></description>
			<content:encoded><![CDATA[<p>配置服务器的MY<span class='wp_keywordlink_affiliate'><a href="http://firefore.com/bq/sql" title="查看 SQL 中的全部文章" target="_blank">SQL</a></span>.发现局域网连接速度非常慢.每次都要等几秒钟.这样对于服务器来说可是致命的.</p>
<p>在<strong>my.ini</strong>的<br />
[mysqld]<br />
里面添加了</p>

<div class="wp_syntax"><div class="code"><pre class="sql" style="font-family:monospace;">skip<span style="color: #66cc66;">-</span>name<span style="color: #66cc66;">-</span>resolve</pre></div></div>

<p>了之后,<br />
发现速度快了.但是localhost却无法登陆,只能使用IP.</p>
<p>后来.发现,我在(windows)<strong>hosts</strong>文件里面把IP地址和对应机器名字输入之后,保存,再连.速度果然快了&#8230;..</p>
<p>此文写于此前的博客</p>
<p>http://www.i0595.net/blog/post/53.htm</p>
<hr /><small><p>&#26412;&#20316;&#21697;&#30001;<a  0="xmlns:cc="http://creativecommons.org/ns#"" href="http://firefore.com" property="cc:attributionName" rel="cc:attributionURL">shiweiyu</a>&#21019;&#20316;&#65292;&#37319;&#29992;<a  rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/">&#30693;&#35782;&#20849;&#20139;&#32626;&#21517;-&#30456;&#21516;&#26041;&#24335;&#20849;&#20139; 3.0 Unported&#35768;&#21487;&#21327;&#35758;</a>&#36827;&#34892;&#35768;&#21487;&#12290;<br />
Copyright &copy; 2010 <a  href="http://firefore.com">FireFore.com</a> (数字指纹： woaiwojia_weiyu (38.107.179.213) )</small></p>]]></content:encoded>
			<wfw:commentRss>http://firefore.com/2008/01/skip-name-resolve.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>设置IIS的MIME让IIS6支持INI文件下载</title>
		<link>http://firefore.com/2007/12/setting-iis-mime.html</link>
		<comments>http://firefore.com/2007/12/setting-iis-mime.html#comments</comments>
		<pubDate>Mon, 17 Dec 2007 19:45:30 +0000</pubDate>
		<dc:creator>FireFore</dc:creator>
				<category><![CDATA[学习笔记]]></category>
		<category><![CDATA[IIS]]></category>
		<category><![CDATA[Windows]]></category>
		<category><![CDATA[工作]]></category>

		<guid isPermaLink="false">http://firefore.com/2007/12/setting-iis-mime.html</guid>
		<description><![CDATA[为了让IIS能下载扩展名是INI的文件，我们需要如此操作：（括号内的是英文版本的名字） 打开“IIS管理器（Internet Information Services (IIS) Manager）” 选择到你的站点。单击右键。选择“属性（Prope... ]]></description>
			<content:encoded><![CDATA[<p>为了让<span class='wp_keywordlink_affiliate'><a href="http://firefore.com/bq/iis" title="查看 IIS 中的全部文章" target="_blank">IIS</a></span>能下载扩展名是INI的文件，我们需要如此操作：（<strong>括号内的是英文版本的名字</strong>）</p>
<ol>
<li>打开“<span class='wp_keywordlink_affiliate'><a href="http://firefore.com/bq/iis" title="查看 IIS 中的全部文章" target="_blank">IIS</a></span>管理器（Internet Information Services (<span class='wp_keywordlink_affiliate'><a href="http://firefore.com/bq/iis" title="查看 IIS 中的全部文章" target="_blank">IIS</a></span>) Manager）”</li>
<li>选择到你的站点。单击右键。选择“属性（Properties）”</li>
<li>单击“HTTP 头（HTTP Headers）”选项卡</li>
<li>单击“MIME 类型（MIME Types）”</li>
<li>单击“新建(NEW)”</li>
<li>在“扩展名（Extension）”框中，输入文件扩展名，这里是<strong>ini</strong></li>
<li>在“MIME 类型（MIME Types）”框中，输入该扩展名的说明。这里输入的是<strong>application/octet-stream</strong></li>
</ol>
<p>解释一下：<br />
MIME Types中输入<strong>application/octet-stream</strong>的目的是为了让IIS把INI文件当作是EXE那样，出现下载的提示。<br />
否则的话是出现404的提示或是直接在浏览器中把内容给显示出来了。都不能达到我们的目的。</p>
<p>百度一下，相关的说明有很多。活学活用。 <img src='http://firefore.com/wp-includes/images/smilies/icon_razz.gif' alt=':razz:' class='wp-smiley' />  </p>
<hr /><h4>相关文章：</h4><ul><li><a  href="http://firefore.com/2007/12/onlinegame-server-requirement.html" rel="bookmark" title="Permanent Link: 浅谈我接触过的网络游戏的服务器需求">浅谈我接触过的网络游戏的服务器需求</a></li></ul><hr /><small><p>&#26412;&#20316;&#21697;&#30001;<a  0="xmlns:cc="http://creativecommons.org/ns#"" href="http://firefore.com" property="cc:attributionName" rel="cc:attributionURL">shiweiyu</a>&#21019;&#20316;&#65292;&#37319;&#29992;<a  rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/">&#30693;&#35782;&#20849;&#20139;&#32626;&#21517;-&#30456;&#21516;&#26041;&#24335;&#20849;&#20139; 3.0 Unported&#35768;&#21487;&#21327;&#35758;</a>&#36827;&#34892;&#35768;&#21487;&#12290;<br />
Copyright &copy; 2010 <a  href="http://firefore.com">FireFore.com</a> (数字指纹： woaiwojia_weiyu (38.107.179.213) )</small></p>]]></content:encoded>
			<wfw:commentRss>http://firefore.com/2007/12/setting-iis-mime.html/feed</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>install shield 11.5 创建反安装(删除)的快捷方式</title>
		<link>http://firefore.com/2007/12/install-shield-115-uninstall-shortcuts.html</link>
		<comments>http://firefore.com/2007/12/install-shield-115-uninstall-shortcuts.html#comments</comments>
		<pubDate>Fri, 14 Dec 2007 18:40:01 +0000</pubDate>
		<dc:creator>FireFore</dc:creator>
				<category><![CDATA[学习笔记]]></category>
		<category><![CDATA[安装制作]]></category>
		<category><![CDATA[游戏]]></category>

		<guid isPermaLink="false">http://firefore.com/2007/12/install-shield-115-uninstall-shortcuts.html</guid>
		<description><![CDATA[因为经常要为游戏的客户端制作光盘安装版。用Inno setup来分卷压缩很难看。所以我就使用了install shield。 但是我在install shield 11.5发现只能创建程序的快捷方式，无法创建反安装的快捷方式（可... ]]></description>
			<content:encoded><![CDATA[<p>因为经常要为<span class='wp_keywordlink_affiliate'><a href="http://firefore.com/bq/%e6%b8%b8%e6%88%8f" title="查看 游戏 中的全部文章" target="_blank">游戏</a></span>的客户端制作光盘安装版。用Inno setup来分卷压缩很难看。所以我就使用了install shield。</p>
<p>但是我在install shield 11.5发现只能创建程序的快捷方式，无法创建反安装的快捷方式（可能是我很笨，没找到）。</p>
<p>所以我一般都采用下面的方式创建：</p>
<p>首先，界面切换到<strong>Installation Designer</strong>中。<br />
然后在<strong>Installation Information</strong>中的<strong>General Information</strong>中的<strong>Product Properties</strong>可以看到有<strong>Product GUID</strong><br />
我们首先要改变这个<strong>Product GUID</strong>。可以选中Product GUID后点下面的<strong>Generate GUID</strong>就可以改变。<br />
当然，还有另外一个方法。那就是点菜单中“<strong>Project</strong>”的“<strong>Settings</strong>”。后，再选择“Application”。就可以看到Product GUID。点旁边的<strong>Change</strong>按钮就可以改变。</p>
<p>为什么要改变这个Product GUID呢？<span id="more-107"></span>因为我使用的添加反安装快捷方式的方法，是有用到这个Product GUID。<br />
所以我们要避免出现一样。。不过其实在创立项目的时候，这个Product GUID会自动生成，随机的，所以不可能出现一样。上面的说明目的也是跟您介绍一下在哪里可以看到Product GUID。</p>
<p>接下来就是回到<strong>Installation Designer</strong>中。<br />
选择<strong>System Configuration</strong>中的<strong>Shortcuts</strong>然后就可以看到我们要创立快捷方式的地方了。</p>
<p>先随便创建一个快捷方式（不用担心，下面我们会把它修改为反安装快捷方式）。<br />
然后选中这个快捷方式。可以看到其详细的属性信息。<br />
<strong>Dispaly Name</strong> 是这个快捷方式的名字，这里我们修改为“反安裝 XXXX”（不要带引号）</p>
<p><strong>Target</strong>是重头戏，修改为</p>

<div class="wp_syntax"><div class="code"><pre class="dos" style="font-family:monospace;"><span style="color: #33cc33;">&lt;</span>PROGRAMFILES<span style="color: #33cc33;">&gt;</span>\InstallShield Installation Information\{201C81B3-67A6-4837-B1B1-491E0CFFECC7}\Setup.exe</pre></div></div>

<p>这里需要根据您的实际情况把</p>

<div class="wp_syntax"><div class="code"><pre class="text" style="font-family:monospace;">{201C81B3-67A6-4837-B1B1-491E0CFFECC7}</pre></div></div>

<p>修改为您实际的<strong>Product GUID</strong>。</p>
<p>然后继续找到<br />
<strong>Arguments</strong><br />
值修改为</p>

<div class="wp_syntax"><div class="code"><pre class="text" style="font-family:monospace;">/m{201C81B3-67A6-4837-B1B1-491E0CFFECC7}</pre></div></div>

<p>同样，把其中的<strong>Product GUID</strong>修改为您实际的。</p>
<p>其他部分参数说明：<br />
Icon File 这个快捷方式使用的图标<br />
Icon Indes 这个快捷方式使用图标中的哪一个（这个我不知道怎么描述，因为有的ICO中有好几个大小和颜色不同的ICO。这里就是可以输入数字制定）</p>
<hr /><h4>相关文章：</h4><ul><li><a  href="http://firefore.com/2011/02/tsmmc.html" rel="bookmark" title="Permanent Link: Tsmmc">Tsmmc</a></li><li><a  href="http://firefore.com/2009/09/installing-eaccelerator-in-ubuntu-server.html" rel="bookmark" title="Permanent Link: ubuntu安装eAccelerator">ubuntu安装eAccelerator</a></li><li><a  href="http://firefore.com/2010/01/ubuntu9-10-eaccelerator.html" rel="bookmark" title="Permanent Link: ubuntu9.10下的eAccelerator">ubuntu9.10下的eAccelerator</a></li></ul><hr /><small><p>&#26412;&#20316;&#21697;&#30001;<a  0="xmlns:cc="http://creativecommons.org/ns#"" href="http://firefore.com" property="cc:attributionName" rel="cc:attributionURL">shiweiyu</a>&#21019;&#20316;&#65292;&#37319;&#29992;<a  rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/">&#30693;&#35782;&#20849;&#20139;&#32626;&#21517;-&#30456;&#21516;&#26041;&#24335;&#20849;&#20139; 3.0 Unported&#35768;&#21487;&#21327;&#35758;</a>&#36827;&#34892;&#35768;&#21487;&#12290;<br />
Copyright &copy; 2010 <a  href="http://firefore.com">FireFore.com</a> (数字指纹： woaiwojia_weiyu (38.107.179.213) )</small></p>]]></content:encoded>
			<wfw:commentRss>http://firefore.com/2007/12/install-shield-115-uninstall-shortcuts.html/feed</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>让PHP不再暴露目录路径&#8230;釜底抽薪招 &gt;.</title>
		<link>http://firefore.com/2007/12/php-display_errors-off.html</link>
		<comments>http://firefore.com/2007/12/php-display_errors-off.html#comments</comments>
		<pubDate>Fri, 14 Dec 2007 02:07:54 +0000</pubDate>
		<dc:creator>FireFore</dc:creator>
				<category><![CDATA[学习笔记]]></category>
		<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://firefore.com/2007/12/php-display_errors-off.html</guid>
		<description><![CDATA[方法就是：关闭掉PHP的错误信息提示。 打开PHP.ini后。 搜索到 display_errors = On(默认是开启状态) 我们修改为 display_errors = Off 这样就关闭了错误信息的提示了。 但是这样一来，有什么错误我们也... ]]></description>
			<content:encoded><![CDATA[<p>方法就是：关闭掉<span class='wp_keywordlink_affiliate'><a href="http://firefore.com/bq/php" title="查看 PHP 中的全部文章" target="_blank">PHP</a></span>的错误信息提示。<br />
打开<span class='wp_keywordlink_affiliate'><a href="http://firefore.com/bq/php" title="查看 PHP 中的全部文章" target="_blank">PHP</a></span>.ini后。<br />
搜索到<br />
<coolcode linenum="off">display_errors = On</coolcode>(默认是开启状态)<br />
我们修改为<br />
<coolcode linenum="off">display_errors = Off</coolcode><br />
这样就关闭了错误信息的提示了。</p>
<p>但是这样一来，有什么错误我们也不知道呀。所以，我们需要起用错误日志功能。<br />
继续搜索<span id="more-105"></span><br />
<coolcode linenum="off">log_errors = Off</coolcode>(次状态是未开启错误日志功能，如果您搜索到的是 log_errors = On 那就可以跳过这步骤了。)<br />
然后修改为<br />
<coolcode linenum="off">log_errors = On</coolcode></p>
<p>接下来就是设置日志的存放地方。<br />
搜索<br />
<coolcode linenum="off">error_log =</coolcode><br />
后可以看到类似下面的<br />
<coolcode linenum="off">;error_log = “XXXXXX”</coolcode>（XXXXX修改为日志的存放目录就行了。但是千万记得要有写入的权限。）<br />
前面的;记得要去掉哦。这个符号去掉了就启用了的意思。</p>
<p>哦，还有，修改保存之后要重新启动WEB服务才有效。</p>
<p><strong>修改<span class='wp_keywordlink_affiliate'><a href="http://firefore.com/bq/php" title="查看 PHP 中的全部文章" target="_blank">PHP</a></span>.ini我个人强烈推荐一个超级文本编辑器：<a  href="http://notepad-plus.sourceforge.net/" target="_blank">Notepad++</a> 看看准没错拉~~</strong></p>
<hr /><small><p>&#26412;&#20316;&#21697;&#30001;<a  0="xmlns:cc="http://creativecommons.org/ns#"" href="http://firefore.com" property="cc:attributionName" rel="cc:attributionURL">shiweiyu</a>&#21019;&#20316;&#65292;&#37319;&#29992;<a  rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/">&#30693;&#35782;&#20849;&#20139;&#32626;&#21517;-&#30456;&#21516;&#26041;&#24335;&#20849;&#20139; 3.0 Unported&#35768;&#21487;&#21327;&#35758;</a>&#36827;&#34892;&#35768;&#21487;&#12290;<br />
Copyright &copy; 2010 <a  href="http://firefore.com">FireFore.com</a> (数字指纹： woaiwojia_weiyu (38.107.179.213) )</small></p>]]></content:encoded>
			<wfw:commentRss>http://firefore.com/2007/12/php-display_errors-off.html/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>用Windows自带的工具强制杀死进程</title>
		<link>http://firefore.com/2007/12/ntsd-tasklist-tskill.html</link>
		<comments>http://firefore.com/2007/12/ntsd-tasklist-tskill.html#comments</comments>
		<pubDate>Tue, 11 Dec 2007 17:38:07 +0000</pubDate>
		<dc:creator>FireFore</dc:creator>
				<category><![CDATA[学习笔记]]></category>
		<category><![CDATA[Windows]]></category>

		<guid isPermaLink="false">http://firefore.com/2007/12/ntsd-tasklist-tskill.html</guid>
		<description><![CDATA[相信很多朋友都有碰到一些奇怪的进程。 在任务管理器里面一直无法关闭它。 针对这些进程，很多朋友选择安装某些软件来进行管理。这里我们说说Windows 2000就开始自带的一个工具：ntsd 用法... ]]></description>
			<content:encoded><![CDATA[<p>相信很多朋友都有碰到一些奇怪的进程。<br />
在任务管理器里面一直无法关闭它。<br />
针对这些进程，很多朋友选择安装某些软件来进行管理。这里我们说说<a  href="http://www.microsoft.com/windows/default.mspx" target="_blank">Windows 2000</a>就开始自带的一个工具：<strong>ntsd</strong><br />
用法是：开始-》运行-》输入cmd-》回车-》</p>

<div class="wp_syntax"><div class="code"><pre class="dos" style="font-family:monospace;">ntsd -c q -p PID</pre></div></div>

<p>这个命令几乎可以杀死所有进程，只有<a  href="http://baike.baidu.com/view/627587.htm" target="_blank">System</a>、<a  href="http://baike.baidu.com/view/9378.htm" target="_blank">SMSS.EXE</a>和<a  href="http://baike.baidu.com/view/29432.htm" target="_blank">CSRSS.EXE</a>不能杀。</p>
<p>实际使用的时候，<span id="more-99"></span>要把最后的PID修改为要杀死的进程的PID。<br />
一般默认的任务管理器是没有显示PID的。怎么让它显示出来？简单。<br />
任务管理器-》查看-》选择列-》把PID(进程标识符) 打勾 -》按确定即可。（以上是<a  href="http://www.microsoft.com/windows/products/windowsxp/default.mspx" target="_blank">windownsXP</a>下的，各个版本的<span class='wp_keywordlink_affiliate'><a href="http://firefore.com/bq/windows" title="查看 Windows 中的全部文章" target="_blank">Windows</a></span>可能有所不同）<br />
&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;<br />
如果您在winxp下。那么更方便。<a  href="http://www.microsoft.com/windows/products/windowsxp/default.mspx" target="_blank">windowsXP</a>自带两个小程序：<strong>tasklist</strong>和<strong>tskill</strong><br />
用法也是在cmd.exe下<br />
先用</p>

<div class="wp_syntax"><div class="code"><pre class="dos" style="font-family:monospace;">tasklist</pre></div></div>

<p>会列出目前的所有进程<br />
再用</p>

<div class="wp_syntax"><div class="code"><pre class="dos" style="font-family:monospace;">tskill 进程名</pre></div></div>

<p>来杀进程</p>
<p>至于这些命令的其他说明，可以上<a  href="http://www.baidu.com" target="_blank">百度</a>或是<a  href="http://www.google.com" target="_blank">Google</a>搜索一下。</p>
<hr /><small><p>&#26412;&#20316;&#21697;&#30001;<a  0="xmlns:cc="http://creativecommons.org/ns#"" href="http://firefore.com" property="cc:attributionName" rel="cc:attributionURL">shiweiyu</a>&#21019;&#20316;&#65292;&#37319;&#29992;<a  rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/">&#30693;&#35782;&#20849;&#20139;&#32626;&#21517;-&#30456;&#21516;&#26041;&#24335;&#20849;&#20139; 3.0 Unported&#35768;&#21487;&#21327;&#35758;</a>&#36827;&#34892;&#35768;&#21487;&#12290;<br />
Copyright &copy; 2010 <a  href="http://firefore.com">FireFore.com</a> (数字指纹： woaiwojia_weiyu (38.107.179.213) )</small></p>]]></content:encoded>
			<wfw:commentRss>http://firefore.com/2007/12/ntsd-tasklist-tskill.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>windows下mysqladmin设置mysql初始密码</title>
		<link>http://firefore.com/2007/12/mysqladmin-change-password.html</link>
		<comments>http://firefore.com/2007/12/mysqladmin-change-password.html#comments</comments>
		<pubDate>Wed, 05 Dec 2007 04:37:20 +0000</pubDate>
		<dc:creator>FireFore</dc:creator>
				<category><![CDATA[学习笔记]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[Windows]]></category>

		<guid isPermaLink="false">http://firefore.com/2007/12/mysqladmin-change-password.html</guid>
		<description><![CDATA[mysqladmin -uroot password &#34;newpassword&#34; 以上是WINDOWS下的方法,注意要使用双引号.WINDOWS下会把单引号也认定为密码的一部分哦. 相关文章：5月9号近期内有空打算再换个主题league of legends OB 账号注... ]]></description>
			<content:encoded><![CDATA[
<div class="wp_syntax"><div class="code"><pre class="mysql" style="font-family:monospace;">mysqladmin <span style="color: #CC0099;">-</span>uroot <span style="color: #000099;">password</span> <span style="color: #008000;">&quot;newpassword&quot;</span></pre></div></div>

<p>以上是WINDOWS下的方法,注意要使用双引号.WINDOWS下会把单引号也认定为密码的一部分哦.</p>
<hr /><h4>相关文章：</h4><ul><li><a  href="http://firefore.com/2011/05/on-may-9.html" rel="bookmark" title="Permanent Link: 5月9号">5月9号</a></li><li><a  href="http://firefore.com/2008/01/change-theme.html" rel="bookmark" title="Permanent Link: 近期内有空打算再换个主题">近期内有空打算再换个主题</a></li><li><a  href="http://firefore.com/2009/10/league-of-legends-open-beta-account-registration-guide.html" rel="bookmark" title="Permanent Link: league of legends OB 账号注册指南">league of legends OB 账号注册指南</a></li></ul><hr /><small><p>&#26412;&#20316;&#21697;&#30001;<a  0="xmlns:cc="http://creativecommons.org/ns#"" href="http://firefore.com" property="cc:attributionName" rel="cc:attributionURL">shiweiyu</a>&#21019;&#20316;&#65292;&#37319;&#29992;<a  rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/">&#30693;&#35782;&#20849;&#20139;&#32626;&#21517;-&#30456;&#21516;&#26041;&#24335;&#20849;&#20139; 3.0 Unported&#35768;&#21487;&#21327;&#35758;</a>&#36827;&#34892;&#35768;&#21487;&#12290;<br />
Copyright &copy; 2010 <a  href="http://firefore.com">FireFore.com</a> (数字指纹： woaiwojia_weiyu (38.107.179.213) )</small></p>]]></content:encoded>
			<wfw:commentRss>http://firefore.com/2007/12/mysqladmin-change-password.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>SQL 2000删除和恢复危险存储过程的语句</title>
		<link>http://firefore.com/2007/11/sql2000-security.html</link>
		<comments>http://firefore.com/2007/11/sql2000-security.html#comments</comments>
		<pubDate>Fri, 30 Nov 2007 04:42:26 +0000</pubDate>
		<dc:creator>FireFore</dc:creator>
				<category><![CDATA[学习笔记]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[Windows]]></category>

		<guid isPermaLink="false">http://firefore.com/2007/11/sql2000-security.html</guid>
		<description><![CDATA[首先，这篇是我从网路上拷贝来的。具体的出处也找不到了。所以，在这里只好对不起作者了。没署上您的名字 &#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212; 删除... ]]></description>
			<content:encoded><![CDATA[<p>首先，这篇是我从网路上拷贝来的。具体的出处也找不到了。所以，在这里只好对不起作者了。没署上您的名字<br />
&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;<br />
删除的语句：</p>

<div class="wp_syntax"><div class="code"><pre class="sql" style="font-family:monospace;"><span style="color: #993333; font-weight: bold;">USE</span> master
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_dropextendedproc <span style="color: #ff0000;">'xp_cmdshell'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_dropextendedproc <span style="color: #ff0000;">'xp_dirtree'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_dropextendedproc <span style="color: #ff0000;">'xp_enumgroups'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_dropextendedproc <span style="color: #ff0000;">'xp_fixeddrives'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_dropextendedproc <span style="color: #ff0000;">'xp_loginconfig'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_dropextendedproc <span style="color: #ff0000;">'xp_enumerrorlogs'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_dropextendedproc <span style="color: #ff0000;">'xp_getfiledetails'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_dropextendedproc <span style="color: #ff0000;">'Sp_OACreate'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_dropextendedproc <span style="color: #ff0000;">'Sp_OADestroy'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_dropextendedproc <span style="color: #ff0000;">'Sp_OAGetErrorInfo'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_dropextendedproc <span style="color: #ff0000;">'Sp_OAGetProperty'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_dropextendedproc <span style="color: #ff0000;">'Sp_OAMethod'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_dropextendedproc <span style="color: #ff0000;">'Sp_OASetProperty'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_dropextendedproc <span style="color: #ff0000;">'Sp_OAStop'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_dropextendedproc <span style="color: #ff0000;">'Xp_regaddmultistring'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_dropextendedproc <span style="color: #ff0000;">'Xp_regdeletekey'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_dropextendedproc <span style="color: #ff0000;">'Xp_regdeletevalue'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_dropextendedproc <span style="color: #ff0000;">'Xp_regenumvalues'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_dropextendedproc <span style="color: #ff0000;">'Xp_regread'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_dropextendedproc <span style="color: #ff0000;">'Xp_regremovemultistring'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_dropextendedproc <span style="color: #ff0000;">'Xp_regwrite'</span>
 <span style="color: #993333; font-weight: bold;">DROP</span> <span style="color: #993333; font-weight: bold;">PROCEDURE</span> sp_makewebtask
 <span style="color: #993333; font-weight: bold;">GO</span></pre></div></div>

<p>&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;-<br />
恢复以上删除的语句</p>

<div class="wp_syntax"><div class="code"><pre class="sql" style="font-family:monospace;"><span style="color: #993333; font-weight: bold;">USE</span> master
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_addextendedproc xp_cmdshell<span style="color: #66cc66;">,</span><span style="color: #ff0000;">'xp_cmdshell.dll'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_addextendedproc xp_dirtree<span style="color: #66cc66;">,</span><span style="color: #ff0000;">'xpstar.dll'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_addextendedproc xp_enumgroups<span style="color: #66cc66;">,</span><span style="color: #ff0000;">'xplog70.dll'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_addextendedproc xp_fixeddrives<span style="color: #66cc66;">,</span><span style="color: #ff0000;">'xpstar.dll'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_addextendedproc xp_loginconfig<span style="color: #66cc66;">,</span><span style="color: #ff0000;">'xplog70.dll'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_addextendedproc xp_enumerrorlogs<span style="color: #66cc66;">,</span><span style="color: #ff0000;">'xpstar.dll'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_addextendedproc xp_getfiledetails<span style="color: #66cc66;">,</span><span style="color: #ff0000;">'xpstar.dll'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_addextendedproc sp_OACreate<span style="color: #66cc66;">,</span><span style="color: #ff0000;">'odsole70.dll'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_addextendedproc sp_OADestroy<span style="color: #66cc66;">,</span><span style="color: #ff0000;">'odsole70.dll'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_addextendedproc sp_OAGetErrorInfo<span style="color: #66cc66;">,</span><span style="color: #ff0000;">'odsole70.dll'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_addextendedproc sp_OAGetProperty<span style="color: #66cc66;">,</span><span style="color: #ff0000;">'odsole70.dll'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_addextendedproc sp_OAMethod<span style="color: #66cc66;">,</span><span style="color: #ff0000;">'odsole70.dll'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_addextendedproc sp_OASetProperty<span style="color: #66cc66;">,</span><span style="color: #ff0000;">'odsole70.dll'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_addextendedproc sp_OAStop<span style="color: #66cc66;">,</span><span style="color: #ff0000;">'odsole70.dll'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_addextendedproc xp_regaddmultistring<span style="color: #66cc66;">,</span><span style="color: #ff0000;">'xpstar.dll'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_addextendedproc xp_regdeletekey<span style="color: #66cc66;">,</span><span style="color: #ff0000;">'xpstar.dll'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_addextendedproc xp_regdeletevalue<span style="color: #66cc66;">,</span><span style="color: #ff0000;">'xpstar.dll'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_addextendedproc xp_regenumvalues<span style="color: #66cc66;">,</span><span style="color: #ff0000;">'xpstar.dll'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_addextendedproc xp_regread<span style="color: #66cc66;">,</span><span style="color: #ff0000;">'xpstar.dll'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_addextendedproc xp_regremovemultistring<span style="color: #66cc66;">,</span><span style="color: #ff0000;">'xpstar.dll'</span>
 <span style="color: #993333; font-weight: bold;">EXEC</span> sp_addextendedproc xp_regwrite<span style="color: #66cc66;">,</span><span style="color: #ff0000;">'xpstar.dll'</span></pre></div></div>

<hr /><h4>相关文章：</h4><ul><li><a  href="http://firefore.com/2009/10/league-of-legends-open-beta-account-registration-guide.html" rel="bookmark" title="Permanent Link: league of legends OB 账号注册指南">league of legends OB 账号注册指南</a></li></ul><hr /><small><p>&#26412;&#20316;&#21697;&#30001;<a  0="xmlns:cc="http://creativecommons.org/ns#"" href="http://firefore.com" property="cc:attributionName" rel="cc:attributionURL">shiweiyu</a>&#21019;&#20316;&#65292;&#37319;&#29992;<a  rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/">&#30693;&#35782;&#20849;&#20139;&#32626;&#21517;-&#30456;&#21516;&#26041;&#24335;&#20849;&#20139; 3.0 Unported&#35768;&#21487;&#21327;&#35758;</a>&#36827;&#34892;&#35768;&#21487;&#12290;<br />
Copyright &copy; 2010 <a  href="http://firefore.com">FireFore.com</a> (数字指纹： woaiwojia_weiyu (38.107.179.213) )</small></p>]]></content:encoded>
			<wfw:commentRss>http://firefore.com/2007/11/sql2000-security.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>怎么查看SQL SERVER 2000是否打过SP4的补丁</title>
		<link>http://firefore.com/2007/11/sql-server-2000-version.html</link>
		<comments>http://firefore.com/2007/11/sql-server-2000-version.html#comments</comments>
		<pubDate>Wed, 28 Nov 2007 02:02:16 +0000</pubDate>
		<dc:creator>FireFore</dc:creator>
				<category><![CDATA[学习笔记]]></category>
		<category><![CDATA[Microsoft]]></category>
		<category><![CDATA[SQL]]></category>

		<guid isPermaLink="false">http://firefore.com/2007/11/sql-server-2000-version.html</guid>
		<description><![CDATA[其实只要查询版本号就知道。 在查询分析器中输入 SELECT @@version 如果是安装过SP4的补丁。应该是下面的信息： Microsoft SQL Server 2000 &#8211; 8.00.2039 其他版本信息如下 6.50.201 SQL Server 6.5 RTM 6.50.213 SQ... ]]></description>
			<content:encoded><![CDATA[<p>其实只要查询版本号就知道。<br />
在查询分析器中输入</p>

<div class="wp_syntax"><div class="code"><pre class="sql" style="font-family:monospace;"><span style="color: #993333; font-weight: bold;">SELECT</span>   @@version</pre></div></div>

<p>如果是安装过<a  href="http://www.microsoft.com/downloads/details.aspx?FamilyID=8e2dfc8d-c20e-4446-99a9-b7f0213f8bc5&#038;DisplayLang=zh-cn" target="_blank">SP4</a>的补丁。应该是下面的信息：</p>
<p><strong><span class='wp_keywordlink_affiliate'><a href="http://firefore.com/bq/microsoft" title="查看 Microsoft 中的全部文章" target="_blank">Microsoft</a></span> <span class='wp_keywordlink_affiliate'><a href="http://firefore.com/bq/sql" title="查看 SQL 中的全部文章" target="_blank">SQL</a></span> Server  2000 &#8211; 8.00.2039</strong></p>
<p>其他版本信息如下</p>

<div class="wp_syntax"><div class="code"><pre class="text" style="font-family:monospace;">6.50.201 SQL Server 6.5 RTM
6.50.213 SQL Server 6.5 with Service Pack 1
6.50.240 SQL Server 6.5 with Service Pack 2
6.50.258 SQL Server 6.5 with Service Pack 3
6.50.281 SQL Server 6.5 with Service Pack 4
6.50.415 SQL Server 6.5 with Service Pack 5
6.50.416 SQL Server 6.5 with Service Pack 5a
7.00.623 SQL Server 7.0 / MSDE 1.0 RTM
7.00.699 SQL Server 7.0 SP1 July 1999
7.00.842 SQL Server 7.0 SP2 March 20th, 2000
7.00.961 SQL Server 7.0 SP3 December 15th, 2000
7.00.1063 SQL Server 7.0 SP4
8.00.194 SQL Server 2000 RTM
8.00.384 SQL Server 2000 SP1
8.00.534 SQL Server 2000 SP2 November 30th, 2001
8.00.760 SQL Server 2000 SP3
8.00.2039 SQL Server 2000 SP4</pre></div></div>

<hr /><h4>相关文章：</h4><ul><li><a  href="http://firefore.com/2007/12/onlinegame-server-requirement.html" rel="bookmark" title="Permanent Link: 浅谈我接触过的网络游戏的服务器需求">浅谈我接触过的网络游戏的服务器需求</a></li><li><a  href="http://firefore.com/2010/01/ubuntu9-10-eaccelerator.html" rel="bookmark" title="Permanent Link: ubuntu9.10下的eAccelerator">ubuntu9.10下的eAccelerator</a></li><li><a  href="http://firefore.com/2011/02/tsmmc.html" rel="bookmark" title="Permanent Link: Tsmmc">Tsmmc</a></li></ul><hr /><small><p>&#26412;&#20316;&#21697;&#30001;<a  0="xmlns:cc="http://creativecommons.org/ns#"" href="http://firefore.com" property="cc:attributionName" rel="cc:attributionURL">shiweiyu</a>&#21019;&#20316;&#65292;&#37319;&#29992;<a  rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/">&#30693;&#35782;&#20849;&#20139;&#32626;&#21517;-&#30456;&#21516;&#26041;&#24335;&#20849;&#20139; 3.0 Unported&#35768;&#21487;&#21327;&#35758;</a>&#36827;&#34892;&#35768;&#21487;&#12290;<br />
Copyright &copy; 2010 <a  href="http://firefore.com">FireFore.com</a> (数字指纹： woaiwojia_weiyu (38.107.179.213) )</small></p>]]></content:encoded>
			<wfw:commentRss>http://firefore.com/2007/11/sql-server-2000-version.html/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>

