<?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>Na-ga.net</title>
	<atom:link href="http://na-ga.net/blog/?feed=rss2" rel="self" type="application/rss+xml" />
	<link>http://na-ga.net/blog</link>
	<description>Linux を中心とした忘却メモ</description>
	<lastBuildDate>Wed, 23 Dec 2009 15:39:43 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</generator>
	<language>ja</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>都内での賃貸探しにおける注意点</title>
		<link>http://na-ga.net/blog/?p=614</link>
		<comments>http://na-ga.net/blog/?p=614#comments</comments>
		<pubDate>Wed, 23 Dec 2009 15:04:15 +0000</pubDate>
		<dc:creator>na-ga</dc:creator>
				<category><![CDATA[Diary]]></category>

		<guid isPermaLink="false">http://na-ga.net/blog/?p=614</guid>
		<description><![CDATA[やっと引越し先が決まりました。本当に色々あって、1 日で終わらせる予定が 5 日もかかってしまった。しかし、最終的に満足の行く新居を見つけることができ、色々と知識がついた。妥協せずに探し続けてよかったと思う。今回の経験でわかった事を書きます。

インターネットの賃貸情報は、見る価値ない
インターネトの賃貸情報サイト HOME&#8217;S や CHINTAI などに転載されている情報は見る価値はない。ここに載っている情報は、「人気がなくて載せている」 または 「いわいる囮広告 (=客付業者の客寄せ) 」です。本当に人気がある情報は、載せなくてもすぐに埋まります。
その地区から勤務先までの移動ルート・距離を調べるのには良いですが、ここに載っている情報を印刷して不動産に持っていくと、「すでに契約者がいる」 または 「実はいわくつき物件で･･･」など、他の物件を強引に勧められる可能性が高い。インターネットの賃貸情報を調べるよりも、実際に不動産に行く方が早い。
不動産の免許番号に注目する
不動産は、国土交通大臣 (1) 第 ○○○○○ 号、国土交通大臣 (10) 第 ○○○○○ 号など免許を取得してます。この括弧内の数字が大きければ大きいほど長くやっている不動産です。この免許番号は、現在は5年間ごとに1つ増えます。(1996年以前は3年間ごとに更新) つまり、(1) の場合は 5 年間未満に設立した不動産で、(10) の場合、約 40 年間 (5*3+3*7=38) やっている不動産です。
この免許番号が (1), (2) &#8230; とかは論外で、できれば (8), (10) などの不動産でお世話になるのが絶対に良い。良い物件を見つけても、(1), (2) の場合、囮広告である可能性が高い。
客付と元付の違いを理解する
賃貸物件のオーナーから直接頼まれている不動産 (=管理業者) が元付業者で、元付業者にその物件に入りたい客を紹介するのが客付業者と言う。元付業者で契約すると、仲介手数料が安くなる場合がある。しかし、管理専門でやっている業者の場合、元付業者では直接の契約を行わず、客付業者経由で契約を行うように言われる場合もある。
どちらにせよ、完全に客付しか行っていない (自分で管理している物件がない) 不動産の場合は、注意が必要である。客付業者は、客を紹介すること利益を出しているが、礼金を本来よりも上乗せしている場合や、自分への利益が多い物件しか紹介しないなど、必ず良い結果にはならない。
住む地区を検討しなおす
引っ越し貧乏と言う言葉もあるが、一度引越ししたら、できれば長くそこに住みたいと思う。繁華街に住めば、乗り換えもなく、種菌時間も短い、また遊びに行くのも良いなど利点はあると思う。もちろん人気があるので家賃が高くなる。けど、その一方、犯罪が多いと言うデメリットを理解するべきである。これは、警視庁が公開している犯罪マップを見ることをお勧めする。
これを見ると、やはり山手線沿いは、ほとんどが赤くなっており、長く住む場所としては適切ではない。1,2 本離れている地域でも中々厳しく、少し離れている場合でも快速が止まる駅は赤くなっている。お薦めは、都内に住みたい場合は快速が止まる駅の 1 本ずらした駅で、少し離れても良いなら埼玉県や、神奈川県などである。自分の場合は通勤時間は短くしたかったので、最終的に練馬区で決めた。住む予定の地域は、本当に長く住むことが出来るかを一度確認した方が良い。
地域密着型の不動産にお世話になる
基本的に山手線沿いの駅前に構えている不動産は避けた方がいい。免許番号が小さく、駅前に構えている不動産は、完全に客付けのみで、強引に契約を勧められることがある。また、大手チェーン店などは、月々のノルマがあり、どうしても契約させようという行動が出てしまう。不動産名でインターネットで検索すると、案外評判が出てくることがある。信憑性は分からないが、火の無い所に煙は立たないとも言うので、気になる書き込みがあれば避けた方が無難だろう。サービス業なので、対応が悪い不動産というのは絶対にありえない。少しでもそう感じた場合は、時間の無駄なので出た方が良い。
そのため、地域密着型の不動産にお世話になる方が良い。免許番号が大きく、対応が良い不動産は間違いない。住みたい地域の不動産情報を HOME&#8217;S (不動産を探すのには非常に便利) で検索し、免許番号の大きい順に並び替えて、インターネットで評判を調べ、2～3 件回るのが良いだろう。余談ではあるが、お互いに違う不動産を紹介しあってる所は間違いないだろう。自分の場合、最初免許番号 (10) の A 不動産で物件を探し、次に [...]]]></description>
			<content:encoded><![CDATA[<p>やっと引越し先が決まりました。本当に色々あって、1 日で終わらせる予定が 5 日もかかってしまった。しかし、最終的に満足の行く新居を見つけることができ、色々と知識がついた。妥協せずに探し続けてよかったと思う。今回の経験でわかった事を書きます。<br />
<span id="more-614"></span></p>
<h3 class="subtitle">インターネットの賃貸情報は、見る価値ない</h3>
<p>インターネトの賃貸情報サイト HOME&#8217;S や CHINTAI などに転載されている情報は見る価値はない。ここに載っている情報は、「人気がなくて載せている」 または 「いわいる囮広告 (=客付業者の客寄せ) 」です。本当に人気がある情報は、載せなくてもすぐに埋まります。</p>
<p>その地区から勤務先までの移動ルート・距離を調べるのには良いですが、ここに載っている情報を印刷して不動産に持っていくと、「すでに契約者がいる」 または 「実はいわくつき物件で･･･」など、他の物件を強引に勧められる可能性が高い。インターネットの賃貸情報を調べるよりも、実際に不動産に行く方が早い。</p>
<h3 class="subtitle">不動産の免許番号に注目する</h3>
<p>不動産は、国土交通大臣 (1) 第 ○○○○○ 号、国土交通大臣 (10) 第 ○○○○○ 号など免許を取得してます。この括弧内の数字が大きければ大きいほど長くやっている不動産です。この免許番号は、現在は5年間ごとに1つ増えます。(1996年以前は3年間ごとに更新) つまり、(1) の場合は 5 年間未満に設立した不動産で、(10) の場合、約 40 年間 (5*3+3*7=38) やっている不動産です。</p>
<p>この免許番号が (1), (2) &#8230; とかは論外で、できれば (8), (10) などの不動産でお世話になるのが絶対に良い。良い物件を見つけても、(1), (2) の場合、囮広告である可能性が高い。</p>
<h3 class="subtitle">客付と元付の違いを理解する</h3>
<p>賃貸物件のオーナーから直接頼まれている不動産 (=管理業者) が元付業者で、元付業者にその物件に入りたい客を紹介するのが客付業者と言う。元付業者で契約すると、仲介手数料が安くなる場合がある。しかし、管理専門でやっている業者の場合、元付業者では直接の契約を行わず、客付業者経由で契約を行うように言われる場合もある。</p>
<p>どちらにせよ、完全に客付しか行っていない (自分で管理している物件がない) 不動産の場合は、注意が必要である。客付業者は、客を紹介すること利益を出しているが、礼金を本来よりも上乗せしている場合や、自分への利益が多い物件しか紹介しないなど、必ず良い結果にはならない。</p>
<h3 class="subtitle">住む地区を検討しなおす</h3>
<p>引っ越し貧乏と言う言葉もあるが、一度引越ししたら、できれば長くそこに住みたいと思う。繁華街に住めば、乗り換えもなく、種菌時間も短い、また遊びに行くのも良いなど利点はあると思う。もちろん人気があるので家賃が高くなる。けど、その一方、犯罪が多いと言うデメリットを理解するべきである。これは、警視庁が公開している<a href="http://www.keishicho.metro.tokyo.jp/toukei/yokushi/yokushi.htm">犯罪マップ</a>を見ることをお勧めする。</p>
<p>これを見ると、やはり山手線沿いは、ほとんどが赤くなっており、長く住む場所としては適切ではない。1,2 本離れている地域でも中々厳しく、少し離れている場合でも快速が止まる駅は赤くなっている。お薦めは、都内に住みたい場合は快速が止まる駅の 1 本ずらした駅で、少し離れても良いなら埼玉県や、神奈川県などである。自分の場合は通勤時間は短くしたかったので、最終的に練馬区で決めた。住む予定の地域は、本当に長く住むことが出来るかを一度確認した方が良い。</p>
<h3 class="subtitle">地域密着型の不動産にお世話になる</h3>
<p>基本的に山手線沿いの駅前に構えている不動産は避けた方がいい。免許番号が小さく、駅前に構えている不動産は、完全に客付けのみで、強引に契約を勧められることがある。また、大手チェーン店などは、月々のノルマがあり、どうしても契約させようという行動が出てしまう。不動産名でインターネットで検索すると、案外評判が出てくることがある。信憑性は分からないが、火の無い所に煙は立たないとも言うので、気になる書き込みがあれば避けた方が無難だろう。サービス業なので、対応が悪い不動産というのは絶対にありえない。少しでもそう感じた場合は、時間の無駄なので出た方が良い。</p>
<p>そのため、地域密着型の不動産にお世話になる方が良い。免許番号が大きく、対応が良い不動産は間違いない。住みたい地域の不動産情報を HOME&#8217;S (不動産を探すのには非常に便利) で検索し、免許番号の大きい順に並び替えて、インターネットで評判を調べ、2～3 件回るのが良いだろう。余談ではあるが、お互いに違う不動産を紹介しあってる所は間違いないだろう。自分の場合、最初免許番号 (10) の A 不動産で物件を探し、次に 免許番号 (8) の B 不動産に行く予定だったが、A 不動産の担当者に、「これよりも良い物件があるか B 不動産に行くと良いよ」と言われた経験がある。地域密着型の不動産は、その地域で長くやっているのでお互いに仲が良いことが多い。</p>
<h3 class="subtitle">朝・昼・夜と 3 回見に行く</h3>
<p>間取りだけで判断してはいけない。もちろん内見は必ずした方が良いが、できれば朝・昼・夜と 3 回見に行ったほうが良い。通勤時間帯の朝・夜は目の前の道路が抜け道になっていて非常にうるさいなど･･･一度見ただけでは分からない事がたくさんある。</p>
<p>あと、日当たりも見たほうがよい。日当たりが悪い部屋は、できれば避けたほうが良い. 隣が駐車場の場合は、今後、マンションが建設される予定がすでに分かる場合もあるので、確認したほうが良い. 個人的に気にする点は、ゴミ捨て場の位置と、街灯・木の高さだ。ゴミ捨て場に近い 1 階は、ゴキブリが多い場合がある。2 階の場合は、窓を開けるとすぐに街灯がある場合は夜に虫が入ってくる場合がある。また、近くに公園がある場合は、木の高さや、夜間のバーベキューや花火を禁止しているかなどを注意したほうが良い.</p>
<h3 class="subtitle">賃貸物件の管理会社を調べる</h3>
<p>良い物件が見つかり、いざ契約となる前に、その物件の管理会社の評判を調べた方が良い。今契約しようとしている業者が元付業者 (=管理会社) である場合は問題ないが、ほとんどの場合は仲介契約になると思う。その物件に住み、実際に今後お世話になるのは管理会社である。</p>
<p>インターネットで情報を検索し、退去時の敷金を過剰請求されたなど、電話の対応が悪いなど、そのような評判が出てくる場合は、どんなに良い物件でも辞めた方が良い。事故物件ではないが、ある意味「いわく付き物件」ではないだろうか。一度良い物件候補を見つけたが、管理会社の評判が悪くて選択肢から外した経験がある。</p>
<h3 class="subtitle">契約する時期</h3>
<p>不動産は、一般的に 1～3 月が一番忙しく、この時期に行くと、ゆっくり物件を探すことが出来ない。人気物件は一瞬で埋まり、人気があまりない物件でも埋まっていく。この時期を過ぎる 4～6月は、今後も誰も契約せずに空き物件になる可能性が高いので、値段交渉がしやすい。しかし、一番忙しい時期に誰も入らなかった物件は、なにか理由がある場合が多い。6～12 月頃は、物件の数は少ないが、掘り出し物が多い。値段交渉もしやすく、一番良い時期ではないだろうか。</p>
<p>悪徳不動産の場合、11,12月頃に物件を探していると、「1～3月になると、大家さんも強気になって家賃を上げる事があります、今が契約するチャンスですよ」 と言う場合がある。しかし、これは早く契約させるための大嘘である。忙しくなるのは確かだが、大家さんが家賃を上げることは無いと思って良い。あえて言うなら、値引き交渉がしにくい時期である。</p>
<h3 class="subtitle">申込書を書いた後の値引交渉</h3>
<p>最後に値引交渉だが、行わない人が結構多くて驚いているのだが、必ずした方が良い。契約する時期にもよるが、5000円引きになる可能性もある。かなりの人気物件でない限り、1000～2000円の値引きが成功する可能性は高い。2年間で考えると、5000 円の場合 12万円、2000円の場合、約 5 万円が浮く計算になる。また、元付け業者の場合は、必ず仲介手数料を交渉するべきである。元付業者にとって、仲介手数料は、客付業者経由での契約の場合は入ってこないお金なので、結構高い可能性で交渉できる。</p>
<p>値引交渉のタイミングだが、担当者と仲良くなり、いよいよ申込という段階で行うのが良い。大家さんから見ても、どのような人が入ってくるのか分からないのに、値引きをするわけにはいかない。すべては担当者にかかっているので、担当者と仲良くなり、申込書類をかき、本当に最後にお願いしてみると成功する可能性は高いと思う。</p>
<p>番外編として、申込書を書く前に、担当者の方から値引きの話をしてくる場合もある。これは免許番号が小さい不動産に多く、実は、最初に間取り図を見せてもらう段階で既に家賃が釣り上げられている可能性がある。そして値引交渉できました～と言い、実際は本当に家賃になっただけ･･･という。悪徳不動産には要注意だ。</p>
<h3 class="subtitle">まとめ</h3>
<p>経験談も含めて書いたので長くなってしまったが、重要な点は次の3点だ。</p>
<ul>
<li>免許番号が大きい、地域密着型の不動産にお世話になる。</li>
<li>犯罪マップで、その地域に長く住むことができるかを調べる。</li>
<li>値引交渉は、担当者と仲良くなり、申込書を書いた後で丁寧にお願いする。</li>
</ul>
<p>あまり構成を考えずに書いてしまったので、そのうち書きなおすと思う。読みにくくて申し訳ないが、良い物件を見つけるために参考になれば幸いです。</p>
]]></content:encoded>
			<wfw:commentRss>http://na-ga.net/blog/?feed=rss2&amp;p=614</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>MySQL の操作</title>
		<link>http://na-ga.net/blog/?p=611</link>
		<comments>http://na-ga.net/blog/?p=611#comments</comments>
		<pubDate>Fri, 04 Dec 2009 05:31:28 +0000</pubDate>
		<dc:creator>na-ga</dc:creator>
				<category><![CDATA[MySQL]]></category>

		<guid isPermaLink="false">http://na-ga.net/blog/?p=611</guid>
		<description><![CDATA[いつも忘れるので忘却メモ

コマンド
新しい DB および ユーザーの作成コマンド
PLAIN TEXT
CODE:




データベースの作成


mysql&#62; create database `test_db`;


&#160;


test_db に全権限を持ったユーザーの作成


mysq&#62; grant all privileges on `test\\_db`.* to `test`@`localhost` identified by 'password';


&#160;


設定反映


mysql&#62; flush privileges; 






]]></description>
			<content:encoded><![CDATA[<p>いつも忘れるので忘却メモ<br />
<span id="more-611"></span></p>
<h3 class="subtitle">コマンド</h3>
<p>新しい DB および ユーザーの作成コマンド</p>
<div class="igBar"><span id="lcode-2"><a href="#" onclick="javascript:showCodeTxt('code-2'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-2">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">データベースの作成</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">mysql&gt; create database `test_db`;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">test_db に全権限を持ったユーザーの作成</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">mysq&gt; grant all privileges on `test\\_db`.* to `test`@`localhost` identified by <span style="color:#CC0000;">'password'</span>;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">設定反映</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">mysql&gt; flush privileges; </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
]]></content:encoded>
			<wfw:commentRss>http://na-ga.net/blog/?feed=rss2&amp;p=611</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>&#8211;wsesslog について駄文</title>
		<link>http://na-ga.net/blog/?p=608</link>
		<comments>http://na-ga.net/blog/?p=608#comments</comments>
		<pubDate>Wed, 02 Dec 2009 09:16:01 +0000</pubDate>
		<dc:creator>na-ga</dc:creator>
				<category><![CDATA[httperf]]></category>

		<guid isPermaLink="false">http://na-ga.net/blog/?p=608</guid>
		<description><![CDATA[--wsesslog で指定した入力ファイルへのリクエストを送信する順番について、少し調べたのをまとめる。

入力ファイルのリクエスト順番
--wsesslog=N,X,F では、F ファイルに記述した順番で、リクエストを送信する。次のような入力ファイルの場合を考える。
PLAIN TEXT
CODE:




/test/index.html


&#160; /test/1gif


&#160; /test/2.gif


&#160; /test/3.gif


&#160; /test/4.gif


&#160; /test/5.gif


&#160; /test/6.gif 






この場合、1 セッションで合計 7 ページにリクエストを送る。また、必ず index.html, 1.gif, 2.gif, ... 7.gif の順番で処理を行う。
もし、サーバー側の MaxKeepAliveRequests などの設定によって、処理を行っている途中で connection-reset エラーが発生した場合も、エラーで処理できなかったファイルに再度リクエストを送り、正常に reply を受け取った事を確認してから、次のファイルにリクエストを送る。リクエストを送る順番が変わることなく、正しくログを再現する。
この入力ファイル F の 1 バーストの長さは 7 なので、--wsesslog を使わない場合の --num-calls=7 と、ほぼ同等とも言える。
]]></description>
			<content:encoded><![CDATA[<p>--wsesslog で指定した入力ファイルへのリクエストを送信する順番について、少し調べたのをまとめる。<br />
<span id="more-608"></span></p>
<h3 class="subtitle">入力ファイルのリクエスト順番</h3>
<p>--wsesslog=N,X,F では、F ファイルに記述した順番で、リクエストを送信する。次のような入力ファイルの場合を考える。</p>
<div class="igBar"><span id="lcode-4"><a href="#" onclick="javascript:showCodeTxt('code-4'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-4">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">/test/index.<span style="">html</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /test/1gif</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /test/<span style="color:#800000;color:#800000;">2</span>.<span style="">gif</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /test/<span style="color:#800000;color:#800000;">3</span>.<span style="">gif</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /test/<span style="color:#800000;color:#800000;">4</span>.<span style="">gif</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /test/<span style="color:#800000;color:#800000;">5</span>.<span style="">gif</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /test/<span style="color:#800000;color:#800000;">6</span>.<span style="">gif</span> </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>この場合、1 セッションで合計 7 ページにリクエストを送る。また、必ず index.html, 1.gif, 2.gif, ... 7.gif の順番で処理を行う。</p>
<p>もし、サーバー側の MaxKeepAliveRequests などの設定によって、処理を行っている途中で connection-reset エラーが発生した場合も、エラーで処理できなかったファイルに再度リクエストを送り、正常に reply を受け取った事を確認してから、次のファイルにリクエストを送る。リクエストを送る順番が変わることなく、正しくログを再現する。</p>
<p>この入力ファイル F の 1 バーストの長さは 7 なので、--wsesslog を使わない場合の --num-calls=7 と、ほぼ同等とも言える。</p>
]]></content:encoded>
			<wfw:commentRss>http://na-ga.net/blog/?feed=rss2&amp;p=608</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Apache の無駄なモジュールをロードしない</title>
		<link>http://na-ga.net/blog/?p=604</link>
		<comments>http://na-ga.net/blog/?p=604#comments</comments>
		<pubDate>Tue, 01 Dec 2009 09:23:55 +0000</pubDate>
		<dc:creator>na-ga</dc:creator>
				<category><![CDATA[Apache]]></category>

		<guid isPermaLink="false">http://na-ga.net/blog/?p=604</guid>
		<description><![CDATA[httpd-2.2.3-31.el5 では、デフォルト値で 52 個のモジュールがロードされる。これを必要最低限のモジュール (今回の例では 27 個) のみにすることで、気休め程度だが速度向上が期待できる。

 httpd.conf 抜粋
モジュールに関する部分のみ抜粋して表示する。なお、モジュールの説明コメント (// 以降) は、実際に設定するときは削除しないと起動しないので注意。
PLAIN TEXT
CODE:




# 認証関連


LoadModule auth_basic_module modules/mod_auth_basic.so&#160; &#160; &#160; &#160; &#160; &#160;// Basic 認証のサポート


LoadModule auth_digest_module modules/mod_auth_digest.so&#160; &#160; &#160; &#160; &#160;// Digest 認証


LoadModule authn_file_module modules/mod_authn_file.so&#160; &#160; &#160; &#160; &#160; &#160;// テキストファイルを用いたユーザ認証


LoadModule authn_alias_module modules/mod_authn_alias.so&#160; &#160; &#160; &#160; &#160;// Provides the ability to create extended authentication providers based [...]]]></description>
			<content:encoded><![CDATA[<p>httpd-2.2.3-31.el5 では、デフォルト値で 52 個のモジュールがロードされる。これを必要最低限のモジュール (今回の例では 27 個) のみにすることで、気休め程度だが速度向上が期待できる。<br />
<span id="more-604"></span></p>
<h3 class="subtitle"> httpd.conf 抜粋</h3>
<p>モジュールに関する部分のみ抜粋して表示する。なお、モジュールの説明コメント (// 以降) は、実際に設定するときは削除しないと起動しないので注意。</p>
<div class="igBar"><span id="lcode-8"><a href="#" onclick="javascript:showCodeTxt('code-8'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-8">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># 認証関連</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">LoadModule auth_basic_module modules/mod_auth_basic.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#FF9933; font-style:italic;">// Basic 認証のサポート</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">LoadModule auth_digest_module modules/mod_auth_digest.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#FF9933; font-style:italic;">// Digest 認証</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">LoadModule authn_file_module modules/mod_authn_file.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#FF9933; font-style:italic;">// テキストファイルを用いたユーザ認証</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">LoadModule authn_alias_module modules/mod_authn_alias.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#FF9933; font-style:italic;">// Provides the ability to create extended authentication providers based on actual providers</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">LoadModule authn_anon_module modules/mod_authn_anon.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#FF9933; font-style:italic;">// 認証が必要な領域への &quot;anonymous&quot; ユーザのアクセスを許可</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">LoadModule authn_dbm_module modules/mod_authn_dbm.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#FF9933; font-style:italic;">// DBM ファイルを用いたユーザ認証</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">LoadModule authn_default_module modules/mod_authn_default.<span style="">so</span>&nbsp; &nbsp; &nbsp;<span style="color:#FF9933; font-style:italic;">// 承認フォールバックモジュール</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">LoadModule authz_host_module modules/mod_authz_host.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#FF9933; font-style:italic;">// ホスト (名前もしくは IP アドレス) に基づいたグループ承認</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">LoadModule authz_user_module modules/mod_authz_user.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#FF9933; font-style:italic;">// ユーザ承認</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">LoadModule authz_owner_module modules/mod_authz_owner.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#FF9933; font-style:italic;">// ファイルの所有者に基づいた承認</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">LoadModule authz_groupfile_module modules/mod_authz_groupfile.<span style="">so</span> <span style="color:#FF9933; font-style:italic;">// プレーンテキストファイルを用いたグループ承認</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">LoadModule authz_dbm_module modules/mod_authz_dbm.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#FF9933; font-style:italic;">// DBM ファイルを用いたグループ承認</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">LoadModule authz_default_module modules/mod_authz_default.<span style="">so</span>&nbsp; &nbsp; &nbsp;<span style="color:#FF9933; font-style:italic;">// 承認フォールバックモジュール</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># Alias 関連</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">LoadModule alias_module modules/mod_alias.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#FF9933; font-style:italic;">// URL のリダイレクトなどを行なう機能</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">LoadModule vhost_alias_module modules/mod_vhost_alias.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#FF9933; font-style:italic;">// Provides for dynamically configured mass virtual hosting</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">#LoadModule rewrite_module modules/mod_rewrite.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// mod_rewrite</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># 動的スクリプト関連&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">LoadModule env_module modules/mod_env.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#FF9933; font-style:italic;">// CGI スクリプト及び SSI ページに渡される環境変数を変更する機能</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">LoadModule suexec_module modules/mod_suexec.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#FF9933; font-style:italic;">// 指定されたユーザとグループで CGI スクリプトを実行する</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">LoadModule cgi_module modules/mod_cgi.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#FF9933; font-style:italic;">// CGI スクリプトの実行</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">LoadModule actions_module modules/mod_actions.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#FF9933; font-style:italic;">// メディアタイプやリクエストメソッドに応じて CGI スクリプトを実行する機能を提供</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">LoadModule usertrack_module modules/mod_usertrack.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#FF9933; font-style:italic;">// トラッキングクッキーの発行</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">#LoadModule include_module modules/mod_include.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// Server-Side Includes (SSI)&nbsp; </span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># ログ関連</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">LoadModule log_config_module modules/mod_log_config.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#FF9933; font-style:italic;">// サーバへのリクエストのロギング</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">LoadModule logio_module modules/mod_logio.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#FF9933; font-style:italic;">// リクエスト毎に入力バイト数と出力バイト数をロギング</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># メンテナンス関連</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">#LoadModule status_module modules/mod_status.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// サーバの活動状況と性能に関する情報を提供</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">#LoadModule info_module modules/mod_info.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// サーバの設定の包括的な概観を提供する</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># WebDev 関連</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">#LoadModule dav_module modules/mod_dav.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// 分散オーサリングとバージョン管理 (WebDAV) 機能</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">#LoadModule dav_fs_module modules/mod_dav_fs.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// mod_dav のためのファイルシステムプロバイダ</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># LDAP</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">#LoadModule ldap_module modules/mod_ldap.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// LDAP connection pooling and result caching services for use by other LDAP modules</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">#LoadModule authnz_ldap_module modules/mod_authnz_ldap.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// Allows an LDAP directory to be used to store the database for HTTP Basic authentication.</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># プロキシ関連</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">#LoadModule proxy_module modules/mod_proxy.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// HTTP/1.1 プロキシ/ゲートウェイサーバ</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">#LoadModule proxy_balancer_module modules/mod_proxy_balancer.<span style="">so</span>&nbsp; <span style="color:#FF9933; font-style:italic;">// 負荷分散のための mod_proxy 拡張</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">#LoadModule proxy_ftp_module modules/mod_proxy_ftp.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// FTP support module for mod_proxy</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">#LoadModule proxy_http_module modules/mod_proxy_http.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// HTTP support module for mod_proxy</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">#LoadModule proxy_connect_module modules/mod_proxy_connect.<span style="">so</span>&nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// SCGI gateway module for mod_proxy</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># キャッシュ関連</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">#LoadModule cache_module modules/mod_cache.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// URI をキーにしたコンテンツのキャッシュ</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">#LoadModule disk_cache_module modules/mod_disk_cache.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// URI をキーにしたコンテンツキャッシュストレージ管理</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">#LoadModule file_cache_module modules/mod_file_cache.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// Caches a static list of files in memory</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">#LoadModule mem_cache_module modules/mod_mem_cache.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// URI をキーにしたコンテンツのキャッシュ</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># その他</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">LoadModule setenvif_module modules/mod_setenvif.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#FF9933; font-style:italic;">// リクエストの特徴に基づいた環境変数の設定を可能にする</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">LoadModule mime_module modules/mod_mime.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#FF9933; font-style:italic;">// リクエストされたファイルの拡張子とファイルの振る舞い</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">LoadModule autoindex_module modules/mod_autoindex.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#FF9933; font-style:italic;">// ディレクトリインデックスを生成する</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">LoadModule negotiation_module modules/mod_negotiation.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#FF9933; font-style:italic;">// コンテントネゴシエーション機能</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">LoadModule dir_module modules/mod_dir.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#FF9933; font-style:italic;">// DirectoryIndex など</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">#LoadModule ext_filter_module modules/mod_ext_filter.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// レスポンスのボディをクライアントに送る前に外部プログラムで処理する</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">#LoadModule mime_magic_module modules/mod_mime_magic.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// Determines the MIME type of a file by looking at a few bytes of its contents</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">#LoadModule expires_module modules/mod_expires.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// ユーザの指定した基準に基づいた Expires と Cache-Control HTTP ヘッダの生成</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">#LoadModule deflate_module modules/mod_deflate.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// クライアントへ送られる前にコンテンツを圧縮する</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">#LoadModule headers_module modules/mod_headers.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// HTTP リクエストのヘッダと応答のヘッダのカスタマイズ</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">#LoadModule speling_module modules/mod_speling.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// スペルの簡単な誤り修正</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">#LoadModule userdir_module modules/mod_userdir.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// ユーザ専用のディレクトリを提供</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">#LoadModule version_module modules/mod_version.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// バージョン依存の設定を行う場合 </span></div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<h3 class="subtitle">速度測定</h3>
<p>チューニング前</p>
<div class="igBar"><span id="lcode-9"><a href="#" onclick="javascript:showCodeTxt('code-9'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-9">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># httperf --server=<span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --uri=/wordpress/?p=<span style="color:#800000;color:#800000;">3</span> --num-conns=<span style="color:#800000;color:#800000;">100</span> --rate=<span style="color:#800000;color:#800000;">10</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; httperf --client=<span style="color:#800000;color:#800000;">0</span>/<span style="color:#800000;color:#800000;">1</span> --server=<span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --port=<span style="color:#800000;color:#800000;">80</span> --uri=/wordpress/?p=<span style="color:#800000;color:#800000;">3</span> --rate=<span style="color:#800000;color:#800000;">10</span> --send-buffer=<span style="color:#800000;color:#800000;">4096</span> --recv-buffer=<span style="color:#800000;color:#800000;">16384</span> --num-conns=<span style="color:#800000;color:#800000;">100</span> --num-calls=<span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Maximum connect burst length: <span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Total: connections <span style="color:#800000;color:#800000;">100</span> requests <span style="color:#800000;color:#800000;">100</span> replies <span style="color:#800000;color:#800000;">100</span> test-duration <span style="color:#800000;color:#800000;">13</span>.<span style="color:#800000;color:#800000;">874</span> s</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection rate: <span style="color:#800000;color:#800000;">7</span>.<span style="color:#800000;color:#800000;">2</span> conn/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">138</span>.<span style="color:#800000;color:#800000;">7</span> ms/conn, &lt;=<span style="color:#800000;color:#800000;">38</span> concurrent connections<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: min <span style="color:#800000;color:#800000;">820</span>.<span style="color:#800000;color:#800000;">3</span> avg <span style="color:#800000;color:#800000;">3030</span>.<span style="color:#800000;color:#800000;">9</span> max <span style="color:#800000;color:#800000;">12804</span>.<span style="color:#800000;color:#800000;">5</span> median <span style="color:#800000;color:#800000;">2775</span>.<span style="color:#800000;color:#800000;">5</span> stddev <span style="color:#800000;color:#800000;">1705</span>.<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: connect <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection length <span style="color:#006600; font-weight:bold;">&#91;</span>replies/conn<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">000</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Request rate: <span style="color:#800000;color:#800000;">7</span>.<span style="color:#800000;color:#800000;">2</span> req/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">138</span>.<span style="color:#800000;color:#800000;">7</span> ms/req<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Request size <span style="color:#006600; font-weight:bold;">&#91;</span>B<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">75</span>.<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply rate <span style="color:#006600; font-weight:bold;">&#91;</span>replies/s<span style="color:#006600; font-weight:bold;">&#93;</span>: min <span style="color:#800000;color:#800000;">5</span>.<span style="color:#800000;color:#800000;">6</span> avg <span style="color:#800000;color:#800000;">6</span>.<span style="color:#800000;color:#800000;">2</span> max <span style="color:#800000;color:#800000;">6</span>.<span style="color:#800000;color:#800000;">8</span> stddev <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">8</span> <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">2</span> samples<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: response <span style="color:#800000;color:#800000;">2984</span>.<span style="color:#800000;color:#800000;">5</span> transfer <span style="color:#800000;color:#800000;">46</span>.<span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply size <span style="color:#006600; font-weight:bold;">&#91;</span>B<span style="color:#006600; font-weight:bold;">&#93;</span>: header <span style="color:#800000;color:#800000;">230</span>.<span style="color:#800000;color:#800000;">0</span> content <span style="color:#800000;color:#800000;">9911</span>.<span style="color:#800000;color:#800000;">0</span> footer <span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">0</span> <span style="color:#006600; font-weight:bold;">&#40;</span>total <span style="color:#800000;color:#800000;">10143</span>.<span style="color:#800000;color:#800000;">0</span><span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply status: 1xx=<span style="color:#800000;color:#800000;">0</span> 2xx=<span style="color:#800000;color:#800000;">100</span> 3xx=<span style="color:#800000;color:#800000;">0</span> 4xx=<span style="color:#800000;color:#800000;">0</span> 5xx=<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; CPU time <span style="color:#006600; font-weight:bold;">&#91;</span>s<span style="color:#006600; font-weight:bold;">&#93;</span>: user <span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">01</span> system <span style="color:#800000;color:#800000;">11</span>.<span style="color:#800000;color:#800000;">86</span> <span style="color:#006600; font-weight:bold;">&#40;</span>user <span style="color:#800000;color:#800000;">14</span>.<span style="color:#800000;color:#800000;">5</span>% system <span style="color:#800000;color:#800000;">85</span>.<span style="color:#800000;color:#800000;">5</span>% total <span style="color:#800000;color:#800000;">100</span>.<span style="color:#800000;color:#800000;">0</span>%<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Net I/O: <span style="color:#800000;color:#800000;">71</span>.<span style="color:#800000;color:#800000;">9</span> KB/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">6</span>*<span style="color:#800000;color:#800000;">10</span>^<span style="color:#800000;color:#800000;">6</span> bps<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Errors: total <span style="color:#800000;color:#800000;">0</span> client-timo <span style="color:#800000;color:#800000;">0</span> socket-timo <span style="color:#800000;color:#800000;">0</span> connrefused <span style="color:#800000;color:#800000;">0</span> connreset <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Errors: fd-unavail <span style="color:#800000;color:#800000;">0</span> addrunavail <span style="color:#800000;color:#800000;">0</span> ftab-full <span style="color:#800000;color:#800000;">0</span> other <span style="color:#800000;color:#800000;">0</span> </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>チューニング後</p>
<div class="igBar"><span id="lcode-10"><a href="#" onclick="javascript:showCodeTxt('code-10'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-10">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># httperf --server=<span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --uri=/wordpress/?p=<span style="color:#800000;color:#800000;">3</span> --num-conns=<span style="color:#800000;color:#800000;">100</span> --rate=<span style="color:#800000;color:#800000;">10</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Total: connections <span style="color:#800000;color:#800000;">100</span> requests <span style="color:#800000;color:#800000;">100</span> replies <span style="color:#800000;color:#800000;">100</span> test-duration <span style="color:#800000;color:#800000;">13</span>.<span style="color:#800000;color:#800000;">554</span> s</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection rate: <span style="color:#800000;color:#800000;">7</span>.<span style="color:#800000;color:#800000;">4</span> conn/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">135</span>.<span style="color:#800000;color:#800000;">5</span> ms/conn, &lt;=<span style="color:#800000;color:#800000;">33</span> concurrent connections<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: min <span style="color:#800000;color:#800000;">528</span>.<span style="color:#800000;color:#800000;">6</span> avg <span style="color:#800000;color:#800000;">2625</span>.<span style="color:#800000;color:#800000;">4</span> max <span style="color:#800000;color:#800000;">9819</span>.<span style="color:#800000;color:#800000;">7</span> median <span style="color:#800000;color:#800000;">2494</span>.<span style="color:#800000;color:#800000;">5</span> stddev <span style="color:#800000;color:#800000;">1498</span>.<span style="color:#800000;color:#800000;">9</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: connect <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection length <span style="color:#006600; font-weight:bold;">&#91;</span>replies/conn<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">000</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Request rate: <span style="color:#800000;color:#800000;">7</span>.<span style="color:#800000;color:#800000;">4</span> req/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">135</span>.<span style="color:#800000;color:#800000;">5</span> ms/req<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Request size <span style="color:#006600; font-weight:bold;">&#91;</span>B<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">75</span>.<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply rate <span style="color:#006600; font-weight:bold;">&#91;</span>replies/s<span style="color:#006600; font-weight:bold;">&#93;</span>: min <span style="color:#800000;color:#800000;">6</span>.<span style="color:#800000;color:#800000;">2</span> avg <span style="color:#800000;color:#800000;">6</span>.<span style="color:#800000;color:#800000;">8</span> max <span style="color:#800000;color:#800000;">7</span>.<span style="color:#800000;color:#800000;">4</span> stddev <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">8</span> <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">2</span> samples<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: response <span style="color:#800000;color:#800000;">2586</span>.<span style="color:#800000;color:#800000;">2</span> transfer <span style="color:#800000;color:#800000;">39</span>.<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply size <span style="color:#006600; font-weight:bold;">&#91;</span>B<span style="color:#006600; font-weight:bold;">&#93;</span>: header <span style="color:#800000;color:#800000;">230</span>.<span style="color:#800000;color:#800000;">0</span> content <span style="color:#800000;color:#800000;">9911</span>.<span style="color:#800000;color:#800000;">0</span> footer <span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">0</span> <span style="color:#006600; font-weight:bold;">&#40;</span>total <span style="color:#800000;color:#800000;">10143</span>.<span style="color:#800000;color:#800000;">0</span><span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply status: 1xx=<span style="color:#800000;color:#800000;">0</span> 2xx=<span style="color:#800000;color:#800000;">100</span> 3xx=<span style="color:#800000;color:#800000;">0</span> 4xx=<span style="color:#800000;color:#800000;">0</span> 5xx=<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; CPU time <span style="color:#006600; font-weight:bold;">&#91;</span>s<span style="color:#006600; font-weight:bold;">&#93;</span>: user <span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">21</span> system <span style="color:#800000;color:#800000;">11</span>.<span style="color:#800000;color:#800000;">34</span> <span style="color:#006600; font-weight:bold;">&#40;</span>user <span style="color:#800000;color:#800000;">16</span>.<span style="color:#800000;color:#800000;">3</span>% system <span style="color:#800000;color:#800000;">83</span>.<span style="color:#800000;color:#800000;">7</span>% total <span style="color:#800000;color:#800000;">100</span>.<span style="color:#800000;color:#800000;">0</span>%<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Net I/O: <span style="color:#800000;color:#800000;">73</span>.<span style="color:#800000;color:#800000;">6</span> KB/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">6</span>*<span style="color:#800000;color:#800000;">10</span>^<span style="color:#800000;color:#800000;">6</span> bps<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Errors: total <span style="color:#800000;color:#800000;">0</span> client-timo <span style="color:#800000;color:#800000;">0</span> socket-timo <span style="color:#800000;color:#800000;">0</span> connrefused <span style="color:#800000;color:#800000;">0</span> connreset <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Errors: fd-unavail <span style="color:#800000;color:#800000;">0</span> addrunavail <span style="color:#800000;color:#800000;">0</span> ftab-full <span style="color:#800000;color:#800000;">0</span> other <span style="color:#800000;color:#800000;">0</span> </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>Request rate: 7.2 req/s が 7.4 /req/s に向上している。誤差の範囲とも取れるので、気休め程度だけど･･･効果あるはず？</p>
<h3 class="subtitle">参考文献</h3>
<p>モジュール一覧 - Apache HTTP サーバ<br />
<a href="http://httpd.apache.org/docs/2.2/ja/mod/">http://httpd.apache.org/docs/2.2/ja/mod/</a></p>
]]></content:encoded>
			<wfw:commentRss>http://na-ga.net/blog/?feed=rss2&amp;p=604</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>APC まとめ</title>
		<link>http://na-ga.net/blog/?p=601</link>
		<comments>http://na-ga.net/blog/?p=601#comments</comments>
		<pubDate>Tue, 01 Dec 2009 04:26:22 +0000</pubDate>
		<dc:creator>na-ga</dc:creator>
				<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://na-ga.net/blog/?p=601</guid>
		<description><![CDATA[APC （Alternative PHP Cache） を導入すると、PHP の実行速度が大幅に向上する。仕組みは、PHP はスクリプト言語なので実行するたびにコンパイルが行われるが、APC によって中間コードをキャッシュすることで、高速化を行っている。

導入
APC を pecl でインストールする。
PLAIN TEXT
CODE:




# yum -y install httpd httpd-devel php php-devel php-pear php-gd gcc


# pecl install apc


&#160;


&#160; &#160; ... 略


&#160; &#160; Build process completed successfully


&#160; &#160; Installing '/var/tmp/pear-build-root/install-APC-3.0.19//usr/lib/php/modules/apc.so'


&#160; &#160; install ok: channel://pecl.php.net/APC-3.0.19


&#160; &#160; You should add "extension=apc.so" to php.ini


&#160;


# ll /usr/lib/php/modules/apc.so


&#160;


&#160; &#160; -rwxr-xr-x 1 root root 412650 [...]]]></description>
			<content:encoded><![CDATA[<p>APC （Alternative PHP Cache） を導入すると、PHP の実行速度が大幅に向上する。仕組みは、PHP はスクリプト言語なので実行するたびにコンパイルが行われるが、APC によって中間コードをキャッシュすることで、高速化を行っている。<br />
<span id="more-601"></span></p>
<h3 class="subtitle">導入</h3>
<p>APC を pecl でインストールする。</p>
<div class="igBar"><span id="lcode-15"><a href="#" onclick="javascript:showCodeTxt('code-15'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-15">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># yum -y install httpd httpd-devel php php-devel php-pear php-gd gcc</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># pecl install apc</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; ... 略</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Build process completed successfully</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Installing <span style="color:#CC0000;">'/var/tmp/pear-build-root/install-APC-3.0.19//usr/lib/php/modules/apc.so'</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; install ok: channel:<span style="color:#FF9933; font-style:italic;">//pecl.php.net/APC-3.0.19</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; You should add <span style="color:#CC0000;">"extension=apc.so"</span> to php.<span style="">ini</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># ll /usr/lib/php/modules/apc.<span style="">so</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; -rwxr-xr-x <span style="color:#800000;color:#800000;">1</span> root root <span style="color:#800000;color:#800000;">412650</span> Dec&nbsp; <span style="color:#800000;color:#800000;">1</span> <span style="color:#800000;color:#800000;">11</span>:<span style="color:#800000;color:#800000;">51</span> /usr/lib/php/modules/apc.<span style="">so</span> </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>APC の設定ファイルを作成する。これはパフォーマンスを重視した設定内容のため、注意する事。</p>
<div class="igBar"><span id="lcode-16"><a href="#" onclick="javascript:showCodeTxt('code-16'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-16">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># cat /etc/php.<span style="">d</span>/apc.<span style="">ini</span> </div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; ; 必修項目</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; extension=apc.<span style="">so</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ; 必修</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; ; カスタマイズ&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">shm_size</span>=<span style="color:#800000;color:#800000;">100</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ; 個々の共有メモリセグメントの大きさを MB 単位で指定 <span style="color:#006600; font-weight:bold;">&#40;</span>default <span style="color:#800000;color:#800000;">30</span><span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">file_update_protection</span>=<span style="color:#800000;color:#800000;">0</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ; <span style="color:#006600; font-weight:bold;">&#91;</span>要注意<span style="color:#006600; font-weight:bold;">&#93;</span> 新しいファイルをキャッシュするまでの遅延秒数 <span style="color:#006600; font-weight:bold;">&#40;</span>default <span style="color:#800000;color:#800000;">2</span><span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">stat</span>=<span style="color:#800000;color:#800000;">0</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ; <span style="color:#006600; font-weight:bold;">&#91;</span>要注意<span style="color:#006600; font-weight:bold;">&#93;</span> ファイル更新を確認する <span style="color:#006600; font-weight:bold;">&#40;</span>default <span style="color:#800000;color:#800000;">1</span><span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; ; デフォルト値&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">enabled</span>=<span style="color:#800000;color:#800000;">1</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;; APC を有効にする</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">shm_segments</span>=<span style="color:#800000;color:#800000;">1</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ; コンパイラキャッシュのために割り当てる共有メモリセグメントの数</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">optimization</span>=<span style="color:#800000;color:#800000;">0</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ; <span style="color:#006600; font-weight:bold;">&#91;</span>実験項目<span style="color:#006600; font-weight:bold;">&#93;</span> 最適化レベル</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">num_files_hint</span>=<span style="color:#800000;color:#800000;">1000</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;; Web サーバで読み込まれるソースファイルの総数についてのヒント</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">user_entries_hint</span>=<span style="color:#800000;color:#800000;">4096</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ; apc.<span style="">num_files_hint</span> と同様に、保存するユーザキャッシュ変数の数についてのヒント</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">ttl</span>=<span style="color:#800000;color:#800000;">0</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;; キャッシュされているエントリが、他のエントリに割り当てられるまでスロットに残っていることの可能な秒数</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">user_ttl</span>=<span style="color:#800000;color:#800000;">0</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ; ユーザキャッシュエントリが、 他のエントリに割り当てられるまでスロットに残っていることの可能な秒数</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">gc_ttl</span>=<span style="color:#800000;color:#800000;">3600</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;; キャッシュエントリがガベージコレクションのリストに残り続ける秒数</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">cache_by_default</span>=<span style="color:#800000;color:#800000;">1</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ; OFF にすると、次項のフィルタリストに一致したファイルのみをキャッシュできる</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">filters</span>=NULL&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ; フィルタリスト</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">mmap_file_mask</span>=NULL&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;; mktemp 形式のファイルマスクを指定</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">slam_defense</span>=<span style="color:#800000;color:#800000;">0</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ; <span style="color:#006600; font-weight:bold;">&#91;</span>非推奨<span style="color:#006600; font-weight:bold;">&#93;</span> ファイルをキャッシュせずに利用する割合</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">enable_cli</span>=<span style="color:#800000;color:#800000;">0</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ; デバッグモード</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">max_file_size</span>=1M&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ; この値よも大きなサイズのファイルは、キャッシュしない <span style="color:#006600; font-weight:bold;">&#40;</span>default 1M<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">write_lock</span>=<span style="color:#800000;color:#800000;">1</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ; ひとつのプロセスのみが未キャッシュのスクリプトをコンパイルする</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">report_autofilter</span>=<span style="color:#800000;color:#800000;">0</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;; バインド時の問題によりキャッシュから自動的に除外されたスクリプトを記録</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">include_once_override</span>=<span style="color:#800000;color:#800000;">0</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;; include_once<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#006600; font-weight:bold;">&#41;</span> および require_once<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#006600; font-weight:bold;">&#41;</span> を最適化し、コストの高いシステムコールの使用を避ける</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">rfc1867</span>=<span style="color:#800000;color:#800000;">0</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;; PHP <span style="color:#800000;color:#800000;">5</span>.<span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">0</span> 以降</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">rfc1867_prefix</span>=upload_&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ; PHP <span style="color:#800000;color:#800000;">5</span>.<span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">0</span> 以降</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">rfc1867_name</span>=APC_UPLOAD_PROGRESS&nbsp; ; PHP <span style="color:#800000;color:#800000;">5</span>.<span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">0</span> 以降</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">rfc1867_freq</span>=<span style="color:#800000;color:#800000;">0</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ; PHP <span style="color:#800000;color:#800000;">5</span>.<span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">0</span> 以降</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">localcache</span>=<span style="color:#800000;color:#800000;">0</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ; ロックが不要なローカルプロセスのシャドウキャッシュを行う</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">localcache</span>.<span style="">size</span>=<span style="color:#800000;color:#800000;">512</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;; ローカルプロセスのシャドウキャッシュの大きさ</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">coredump_unmap</span>=<span style="color:#800000;color:#800000;">0</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ; <span style="color:#006600; font-weight:bold;">&#91;</span>実験項目<span style="color:#006600; font-weight:bold;">&#93;</span> シグナルの発生時にコアファイルを書き出せる</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">stat_ctime</span>=<span style="color:#800000;color:#800000;">0</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ; ctime による検証を行う </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>APC のステータスを Web 上から確認するスクリプトへのリンクを張る。また、デフォルト値の状態だと認証できない為、認証情報を修正する。</p>
<div class="igBar"><span id="lcode-17"><a href="#" onclick="javascript:showCodeTxt('code-17'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-17">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># ln -s /usr/share/pear/apc.<span style="">php</span> /var/www/html/apcinfo.<span style="">php</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># vi /var/www/html/apcinfo.<span style="">php</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; defaults<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'ADMIN_USERNAME'</span>,<span style="color:#CC0000;">'********'</span><span style="color:#006600; font-weight:bold;">&#41;</span>;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// Admin Username</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; defaults<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'ADMIN_PASSWORD'</span>,<span style="color:#CC0000;">'********'</span><span style="color:#006600; font-weight:bold;">&#41;</span>;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// Admin Password - CHANGE THIS TO ENABLE!!! </span></div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>APC を実行し、設定内容を確認する。</p>
<div class="igBar"><span id="lcode-18"><a href="#" onclick="javascript:showCodeTxt('code-18'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-18">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># service httpd restart</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># echo <span style="color:#CC0000;">"&lt;?php phpinfo(); ?&gt;"</span> /var/www/html/phpinfo.<span style="">php</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># php /var/www/html/phpinfo.<span style="">php</span> | grep apc</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; additional .<span style="">ini</span> files parsed =&gt; /etc/php.<span style="">d</span>/apc.<span style="">ini</span>,</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">cache_by_default</span> =&gt; On =&gt; On</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">coredump_unmap</span> =&gt; Off =&gt; Off</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">enable_cli</span> =&gt; Off =&gt; Off</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">enabled</span> =&gt; On =&gt; On</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">file_update_protection</span> =&gt; <span style="color:#800000;color:#800000;">0</span> =&gt; <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">filters</span> =&gt; no value =&gt; no value</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">gc_ttl</span> =&gt; <span style="color:#800000;color:#800000;">3600</span> =&gt; <span style="color:#800000;color:#800000;">3600</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">include_once_override</span> =&gt; Off =&gt; Off</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">max_file_size</span> =&gt; 1M =&gt; 1M</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">mmap_file_mask</span> =&gt; no value =&gt; no value</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">num_files_hint</span> =&gt; <span style="color:#800000;color:#800000;">1000</span> =&gt; <span style="color:#800000;color:#800000;">1000</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">report_autofilter</span> =&gt; Off =&gt; Off</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">shm_segments</span> =&gt; <span style="color:#800000;color:#800000;">1</span> =&gt; <span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">shm_size</span> =&gt; <span style="color:#800000;color:#800000;">100</span> =&gt; <span style="color:#800000;color:#800000;">100</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">slam_defense</span> =&gt; <span style="color:#800000;color:#800000;">0</span> =&gt; <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">stat</span> =&gt; Off =&gt; Off</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">stat_ctime</span> =&gt; Off =&gt; Off</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">ttl</span> =&gt; <span style="color:#800000;color:#800000;">0</span> =&gt; <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">user_entries_hint</span> =&gt; <span style="color:#800000;color:#800000;">4096</span> =&gt; <span style="color:#800000;color:#800000;">4096</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">user_ttl</span> =&gt; <span style="color:#800000;color:#800000;">0</span> =&gt; <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; apc.<span style="">write_lock</span> =&gt; On =&gt; On </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>http://IP/apcinfo.php に接続し、設定した認証情報で表示できるか確かめる。また、APC の設定項目で apc.stat=0 を行っているため、PHP スクリプトを編集した場合も、APC による編集前のキャッシュが実行される。そのため、ファイル更新を行うには Apache の再起動を行い、古いキャッシュを削除する必要がある。</p>
<h3 class="subtitle">関連文献</h3>
<p>PHP: APC - Manual<br />
<a href="http://www.php.net/manual/ja/book.apc.php">http://www.php.net/manual/ja/book.apc.php</a></p>
]]></content:encoded>
			<wfw:commentRss>http://na-ga.net/blog/?feed=rss2&amp;p=601</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>WordPress のチューニングポイントを探す 2</title>
		<link>http://na-ga.net/blog/?p=590</link>
		<comments>http://na-ga.net/blog/?p=590#comments</comments>
		<pubDate>Thu, 19 Nov 2009 10:20:09 +0000</pubDate>
		<dc:creator>na-ga</dc:creator>
				<category><![CDATA[MySQL]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[httperf]]></category>
		<category><![CDATA[memcached]]></category>

		<guid isPermaLink="false">http://na-ga.net/blog/?p=590</guid>
		<description><![CDATA[前回 WordPress のチューニングポイントを探す の続編。MySQL のクエリーキャッシュと、 memcached による分散キャッシュサーバを導入して、WordPress の高速化を目指す。

MySQL のクエリーキャッシュ
デフォルト状態では、クエリーキャッシュが有効になっていないため、有効にする。動作を確認する為に実行されたクエリーをファイルに保存する。クエリーキャッシュを有効にした直後のアクセスと、2 回目のアクセスでどのような変化があるかを調べる。
PLAIN TEXT
CODE:




# mysqladmin -u root variables &#124; grep query_cache_


&#160;


&#160; &#160; &#124; query_cache_limit&#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160;&#124; 1048576 &#124;


&#160; &#160; &#124; query_cache_min_res_unit&#160; &#160; &#160; &#160; &#124; 4096&#160; &#160; &#124;


&#160; &#160; &#124; query_cache_size&#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#124; 0&#160; &#160; &#160; &#160;&#124;


&#160; [...]]]></description>
			<content:encoded><![CDATA[<p><a href="/?p=544">前回 WordPress のチューニングポイントを探す</a> の続編。MySQL のクエリーキャッシュと、 memcached による分散キャッシュサーバを導入して、WordPress の高速化を目指す。<br />
<span id="more-590"></span></p>
<h3 class="subtitle">MySQL のクエリーキャッシュ</h3>
<p>デフォルト状態では、クエリーキャッシュが有効になっていないため、有効にする。動作を確認する為に実行されたクエリーをファイルに保存する。クエリーキャッシュを有効にした直後のアクセスと、2 回目のアクセスでどのような変化があるかを調べる。</p>
<div class="igBar"><span id="lcode-28"><a href="#" onclick="javascript:showCodeTxt('code-28'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-28">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># mysqladmin -u root variables | grep query_cache_</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | query_cache_limit&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">1048576</span> |</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | query_cache_min_res_unit&nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">4096</span>&nbsp; &nbsp; |</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | query_cache_size&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">0</span>&nbsp; &nbsp; &nbsp; &nbsp;|</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | query_cache_type&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | ON&nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | query_cache_wlock_invalidate&nbsp; &nbsp; | OFF&nbsp; &nbsp; &nbsp;|</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># vi /etc/my.<span style="">cnf</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color:#006600; font-weight:bold;">&#91;</span>mysqld<span style="color:#006600; font-weight:bold;">&#93;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; datadir=/var/lib/mysql&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; # 初期設定</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; socket=/var/lib/mysql/mysql.<span style="">sock</span>&nbsp; &nbsp; # 初期設定</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; user=mysql&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; # 初期設定</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; old_passwords=<span style="color:#800000;color:#800000;">1</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;# 初期設定</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; query_cache_limit=1M&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; # 1MB より大きい結果はキャッシュしない</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; query_cache_min_res_unit=4k&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;# 4K が推奨値</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; query_cache_size=24M&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; # クエリキャッシュにメモリを 24M <span style="color:#006600; font-weight:bold;">&#40;</span>bytes<span style="color:#006600; font-weight:bold;">&#41;</span> 割り当てる</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; query_cache_type=<span style="color:#800000;color:#800000;">1</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; # <span style="color:#800000;color:#800000;">0</span>:　OFF <span style="color:#800000;color:#800000;">1</span>:　ON <span style="color:#800000;color:#800000;">2</span>:　DEMAND</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; log=/var/log/mysql-all.<span style="">log</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; # クエリーを全文保存</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color:#006600; font-weight:bold;">&#91;</span>mysqld_safe<span style="color:#006600; font-weight:bold;">&#93;</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;# 初期設定</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; log-error=/var/log/mysqld.<span style="">log</span>&nbsp; &nbsp; &nbsp; &nbsp;# 初期設定</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; pid-file=/var/run/mysqld/mysqld.<span style="">pid</span> # 初期設定</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># echo <span style="color:#CC0000;">""</span>&gt; /var/log/mysql-all.<span style="">log</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># chown mysql. /var/log/mysql-all.<span style="">log</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># service mysqld restart</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># mysqladmin -u root variables | grep query_cache_</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | query_cache_limit&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">1048576</span>&nbsp; |</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | query_cache_min_res_unit&nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">4096</span>&nbsp; &nbsp; &nbsp;|</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | query_cache_size&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">25165824</span> |</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | query_cache_type&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | ON&nbsp; &nbsp; &nbsp; &nbsp;|</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | query_cache_wlock_invalidate&nbsp; &nbsp; | OFF&nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># mysqladmin -u root extended-status | grep Qcache</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_free_blocks&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">1</span>&nbsp; &nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_free_memory&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">25157000</span> |</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_hits&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">0</span>&nbsp; &nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_inserts&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">0</span>&nbsp; &nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_lowmem_prunes&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">0</span>&nbsp; &nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_not_cached&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">1</span>&nbsp; &nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_queries_in_cache&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">0</span>&nbsp; &nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_total_blocks&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">1</span>&nbsp; &nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># echo <span style="color:#CC0000;">""</span>&gt; /var/log/mysql-all.<span style="">log</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># httperf --hog --server=<span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --uri=/wordpress/?p=<span style="color:#800000;color:#800000;">3</span> --num-conns=<span style="color:#800000;color:#800000;">1</span> --num-calls=<span style="color:#800000;color:#800000;">1</span> --rate=<span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># cat /var/log/mysql-all.<span style="">log</span> | wc -l</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color:#800000;color:#800000;">22</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># mysqladmin -u root extended-status | grep Qcache</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_free_blocks&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">1</span>&nbsp; &nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_free_memory&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">25115576</span> |</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_hits&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">0</span>&nbsp; &nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_inserts&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">16</span>&nbsp; &nbsp; &nbsp; &nbsp;|</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_lowmem_prunes&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">0</span>&nbsp; &nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_not_cached&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">3</span>&nbsp; &nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_queries_in_cache&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">16</span>&nbsp; &nbsp; &nbsp; &nbsp;|</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_total_blocks&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">42</span>&nbsp; &nbsp; &nbsp; &nbsp;|</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># echo <span style="color:#CC0000;">""</span>&gt; /var/log/mysql-all.<span style="">log</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># httperf --hog --server=<span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --uri=/wordpress/?p=<span style="color:#800000;color:#800000;">3</span> --num-conns=<span style="color:#800000;color:#800000;">1</span> --num-calls=<span style="color:#800000;color:#800000;">1</span> --rate=<span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># cat /var/log/mysql-all.<span style="">log</span> | wc -l</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color:#800000;color:#800000;">22</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># mysqladmin -u root extended-status | grep Qcache</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_free_blocks&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">1</span>&nbsp; &nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_free_memory&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">25115576</span> |</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_hits&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">16</span>&nbsp; &nbsp; &nbsp; &nbsp;|</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_inserts&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">16</span>&nbsp; &nbsp; &nbsp; &nbsp;|</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_lowmem_prunes&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">0</span>&nbsp; &nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_not_cached&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">5</span>&nbsp; &nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_queries_in_cache&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">16</span>&nbsp; &nbsp; &nbsp; &nbsp;|</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_total_blocks&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">42</span>&nbsp; &nbsp; &nbsp; &nbsp;| </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>1 回目のアクセスで 22 回のクエリーが実行された事が分かった。その内、16 クエリーがキャッシュに保存された。(クエリーに保存されるのは、SELECT 文のみ) 2 回目のアクセスでは、同じページへのアクセスなので、前回同様に 22 回のクエリーが実行された。その内、16 回のクエリーがキャッシュに保存された内容と一致し、キャッシュから返された。クエリーを有効にすることで、多少の高速化が見込めそうだ。</p>
<h3 class="subtitle">WordPress 標準のキャッシュ機能</h3>
<p><s>WordPress には標準でキャッシュ機能がある。</p>
<div class="igBar"><span id="lcode-29"><a href="#" onclick="javascript:showCodeTxt('code-29'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-29">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># cd $wordpress_root_dir</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># vi wp-config</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; define<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'ENABLE_CACHE'</span>,true<span style="color:#006600; font-weight:bold;">&#41;</span>; <span style="color:#FF9933; font-style:italic;">// 先頭の方に追加</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># mkdir ./wp-content/cache</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># chmod <span style="color:#800000;color:#800000;">777</span> ./wp-content/cache </div>
</li>
</ol>
</div>
</div>
</div>
<p></s></p>
<p>WordPress 2.5 より、この機能が削除された。</p>
<h3 class="subtitle">memcached による分散キャッシュ</h3>
<p>memcached は高性能な分散メモリキャッシュサーバで、データベースへのクエリー結果を一時的にキャッシュできる。MySQL のクエリーキャッシュの場合は、実際に問い合わせが発生するが、memcached の場合は問い合わせが発生しない。memcached は分散キャッシュサーバなので、複数のサーバで構築する事も出来るが、今回はlocalhost で memcached にアクセスできるように WordPress をインストールしたサーバに memcached を同居させる。memcached を有効にした直後のアクセスと、2 回目のアクセスでどのような変化があるかを調べる。</p>
<div class="igBar"><span id="lcode-30"><a href="#" onclick="javascript:showCodeTxt('code-30'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-30">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># cd $wordpress_root_dir</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># wget http:<span style="color:#FF9933; font-style:italic;">//dag.wieers.com/rpm/packages/rpmforge-release/rpmforge-release-0.3.6-1.el5.rf.i386.rpm</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># rpm -ihv rpmforge-release-<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span>.<span style="color:#800000;color:#800000;">6</span>-<span style="color:#800000;color:#800000;">1</span>.<span style="">el5</span>.<span style="">rf</span>.<span style="">i386</span>.<span style="">rpm</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># yum install php-pecl-memcache memcached</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># service memcached start</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># chkconfig memcached on </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>次に WordPress に取り込むために object-cache.php をダウンロードし、./wp-content/object-cache.php として設置する。</p>
<blockquote><p><a href="http://ryan.boren.me/2005/12/23/memcached-backend/">http://ryan.boren.me/2005/12/23/memcached-backend/</a><br />
<a href="http://plugins.trac.wordpress.org/browser/memcached/trunk/object-cache.php">http://plugins.trac.wordpress.org/browser/memcached/trunk/object-cache.php</a></p></blockquote>
<p>WordPress と memcached が同じサーバーの場合は特に設定は必要ないが、異なるサーバーの場合は、wp-config.php に追記する必要がある。</p>
<div class="igBar"><span id="lcode-31"><a href="#" onclick="javascript:showCodeTxt('code-31'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-31">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># echo <span style="color:#CC0000;">"$memcached_servers = array('192.168.1.1:11211', '192.168.1.2:11211');"</span>&gt;&gt; ./wp-config.<span style="">php</span> </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>必要ではないが、便利なツールとして memcache.php がある。これを設置すると、memcache でキャッシュしているサイズを表示する事ができる。</p>
<blockquote><p><a href="http://livebookmark.net/journal/2008/05/21/memcachephp-stats-like-apcphp/">http://livebookmark.net/journal/2008/05/21/memcachephp-stats-like-apcphp/</a><br />
<a href="http://livebookmark.net/memcachephp/memcachephp.zip">http://livebookmark.net/memcachephp/memcachephp.zip</a></p></blockquote>
<p>memcached が動作しているサーバと、接続するのに必要な認証情報を編集する必要がある。</p>
<div class="igBar"><span id="lcode-32"><a href="#" onclick="javascript:showCodeTxt('code-32'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-32">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># cat memcache.<span style="">php</span> |grep -e <span style="color:#CC0000;">"define('ADMIN_"</span> -e <span style="color:#CC0000;">"add more as an array"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; define<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'ADMIN_USERNAME'</span>,<span style="color:#CC0000;">'memcache'</span><span style="color:#006600; font-weight:bold;">&#41;</span>;&nbsp; &nbsp; &nbsp;<span style="color:#FF9933; font-style:italic;">// Admin Username</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; define<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'ADMIN_PASSWORD'</span>,<span style="color:#CC0000;">'password'</span><span style="color:#006600; font-weight:bold;">&#41;</span>;&nbsp; &nbsp; &nbsp;<span style="color:#FF9933; font-style:italic;">// Admin Password</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; $MEMCACHE_SERVERS<span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#006600; font-weight:bold;">&#93;</span> = <span style="color:#CC0000;">'localhost:11211'</span>; <span style="color:#FF9933; font-style:italic;">// add more as an array </span></div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>memcache.php を開くと、現在のキャッシュ容量が Used: 0 KBytes (0.0%) と表示されていれば正常。準備は整ったので、実際に memcached を動作させ、アクセスする。</p>
<div class="igBar"><span id="lcode-33"><a href="#" onclick="javascript:showCodeTxt('code-33'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-33">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># service mysqld restart</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># echo <span style="color:#CC0000;">""</span>&gt; /var/log/mysql-all.<span style="">log</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># httperf --hog --server=<span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --uri=/wordpress/?p=<span style="color:#800000;color:#800000;">3</span> --num-conns=<span style="color:#800000;color:#800000;">1</span> --num-calls=<span style="color:#800000;color:#800000;">1</span> --rate=<span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># cat /var/log/mysql-all.<span style="">log</span> | wc -l</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color:#800000;color:#800000;">22</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># mysqladmin -u root extended-status | grep Qcache</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_free_blocks&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">1</span>&nbsp; &nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_free_memory&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">25115576</span> |</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_hits&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">0</span>&nbsp; &nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_inserts&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">16</span>&nbsp; &nbsp; &nbsp; &nbsp;|</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_lowmem_prunes&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">0</span>&nbsp; &nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_not_cached&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">2</span>&nbsp; &nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_queries_in_cache&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">16</span>&nbsp; &nbsp; &nbsp; &nbsp;|</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_total_blocks&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">42</span>&nbsp; &nbsp; &nbsp; &nbsp;| </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>memcache.php を確認すると、17 クエリー (Current Items 17) がキャッシュに保存されており Used: 18.7 KBytes (0.0%) となっている。MySQL のクエリーキャッシュには 16 クエリー保存されている。</p>
<div class="igBar"><span id="lcode-34"><a href="#" onclick="javascript:showCodeTxt('code-34'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-34">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># echo <span style="color:#CC0000;">""</span>&gt; /var/log/mysql-all.<span style="">log</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># httperf --hog --server=<span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --uri=/wordpress/?p=<span style="color:#800000;color:#800000;">3</span> --num-conns=<span style="color:#800000;color:#800000;">1</span> --num-calls=<span style="color:#800000;color:#800000;">1</span> --rate=<span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># cat /var/log/mysql-all.<span style="">log</span> | wc -l</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color:#800000;color:#800000;">11</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># mysqladmin -u root extended-status | grep Qcache</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_free_blocks&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">1</span>&nbsp; &nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_free_memory&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">25115576</span> |</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_hits&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">5</span>&nbsp; &nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_inserts&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">16</span>&nbsp; &nbsp; &nbsp; &nbsp;|</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_lowmem_prunes&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">0</span>&nbsp; &nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_not_cached&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">4</span>&nbsp; &nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_queries_in_cache&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">16</span>&nbsp; &nbsp; &nbsp; &nbsp;|</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Qcache_total_blocks&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">42</span>&nbsp; &nbsp; &nbsp; &nbsp;| </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>2 回目のアクセスでは、memcached のキャッシュに保存された内容と一致し、最終的に 11 回のクエリーが実行された。その内、5 クエリーが MySQL キャッシュに保存された内容と一致し、キャッシュから返された。大幅に減少しており、かなりの高速化が見込めそうだ。検証する為に設定したクエリーの全文保存は、負荷が増加する為、通常運営時は無効にする。</p>
<div class="igBar"><span id="lcode-35"><a href="#" onclick="javascript:showCodeTxt('code-35'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-35">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># sed -i <span style="color:#CC0000;">'s/log=/#log=/g'</span> /etc/my.<span style="">cnf</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># service mysqld restart </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<h3 class="subtitle">パフォーマンス測定</h3>
<p>httperf を使って、チューニング後のパフォーマンスを測定する。生成する負荷は、WordPress の 1 ページ (?p=3) に X={1,5,10.20.50} 人 (--rate=X) が同時にアクセスして、合計 100 回 (--num-conns=100) 表示されたらベンチマークを終了する。Apache の設定はデフォルト値とする。</p>
<div class="igBar"><span id="lcode-36"><a href="#" onclick="javascript:showCodeTxt('code-36'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-36">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># ssh <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> <span style="color:#CC0000;">"service memcached restart"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># ssh <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span> <span style="color:#CC0000;">"service httpd restart"</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># ssh <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span> <span style="color:#CC0000;">"service mysqld restart"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># sleep <span style="color:#800000;color:#800000;">3</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># httperf --hog --server=<span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --uri=/wordpress/?p=<span style="color:#800000;color:#800000;">3</span> --num-conns=<span style="color:#800000;color:#800000;">100</span> --num-calls=<span style="color:#800000;color:#800000;">1</span> --rate=<span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; httperf --hog --client=<span style="color:#800000;color:#800000;">0</span>/<span style="color:#800000;color:#800000;">1</span> --server=<span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --port=<span style="color:#800000;color:#800000;">80</span> --uri=/wordpress/?p=<span style="color:#800000;color:#800000;">3</span> --rate=<span style="color:#800000;color:#800000;">1</span> --send-buffer=<span style="color:#800000;color:#800000;">4096</span> --recv-buffer=<span style="color:#800000;color:#800000;">16384</span> --num-conns=<span style="color:#800000;color:#800000;">100</span> --num-calls=<span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Total: connections <span style="color:#800000;color:#800000;">100</span> requests <span style="color:#800000;color:#800000;">100</span> replies <span style="color:#800000;color:#800000;">100</span> test-duration <span style="color:#800000;color:#800000;">99</span>.<span style="color:#800000;color:#800000;">488</span> s</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection rate: <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">0</span> conn/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">994</span>.<span style="color:#800000;color:#800000;">9</span> ms/conn, &lt;=<span style="color:#800000;color:#800000;">1</span> concurrent connections<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: min <span style="color:#800000;color:#800000;">459</span>.<span style="color:#800000;color:#800000;">9</span> avg <span style="color:#800000;color:#800000;">479</span>.<span style="color:#800000;color:#800000;">0</span> max <span style="color:#800000;color:#800000;">559</span>.<span style="color:#800000;color:#800000;">8</span> median <span style="color:#800000;color:#800000;">466</span>.<span style="color:#800000;color:#800000;">5</span> stddev <span style="color:#800000;color:#800000;">24</span>.<span style="color:#800000;color:#800000;">2</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: connect <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection length <span style="color:#006600; font-weight:bold;">&#91;</span>replies/conn<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">000</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Request rate: <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">0</span> req/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">994</span>.<span style="color:#800000;color:#800000;">9</span> ms/req<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Request size <span style="color:#006600; font-weight:bold;">&#91;</span>B<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">75</span>.<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply rate <span style="color:#006600; font-weight:bold;">&#91;</span>replies/s<span style="color:#006600; font-weight:bold;">&#93;</span>: min <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">0</span> avg <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">0</span> max <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">0</span> stddev <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span> <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">19</span> samples<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: response <span style="color:#800000;color:#800000;">448</span>.<span style="color:#800000;color:#800000;">6</span> transfer <span style="color:#800000;color:#800000;">30</span>.<span style="color:#800000;color:#800000;">2</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply size <span style="color:#006600; font-weight:bold;">&#91;</span>B<span style="color:#006600; font-weight:bold;">&#93;</span>: header <span style="color:#800000;color:#800000;">230</span>.<span style="color:#800000;color:#800000;">0</span> content <span style="color:#800000;color:#800000;">9911</span>.<span style="color:#800000;color:#800000;">0</span> footer <span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">0</span> <span style="color:#006600; font-weight:bold;">&#40;</span>total <span style="color:#800000;color:#800000;">10143</span>.<span style="color:#800000;color:#800000;">0</span><span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply status: 1xx=<span style="color:#800000;color:#800000;">0</span> 2xx=<span style="color:#800000;color:#800000;">100</span> 3xx=<span style="color:#800000;color:#800000;">0</span> 4xx=<span style="color:#800000;color:#800000;">0</span> 5xx=<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; CPU time <span style="color:#006600; font-weight:bold;">&#91;</span>s<span style="color:#006600; font-weight:bold;">&#93;</span>: user <span style="color:#800000;color:#800000;">27</span>.<span style="color:#800000;color:#800000;">90</span> system <span style="color:#800000;color:#800000;">71</span>.<span style="color:#800000;color:#800000;">59</span> <span style="color:#006600; font-weight:bold;">&#40;</span>user <span style="color:#800000;color:#800000;">28</span>.<span style="color:#800000;color:#800000;">0</span>% system <span style="color:#800000;color:#800000;">72</span>.<span style="color:#800000;color:#800000;">0</span>% total <span style="color:#800000;color:#800000;">100</span>.<span style="color:#800000;color:#800000;">0</span>%<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Net I/O: <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span> KB/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span>*<span style="color:#800000;color:#800000;">10</span>^<span style="color:#800000;color:#800000;">6</span> bps<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Errors: total <span style="color:#800000;color:#800000;">0</span> client-timo <span style="color:#800000;color:#800000;">0</span> socket-timo <span style="color:#800000;color:#800000;">0</span> connrefused <span style="color:#800000;color:#800000;">0</span> connreset <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Errors: fd-unavail <span style="color:#800000;color:#800000;">0</span> addrunavail <span style="color:#800000;color:#800000;">0</span> ftab-full <span style="color:#800000;color:#800000;">0</span> other <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># ssh <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span> <span style="color:#CC0000;">"mysqladmin -u root extended-status | grep Max_used_connections"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Max_used_connections&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">1</span>&nbsp; &nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># ssh <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> <span style="color:#CC0000;">"service memcached restart"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># ssh <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span> <span style="color:#CC0000;">"service httpd restart"</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># ssh <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span> <span style="color:#CC0000;">"service mysqld restart"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># sleep <span style="color:#800000;color:#800000;">3</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># httperf --hog --server=<span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --uri=/wordpress/?p=<span style="color:#800000;color:#800000;">3</span> --num-conns=<span style="color:#800000;color:#800000;">100</span> --num-calls=<span style="color:#800000;color:#800000;">1</span> --rate=<span style="color:#800000;color:#800000;">5</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; httperf --hog --client=<span style="color:#800000;color:#800000;">0</span>/<span style="color:#800000;color:#800000;">1</span> --server=<span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --port=<span style="color:#800000;color:#800000;">80</span> --uri=/wordpress/?p=<span style="color:#800000;color:#800000;">3</span> --rate=<span style="color:#800000;color:#800000;">5</span> --send-buffer=<span style="color:#800000;color:#800000;">4096</span> --recv-buffer=<span style="color:#800000;color:#800000;">16384</span> --num-conns=<span style="color:#800000;color:#800000;">100</span> --num-calls=<span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Total: connections <span style="color:#800000;color:#800000;">100</span> requests <span style="color:#800000;color:#800000;">100</span> replies <span style="color:#800000;color:#800000;">100</span> test-duration <span style="color:#800000;color:#800000;">21</span>.<span style="color:#800000;color:#800000;">629</span> s</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection rate: <span style="color:#800000;color:#800000;">4</span>.<span style="color:#800000;color:#800000;">6</span> conn/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">216</span>.<span style="color:#800000;color:#800000;">3</span> ms/conn, &lt;=<span style="color:#800000;color:#800000;">17</span> concurrent connections<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: min <span style="color:#800000;color:#800000;">528</span>.<span style="color:#800000;color:#800000;">4</span> avg <span style="color:#800000;color:#800000;">1948</span>.<span style="color:#800000;color:#800000;">2</span> max <span style="color:#800000;color:#800000;">8628</span>.<span style="color:#800000;color:#800000;">6</span> median <span style="color:#800000;color:#800000;">1789</span>.<span style="color:#800000;color:#800000;">5</span> stddev <span style="color:#800000;color:#800000;">1026</span>.<span style="color:#800000;color:#800000;">5</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: connect <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection length <span style="color:#006600; font-weight:bold;">&#91;</span>replies/conn<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">000</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Request rate: <span style="color:#800000;color:#800000;">4</span>.<span style="color:#800000;color:#800000;">6</span> req/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">216</span>.<span style="color:#800000;color:#800000;">3</span> ms/req<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Request size <span style="color:#006600; font-weight:bold;">&#91;</span>B<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">75</span>.<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply rate <span style="color:#006600; font-weight:bold;">&#91;</span>replies/s<span style="color:#006600; font-weight:bold;">&#93;</span>: min <span style="color:#800000;color:#800000;">3</span>.<span style="color:#800000;color:#800000;">6</span> avg <span style="color:#800000;color:#800000;">4</span>.<span style="color:#800000;color:#800000;">2</span> max <span style="color:#800000;color:#800000;">4</span>.<span style="color:#800000;color:#800000;">8</span> stddev <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">5</span> <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">4</span> samples<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: response <span style="color:#800000;color:#800000;">1897</span>.<span style="color:#800000;color:#800000;">1</span> transfer <span style="color:#800000;color:#800000;">50</span>.<span style="color:#800000;color:#800000;">9</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply size <span style="color:#006600; font-weight:bold;">&#91;</span>B<span style="color:#006600; font-weight:bold;">&#93;</span>: header <span style="color:#800000;color:#800000;">230</span>.<span style="color:#800000;color:#800000;">0</span> content <span style="color:#800000;color:#800000;">9911</span>.<span style="color:#800000;color:#800000;">0</span> footer <span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">0</span> <span style="color:#006600; font-weight:bold;">&#40;</span>total <span style="color:#800000;color:#800000;">10143</span>.<span style="color:#800000;color:#800000;">0</span><span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply status: 1xx=<span style="color:#800000;color:#800000;">0</span> 2xx=<span style="color:#800000;color:#800000;">100</span> 3xx=<span style="color:#800000;color:#800000;">0</span> 4xx=<span style="color:#800000;color:#800000;">0</span> 5xx=<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; CPU time <span style="color:#006600; font-weight:bold;">&#91;</span>s<span style="color:#006600; font-weight:bold;">&#93;</span>: user <span style="color:#800000;color:#800000;">4</span>.<span style="color:#800000;color:#800000;">68</span> system <span style="color:#800000;color:#800000;">16</span>.<span style="color:#800000;color:#800000;">95</span> <span style="color:#006600; font-weight:bold;">&#40;</span>user <span style="color:#800000;color:#800000;">21</span>.<span style="color:#800000;color:#800000;">6</span>% system <span style="color:#800000;color:#800000;">78</span>.<span style="color:#800000;color:#800000;">4</span>% total <span style="color:#800000;color:#800000;">100</span>.<span style="color:#800000;color:#800000;">0</span>%<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Net I/O: <span style="color:#800000;color:#800000;">46</span>.<span style="color:#800000;color:#800000;">1</span> KB/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">4</span>*<span style="color:#800000;color:#800000;">10</span>^<span style="color:#800000;color:#800000;">6</span> bps<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Errors: total <span style="color:#800000;color:#800000;">0</span> client-timo <span style="color:#800000;color:#800000;">0</span> socket-timo <span style="color:#800000;color:#800000;">0</span> connrefused <span style="color:#800000;color:#800000;">0</span> connreset <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Errors: fd-unavail <span style="color:#800000;color:#800000;">0</span> addrunavail <span style="color:#800000;color:#800000;">0</span> ftab-full <span style="color:#800000;color:#800000;">0</span> other <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># ssh <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span> <span style="color:#CC0000;">"mysqladmin -u root extended-status | grep Max_used_connections"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Max_used_connections&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">16</span>&nbsp; &nbsp; &nbsp; &nbsp;|</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># ssh <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> <span style="color:#CC0000;">"service memcached restart"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># ssh <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span> <span style="color:#CC0000;">"service httpd restart"</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># ssh <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span> <span style="color:#CC0000;">"service mysqld restart"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># sleep <span style="color:#800000;color:#800000;">3</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># httperf --hog --server=<span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --uri=/wordpress/?p=<span style="color:#800000;color:#800000;">3</span> --num-conns=<span style="color:#800000;color:#800000;">100</span> --num-calls=<span style="color:#800000;color:#800000;">1</span> --rate=<span style="color:#800000;color:#800000;">10</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; httperf --hog --client=<span style="color:#800000;color:#800000;">0</span>/<span style="color:#800000;color:#800000;">1</span> --server=<span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --port=<span style="color:#800000;color:#800000;">80</span> --uri=/wordpress/?p=<span style="color:#800000;color:#800000;">3</span> --rate=<span style="color:#800000;color:#800000;">10</span> --send-buffer=<span style="color:#800000;color:#800000;">4096</span> --recv-buffer=<span style="color:#800000;color:#800000;">16384</span> --num-conns=<span style="color:#800000;color:#800000;">100</span> --num-calls=<span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Total: connections <span style="color:#800000;color:#800000;">100</span> requests <span style="color:#800000;color:#800000;">100</span> replies <span style="color:#800000;color:#800000;">100</span> test-duration <span style="color:#800000;color:#800000;">22</span>.<span style="color:#800000;color:#800000;">186</span> s</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection rate: <span style="color:#800000;color:#800000;">4</span>.<span style="color:#800000;color:#800000;">5</span> conn/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">221</span>.<span style="color:#800000;color:#800000;">9</span> ms/conn, &lt;=<span style="color:#800000;color:#800000;">65</span> concurrent connections<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: min <span style="color:#800000;color:#800000;">1423</span>.<span style="color:#800000;color:#800000;">8</span> avg <span style="color:#800000;color:#800000;">8411</span>.<span style="color:#800000;color:#800000;">0</span> max <span style="color:#800000;color:#800000;">18285</span>.<span style="color:#800000;color:#800000;">9</span> median <span style="color:#800000;color:#800000;">8540</span>.<span style="color:#800000;color:#800000;">5</span> stddev <span style="color:#800000;color:#800000;">3848</span>.<span style="color:#800000;color:#800000;">5</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: connect <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection length <span style="color:#006600; font-weight:bold;">&#91;</span>replies/conn<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">000</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Request rate: <span style="color:#800000;color:#800000;">4</span>.<span style="color:#800000;color:#800000;">5</span> req/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">221</span>.<span style="color:#800000;color:#800000;">9</span> ms/req<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Request size <span style="color:#006600; font-weight:bold;">&#91;</span>B<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">75</span>.<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply rate <span style="color:#006600; font-weight:bold;">&#91;</span>replies/s<span style="color:#006600; font-weight:bold;">&#93;</span>: min <span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">4</span> avg <span style="color:#800000;color:#800000;">4</span>.<span style="color:#800000;color:#800000;">0</span> max <span style="color:#800000;color:#800000;">4</span>.<span style="color:#800000;color:#800000;">8</span> stddev <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">1</span> <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">4</span> samples<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: response <span style="color:#800000;color:#800000;">8321</span>.<span style="color:#800000;color:#800000;">4</span> transfer <span style="color:#800000;color:#800000;">89</span>.<span style="color:#800000;color:#800000;">4</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply size <span style="color:#006600; font-weight:bold;">&#91;</span>B<span style="color:#006600; font-weight:bold;">&#93;</span>: header <span style="color:#800000;color:#800000;">230</span>.<span style="color:#800000;color:#800000;">0</span> content <span style="color:#800000;color:#800000;">9911</span>.<span style="color:#800000;color:#800000;">0</span> footer <span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">0</span> <span style="color:#006600; font-weight:bold;">&#40;</span>total <span style="color:#800000;color:#800000;">10143</span>.<span style="color:#800000;color:#800000;">0</span><span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply status: 1xx=<span style="color:#800000;color:#800000;">0</span> 2xx=<span style="color:#800000;color:#800000;">100</span> 3xx=<span style="color:#800000;color:#800000;">0</span> 4xx=<span style="color:#800000;color:#800000;">0</span> 5xx=<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; CPU time <span style="color:#006600; font-weight:bold;">&#91;</span>s<span style="color:#006600; font-weight:bold;">&#93;</span>: user <span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">61</span> system <span style="color:#800000;color:#800000;">19</span>.<span style="color:#800000;color:#800000;">58</span> <span style="color:#006600; font-weight:bold;">&#40;</span>user <span style="color:#800000;color:#800000;">11</span>.<span style="color:#800000;color:#800000;">8</span>% system <span style="color:#800000;color:#800000;">88</span>.<span style="color:#800000;color:#800000;">2</span>% total <span style="color:#800000;color:#800000;">100</span>.<span style="color:#800000;color:#800000;">0</span>%<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Net I/O: <span style="color:#800000;color:#800000;">45</span>.<span style="color:#800000;color:#800000;">0</span> KB/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">4</span>*<span style="color:#800000;color:#800000;">10</span>^<span style="color:#800000;color:#800000;">6</span> bps<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Errors: total <span style="color:#800000;color:#800000;">0</span> client-timo <span style="color:#800000;color:#800000;">0</span> socket-timo <span style="color:#800000;color:#800000;">0</span> connrefused <span style="color:#800000;color:#800000;">0</span> connreset <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Errors: fd-unavail <span style="color:#800000;color:#800000;">0</span> addrunavail <span style="color:#800000;color:#800000;">0</span> ftab-full <span style="color:#800000;color:#800000;">0</span> other <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># ssh <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span> <span style="color:#CC0000;">"mysqladmin -u root extended-status | grep Max_used_connections"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Max_used_connections&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">22</span>&nbsp; &nbsp; &nbsp; &nbsp;|</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># ssh <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> <span style="color:#CC0000;">"service memcached restart"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># ssh <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span> <span style="color:#CC0000;">"service httpd restart"</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># ssh <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span> <span style="color:#CC0000;">"service mysqld restart"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># sleep <span style="color:#800000;color:#800000;">3</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># httperf --hog --server=<span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --uri=/wordpress/?p=<span style="color:#800000;color:#800000;">3</span> --num-conns=<span style="color:#800000;color:#800000;">100</span> --num-calls=<span style="color:#800000;color:#800000;">1</span> --rate=<span style="color:#800000;color:#800000;">20</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; httperf --hog --client=<span style="color:#800000;color:#800000;">0</span>/<span style="color:#800000;color:#800000;">1</span> --server=<span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --port=<span style="color:#800000;color:#800000;">80</span> --uri=/wordpress/?p=<span style="color:#800000;color:#800000;">3</span> --rate=<span style="color:#800000;color:#800000;">20</span> --send-buffer=<span style="color:#800000;color:#800000;">4096</span> --recv-buffer=<span style="color:#800000;color:#800000;">16384</span> --num-conns=<span style="color:#800000;color:#800000;">100</span> --num-calls=<span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Maximum connect burst length: <span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Total: connections <span style="color:#800000;color:#800000;">100</span> requests <span style="color:#800000;color:#800000;">100</span> replies <span style="color:#800000;color:#800000;">100</span> test-duration <span style="color:#800000;color:#800000;">21</span>.<span style="color:#800000;color:#800000;">534</span> s</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection rate: <span style="color:#800000;color:#800000;">4</span>.<span style="color:#800000;color:#800000;">6</span> conn/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">215</span>.<span style="color:#800000;color:#800000;">3</span> ms/conn, &lt;=<span style="color:#800000;color:#800000;">86</span> concurrent connections<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: min <span style="color:#800000;color:#800000;">1024</span>.<span style="color:#800000;color:#800000;">4</span> avg <span style="color:#800000;color:#800000;">10203</span>.<span style="color:#800000;color:#800000;">0</span> max <span style="color:#800000;color:#800000;">21183</span>.<span style="color:#800000;color:#800000;">5</span> median <span style="color:#800000;color:#800000;">10542</span>.<span style="color:#800000;color:#800000;">5</span> stddev <span style="color:#800000;color:#800000;">5459</span>.<span style="color:#800000;color:#800000;">2</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: connect <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection length <span style="color:#006600; font-weight:bold;">&#91;</span>replies/conn<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">000</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Request rate: <span style="color:#800000;color:#800000;">4</span>.<span style="color:#800000;color:#800000;">6</span> req/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">215</span>.<span style="color:#800000;color:#800000;">3</span> ms/req<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Request size <span style="color:#006600; font-weight:bold;">&#91;</span>B<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">75</span>.<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply rate <span style="color:#006600; font-weight:bold;">&#91;</span>replies/s<span style="color:#006600; font-weight:bold;">&#93;</span>: min <span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">8</span> avg <span style="color:#800000;color:#800000;">4</span>.<span style="color:#800000;color:#800000;">2</span> max <span style="color:#800000;color:#800000;">5</span>.<span style="color:#800000;color:#800000;">0</span> stddev <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">0</span> <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">4</span> samples<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: response <span style="color:#800000;color:#800000;">10091</span>.<span style="color:#800000;color:#800000;">4</span> transfer <span style="color:#800000;color:#800000;">111</span>.<span style="color:#800000;color:#800000;">4</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply size <span style="color:#006600; font-weight:bold;">&#91;</span>B<span style="color:#006600; font-weight:bold;">&#93;</span>: header <span style="color:#800000;color:#800000;">230</span>.<span style="color:#800000;color:#800000;">0</span> content <span style="color:#800000;color:#800000;">9911</span>.<span style="color:#800000;color:#800000;">0</span> footer <span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">0</span> <span style="color:#006600; font-weight:bold;">&#40;</span>total <span style="color:#800000;color:#800000;">10143</span>.<span style="color:#800000;color:#800000;">0</span><span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply status: 1xx=<span style="color:#800000;color:#800000;">0</span> 2xx=<span style="color:#800000;color:#800000;">100</span> 3xx=<span style="color:#800000;color:#800000;">0</span> 4xx=<span style="color:#800000;color:#800000;">0</span> 5xx=<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; CPU time <span style="color:#006600; font-weight:bold;">&#91;</span>s<span style="color:#006600; font-weight:bold;">&#93;</span>: user <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">81</span> system <span style="color:#800000;color:#800000;">19</span>.<span style="color:#800000;color:#800000;">73</span> <span style="color:#006600; font-weight:bold;">&#40;</span>user <span style="color:#800000;color:#800000;">8</span>.<span style="color:#800000;color:#800000;">4</span>% system <span style="color:#800000;color:#800000;">91</span>.<span style="color:#800000;color:#800000;">6</span>% total <span style="color:#800000;color:#800000;">100</span>.<span style="color:#800000;color:#800000;">0</span>%<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Net I/O: <span style="color:#800000;color:#800000;">46</span>.<span style="color:#800000;color:#800000;">3</span> KB/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">4</span>*<span style="color:#800000;color:#800000;">10</span>^<span style="color:#800000;color:#800000;">6</span> bps<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Errors: total <span style="color:#800000;color:#800000;">0</span> client-timo <span style="color:#800000;color:#800000;">0</span> socket-timo <span style="color:#800000;color:#800000;">0</span> connrefused <span style="color:#800000;color:#800000;">0</span> connreset <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Errors: fd-unavail <span style="color:#800000;color:#800000;">0</span> addrunavail <span style="color:#800000;color:#800000;">0</span> ftab-full <span style="color:#800000;color:#800000;">0</span> other <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># ssh <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span> <span style="color:#CC0000;">"mysqladmin -u root extended-status | grep Max_used_connections"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Max_used_connections&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">22</span>&nbsp; &nbsp; &nbsp; &nbsp;|</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># ssh <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> <span style="color:#CC0000;">"service memcached restart"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># ssh <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span> <span style="color:#CC0000;">"service httpd restart"</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># ssh <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span> <span style="color:#CC0000;">"service mysqld restart"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># sleep <span style="color:#800000;color:#800000;">3</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># httperf --hog --server=<span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --uri=/wordpress/?p=<span style="color:#800000;color:#800000;">3</span> --num-conns=<span style="color:#800000;color:#800000;">100</span> --num-calls=<span style="color:#800000;color:#800000;">1</span> --rate=<span style="color:#800000;color:#800000;">50</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; httperf --hog --client=<span style="color:#800000;color:#800000;">0</span>/<span style="color:#800000;color:#800000;">1</span> --server=<span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --port=<span style="color:#800000;color:#800000;">80</span> --uri=/wordpress/?p=<span style="color:#800000;color:#800000;">3</span> --rate=<span style="color:#800000;color:#800000;">50</span> --send-buffer=<span style="color:#800000;color:#800000;">4096</span> --recv-buffer=<span style="color:#800000;color:#800000;">16384</span> --num-conns=<span style="color:#800000;color:#800000;">100</span> --num-calls=<span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Maximum connect burst length: <span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Total: connections <span style="color:#800000;color:#800000;">100</span> requests <span style="color:#800000;color:#800000;">100</span> replies <span style="color:#800000;color:#800000;">100</span> test-duration <span style="color:#800000;color:#800000;">21</span>.<span style="color:#800000;color:#800000;">443</span> s</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection rate: <span style="color:#800000;color:#800000;">4</span>.<span style="color:#800000;color:#800000;">7</span> conn/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">214</span>.<span style="color:#800000;color:#800000;">4</span> ms/conn, &lt;=<span style="color:#800000;color:#800000;">98</span> concurrent connections<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: min <span style="color:#800000;color:#800000;">851</span>.<span style="color:#800000;color:#800000;">2</span> avg <span style="color:#800000;color:#800000;">11621</span>.<span style="color:#800000;color:#800000;">5</span> max <span style="color:#800000;color:#800000;">20695</span>.<span style="color:#800000;color:#800000;">9</span> median <span style="color:#800000;color:#800000;">11338</span>.<span style="color:#800000;color:#800000;">5</span> stddev <span style="color:#800000;color:#800000;">5828</span>.<span style="color:#800000;color:#800000;">4</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: connect <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection length <span style="color:#006600; font-weight:bold;">&#91;</span>replies/conn<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">000</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Request rate: <span style="color:#800000;color:#800000;">4</span>.<span style="color:#800000;color:#800000;">7</span> req/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">214</span>.<span style="color:#800000;color:#800000;">4</span> ms/req<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Request size <span style="color:#006600; font-weight:bold;">&#91;</span>B<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">75</span>.<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply rate <span style="color:#006600; font-weight:bold;">&#91;</span>replies/s<span style="color:#006600; font-weight:bold;">&#93;</span>: min <span style="color:#800000;color:#800000;">3</span>.<span style="color:#800000;color:#800000;">0</span> avg <span style="color:#800000;color:#800000;">4</span>.<span style="color:#800000;color:#800000;">3</span> max <span style="color:#800000;color:#800000;">5</span>.<span style="color:#800000;color:#800000;">8</span> stddev <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">2</span> <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">4</span> samples<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: response <span style="color:#800000;color:#800000;">11573</span>.<span style="color:#800000;color:#800000;">4</span> transfer <span style="color:#800000;color:#800000;">47</span>.<span style="color:#800000;color:#800000;">9</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply size <span style="color:#006600; font-weight:bold;">&#91;</span>B<span style="color:#006600; font-weight:bold;">&#93;</span>: header <span style="color:#800000;color:#800000;">230</span>.<span style="color:#800000;color:#800000;">0</span> content <span style="color:#800000;color:#800000;">9911</span>.<span style="color:#800000;color:#800000;">0</span> footer <span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">0</span> <span style="color:#006600; font-weight:bold;">&#40;</span>total <span style="color:#800000;color:#800000;">10143</span>.<span style="color:#800000;color:#800000;">0</span><span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply status: 1xx=<span style="color:#800000;color:#800000;">0</span> 2xx=<span style="color:#800000;color:#800000;">100</span> 3xx=<span style="color:#800000;color:#800000;">0</span> 4xx=<span style="color:#800000;color:#800000;">0</span> 5xx=<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; CPU time <span style="color:#006600; font-weight:bold;">&#91;</span>s<span style="color:#006600; font-weight:bold;">&#93;</span>: user <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">98</span> system <span style="color:#800000;color:#800000;">19</span>.<span style="color:#800000;color:#800000;">47</span> <span style="color:#006600; font-weight:bold;">&#40;</span>user <span style="color:#800000;color:#800000;">9</span>.<span style="color:#800000;color:#800000;">3</span>% system <span style="color:#800000;color:#800000;">90</span>.<span style="color:#800000;color:#800000;">8</span>% total <span style="color:#800000;color:#800000;">100</span>.<span style="color:#800000;color:#800000;">0</span>%<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Net I/O: <span style="color:#800000;color:#800000;">46</span>.<span style="color:#800000;color:#800000;">5</span> KB/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">4</span>*<span style="color:#800000;color:#800000;">10</span>^<span style="color:#800000;color:#800000;">6</span> bps<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Errors: total <span style="color:#800000;color:#800000;">0</span> client-timo <span style="color:#800000;color:#800000;">0</span> socket-timo <span style="color:#800000;color:#800000;">0</span> connrefused <span style="color:#800000;color:#800000;">0</span> connreset <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Errors: fd-unavail <span style="color:#800000;color:#800000;">0</span> addrunavail <span style="color:#800000;color:#800000;">0</span> ftab-full <span style="color:#800000;color:#800000;">0</span> other <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># ssh <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span> <span style="color:#CC0000;">"mysqladmin -u root extended-status | grep Max_used_connections"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Max_used_connections&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">25</span>&nbsp; &nbsp; &nbsp; &nbsp;| </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>チューニング後の測定結果のポイントとなる点を以下に示す。</p>
<table id="table-2rows">
<tbody>
<tr>
<td id="item">--rate=1</td>
<td id="value">
Request rate: 1.0 req/s<br />
Reply time [ms]: response 448.6<br />
Errors: total 0<br />
Max_used_connections 1
</td>
</tr>
<tr>
<td id="item">--rate=5</td>
<td id="value">
Request rate: 4.6 req/<br />
Reply time [ms]: response 1897.1<br />
Errors: total 0<br />
Max_used_connections 16
</td>
</tr>
<tr>
<td id="item">--rate=10</td>
<td id="value">
Request rate: 4.5 req/s<br />
Reply time [ms]: response 8321.4<br />
Errors: total 0<br />
Max_used_connections 22
</td>
</tr>
<tr>
<td id="item">--rate=20</td>
<td id="value">
Request rate: 4.6 req/s<br />
Reply time [ms]: response 10091.4<br />
Errors: total 0<br />
Max_used_connections 22
</td>
</tr>
<tr>
<td id="item">--rate=50</td>
<td id="value">
Request rate: 4.7 req/s<br />
Reply time [ms]: response 11573.4<br />
Errors: total 0<br />
Max_used_connections 25
</td>
</tr>
</tbody>
</table>
<p>--rate=1 のときは、1 リクエストあたりの平均 response 448.6 [ms] で、まだまだサーバに余裕がある。--rate=5～50 をみると、Request rate が 4.5～4.7 req/s となっているため、サーバに余裕が無い状態を示している。MySQL への同時コネクション数は、初期設定では最大 100 だが、測定結果の Max_used_connections をみると、最大 25 となっている。このため、まだまだ MySQL 側には余裕があるがサーバからのリクエストが届いていない状態を表しており、MySQL 側がボトルネックになっている可能性は低いと考えられる。</p>
]]></content:encoded>
			<wfw:commentRss>http://na-ga.net/blog/?feed=rss2&amp;p=590</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>httperf man (OUTPUT)</title>
		<link>http://na-ga.net/blog/?p=559</link>
		<comments>http://na-ga.net/blog/?p=559#comments</comments>
		<pubDate>Wed, 18 Nov 2009 09:04:54 +0000</pubDate>
		<dc:creator>na-ga</dc:creator>
				<category><![CDATA[httperf]]></category>

		<guid isPermaLink="false">http://na-ga.net/blog/?p=559</guid>
		<description><![CDATA[httperf の出力情報を正しく理解できるように man の OUTPUT カテゴリーを日本語訳にしてみた。かなり怪しい訳なので、参考にされる場合は英文と照らし合わせてください。大体の意味は理解できると思うが、意味が分からないところは英文のまま載せました。

OUTPUT
このセクションは、各テストの終わりの統計出力について説明します。次に示された基本情報は、負荷生成のオプションに関わらず表示されます。

Total: connections 30000 requests 29997 replies 29997 test-duration 299.992 s
　
Connection  rate: 100.0 conn/s (10.0 ms/conn, ]]></description>
			<content:encoded><![CDATA[<p>httperf の出力情報を正しく理解できるように man の OUTPUT カテゴリーを日本語訳にしてみた。かなり怪しい訳なので、参考にされる場合は英文と照らし合わせてください。大体の意味は理解できると思うが、意味が分からないところは英文のまま載せました。<br />
<span id="more-559"></span></p>
<h3 class="subtitle">OUTPUT</h3>
<p>このセクションは、各テストの終わりの統計出力について説明します。次に示された基本情報は、負荷生成のオプションに関わらず表示されます。</p>
<ul>
<strong>Total:</strong> connections 30000 requests 29997 replies 29997 test-duration 299.992 s<br />
　<br />
<strong>Connection  rate:</strong> 100.0 conn/s (10.0 ms/conn, <=14 concurrent<br />
connections)<br />
<strong>Connection time [ms]:</strong> min 1.4 avg 3.0 max 163.4 median 1.5 stddev 7.3<br />
<strong>Connection time [ms]:</strong> connect 0.6<br />
<strong>Connection length [replies/conn]:</strong> 1.000<br />
　<br />
<strong>Request rate:</strong> 100.0 req/s (10.0 ms/req)<br />
<strong>Request size [B]:</strong> 75.0<br />
　<br />
<strong>Reply  rate [replies/s]:</strong> min 98.8 avg 100.0 max 101.2 stddev 0.3 (60 samples)<br />
<strong>Reply time [ms]:</strong> response 2.4 transfer 0.0<br />
<strong>Reply size [B]:</strong> header 242.0 content 1010.0 footer 0.0 (total 1252.0)<br />
<strong>Reply status:</strong> 1xx=0 2xx=29997 3xx=0 4xx=0 5xx=0<br />
　<br />
<strong>CPU  time [s]:</strong> user 94.31 system 205.26 (user 31.4% system 68.4% total 99.9%)<br />
<strong>Net I/O:</strong> 129.6 KB/s (1.1*10^6 bps)<br />
　<br />
<strong>Errors:</strong> total 3 client-timo 0 socket-timo 0 connrefused 3 connreset 0<br />
<strong>Errors:</strong> fd-unavail 0 addrunavail 0 ftab-full 0 other 0
</ul>
<p>6 つのグループがあります。総合的な結果の `Total`、コネクションに関係した結果の `Conection`、HTTP リクエストに関係した結果の `Request`、サーバから受け取った回答に関する結果の `Reply`、CPU に関係する多方面の結果の `CPU`、ネットワークの利用の `Net I/O`、最後に大切な内容となるエラーに関する要約の `Errors`です。</p>
<p><strong>Total Section</strong></p>
<ul>
このセクションは何個の TCP コネクションが httperf によって開始されたか、何個のリクエストを出したか、何個のリプライを受け取ったか、テストにかかった時間は何秒か、をまとめています。上の出力結果の例の場合では、3 万コネクションが作成され、2 万 9997 リクエストを送信し、2 万 9997 リプライを受け取り、テストにかかった時間は、ほとんど正確に 5 分 (300秒) でした。
</ul>
<p><strong>Connection Section</strong></p>
<ul>
このセクションはツールで生成される TCP コネクションに関する情報を伝えます。明確に、`Connection rate` 行は、新しいコネクションが1 秒あたり 100.0 のレートで開始された事を示しています。このレートを言い換えるとは、1 コネクションあたり 10.0 ミリ秒です。この行の最後の数は、いつでも 14 コネクション開かれていた事を示します。</p>
<p>最初の行の `Conection time` ラベルは、成功したコネクションのライフタイムの統計です。コネクションのライフタイムは、TCP コネクションが開始された時間と、コネクションが閉じられた時間の、間となります。A connection is considered successful if it had at least one call that completed successfully. 出力結果の例の場合では、最小のコネクションライフタイム (min) は 1.4 ミリ秒、平均 (ave) は 3.0 ミリ秒、最大 (max) は 163.4 ミリ秒、中間 (midian) は 1.5 ミリ秒、標準偏差は 7.4 ミリ秒を示しています。The median lifetime is computed based on a histogram with one millisecond resolution and a maximum lifetime of 100 seconds. Thus, the median isaccurate to within half a millisecond if at least half of thesuccessful connections have a lifetime of no more than 100seconds.</p>
<p>このセクションの次の統計値は、TCP コネクションが確立するのにかかる平均時間です。成功した TCP コネクションの確立のみを数えます。出力結果の例では、2 行目の `Connection time` が示し、コネクションが確立するのに平均 0.6 ミリ秒かかりました。</p>
<p>このセクションの最後の行 `Connection length` ラベルは、少なくても 1 つの回答を受け取った各コネクションで、受け取った回答の平均値を示します。つまり、最初の回答を受け取る前に失敗したコネクションはカウントしません。この数は、持続するコネクションの場合 1.0 より大きい場合があります。
</ul>
<p><strong>Request Section</strong></p>
<ul>
`Request rate` は、HTTP リクエストが出されたレートを示します。出力例の場合では 1 秒あたり 100.0 リクエスト出された事を示しています。このレートを言い換えると、1 リクエストあたり 10.0 ミリ秒です。持続するコネクションを有効にしていない限り、このセクションの結果は、コネクションセクションの結果と、同じ・または非常に似ています。しかしながら、持続する接続が有効の場合、1 つのコネクションで複数のリクエストを実行できます。その場合、これらの結果は異なっているでしょう。</p>
<p>`Request size` は HTTP リクエストの平均サイズ (bytes) を示しています。出力結果の例の場合では、平均リクエストサイズは 75 bytes です。
</ul>
<p><strong>Reply Section</strong></p>
<ul>
`Reply rate` は、様々なリプライレートの統計を示します。簡易測定のために、このセクションはしばしば最も面白いです。出力結果の例では、最小 (min) リプライレートは 1 秒あたり 98.8 回、平均 (avg) は 1 秒あたり 100 回、最大 (max) は 1 秒あたり 101.2 です。括弧の中の数は 60 個のサンプルを取得した事を示しています。現在は httperf は 5 秒に 1 個のサンプルを取得します。重要な標準偏差を得るために、十分長いテストを行う事が勧められるので、少なくても 30 個のサンプルを取得します。これは、少なくても 150 秒のテストを行う事に相当します。</p>
<p>`Reply Time` は、そのサーバからの応答にどれくらかかったかと、そのリプライを受け取るのにどれくらいかかったかを示します。出力結果の例では、最初のリクエストを送ってから最初のリプライを受け取る間 (response) は、平均 2.4 ミリ秒です。transfer はリプライが測定するためには短すぎる場合は、0 と表示されます。典型的には、連続したリプライが 1 つの TCP セグメントに収まります。</p>
<p>`Reply size` は、リプライの平均サイズ (byte) を示します。正確に言うと、リプライヘッダー、コンテンツ、フッター (HTTP/1.1 は Chunked Transfer-Encoding を使用します) の平均長さです。括弧では、各平均値の合計を示しています。出力結果の例では、ヘッダーの平均長さ (header) が 242 byte、コンテンツの平均長さ (content) が 1010 byte、フッターの平均長さは 0 byte です。また、リプライ全体の平均長さは 1252 byte です。</p>
<p>このセクションの最後の行は、サーバからリプライで受け取った主要なステータスコードのヒストグラム (度数分布図) です。主要なステータスコードは完全な HTTP ステータスコードの数百桁です。出力結果の例では、全ての 2 万 9997 回のリプライが主要なステータスコード 2XX を持っていました。良い方の推測をすると、全てのステータスコードが 200 OK  である事です。しかし、ヒストグラムによる情報は同じ主要なコードでステータスコードを区別するのを許容するくらいには詳細ではありません。
</ul>
<p><strong>Miscellaneous Section</strong></p>
<ul>
`CPU time` はクライアントマシンの CPU 使用率のサマリーを示します。出力結果の例では、`CPU time` は、ユーザーモード (user) の実行に費やされた時間が 94.31 秒、システムモード (system) の実行に費やされた時間が 205.26 秒です。ユーザーモードの実行が 31.4%、システムモードの実行が 68.4% に相当します。また合計 CPU 使用率が 99.9% で、httperf は CPU に貪欲であることが予想できます。合計 CPU 使用率が 100% 未満である場合は、テストを妨げた競争しているプロセスがあったという重要なサインです。</p>
<p>`Net I/O` は、1 秒あたりの Kbyte (1kbyte=1024bytes) と、1 秒あたりの Mbit (1Mbit=10^6bits) における平均ネットワークスループットを示します。出力結果の例では、1 秒あたり約 129.6 Kbytes の平均してネットワーク帯域を使用しています。括弧の数は、これが 1 秒あたり約 1.1 Mbit に相当する事を示しています。このネットワーク回線帯域は、TCP コネクションのときに送られて、受け取ったバイト数に基づいて計算されます。言い換えれば、発生したかもしれない TCP 再送信またはネットワークヘッダーの account? になりません。
</ul>
<p><strong>Errors Section</strong></p>
<ul>
最後のセクションでは、テストを行っている間に発生したエラーの統計を示します。出力結果の例では、2 行の `Error` ラベルで、合計 3 個のエラーが発生し、3 個全てのエラーがサーバがコネクションの受け入れを拒否 (connrefused) した事を示しています。各エラーの詳細を以下に記述します。</p>
<p><strong>client-timo:</strong> クライアントタイムアウトのために呼び出しが失敗した回数。クライアントタイムアウトオプション (具体的に --timeout と--think-timeout) が正当であるか確認してください。</p>
<p><strong>socket-timo:</strong> TCP コネクションがソケットレベルでタイムアウトした回数 (ETIMEDOUT)</p>
<p><strong>connrefused:</strong> サーバによって拒否されたコネクションエラーに応じて失敗された TCP コネクションの回数 (ECONNREFUSED)</p>
<p><strong>connreset:</strong> サーバからの RESET のために失敗した TCP コネクションの回数。通常、サーバが既にコネクションを閉じたときに、クライアントがデータを送る試みを行うと RESET を受け取ります。listen queue が一杯のとき、新しいコネクションの確立を試みるとき、NT サーバは RESETs を送ります。</p>
<p><strong>fd-unavail:</strong> httperf プロセスがファイルディスクリプタを使い果たした回数。このカウントが 0 以外の場合はクライアントがオーバーロード状態であり、テスト結果が無意味である事を示します。(fd-unavail エラーの場合、コネクションを再生成できないため正統性が失われる) 詳しくは CHOOSING TIMEOUT VALUES セクションを見てください。</p>
<p><strong>addrunavail:</strong> 存在しないインタフェースが要求されたか、要求されたアドレスが ローカルではなかった回数。もしこのエラーが発生した場合は、テスト結果が無意味である事を示します。(EADDRNOTAVAIL)</p>
<p><strong>ftab-full:</strong> システムのファイルディスクリプタテーブルの上限に達した回数。もしこのエラーが発生した場合は、テスト結果が無意味である事を示します。(ulimit -n で上限値を上げる対策が考えられる)</p>
<p><strong>other:</strong> 上記以外のエラーが発生した回数。このカウントが 0 以外の場合は、エラーの本当の原因を探し出す必要があります。これを助けるために、httperf はテストの間に起こる最初の未知のエラーコードを表示します。
</ul>
<p>--wsess オプションまたは --wsesslog オプションが指定された場合、httperf はコネクション呼び出しの代わりにセッションを精製して測定します。そして、テストの終わりに追加情報を表示します。実際の表示例を以下に示します。</p>
<ul>
<strong>Session  rate [sess/s]:</strong> min 0.00 avg 0.59 max 2.40 stddev 0.37 (240/450)<br />
<strong>Session</strong>: avg 6.45 connections/session<br />
<strong>Session lifetime [s]:</strong> 123.9<br />
<strong>Session failtime [s]:</strong> 58.5<br />
<strong>Session length histogram:</strong> 4 7 4 ... 3 3 240
</ul>
<p>1 つのグループがあります。セッションに関係した結果で、`Session rate`、`Session`、`Session lifetime`、`Session failtime`、`Session length histogram` の 5 つの項目です。</p>
<p><strong>Session Section</strong></p>
<ul>
`Session rate` は、セッションが完了したときの 5 秒間隔のサンプルに基づいた最小、平均、最大のレートを示します。また、それはセッションの標準偏差を示します。括弧内の数は、いくつのセッションを行い、その内いくつのセッションがい成功したかを示しています。実際の例では、1 秒あたりの最小が 0.00、平均が 0.59、最大が 2.40、標準偏差は 0.37 でした。450 セッションの内、240 セッションが完了しました。210 は、タイムアウトなどのエラーのために失敗しました。</p>
<p>`Session` は、1 セッションの平均コネクション数を示します。実際の例では、1 セッションが完了するのに、平均 6.45 コネクションを必要とした事を示しています。</p>
<p>`Session lifetime` は、成功したセッションが終了するのに要した平均時間を示します。実際の例では、1.23.9 秒かかったことを示しています。</p>
<p>`Session failtime` は、失敗したセッションの平均時間を示します。実際の例では、セッションが失敗するには平均 58.5 秒かかったことを示しています。</p>
<p>最後に、`Session length  histogram` は、各セッションで受け取ったリプライ数のヒストグラムを示します。実際の例では、4 セッションが終了した後に、In the example above, 4 sessions ended after receiving no reply at	all,  7	 ended after receiving one  reply,  and  so  on  (the ellipsis  indicates additional histogram counts that were omitted from this manual for space reasons). このヒストグラムが成功したセッションと失敗したセッションを区別しないことに注意してください。
</ul>
<h3 class="subtitle">参考文献</h3>
<p>httperf-man-0.9.pdf<br />
<a href="http://www.hpl.hp.com/research/linux/httperf/httperf-man-0.9.pdf">http://www.hpl.hp.com/research/linux/httperf/httperf-man-0.9.pdf</a></p>
]]></content:encoded>
			<wfw:commentRss>http://na-ga.net/blog/?feed=rss2&amp;p=559</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>date コマンドのオプション</title>
		<link>http://na-ga.net/blog/?p=552</link>
		<comments>http://na-ga.net/blog/?p=552#comments</comments>
		<pubDate>Fri, 13 Nov 2009 11:11:26 +0000</pubDate>
		<dc:creator>na-ga</dc:creator>
				<category><![CDATA[未分類]]></category>

		<guid isPermaLink="false">http://na-ga.net/blog/?p=552</guid>
		<description><![CDATA[date コマンドのオプションの使い方メモ

日時を表示
実は色々と奥が深いコマンド！
シェルスクリプトを書くときにかなり便利。
PLAIN TEXT
CODE:




# date


Fri Nov 13 19:58:12 JST 2009&#160; &#160;// 引数なし


&#160;


# date +"%y-%m-%d %H:%M:%S"


09-11-13 20:00:52&#160; &#160; &#160; &#160; &#160; &#160; &#160; // 表示方法を変更


&#160;


# date +"%Y-%m-%d %H:%M:%S"


2009-11-13 19:59:13&#160; &#160; &#160; &#160; &#160; &#160; // 表示方法を変更


&#160;


# echo "`date +"%Y-%m-%d %H:%M:%S"`.`perl -e 'use Time::HiRes qw(gettimeofday); my($sec,$microsec)=gettimeofday(); print $microsec . "\n";'`"


2009-11-13 19:59:56.720774&#160; &#160; &#160;// マイクロ秒まで表示 (これがやりたかった)


&#160;


# date +"%Y-%m-%d %H:%M:%S" [...]]]></description>
			<content:encoded><![CDATA[<p>date コマンドのオプションの使い方メモ<br />
<span id="more-552"></span></p>
<h3 class="subtitle">日時を表示</h3>
<p>実は色々と奥が深いコマンド！<br />
シェルスクリプトを書くときにかなり便利。</p>
<div class="igBar"><span id="lcode-39"><a href="#" onclick="javascript:showCodeTxt('code-39'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-39">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># date</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">Fri Nov <span style="color:#800000;color:#800000;">13</span> <span style="color:#800000;color:#800000;">19</span>:<span style="color:#800000;color:#800000;">58</span>:<span style="color:#800000;color:#800000;">12</span> JST <span style="color:#800000;color:#800000;">2009</span>&nbsp; &nbsp;<span style="color:#FF9933; font-style:italic;">// 引数なし</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># date +<span style="color:#CC0000;">"%y-%m-%d %H:%M:%S"</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#800000;color:#800000;">09</span>-<span style="color:#800000;color:#800000;">11</span>-<span style="color:#800000;color:#800000;">13</span> <span style="color:#800000;color:#800000;">20</span>:<span style="color:#800000;color:#800000;">00</span>:<span style="color:#800000;color:#800000;">52</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// 表示方法を変更</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># date +<span style="color:#CC0000;">"%Y-%m-%d %H:%M:%S"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#800000;color:#800000;">2009</span>-<span style="color:#800000;color:#800000;">11</span>-<span style="color:#800000;color:#800000;">13</span> <span style="color:#800000;color:#800000;">19</span>:<span style="color:#800000;color:#800000;">59</span>:<span style="color:#800000;color:#800000;">13</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// 表示方法を変更</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># echo <span style="color:#CC0000;">"`date +"</span>%Y-%m-%d %H:%M:%S<span style="color:#CC0000;">"`.`perl -e 'use Time::HiRes qw(gettimeofday); my($sec,$microsec)=gettimeofday(); print $microsec . "</span>\n<span style="color:#CC0000;">";'`"</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#800000;color:#800000;">2009</span>-<span style="color:#800000;color:#800000;">11</span>-<span style="color:#800000;color:#800000;">13</span> <span style="color:#800000;color:#800000;">19</span>:<span style="color:#800000;color:#800000;">59</span>:<span style="color:#800000;color:#800000;">56</span>.<span style="color:#800000;color:#800000;">720774</span>&nbsp; &nbsp; &nbsp;<span style="color:#FF9933; font-style:italic;">// マイクロ秒まで表示 (これがやりたかった)</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># date +<span style="color:#CC0000;">"%Y-%m-%d %H:%M:%S"</span> --date <span style="color:#CC0000;">"1 day"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#800000;color:#800000;">2009</span>-<span style="color:#800000;color:#800000;">11</span>-<span style="color:#800000;color:#800000;">14</span> <span style="color:#800000;color:#800000;">20</span>:<span style="color:#800000;color:#800000;">04</span>:<span style="color:#800000;color:#800000;">43</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// 1 日後の日時で表示</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># date +<span style="color:#CC0000;">"%Y-%m-%d %H:%M:%S"</span> --date <span style="color:#CC0000;">"1 day ago"</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#800000;color:#800000;">2009</span>-<span style="color:#800000;color:#800000;">11</span>-<span style="color:#800000;color:#800000;">12</span> <span style="color:#800000;color:#800000;">20</span>:<span style="color:#800000;color:#800000;">05</span>:<span style="color:#800000;color:#800000;">18</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// 1 日前の日時で表示</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># date +<span style="color:#CC0000;">"%Y-%m-%d %H:%M:%S"</span> --date <span style="color:#CC0000;">"10 year 1 month ago 1 day ago 1 hour ago 1 minute ago 1 second ago"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#800000;color:#800000;">2019</span>-<span style="color:#800000;color:#800000;">10</span>-<span style="color:#800000;color:#800000;">12</span> <span style="color:#800000;color:#800000;">19</span>:<span style="color:#800000;color:#800000;">07</span>:<span style="color:#800000;color:#800000;">36</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// 10 年後の 1 ヶ月 1 日 1 時間 1 分 1 秒前の日時を表示 </span></div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>date_micro コマンド</p>
<div class="igBar"><span id="lcode-40"><a href="#" onclick="javascript:showCodeTxt('code-40'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-40">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># cat /bin/date_micro </div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">perl -e <span style="color:#CC0000;">'use Time::HiRes qw(gettimeofday); my($sec,$microsec)=gettimeofday(); print $microsec . &quot;<span style="color:#000099; font-weight:bold;">\n</span>&quot;;'</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># chmod +x /bin/date_micro </div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># date_micro | cut -c1-<span style="color:#800000;color:#800000;">3</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#800000;color:#800000;">531</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// 現在のミリ秒を表示</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># date_micro </div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#800000;color:#800000;">698378</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#FF9933; font-style:italic;">// 現在のマイクロ秒を表示</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># echo <span style="color:#CC0000;">"`date +"</span>%Y-%m-%d %H:%M:%S<span style="color:#CC0000;">"`.`date_micro | cut -c1-3`"</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#800000;color:#800000;">2009</span>-<span style="color:#800000;color:#800000;">11</span>-<span style="color:#800000;color:#800000;">13</span> <span style="color:#800000;color:#800000;">20</span>:<span style="color:#800000;color:#800000;">20</span>:<span style="color:#800000;color:#800000;">51</span>.<span style="color:#800000;color:#800000;">425</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// 現在の日時にミリ秒を加える</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># echo <span style="color:#CC0000;">"`date +"</span>%Y-%m-%d %H:%M:%S<span style="color:#CC0000;">"`.`date_micro`"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#800000;color:#800000;">2009</span>-<span style="color:#800000;color:#800000;">11</span>-<span style="color:#800000;color:#800000;">13</span> <span style="color:#800000;color:#800000;">20</span>:<span style="color:#800000;color:#800000;">21</span>:<span style="color:#800000;color:#800000;">18</span>.<span style="color:#800000;color:#800000;">815870</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#FF9933; font-style:italic;">// 現在の日時にマイクロ秒を加える </span></div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>以上</p>
]]></content:encoded>
			<wfw:commentRss>http://na-ga.net/blog/?feed=rss2&amp;p=552</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>WordPress のチューニングポイントを探す</title>
		<link>http://na-ga.net/blog/?p=544</link>
		<comments>http://na-ga.net/blog/?p=544#comments</comments>
		<pubDate>Fri, 13 Nov 2009 09:53:55 +0000</pubDate>
		<dc:creator>na-ga</dc:creator>
				<category><![CDATA[Apache]]></category>
		<category><![CDATA[MySQL]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[httperf]]></category>

		<guid isPermaLink="false">http://na-ga.net/blog/?p=544</guid>
		<description><![CDATA[WordPress の 1 ページを表示するには、複数のファイルにリクエストを出している。その中でも、実際にデータベースに問い合わせが発生するファイルが一番のリクエスト処理時間がかかると考えられる。ベンチマークソフトで負荷を生成し、WordPress のチューニングポイントを探す。

テスト環境
10.0.0.1 サーバで Apache + PHP (module) を動作させる。また、10.0.0.2 サーバで MySQL を動作させる。各サービスの設定項目はデフォルト値とする。最後に、10.0.0.3 サーバで httperf を動作させ、WordPress に対して負荷を生成する。
各サーバは CPU 3.6GHz Quad-Core、RAM 2048MB, SCSI 32GB で構成されている。各サーバは 1000BASE-T の単一スイッチで接続されている。ハードウェア性能、ネットワークがボトルネックになる心配はないと思う。
WordPress は version 2.8.4 で、設定項目はデフォルト値とし、デフォルトのテンプレートを使用する。適当な文字列のみを投稿した 1 ページに対して調査する。
1 ページを表示するのに必要なリクエスト
通常 WordPress に接続すると、デフォルトのテーマの場合 7 ファイルに接続している。これはアクセスログを見れば明らかで、具体的に示すと、以下のファイルである。これらのファイル群をまとめて、「バースト」と呼ぶ。
PLAIN TEXT
CODE:




&#91;10.0.0.3&#93;# cat -n wplog


&#160;


&#160; &#160; &#160;1&#160; /WordPress/?p=3


&#160; &#160; &#160;2&#160; &#160; /WordPress/wp-content/themes/default/style.css 


&#160; &#160; &#160;3&#160; &#160; /WordPress/wp-includes/js/comment-reply.js?ver=20090102


&#160; &#160; [...]]]></description>
			<content:encoded><![CDATA[<p>WordPress の 1 ページを表示するには、複数のファイルにリクエストを出している。その中でも、実際にデータベースに問い合わせが発生するファイルが一番のリクエスト処理時間がかかると考えられる。ベンチマークソフトで負荷を生成し、WordPress のチューニングポイントを探す。<br />
<span id="more-544"></span></p>
<h3 class="subtitle">テスト環境</h3>
<p>10.0.0.1 サーバで Apache + PHP (module) を動作させる。また、10.0.0.2 サーバで MySQL を動作させる。各サービスの設定項目はデフォルト値とする。最後に、10.0.0.3 サーバで httperf を動作させ、WordPress に対して負荷を生成する。</p>
<p>各サーバは CPU 3.6GHz Quad-Core、RAM 2048MB, SCSI 32GB で構成されている。各サーバは 1000BASE-T の単一スイッチで接続されている。ハードウェア性能、ネットワークがボトルネックになる心配はないと思う。</p>
<p>WordPress は version 2.8.4 で、設定項目はデフォルト値とし、デフォルトのテンプレートを使用する。適当な文字列のみを投稿した 1 ページに対して調査する。</p>
<h3 class="subtitle">1 ページを表示するのに必要なリクエスト</h3>
<p>通常 WordPress に接続すると、デフォルトのテーマの場合 7 ファイルに接続している。これはアクセスログを見れば明らかで、具体的に示すと、以下のファイルである。これらのファイル群をまとめて、「バースト」と呼ぶ。</p>
<div class="igBar"><span id="lcode-56"><a href="#" onclick="javascript:showCodeTxt('code-56'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-56">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span><span style="color:#006600; font-weight:bold;">&#93;</span># cat -n wplog</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &nbsp;<span style="color:#800000;color:#800000;">1</span>&nbsp; /WordPress/?p=<span style="color:#800000;color:#800000;">3</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &nbsp;<span style="color:#800000;color:#800000;">2</span>&nbsp; &nbsp; /WordPress/wp-content/themes/default/style.<span style="">css</span> </div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &nbsp;<span style="color:#800000;color:#800000;">3</span>&nbsp; &nbsp; /WordPress/wp-includes/js/comment-reply.<span style="">js</span>?ver=<span style="color:#800000;color:#800000;">20090102</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &nbsp;<span style="color:#800000;color:#800000;">4</span>&nbsp; &nbsp; /WordPress/wp-content/themes/default/images/kubrickbgcolor.<span style="">jpg</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &nbsp;<span style="color:#800000;color:#800000;">5</span>&nbsp; &nbsp; /WordPress/wp-content/themes/default/images/kubrickbgwide.<span style="">jpg</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &nbsp;<span style="color:#800000;color:#800000;">6</span>&nbsp; &nbsp; /WordPress/wp-content/themes/default/images/kubrickfooter.<span style="">jpg</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &nbsp;<span style="color:#800000;color:#800000;">7</span>&nbsp; &nbsp; /WordPress/wp-content/themes/default/images/kubrickheader.<span style="">jpg</span> </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<h3 class="subtitle">response time [ms] の測定</h3>
<p>バーストを表示するのにかかる response time [ms] を測定する。</p>
<div class="igBar"><span id="lcode-57"><a href="#" onclick="javascript:showCodeTxt('code-57'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-57">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span><span style="color:#006600; font-weight:bold;">&#93;</span># httperf --hog --server <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --wsesslog=<span style="color:#800000;color:#800000;">1</span>,<span style="color:#800000;color:#800000;">0</span>,wplog --rate=<span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; httperf --hog --client=<span style="color:#800000;color:#800000;">0</span>/<span style="color:#800000;color:#800000;">1</span> --server=<span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --port=<span style="color:#800000;color:#800000;">80</span> --uri=/ --rate=<span style="color:#800000;color:#800000;">1</span> --send-buffer=<span style="color:#800000;color:#800000;">4096</span> --recv-buffer=<span style="color:#800000;color:#800000;">16384</span> --wsesslog=<span style="color:#800000;color:#800000;">1</span>,<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">000</span>,wplog</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">Maximum connect burst length: <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Total: connections <span style="color:#800000;color:#800000;">1</span> requests <span style="color:#800000;color:#800000;">7</span> replies <span style="color:#800000;color:#800000;">7</span> test-duration <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">476</span> s</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection rate: <span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">1</span> conn/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">476</span>.<span style="color:#800000;color:#800000;">2</span> ms/conn, &lt;=<span style="color:#800000;color:#800000;">1</span> concurrent connections<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: min <span style="color:#800000;color:#800000;">476</span>.<span style="color:#800000;color:#800000;">2</span> avg <span style="color:#800000;color:#800000;">476</span>.<span style="color:#800000;color:#800000;">2</span> max <span style="color:#800000;color:#800000;">476</span>.<span style="color:#800000;color:#800000;">2</span> median <span style="color:#800000;color:#800000;">476</span>.<span style="color:#800000;color:#800000;">5</span> stddev <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: connect <span style="color:#800000;color:#800000;">4</span>.<span style="color:#800000;color:#800000;">3</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection length <span style="color:#006600; font-weight:bold;">&#91;</span>replies/conn<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">7</span>.<span style="color:#800000;color:#800000;">000</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Request rate: <span style="color:#800000;color:#800000;">14</span>.<span style="color:#800000;color:#800000;">7</span> req/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">68</span>.<span style="color:#800000;color:#800000;">0</span> ms/req<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Request size <span style="color:#006600; font-weight:bold;">&#91;</span>B<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">111</span>.<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply rate <span style="color:#006600; font-weight:bold;">&#91;</span>replies/s<span style="color:#006600; font-weight:bold;">&#93;</span>: min <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span> avg <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span> max <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span> stddev <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span> <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">0</span> samples<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: response <span style="color:#800000;color:#800000;">63</span>.<span style="color:#800000;color:#800000;">5</span> transfer <span style="color:#800000;color:#800000;">4</span>.<span style="color:#800000;color:#800000;">5</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply size <span style="color:#006600; font-weight:bold;">&#91;</span>B<span style="color:#006600; font-weight:bold;">&#93;</span>: header <span style="color:#800000;color:#800000;">233</span>.<span style="color:#800000;color:#800000;">0</span> content <span style="color:#800000;color:#800000;">4685</span>.<span style="color:#800000;color:#800000;">0</span> footer <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span> <span style="color:#006600; font-weight:bold;">&#40;</span>total <span style="color:#800000;color:#800000;">4918</span>.<span style="color:#800000;color:#800000;">0</span><span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply status: 1xx=<span style="color:#800000;color:#800000;">0</span> 2xx=<span style="color:#800000;color:#800000;">7</span> 3xx=<span style="color:#800000;color:#800000;">0</span> 4xx=<span style="color:#800000;color:#800000;">0</span> 5xx=<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; CPU time <span style="color:#006600; font-weight:bold;">&#91;</span>s<span style="color:#006600; font-weight:bold;">&#93;</span>: user <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">11</span> system <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">36</span> <span style="color:#006600; font-weight:bold;">&#40;</span>user <span style="color:#800000;color:#800000;">23</span>.<span style="color:#800000;color:#800000;">5</span>% system <span style="color:#800000;color:#800000;">76</span>.<span style="color:#800000;color:#800000;">4</span>% total <span style="color:#800000;color:#800000;">100</span>.<span style="color:#800000;color:#800000;">0</span>%<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Net I/O: <span style="color:#800000;color:#800000;">72</span>.<span style="color:#800000;color:#800000;">2</span> KB/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">6</span>*<span style="color:#800000;color:#800000;">10</span>^<span style="color:#800000;color:#800000;">6</span> bps<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Errors: total <span style="color:#800000;color:#800000;">0</span> client-timo <span style="color:#800000;color:#800000;">0</span> socket-timo <span style="color:#800000;color:#800000;">0</span> connrefused <span style="color:#800000;color:#800000;">0</span> connreset <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Errors: fd-unavail <span style="color:#800000;color:#800000;">0</span> addrunavail <span style="color:#800000;color:#800000;">0</span> ftab-full <span style="color:#800000;color:#800000;">0</span> other <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Session rate <span style="color:#006600; font-weight:bold;">&#91;</span>sess/s<span style="color:#006600; font-weight:bold;">&#93;</span>: min <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">00</span> avg <span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">10</span> max <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">00</span> stddev <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">00</span> <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">1</span>/<span style="color:#800000;color:#800000;">1</span><span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Session: avg <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">00</span> connections/session</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Session lifetime <span style="color:#006600; font-weight:bold;">&#91;</span>s<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">5</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Session failtime <span style="color:#006600; font-weight:bold;">&#91;</span>s<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Session length histogram: <span style="color:#800000;color:#800000;">0</span> <span style="color:#800000;color:#800000;">0</span> <span style="color:#800000;color:#800000;">0</span> <span style="color:#800000;color:#800000;">0</span> <span style="color:#800000;color:#800000;">0</span> <span style="color:#800000;color:#800000;">0</span> <span style="color:#800000;color:#800000;">0</span> <span style="color:#800000;color:#800000;">1</span> </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>上記結果から、1 リクエストあたりの平均 response time [ms] は、63.5 と分かった。1ページを表示するのにかかった response time [ms] は、444.5 (63.5*7) である。また、バーストの中で "/WordPress/?p=3" ファイルのみの response time [ms] を測定する。</p>
<div class="igBar"><span id="lcode-58"><a href="#" onclick="javascript:showCodeTxt('code-58'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-58">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># httperf --hog --server <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --uri=/WordPress/?p=<span style="color:#800000;color:#800000;">3</span> --num-conns=<span style="color:#800000;color:#800000;">1</span> --num-calls=<span style="color:#800000;color:#800000;">1</span> --rate=<span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; httperf --hog --client=<span style="color:#800000;color:#800000;">0</span>/<span style="color:#800000;color:#800000;">1</span> --server=<span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --port=<span style="color:#800000;color:#800000;">80</span> --uri=/WordPress/?p=<span style="color:#800000;color:#800000;">3</span> --rate=<span style="color:#800000;color:#800000;">1</span> --send-buffer=<span style="color:#800000;color:#800000;">4096</span> --recv-buffer=<span style="color:#800000;color:#800000;">16384</span> --num-conns=<span style="color:#800000;color:#800000;">1</span> --num-calls=<span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Maximum connect burst length: <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Total: connections <span style="color:#800000;color:#800000;">1</span> requests <span style="color:#800000;color:#800000;">1</span> replies <span style="color:#800000;color:#800000;">1</span> test-duration <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">469</span> s</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection rate: <span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">1</span> conn/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">469</span>.<span style="color:#800000;color:#800000;">4</span> ms/conn, &lt;=<span style="color:#800000;color:#800000;">1</span> concurrent connections<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: min <span style="color:#800000;color:#800000;">469</span>.<span style="color:#800000;color:#800000;">4</span> avg <span style="color:#800000;color:#800000;">469</span>.<span style="color:#800000;color:#800000;">4</span> max <span style="color:#800000;color:#800000;">469</span>.<span style="color:#800000;color:#800000;">4</span> median <span style="color:#800000;color:#800000;">469</span>.<span style="color:#800000;color:#800000;">5</span> stddev <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: connect <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection length <span style="color:#006600; font-weight:bold;">&#91;</span>replies/conn<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">000</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Request rate: <span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">1</span> req/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">469</span>.<span style="color:#800000;color:#800000;">4</span> ms/req<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Request size <span style="color:#006600; font-weight:bold;">&#91;</span>B<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">75</span>.<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply rate <span style="color:#006600; font-weight:bold;">&#91;</span>replies/s<span style="color:#006600; font-weight:bold;">&#93;</span>: min <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span> avg <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span> max <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span> stddev <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span> <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">0</span> samples<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: response <span style="color:#800000;color:#800000;">437</span>.<span style="color:#800000;color:#800000;">9</span> transfer <span style="color:#800000;color:#800000;">31</span>.<span style="color:#800000;color:#800000;">2</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply size <span style="color:#006600; font-weight:bold;">&#91;</span>B<span style="color:#006600; font-weight:bold;">&#93;</span>: header <span style="color:#800000;color:#800000;">230</span>.<span style="color:#800000;color:#800000;">0</span> content <span style="color:#800000;color:#800000;">9912</span>.<span style="color:#800000;color:#800000;">0</span> footer <span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">0</span> <span style="color:#006600; font-weight:bold;">&#40;</span>total <span style="color:#800000;color:#800000;">10144</span>.<span style="color:#800000;color:#800000;">0</span><span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply status: 1xx=<span style="color:#800000;color:#800000;">0</span> 2xx=<span style="color:#800000;color:#800000;">1</span> 3xx=<span style="color:#800000;color:#800000;">0</span> 4xx=<span style="color:#800000;color:#800000;">0</span> 5xx=<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; CPU time <span style="color:#006600; font-weight:bold;">&#91;</span>s<span style="color:#006600; font-weight:bold;">&#93;</span>: user <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">14</span> system <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">33</span> <span style="color:#006600; font-weight:bold;">&#40;</span>user <span style="color:#800000;color:#800000;">29</span>.<span style="color:#800000;color:#800000;">8</span>% system <span style="color:#800000;color:#800000;">69</span>.<span style="color:#800000;color:#800000;">9</span>% total <span style="color:#800000;color:#800000;">99</span>.<span style="color:#800000;color:#800000;">7</span>%<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Net I/O: <span style="color:#800000;color:#800000;">21</span>.<span style="color:#800000;color:#800000;">3</span> KB/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span>*<span style="color:#800000;color:#800000;">10</span>^<span style="color:#800000;color:#800000;">6</span> bps<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Errors: total <span style="color:#800000;color:#800000;">0</span> client-timo <span style="color:#800000;color:#800000;">0</span> socket-timo <span style="color:#800000;color:#800000;">0</span> connrefused <span style="color:#800000;color:#800000;">0</span> connreset <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Errors: fd-unavail <span style="color:#800000;color:#800000;">0</span> addrunavail <span style="color:#800000;color:#800000;">0</span> ftab-full <span style="color:#800000;color:#800000;">0</span> other <span style="color:#800000;color:#800000;">0</span> </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>上記結果から、437.9 とわかった。このように、バーストの中で圧倒的にリクエスト時間がかかるのが、"/WordPress/?p=3" である。他のファイルは static なので特に処理は必要ないが、"/WordPress/?p=3" はデータベースへの問い合わせが発生している。具体的にどんな問い合わせが発生しているのかを調べてみる。</p>
<h3 class="subtitle">1 ページを表示するのに発生するデータベースへの問い合わせ</h3>
<p>MySQL の設定項目はデフォルト値となっており、次のようになっている。</p>
<div class="igBar"><span id="lcode-59"><a href="#" onclick="javascript:showCodeTxt('code-59'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-59">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span><span style="color:#006600; font-weight:bold;">&#93;</span># cat /etc/my.<span style="">cnf</span> </div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color:#006600; font-weight:bold;">&#91;</span>mysqld<span style="color:#006600; font-weight:bold;">&#93;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; datadir=/var/lib/mysql</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; socket=/var/lib/mysql/mysql.<span style="">sock</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; user=mysql</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; old_passwords=<span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color:#006600; font-weight:bold;">&#91;</span>mysqld_safe<span style="color:#006600; font-weight:bold;">&#93;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; log-error=/var/log/mysqld.<span style="">log</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; pid-file=/var/run/mysqld/mysqld.<span style="">pid</span> </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>クエリー内容を調べるために、以下の処理を行う。</p>
<div class="igBar"><span id="lcode-60"><a href="#" onclick="javascript:showCodeTxt('code-60'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-60">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span><span style="color:#006600; font-weight:bold;">&#93;</span># cat /etc/my.<span style="">cnf</span> </div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color:#006600; font-weight:bold;">&#91;</span>mysqld<span style="color:#006600; font-weight:bold;">&#93;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; datadir=/var/lib/mysql</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; socket=/var/lib/mysql/mysql.<span style="">sock</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; user=mysql</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; old_passwords=<span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; log=/var/log/mysql-all.<span style="">log</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color:#006600; font-weight:bold;">&#91;</span>mysqld_safe<span style="color:#006600; font-weight:bold;">&#93;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; log-error=/var/log/mysqld.<span style="">log</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; pid-file=/var/run/mysqld/mysqld.<span style="">pid</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span><span style="color:#006600; font-weight:bold;">&#93;</span># rm -f /var/log/mysql-all.<span style="">log</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span><span style="color:#006600; font-weight:bold;">&#93;</span># touch /var/log/mysql-all.<span style="">log</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span><span style="color:#006600; font-weight:bold;">&#93;</span># chown mysql. /var/log/mysql-all.<span style="">log</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span><span style="color:#006600; font-weight:bold;">&#93;</span># service mysqld restart</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span><span style="color:#006600; font-weight:bold;">&#93;</span># cat /var/log/mysql-all.<span style="">log</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; /usr/libexec/mysqld, Version: <span style="color:#800000;color:#800000;">5</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">77</span>-log <span style="color:#006600; font-weight:bold;">&#40;</span>Source distribution<span style="color:#006600; font-weight:bold;">&#41;</span>. <span style="">started</span> with:</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Tcp port: <span style="color:#800000;color:#800000;">0</span>&nbsp; Unix socket: /var/lib/mysql/mysql.<span style="">sock</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Time&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;Id Command&nbsp; &nbsp; Argument</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color:#800000;color:#800000;">091113</span> <span style="color:#800000;color:#800000;">17</span>:<span style="color:#800000;color:#800000;">13</span>:<span style="color:#800000;color:#800000;">54</span>&nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#800000;color:#800000;">1</span> Connect&nbsp; &nbsp; &nbsp;UNKNOWN_MYSQL_US@localhost as anonymous on </div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#800000;color:#800000;">1</span> Quit </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>httperf で "/WordPress/?p=3" ファイルのみにリクエストを出す。</p>
<div class="igBar"><span id="lcode-61"><a href="#" onclick="javascript:showCodeTxt('code-61'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-61">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span><span style="color:#006600; font-weight:bold;">&#93;</span># httperf --hog --server <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --uri=/WordPress/?p=<span style="color:#800000;color:#800000;">3</span> --num-conns=<span style="color:#800000;color:#800000;">1</span> --num-calls=<span style="color:#800000;color:#800000;">1</span> --rate=<span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; httperf --hog --client=<span style="color:#800000;color:#800000;">0</span>/<span style="color:#800000;color:#800000;">1</span> --server=<span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --port=<span style="color:#800000;color:#800000;">80</span> --uri=/WordPress/?p=<span style="color:#800000;color:#800000;">3</span> --rate=<span style="color:#800000;color:#800000;">1</span> --send-buffer=<span style="color:#800000;color:#800000;">4096</span> --recv-buffer=<span style="color:#800000;color:#800000;">16384</span> --num-conns=<span style="color:#800000;color:#800000;">1</span> --num-calls=<span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Maximum connect burst length: <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Total: connections <span style="color:#800000;color:#800000;">1</span> requests <span style="color:#800000;color:#800000;">1</span> replies <span style="color:#800000;color:#800000;">1</span> test-duration <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">474</span> s</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection rate: <span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">1</span> conn/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">474</span>.<span style="color:#800000;color:#800000;">3</span> ms/conn, &lt;=<span style="color:#800000;color:#800000;">1</span> concurrent connections<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: min <span style="color:#800000;color:#800000;">474</span>.<span style="color:#800000;color:#800000;">3</span> avg <span style="color:#800000;color:#800000;">474</span>.<span style="color:#800000;color:#800000;">3</span> max <span style="color:#800000;color:#800000;">474</span>.<span style="color:#800000;color:#800000;">3</span> median <span style="color:#800000;color:#800000;">474</span>.<span style="color:#800000;color:#800000;">5</span> stddev <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: connect <span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">4</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection length <span style="color:#006600; font-weight:bold;">&#91;</span>replies/conn<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">000</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Request rate: <span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">1</span> req/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">474</span>.<span style="color:#800000;color:#800000;">3</span> ms/req<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Request size <span style="color:#006600; font-weight:bold;">&#91;</span>B<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">75</span>.<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply rate <span style="color:#006600; font-weight:bold;">&#91;</span>replies/s<span style="color:#006600; font-weight:bold;">&#93;</span>: min <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span> avg <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span> max <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span> stddev <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span> <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">0</span> samples<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: response <span style="color:#800000;color:#800000;">440</span>.<span style="color:#800000;color:#800000;">6</span> transfer <span style="color:#800000;color:#800000;">31</span>.<span style="color:#800000;color:#800000;">4</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply size <span style="color:#006600; font-weight:bold;">&#91;</span>B<span style="color:#006600; font-weight:bold;">&#93;</span>: header <span style="color:#800000;color:#800000;">230</span>.<span style="color:#800000;color:#800000;">0</span> content <span style="color:#800000;color:#800000;">9912</span>.<span style="color:#800000;color:#800000;">0</span> footer <span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">0</span> <span style="color:#006600; font-weight:bold;">&#40;</span>total <span style="color:#800000;color:#800000;">10144</span>.<span style="color:#800000;color:#800000;">0</span><span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply status: 1xx=<span style="color:#800000;color:#800000;">0</span> 2xx=<span style="color:#800000;color:#800000;">1</span> 3xx=<span style="color:#800000;color:#800000;">0</span> 4xx=<span style="color:#800000;color:#800000;">0</span> 5xx=<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; CPU time <span style="color:#006600; font-weight:bold;">&#91;</span>s<span style="color:#006600; font-weight:bold;">&#93;</span>: user <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">13</span> system <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">34</span> <span style="color:#006600; font-weight:bold;">&#40;</span>user <span style="color:#800000;color:#800000;">27</span>.<span style="color:#800000;color:#800000;">0</span>% system <span style="color:#800000;color:#800000;">72</span>.<span style="color:#800000;color:#800000;">5</span>% total <span style="color:#800000;color:#800000;">99</span>.<span style="color:#800000;color:#800000;">5</span>%<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Net I/O: <span style="color:#800000;color:#800000;">21</span>.<span style="color:#800000;color:#800000;">0</span> KB/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span>*<span style="color:#800000;color:#800000;">10</span>^<span style="color:#800000;color:#800000;">6</span> bps<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Errors: total <span style="color:#800000;color:#800000;">0</span> client-timo <span style="color:#800000;color:#800000;">0</span> socket-timo <span style="color:#800000;color:#800000;">0</span> connrefused <span style="color:#800000;color:#800000;">0</span> connreset <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Errors: fd-unavail <span style="color:#800000;color:#800000;">0</span> addrunavail <span style="color:#800000;color:#800000;">0</span> ftab-full <span style="color:#800000;color:#800000;">0</span> other <span style="color:#800000;color:#800000;">0</span> </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>/var/log/mysql-all.log ファイルを確認する。</p>
<div class="igBar"><span id="lcode-62"><a href="#" onclick="javascript:showCodeTxt('code-62'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-62">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span><span style="color:#006600; font-weight:bold;">&#93;</span># cat /var/log/mysql-all.<span style="">log</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; /usr/libexec/mysqld, Version: <span style="color:#800000;color:#800000;">5</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">77</span>-log <span style="color:#006600; font-weight:bold;">&#40;</span>Source distribution<span style="color:#006600; font-weight:bold;">&#41;</span>. <span style="">started</span> with:</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Tcp port: <span style="color:#800000;color:#800000;">0</span>&nbsp; Unix socket: /var/lib/mysql/mysql.<span style="">sock</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Time&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;Id Command&nbsp; &nbsp; Argument</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color:#800000;color:#800000;">091113</span> <span style="color:#800000;color:#800000;">17</span>:<span style="color:#800000;color:#800000;">13</span>:<span style="color:#800000;color:#800000;">54</span>&nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#800000;color:#800000;">1</span> Connect&nbsp; &nbsp; &nbsp;UNKNOWN_MYSQL_US@localhost as anonymous on </div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#800000;color:#800000;">1</span> Quit&nbsp; &nbsp; &nbsp; &nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color:#800000;color:#800000;">091113</span> <span style="color:#800000;color:#800000;">17</span>:<span style="color:#800000;color:#800000;">14</span>:<span style="color:#800000;color:#800000;">26</span>&nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#800000;color:#800000;">2</span> Connect&nbsp; &nbsp; &nbsp;httperf@<span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> on </div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#800000;color:#800000;">2</span> Query&nbsp; &nbsp; &nbsp; &nbsp;SET NAMES <span style="color:#CC0000;">'utf8'</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#800000;color:#800000;">2</span> Init DB&nbsp; &nbsp; &nbsp;httperf_db</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#800000;color:#800000;">2</span> Query&nbsp; &nbsp; &nbsp; &nbsp;SELECT option_name, option_value FROM wp_options WHERE autoload = <span style="color:#CC0000;">'yes'</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#800000;color:#800000;">2</span> Query&nbsp; &nbsp; &nbsp; &nbsp;SELECT option_value FROM wp_options WHERE option_name = <span style="color:#CC0000;">'sidebars_widgets'</span> LIMIT <span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#800000;color:#800000;">2</span> Query&nbsp; &nbsp; &nbsp; &nbsp;SELECT&nbsp; &nbsp;wp_posts.* FROM wp_posts&nbsp; WHERE <span style="color:#800000;color:#800000;">1</span>=<span style="color:#800000;color:#800000;">1</span>&nbsp; AND wp_posts.<span style="">ID</span> = <span style="color:#800000;color:#800000;">3</span> AND wp_posts.<span style="">post_type</span> = <span style="color:#CC0000;">'post'</span>&nbsp; ORDER BY wp_posts.<span style="">post_date</span> DESC</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#800000;color:#800000;">2</span> Query&nbsp; &nbsp; &nbsp; &nbsp;SELECT t.*, tt.*, tr.<span style="">object_id</span> FROM wp_terms AS t INNER JOIN wp_term_taxonomy AS tt ON tt.<span style="">term_id</span> = t.<span style="">term_id</span> INNER JOIN wp_term_relationships AS tr ON tr.<span style="">term_taxonomy_id</span> = tt.<span style="">term_taxonomy_id</span> WHERE tt.<span style="">taxonomy</span> IN <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'category'</span>, <span style="color:#CC0000;">'post_tag'</span><span style="color:#006600; font-weight:bold;">&#41;</span> AND tr.<span style="">object_id</span> IN <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">3</span><span style="color:#006600; font-weight:bold;">&#41;</span> ORDER BY t.<span style="">name</span> ASC</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#800000;color:#800000;">2</span> Query&nbsp; &nbsp; &nbsp; &nbsp;SELECT post_id, meta_key, meta_value FROM wp_postmeta WHERE post_id IN <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">3</span><span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#800000;color:#800000;">2</span> Query&nbsp; &nbsp; &nbsp; &nbsp;SELECT SQL_CALC_FOUND_ROWS&nbsp; wp_posts.* FROM wp_posts&nbsp; WHERE <span style="color:#800000;color:#800000;">1</span>=<span style="color:#800000;color:#800000;">1</span>&nbsp; AND wp_posts.<span style="">post_type</span> = <span style="color:#CC0000;">'post'</span> AND <span style="color:#006600; font-weight:bold;">&#40;</span>wp_posts.<span style="">post_status</span> = <span style="color:#CC0000;">'publish'</span><span style="color:#006600; font-weight:bold;">&#41;</span>&nbsp; ORDER BY wp_posts.<span style="">ID</span> ASC LIMIT <span style="color:#800000;color:#800000;">0</span>, <span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#800000;color:#800000;">2</span> Query&nbsp; &nbsp; &nbsp; &nbsp;SELECT FOUND_ROWS<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#800000;color:#800000;">2</span> Query&nbsp; &nbsp; &nbsp; &nbsp;SELECT t.*, tt.*, tr.<span style="">object_id</span> FROM wp_terms AS t INNER JOIN wp_term_taxonomy AS tt ON tt.<span style="">term_id</span> = t.<span style="">term_id</span> INNER JOIN wp_term_relationships AS tr ON tr.<span style="">term_taxonomy_id</span> = tt.<span style="">term_taxonomy_id</span> WHERE tt.<span style="">taxonomy</span> IN <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'category'</span>, <span style="color:#CC0000;">'post_tag'</span><span style="color:#006600; font-weight:bold;">&#41;</span> AND tr.<span style="">object_id</span> IN <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">1</span><span style="color:#006600; font-weight:bold;">&#41;</span> ORDER BY t.<span style="">name</span> ASC</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#800000;color:#800000;">2</span> Query&nbsp; &nbsp; &nbsp; &nbsp;SELECT post_id, meta_key, meta_value FROM wp_postmeta WHERE post_id IN <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">1</span><span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#800000;color:#800000;">2</span> Query&nbsp; &nbsp; &nbsp; &nbsp;SELECT p.* FROM wp_posts AS p&nbsp; WHERE p.<span style="">post_date</span> &lt;<span style="color:#CC0000;">'2009-11-08 16:46:10'</span> AND p.<span style="">post_type</span> = <span style="color:#CC0000;">'post'</span> AND p.<span style="">post_status</span> = <span style="color:#CC0000;">'publish'</span>&nbsp; ORDER BY p.<span style="">post_date</span> DESC LIMIT <span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#800000;color:#800000;">2</span> Query&nbsp; &nbsp; &nbsp; &nbsp;SELECT p.* FROM wp_posts AS p&nbsp; WHERE p.<span style="">post_date</span>&gt; <span style="color:#CC0000;">'2009-11-08 16:46:10'</span> AND p.<span style="">post_type</span> = <span style="color:#CC0000;">'post'</span> AND p.<span style="">post_status</span> = <span style="color:#CC0000;">'publish'</span>&nbsp; ORDER BY p.<span style="">post_date</span> ASC LIMIT <span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#800000;color:#800000;">2</span> Query&nbsp; &nbsp; &nbsp; &nbsp;SELECT option_value FROM wp_options WHERE option_name = <span style="color:#CC0000;">'kubrick_header_image'</span> LIMIT <span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#800000;color:#800000;">2</span> Query&nbsp; &nbsp; &nbsp; &nbsp;SELECT option_value FROM wp_options WHERE option_name = <span style="color:#CC0000;">'kubrick_header_color'</span> LIMIT <span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#800000;color:#800000;">2</span> Query&nbsp; &nbsp; &nbsp; &nbsp;SELECT option_value FROM wp_options WHERE option_name = <span style="color:#CC0000;">'kubrick_header_display'</span> LIMIT <span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#800000;color:#800000;">2</span> Query&nbsp; &nbsp; &nbsp; &nbsp;SELECT * FROM wp_users WHERE ID = <span style="color:#800000;color:#800000;">1</span> LIMIT <span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#800000;color:#800000;">2</span> Query&nbsp; &nbsp; &nbsp; &nbsp;SELECT meta_key, meta_value FROM wp_usermeta WHERE user_id = <span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#800000;color:#800000;">2</span> Query&nbsp; &nbsp; &nbsp; &nbsp;SELECT * FROM wp_comments WHERE comment_post_ID = <span style="color:#800000;color:#800000;">3</span> AND comment_approved = <span style="color:#CC0000;">'1'</span> ORDER BY comment_date_gmt ASC</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color:#800000;color:#800000;">091113</span> <span style="color:#800000;color:#800000;">17</span>:<span style="color:#800000;color:#800000;">14</span>:<span style="color:#800000;color:#800000;">27</span>&nbsp; &nbsp; &nbsp; &nbsp;<span style="color:#800000;color:#800000;">2</span> Quit </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>1 ページを表示するのに、20 回のクエリーが発生している。思っていたよりも多い結果だと思う。すべてのクエリーを保存するのはパフォーマンスを悪化させるため、設定ファイルを戻しておく。</p>
<div class="igBar"><span id="lcode-63"><a href="#" onclick="javascript:showCodeTxt('code-63'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-63">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span><span style="color:#006600; font-weight:bold;">&#93;</span># sed -i <span style="color:#CC0000;">'/^log=/d'</span> /etc/my.<span style="">cnf</span> </div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span><span style="color:#006600; font-weight:bold;">&#93;</span># cat /etc/my.<span style="">cnf</span> </div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color:#006600; font-weight:bold;">&#91;</span>mysqld<span style="color:#006600; font-weight:bold;">&#93;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; datadir=/var/lib/mysql</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; socket=/var/lib/mysql/mysql.<span style="">sock</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; user=mysql</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; old_passwords=<span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color:#006600; font-weight:bold;">&#91;</span>mysqld_safe<span style="color:#006600; font-weight:bold;">&#93;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; log-error=/var/log/mysqld.<span style="">log</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; pid-file=/var/run/mysqld/mysqld.<span style="">pid</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span><span style="color:#006600; font-weight:bold;">&#93;</span># service mysqld restart </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<h3 class="subtitle">負荷が高い状況での response time [ms]</h3>
<p>同時に 1 人が WordPress のページを表示している状況の場合の response time [ms] を測定する。本来ならバースト全てのファイルでやるべきだが、バーストの中で一番処理時間がかかる "/WordPress/?p=3" ファイルのみにリクエストを出す。</p>
<div class="igBar"><span id="lcode-64"><a href="#" onclick="javascript:showCodeTxt('code-64'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-64">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span><span style="color:#006600; font-weight:bold;">&#93;</span># ssh <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span> <span style="color:#CC0000;">"service mysqld restart"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span><span style="color:#006600; font-weight:bold;">&#93;</span># httperf --hog --server <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --uri=/WordPress/?p=<span style="color:#800000;color:#800000;">3</span> --num-conns=<span style="color:#800000;color:#800000;">100</span> --num-calls=<span style="color:#800000;color:#800000;">1</span> --rate=<span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; httperf --hog --client=<span style="color:#800000;color:#800000;">0</span>/<span style="color:#800000;color:#800000;">1</span> --server=<span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --port=<span style="color:#800000;color:#800000;">80</span> --uri=/WordPress/?p=<span style="color:#800000;color:#800000;">3</span> --rate=<span style="color:#800000;color:#800000;">1</span> --send-buffer=<span style="color:#800000;color:#800000;">4096</span> --recv-buffer=<span style="color:#800000;color:#800000;">16384</span> --num-conns=<span style="color:#800000;color:#800000;">100</span> --num-calls=<span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Maximum connect burst length: <span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Total: connections <span style="color:#800000;color:#800000;">100</span> requests <span style="color:#800000;color:#800000;">100</span> replies <span style="color:#800000;color:#800000;">100</span> test-duration <span style="color:#800000;color:#800000;">99</span>.<span style="color:#800000;color:#800000;">465</span> s</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection rate: <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">0</span> conn/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">994</span>.<span style="color:#800000;color:#800000;">7</span> ms/conn, &lt;=<span style="color:#800000;color:#800000;">1</span> concurrent connections<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: min <span style="color:#800000;color:#800000;">462</span>.<span style="color:#800000;color:#800000;">9</span> avg <span style="color:#800000;color:#800000;">468</span>.<span style="color:#800000;color:#800000;">0</span> max <span style="color:#800000;color:#800000;">493</span>.<span style="color:#800000;color:#800000;">0</span> median <span style="color:#800000;color:#800000;">464</span>.<span style="color:#800000;color:#800000;">5</span> stddev <span style="color:#800000;color:#800000;">6</span>.<span style="color:#800000;color:#800000;">8</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: connect <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection length <span style="color:#006600; font-weight:bold;">&#91;</span>replies/conn<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">000</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Request rate: <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">0</span> req/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">994</span>.<span style="color:#800000;color:#800000;">7</span> ms/req<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Request size <span style="color:#006600; font-weight:bold;">&#91;</span>B<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">75</span>.<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply rate <span style="color:#006600; font-weight:bold;">&#91;</span>replies/s<span style="color:#006600; font-weight:bold;">&#93;</span>: min <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">0</span> avg <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">0</span> max <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">0</span> stddev <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span> <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">19</span> samples<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: response <span style="color:#800000;color:#800000;">436</span>.<span style="color:#800000;color:#800000;">4</span> transfer <span style="color:#800000;color:#800000;">31</span>.<span style="color:#800000;color:#800000;">4</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply size <span style="color:#006600; font-weight:bold;">&#91;</span>B<span style="color:#006600; font-weight:bold;">&#93;</span>: header <span style="color:#800000;color:#800000;">230</span>.<span style="color:#800000;color:#800000;">0</span> content <span style="color:#800000;color:#800000;">9912</span>.<span style="color:#800000;color:#800000;">0</span> footer <span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">0</span> <span style="color:#006600; font-weight:bold;">&#40;</span>total <span style="color:#800000;color:#800000;">10144</span>.<span style="color:#800000;color:#800000;">0</span><span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply status: 1xx=<span style="color:#800000;color:#800000;">0</span> 2xx=<span style="color:#800000;color:#800000;">100</span> 3xx=<span style="color:#800000;color:#800000;">0</span> 4xx=<span style="color:#800000;color:#800000;">0</span> 5xx=<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; CPU time <span style="color:#006600; font-weight:bold;">&#91;</span>s<span style="color:#006600; font-weight:bold;">&#93;</span>: user <span style="color:#800000;color:#800000;">27</span>.<span style="color:#800000;color:#800000;">84</span> system <span style="color:#800000;color:#800000;">71</span>.<span style="color:#800000;color:#800000;">63</span> <span style="color:#006600; font-weight:bold;">&#40;</span>user <span style="color:#800000;color:#800000;">28</span>.<span style="color:#800000;color:#800000;">0</span>% system <span style="color:#800000;color:#800000;">72</span>.<span style="color:#800000;color:#800000;">0</span>% total <span style="color:#800000;color:#800000;">100</span>.<span style="color:#800000;color:#800000;">0</span>%<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Net I/O: <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span> KB/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span>*<span style="color:#800000;color:#800000;">10</span>^<span style="color:#800000;color:#800000;">6</span> bps<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Errors: total <span style="color:#800000;color:#800000;">0</span> client-timo <span style="color:#800000;color:#800000;">0</span> socket-timo <span style="color:#800000;color:#800000;">0</span> connrefused <span style="color:#800000;color:#800000;">0</span> connreset <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Errors: fd-unavail <span style="color:#800000;color:#800000;">0</span> addrunavail <span style="color:#800000;color:#800000;">0</span> ftab-full <span style="color:#800000;color:#800000;">0</span> other <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span><span style="color:#006600; font-weight:bold;">&#93;</span># ssh <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span> <span style="color:#CC0000;">"mysqladmin -uroot extended-status | grep -e Threads -e Max"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Max_used_connections&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">1</span>&nbsp; &nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Threads_cached&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">0</span>&nbsp; &nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Threads_connected&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">1</span>&nbsp; &nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Threads_created&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">107</span>&nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Threads_running&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">1</span>&nbsp; &nbsp; &nbsp; &nbsp; | </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>同時に 5 人が WordPress のページを表示している状況の場合。</p>
<div class="igBar"><span id="lcode-65"><a href="#" onclick="javascript:showCodeTxt('code-65'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-65">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span><span style="color:#006600; font-weight:bold;">&#93;</span># ssh <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span> <span style="color:#CC0000;">"service mysqld restart"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span><span style="color:#006600; font-weight:bold;">&#93;</span># httperf --hog --server <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --uri=/WordPress/?p=<span style="color:#800000;color:#800000;">3</span> --num-conns=<span style="color:#800000;color:#800000;">100</span> --num-calls=<span style="color:#800000;color:#800000;">1</span> --rate=<span style="color:#800000;color:#800000;">5</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; httperf --hog --client=<span style="color:#800000;color:#800000;">0</span>/<span style="color:#800000;color:#800000;">1</span> --server=<span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --port=<span style="color:#800000;color:#800000;">80</span> --uri=/WordPress/?p=<span style="color:#800000;color:#800000;">3</span> --rate=<span style="color:#800000;color:#800000;">5</span> --send-buffer=<span style="color:#800000;color:#800000;">4096</span> --recv-buffer=<span style="color:#800000;color:#800000;">16384</span> --num-conns=<span style="color:#800000;color:#800000;">100</span> --num-calls=<span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Maximum connect burst length: <span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Total: connections <span style="color:#800000;color:#800000;">100</span> requests <span style="color:#800000;color:#800000;">100</span> replies <span style="color:#800000;color:#800000;">100</span> test-duration <span style="color:#800000;color:#800000;">21</span>.<span style="color:#800000;color:#800000;">124</span> s</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection rate: <span style="color:#800000;color:#800000;">4</span>.<span style="color:#800000;color:#800000;">7</span> conn/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">211</span>.<span style="color:#800000;color:#800000;">2</span> ms/conn, &lt;=<span style="color:#800000;color:#800000;">12</span> concurrent connections<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: min <span style="color:#800000;color:#800000;">491</span>.<span style="color:#800000;color:#800000;">8</span> avg <span style="color:#800000;color:#800000;">1478</span>.<span style="color:#800000;color:#800000;">1</span> max <span style="color:#800000;color:#800000;">4888</span>.<span style="color:#800000;color:#800000;">7</span> median <span style="color:#800000;color:#800000;">1377</span>.<span style="color:#800000;color:#800000;">5</span> stddev <span style="color:#800000;color:#800000;">702</span>.<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: connect <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection length <span style="color:#006600; font-weight:bold;">&#91;</span>replies/conn<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">000</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Request rate: <span style="color:#800000;color:#800000;">4</span>.<span style="color:#800000;color:#800000;">7</span> req/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">211</span>.<span style="color:#800000;color:#800000;">2</span> ms/req<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Request size <span style="color:#006600; font-weight:bold;">&#91;</span>B<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">75</span>.<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply rate <span style="color:#006600; font-weight:bold;">&#91;</span>replies/s<span style="color:#006600; font-weight:bold;">&#93;</span>: min <span style="color:#800000;color:#800000;">4</span>.<span style="color:#800000;color:#800000;">2</span> avg <span style="color:#800000;color:#800000;">4</span>.<span style="color:#800000;color:#800000;">5</span> max <span style="color:#800000;color:#800000;">4</span>.<span style="color:#800000;color:#800000;">8</span> stddev <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span> <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">4</span> samples<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: response <span style="color:#800000;color:#800000;">1422</span>.<span style="color:#800000;color:#800000;">1</span> transfer <span style="color:#800000;color:#800000;">55</span>.<span style="color:#800000;color:#800000;">8</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply size <span style="color:#006600; font-weight:bold;">&#91;</span>B<span style="color:#006600; font-weight:bold;">&#93;</span>: header <span style="color:#800000;color:#800000;">230</span>.<span style="color:#800000;color:#800000;">0</span> content <span style="color:#800000;color:#800000;">9912</span>.<span style="color:#800000;color:#800000;">0</span> footer <span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">0</span> <span style="color:#006600; font-weight:bold;">&#40;</span>total <span style="color:#800000;color:#800000;">10144</span>.<span style="color:#800000;color:#800000;">0</span><span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply status: 1xx=<span style="color:#800000;color:#800000;">0</span> 2xx=<span style="color:#800000;color:#800000;">100</span> 3xx=<span style="color:#800000;color:#800000;">0</span> 4xx=<span style="color:#800000;color:#800000;">0</span> 5xx=<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; CPU time <span style="color:#006600; font-weight:bold;">&#91;</span>s<span style="color:#006600; font-weight:bold;">&#93;</span>: user <span style="color:#800000;color:#800000;">4</span>.<span style="color:#800000;color:#800000;">74</span> system <span style="color:#800000;color:#800000;">16</span>.<span style="color:#800000;color:#800000;">39</span> <span style="color:#006600; font-weight:bold;">&#40;</span>user <span style="color:#800000;color:#800000;">22</span>.<span style="color:#800000;color:#800000;">4</span>% system <span style="color:#800000;color:#800000;">77</span>.<span style="color:#800000;color:#800000;">6</span>% total <span style="color:#800000;color:#800000;">100</span>.<span style="color:#800000;color:#800000;">0</span>%<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Net I/O: <span style="color:#800000;color:#800000;">47</span>.<span style="color:#800000;color:#800000;">2</span> KB/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">4</span>*<span style="color:#800000;color:#800000;">10</span>^<span style="color:#800000;color:#800000;">6</span> bps<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Errors: total <span style="color:#800000;color:#800000;">0</span> client-timo <span style="color:#800000;color:#800000;">0</span> socket-timo <span style="color:#800000;color:#800000;">0</span> connrefused <span style="color:#800000;color:#800000;">0</span> connreset <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Errors: fd-unavail <span style="color:#800000;color:#800000;">0</span> addrunavail <span style="color:#800000;color:#800000;">0</span> ftab-full <span style="color:#800000;color:#800000;">0</span> other <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span><span style="color:#006600; font-weight:bold;">&#93;</span># ssh <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span> <span style="color:#CC0000;">"mysqladmin -uroot extended-status | grep -e Threads -e Max"</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Max_used_connections&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">12</span>&nbsp; &nbsp; &nbsp; &nbsp;|</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Threads_cached&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">0</span>&nbsp; &nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Threads_connected&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">1</span>&nbsp; &nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Threads_created&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">102</span>&nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Threads_running&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">1</span>&nbsp; &nbsp; &nbsp; &nbsp; | </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>同時に 10 人が WordPress のページを表示している状況の場合。</p>
<div class="igBar"><span id="lcode-66"><a href="#" onclick="javascript:showCodeTxt('code-66'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-66">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span><span style="color:#006600; font-weight:bold;">&#93;</span># ssh <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span> <span style="color:#CC0000;">"service mysqld restart"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span><span style="color:#006600; font-weight:bold;">&#93;</span># httperf --hog --server <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --uri=/WordPress/?p=<span style="color:#800000;color:#800000;">3</span> --num-conns=<span style="color:#800000;color:#800000;">100</span> --num-calls=<span style="color:#800000;color:#800000;">1</span> --rate=<span style="color:#800000;color:#800000;">10</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; httperf --hog --client=<span style="color:#800000;color:#800000;">0</span>/<span style="color:#800000;color:#800000;">1</span> --server=<span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --port=<span style="color:#800000;color:#800000;">80</span> --uri=/WordPress/?p=<span style="color:#800000;color:#800000;">3</span> --rate=<span style="color:#800000;color:#800000;">10</span> --send-buffer=<span style="color:#800000;color:#800000;">4096</span> --recv-buffer=<span style="color:#800000;color:#800000;">16384</span> --num-conns=<span style="color:#800000;color:#800000;">100</span> --num-calls=<span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Maximum connect burst length: <span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Total: connections <span style="color:#800000;color:#800000;">100</span> requests <span style="color:#800000;color:#800000;">100</span> replies <span style="color:#800000;color:#800000;">100</span> test-duration <span style="color:#800000;color:#800000;">21</span>.<span style="color:#800000;color:#800000;">002</span> s</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection rate: <span style="color:#800000;color:#800000;">4</span>.<span style="color:#800000;color:#800000;">8</span> conn/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">210</span>.<span style="color:#800000;color:#800000;">0</span> ms/conn, &lt;=<span style="color:#800000;color:#800000;">65</span> concurrent connections<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: min <span style="color:#800000;color:#800000;">1283</span>.<span style="color:#800000;color:#800000;">8</span> avg <span style="color:#800000;color:#800000;">7690</span>.<span style="color:#800000;color:#800000;">3</span> max <span style="color:#800000;color:#800000;">12514</span>.<span style="color:#800000;color:#800000;">7</span> median <span style="color:#800000;color:#800000;">7629</span>.<span style="color:#800000;color:#800000;">5</span> stddev <span style="color:#800000;color:#800000;">3051</span>.<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: connect <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection length <span style="color:#006600; font-weight:bold;">&#91;</span>replies/conn<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">000</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Request rate: <span style="color:#800000;color:#800000;">4</span>.<span style="color:#800000;color:#800000;">8</span> req/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">210</span>.<span style="color:#800000;color:#800000;">0</span> ms/req<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Request size <span style="color:#006600; font-weight:bold;">&#91;</span>B<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">75</span>.<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply rate <span style="color:#006600; font-weight:bold;">&#91;</span>replies/s<span style="color:#006600; font-weight:bold;">&#93;</span>: min <span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">0</span> avg <span style="color:#800000;color:#800000;">4</span>.<span style="color:#800000;color:#800000;">3</span> max <span style="color:#800000;color:#800000;">5</span>.<span style="color:#800000;color:#800000;">2</span> stddev <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">5</span> <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">4</span> samples<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: response <span style="color:#800000;color:#800000;">7632</span>.<span style="color:#800000;color:#800000;">7</span> transfer <span style="color:#800000;color:#800000;">57</span>.<span style="color:#800000;color:#800000;">4</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply size <span style="color:#006600; font-weight:bold;">&#91;</span>B<span style="color:#006600; font-weight:bold;">&#93;</span>: header <span style="color:#800000;color:#800000;">230</span>.<span style="color:#800000;color:#800000;">0</span> content <span style="color:#800000;color:#800000;">9912</span>.<span style="color:#800000;color:#800000;">0</span> footer <span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">0</span> <span style="color:#006600; font-weight:bold;">&#40;</span>total <span style="color:#800000;color:#800000;">10144</span>.<span style="color:#800000;color:#800000;">0</span><span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply status: 1xx=<span style="color:#800000;color:#800000;">0</span> 2xx=<span style="color:#800000;color:#800000;">100</span> 3xx=<span style="color:#800000;color:#800000;">0</span> 4xx=<span style="color:#800000;color:#800000;">0</span> 5xx=<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; CPU time <span style="color:#006600; font-weight:bold;">&#91;</span>s<span style="color:#006600; font-weight:bold;">&#93;</span>: user <span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">47</span> system <span style="color:#800000;color:#800000;">18</span>.<span style="color:#800000;color:#800000;">53</span> <span style="color:#006600; font-weight:bold;">&#40;</span>user <span style="color:#800000;color:#800000;">11</span>.<span style="color:#800000;color:#800000;">8</span>% system <span style="color:#800000;color:#800000;">88</span>.<span style="color:#800000;color:#800000;">2</span>% total <span style="color:#800000;color:#800000;">100</span>.<span style="color:#800000;color:#800000;">0</span>%<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Net I/O: <span style="color:#800000;color:#800000;">47</span>.<span style="color:#800000;color:#800000;">5</span> KB/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">4</span>*<span style="color:#800000;color:#800000;">10</span>^<span style="color:#800000;color:#800000;">6</span> bps<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Errors: total <span style="color:#800000;color:#800000;">0</span> client-timo <span style="color:#800000;color:#800000;">0</span> socket-timo <span style="color:#800000;color:#800000;">0</span> connrefused <span style="color:#800000;color:#800000;">0</span> connreset <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Errors: fd-unavail <span style="color:#800000;color:#800000;">0</span> addrunavail <span style="color:#800000;color:#800000;">0</span> ftab-full <span style="color:#800000;color:#800000;">0</span> other <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span><span style="color:#006600; font-weight:bold;">&#93;</span># ssh <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span> <span style="color:#CC0000;">"mysqladmin -uroot extended-status | grep -e Threads -e Max"</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Max_used_connections&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">20</span>&nbsp; &nbsp; &nbsp; &nbsp;|</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Threads_cached&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">0</span>&nbsp; &nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Threads_connected&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">1</span>&nbsp; &nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Threads_created&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">102</span>&nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Threads_running&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">1</span>&nbsp; &nbsp; &nbsp; &nbsp; | </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>同時に 20 人が WordPress のページを表示している状況の場合。</p>
<div class="igBar"><span id="lcode-67"><a href="#" onclick="javascript:showCodeTxt('code-67'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-67">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span><span style="color:#006600; font-weight:bold;">&#93;</span># ssh <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span> <span style="color:#CC0000;">"service mysqld restart"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span><span style="color:#006600; font-weight:bold;">&#93;</span># httperf --hog --server <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --uri=/WordPress/?p=<span style="color:#800000;color:#800000;">3</span> --num-conns=<span style="color:#800000;color:#800000;">100</span> --num-calls=<span style="color:#800000;color:#800000;">1</span> --rate=<span style="color:#800000;color:#800000;">20</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; httperf --hog --client=<span style="color:#800000;color:#800000;">0</span>/<span style="color:#800000;color:#800000;">1</span> --server=<span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --port=<span style="color:#800000;color:#800000;">80</span> --uri=/WordPress/?p=<span style="color:#800000;color:#800000;">3</span> --rate=<span style="color:#800000;color:#800000;">20</span> --send-buffer=<span style="color:#800000;color:#800000;">4096</span> --recv-buffer=<span style="color:#800000;color:#800000;">16384</span> --num-conns=<span style="color:#800000;color:#800000;">100</span> --num-calls=<span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Maximum connect burst length: <span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Total: connections <span style="color:#800000;color:#800000;">100</span> requests <span style="color:#800000;color:#800000;">100</span> replies <span style="color:#800000;color:#800000;">100</span> test-duration <span style="color:#800000;color:#800000;">21</span>.<span style="color:#800000;color:#800000;">443</span> s</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection rate: <span style="color:#800000;color:#800000;">4</span>.<span style="color:#800000;color:#800000;">7</span> conn/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">214</span>.<span style="color:#800000;color:#800000;">4</span> ms/conn, &lt;=<span style="color:#800000;color:#800000;">83</span> concurrent connections<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: min <span style="color:#800000;color:#800000;">2649</span>.<span style="color:#800000;color:#800000;">3</span> avg <span style="color:#800000;color:#800000;">10238</span>.<span style="color:#800000;color:#800000;">4</span> max <span style="color:#800000;color:#800000;">21242</span>.<span style="color:#800000;color:#800000;">6</span> median <span style="color:#800000;color:#800000;">10376</span>.<span style="color:#800000;color:#800000;">5</span> stddev <span style="color:#800000;color:#800000;">4591</span>.<span style="color:#800000;color:#800000;">8</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: connect <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection length <span style="color:#006600; font-weight:bold;">&#91;</span>replies/conn<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">000</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Request rate: <span style="color:#800000;color:#800000;">4</span>.<span style="color:#800000;color:#800000;">7</span> req/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">214</span>.<span style="color:#800000;color:#800000;">4</span> ms/req<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Request size <span style="color:#006600; font-weight:bold;">&#91;</span>B<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">75</span>.<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply rate <span style="color:#006600; font-weight:bold;">&#91;</span>replies/s<span style="color:#006600; font-weight:bold;">&#93;</span>: min <span style="color:#800000;color:#800000;">3</span>.<span style="color:#800000;color:#800000;">4</span> avg <span style="color:#800000;color:#800000;">4</span>.<span style="color:#800000;color:#800000;">2</span> max <span style="color:#800000;color:#800000;">4</span>.<span style="color:#800000;color:#800000;">6</span> stddev <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">5</span> <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">4</span> samples<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: response <span style="color:#800000;color:#800000;">10180</span>.<span style="color:#800000;color:#800000;">1</span> transfer <span style="color:#800000;color:#800000;">58</span>.<span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply size <span style="color:#006600; font-weight:bold;">&#91;</span>B<span style="color:#006600; font-weight:bold;">&#93;</span>: header <span style="color:#800000;color:#800000;">230</span>.<span style="color:#800000;color:#800000;">0</span> content <span style="color:#800000;color:#800000;">9912</span>.<span style="color:#800000;color:#800000;">0</span> footer <span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">0</span> <span style="color:#006600; font-weight:bold;">&#40;</span>total <span style="color:#800000;color:#800000;">10144</span>.<span style="color:#800000;color:#800000;">0</span><span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply status: 1xx=<span style="color:#800000;color:#800000;">0</span> 2xx=<span style="color:#800000;color:#800000;">100</span> 3xx=<span style="color:#800000;color:#800000;">0</span> 4xx=<span style="color:#800000;color:#800000;">0</span> 5xx=<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; CPU time <span style="color:#006600; font-weight:bold;">&#91;</span>s<span style="color:#006600; font-weight:bold;">&#93;</span>: user <span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">19</span> system <span style="color:#800000;color:#800000;">19</span>.<span style="color:#800000;color:#800000;">25</span> <span style="color:#006600; font-weight:bold;">&#40;</span>user <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">2</span>% system <span style="color:#800000;color:#800000;">89</span>.<span style="color:#800000;color:#800000;">8</span>% total <span style="color:#800000;color:#800000;">100</span>.<span style="color:#800000;color:#800000;">0</span>%<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Net I/O: <span style="color:#800000;color:#800000;">46</span>.<span style="color:#800000;color:#800000;">5</span> KB/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">4</span>*<span style="color:#800000;color:#800000;">10</span>^<span style="color:#800000;color:#800000;">6</span> bps<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Errors: total <span style="color:#800000;color:#800000;">0</span> client-timo <span style="color:#800000;color:#800000;">0</span> socket-timo <span style="color:#800000;color:#800000;">0</span> connrefused <span style="color:#800000;color:#800000;">0</span> connreset <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Errors: fd-unavail <span style="color:#800000;color:#800000;">0</span> addrunavail <span style="color:#800000;color:#800000;">0</span> ftab-full <span style="color:#800000;color:#800000;">0</span> other <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span><span style="color:#006600; font-weight:bold;">&#93;</span># ssh <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span> <span style="color:#CC0000;">"mysqladmin -uroot extended-status | grep -e Threads -e Max"</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Max_used_connections&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">22</span>&nbsp; &nbsp; &nbsp; &nbsp;|</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Threads_cached&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">0</span>&nbsp; &nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Threads_connected&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">1</span>&nbsp; &nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Threads_created&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">102</span>&nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Threads_running&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">1</span>&nbsp; &nbsp; &nbsp; &nbsp; | </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>同時に 50 人が WordPress のページを表示している状況の場合。</p>
<div class="igBar"><span id="lcode-68"><a href="#" onclick="javascript:showCodeTxt('code-68'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-68">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span><span style="color:#006600; font-weight:bold;">&#93;</span># ssh <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span> <span style="color:#CC0000;">"service mysqld restart"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span><span style="color:#006600; font-weight:bold;">&#93;</span># httperf --hog --server <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --uri=/WordPress/?p=<span style="color:#800000;color:#800000;">3</span> --num-conns=<span style="color:#800000;color:#800000;">100</span> --num-calls=<span style="color:#800000;color:#800000;">1</span> --rate=<span style="color:#800000;color:#800000;">50</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; httperf --hog --client=<span style="color:#800000;color:#800000;">0</span>/<span style="color:#800000;color:#800000;">1</span> --server=<span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --port=<span style="color:#800000;color:#800000;">80</span> --uri=/WordPress/?p=<span style="color:#800000;color:#800000;">3</span> --rate=<span style="color:#800000;color:#800000;">50</span> --send-buffer=<span style="color:#800000;color:#800000;">4096</span> --recv-buffer=<span style="color:#800000;color:#800000;">16384</span> --num-conns=<span style="color:#800000;color:#800000;">100</span> --num-calls=<span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Maximum connect burst length: <span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Total: connections <span style="color:#800000;color:#800000;">100</span> requests <span style="color:#800000;color:#800000;">100</span> replies <span style="color:#800000;color:#800000;">100</span> test-duration <span style="color:#800000;color:#800000;">21</span>.<span style="color:#800000;color:#800000;">210</span> s</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection rate: <span style="color:#800000;color:#800000;">4</span>.<span style="color:#800000;color:#800000;">7</span> conn/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">212</span>.<span style="color:#800000;color:#800000;">1</span> ms/conn, &lt;=<span style="color:#800000;color:#800000;">100</span> concurrent connections<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: min <span style="color:#800000;color:#800000;">2634</span>.<span style="color:#800000;color:#800000;">4</span> avg <span style="color:#800000;color:#800000;">11377</span>.<span style="color:#800000;color:#800000;">5</span> max <span style="color:#800000;color:#800000;">20183</span>.<span style="color:#800000;color:#800000;">5</span> median <span style="color:#800000;color:#800000;">11855</span>.<span style="color:#800000;color:#800000;">5</span> stddev <span style="color:#800000;color:#800000;">5254</span>.<span style="color:#800000;color:#800000;">8</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: connect <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection length <span style="color:#006600; font-weight:bold;">&#91;</span>replies/conn<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">000</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Request rate: <span style="color:#800000;color:#800000;">4</span>.<span style="color:#800000;color:#800000;">7</span> req/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">212</span>.<span style="color:#800000;color:#800000;">1</span> ms/req<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Request size <span style="color:#006600; font-weight:bold;">&#91;</span>B<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">75</span>.<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply rate <span style="color:#006600; font-weight:bold;">&#91;</span>replies/s<span style="color:#006600; font-weight:bold;">&#93;</span>: min <span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">4</span> avg <span style="color:#800000;color:#800000;">4</span>.<span style="color:#800000;color:#800000;">5</span> max <span style="color:#800000;color:#800000;">5</span>.<span style="color:#800000;color:#800000;">6</span> stddev <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">4</span> <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">4</span> samples<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: response <span style="color:#800000;color:#800000;">11324</span>.<span style="color:#800000;color:#800000;">0</span> transfer <span style="color:#800000;color:#800000;">53</span>.<span style="color:#800000;color:#800000;">3</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply size <span style="color:#006600; font-weight:bold;">&#91;</span>B<span style="color:#006600; font-weight:bold;">&#93;</span>: header <span style="color:#800000;color:#800000;">230</span>.<span style="color:#800000;color:#800000;">0</span> content <span style="color:#800000;color:#800000;">9912</span>.<span style="color:#800000;color:#800000;">0</span> footer <span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">0</span> <span style="color:#006600; font-weight:bold;">&#40;</span>total <span style="color:#800000;color:#800000;">10144</span>.<span style="color:#800000;color:#800000;">0</span><span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply status: 1xx=<span style="color:#800000;color:#800000;">0</span> 2xx=<span style="color:#800000;color:#800000;">100</span> 3xx=<span style="color:#800000;color:#800000;">0</span> 4xx=<span style="color:#800000;color:#800000;">0</span> 5xx=<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; CPU time <span style="color:#006600; font-weight:bold;">&#91;</span>s<span style="color:#006600; font-weight:bold;">&#93;</span>: user <span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">27</span> system <span style="color:#800000;color:#800000;">18</span>.<span style="color:#800000;color:#800000;">93</span> <span style="color:#006600; font-weight:bold;">&#40;</span>user <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">7</span>% system <span style="color:#800000;color:#800000;">89</span>.<span style="color:#800000;color:#800000;">3</span>% total <span style="color:#800000;color:#800000;">100</span>.<span style="color:#800000;color:#800000;">0</span>%<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Net I/O: <span style="color:#800000;color:#800000;">47</span>.<span style="color:#800000;color:#800000;">0</span> KB/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">4</span>*<span style="color:#800000;color:#800000;">10</span>^<span style="color:#800000;color:#800000;">6</span> bps<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Errors: total <span style="color:#800000;color:#800000;">0</span> client-timo <span style="color:#800000;color:#800000;">0</span> socket-timo <span style="color:#800000;color:#800000;">0</span> connrefused <span style="color:#800000;color:#800000;">0</span> connreset <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Errors: fd-unavail <span style="color:#800000;color:#800000;">0</span> addrunavail <span style="color:#800000;color:#800000;">0</span> ftab-full <span style="color:#800000;color:#800000;">0</span> other <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span><span style="color:#006600; font-weight:bold;">&#93;</span># ssh <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span> <span style="color:#CC0000;">"mysqladmin -uroot extended-status | grep -e Threads -e Max"</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Max_used_connections&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">21</span>&nbsp; &nbsp; &nbsp; &nbsp;|</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Threads_cached&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; | <span style="color:#800000;color:#800000;">0</span>&nbsp; &nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Threads_connected&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">1</span>&nbsp; &nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Threads_created&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">102</span>&nbsp; &nbsp; &nbsp; |</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | Threads_running&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">1</span>&nbsp; &nbsp; &nbsp; &nbsp; | </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>上記結果をまとめると、このようになる。</p>
<table id="table-2rows">
<tbody>
<tr>
<td id="item">--rate=1</td>
<td id="value">
Request rate: 1.0 req/s<br />
Reply time [ms]: response 436.4<br />
Errors: total 0<br />
Max_used_connections 1
</td>
</tr>
<tr>
<td id="item">--rate=5</td>
<td id="value">
Request rate: 4.7 req/<br />
Reply time [ms]: response 1422.1<br />
Errors: total 0<br />
Max_used_connections 12
</td>
</tr>
<tr>
<td id="item">--rate=10</td>
<td id="value">
Request rate: 4.8 req/s<br />
Reply time [ms]: response 7632.7<br />
Errors: total 0<br />
Max_used_connections 20
</td>
</tr>
<tr>
<td id="item">--rate=20</td>
<td id="value">
Request rate: 4.7 req/s<br />
Reply time [ms]: response 10180.1<br />
Errors: total 0<br />
Max_used_connections 22
</td>
</tr>
<tr>
<td id="item">--rate=50</td>
<td id="value">
Request rate: 4.7 req/s<br />
Reply time [ms]: response 11324.0<br />
Errors: total 0<br />
Max_used_connections 21
</td>
</tr>
</tbody>
</table>
<p>上記結果から --rate=10 を超えると Max_used_connections があまり増えなくなっている事が分かる。この値は、MySQL への同時コネクション数を示している。また、MySQL のデフォルト値では、同時コネクション数は最大 100 になっている。</p>
<div class="igBar"><span id="lcode-69"><a href="#" onclick="javascript:showCodeTxt('code-69'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-69">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span><span style="color:#006600; font-weight:bold;">&#93;</span># mysqladmin -u root variables | grep max_connections</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; | max_connections&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;| <span style="color:#800000;color:#800000;">100</span> </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>つまり、10.0.0.1 サーバの Apache + PHP 側がボトルネックになっている可能性が高いと考えられる。それを確かめるために、MySQL で1 秒以上処理時間がかかるクエリーがある場合、ログファイルに書き出す設定を行う。</p>
<div class="igBar"><span id="lcode-70"><a href="#" onclick="javascript:showCodeTxt('code-70'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-70">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span><span style="color:#006600; font-weight:bold;">&#93;</span># cat /etc/my.<span style="">cnf</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color:#006600; font-weight:bold;">&#91;</span>mysqld<span style="color:#006600; font-weight:bold;">&#93;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; datadir=/var/lib/mysql</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; socket=/var/lib/mysql/mysql.<span style="">sock</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; user=mysql</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; old_passwords=<span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; long_query_time=<span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; log-slow-queries=/var/log/mysql-slow.<span style="">log</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color:#006600; font-weight:bold;">&#91;</span>mysqld_safe<span style="color:#006600; font-weight:bold;">&#93;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; log-error=/var/log/mysqld.<span style="">log</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; pid-file=/var/run/mysqld/mysqld.<span style="">pid</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span><span style="color:#006600; font-weight:bold;">&#93;</span># rm -f /var/log/mysql-slow.<span style="">log</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span><span style="color:#006600; font-weight:bold;">&#93;</span># touch /var/log/mysql-slow.<span style="">log</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span><span style="color:#006600; font-weight:bold;">&#93;</span># chown mysql. /var/log/mysql-slow.<span style="">log</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span><span style="color:#006600; font-weight:bold;">&#93;</span># service mysqld restart</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Stopping MySQL:&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#006600; font-weight:bold;">&#91;</span>&nbsp; OK&nbsp; <span style="color:#006600; font-weight:bold;">&#93;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Starting MySQL:&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#006600; font-weight:bold;">&#91;</span>&nbsp; OK&nbsp; <span style="color:#006600; font-weight:bold;">&#93;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span><span style="color:#006600; font-weight:bold;">&#93;</span># cat /var/log/mysql-slow.<span style="">log</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; /usr/libexec/mysqld, Version: <span style="color:#800000;color:#800000;">5</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">77</span>-log <span style="color:#006600; font-weight:bold;">&#40;</span>Source distribution<span style="color:#006600; font-weight:bold;">&#41;</span>. <span style="">started</span> with:</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Tcp port: <span style="color:#800000;color:#800000;">0</span>&nbsp; Unix socket: /var/lib/mysql/mysql.<span style="">sock</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Time&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;Id Command&nbsp; &nbsp; Argument</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span><span style="color:#006600; font-weight:bold;">&#93;</span># ssh <span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span> <span style="color:#CC0000;">"httperf --hog --server 10.0.0.1 --uri=/WordPress/?p=3 --num-conns=100 --num-calls=1 --rate=50"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">2</span><span style="color:#006600; font-weight:bold;">&#93;</span># cat /var/log/mysql-slow.<span style="">log</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; /usr/libexec/mysqld, Version: <span style="color:#800000;color:#800000;">5</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">77</span>-log <span style="color:#006600; font-weight:bold;">&#40;</span>Source distribution<span style="color:#006600; font-weight:bold;">&#41;</span>. <span style="">started</span> with:</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Tcp port: <span style="color:#800000;color:#800000;">0</span>&nbsp; Unix socket: /var/lib/mysql/mysql.<span style="">sock</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Time&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;Id Command&nbsp; &nbsp; Argument </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>上記結果から、1 秒以上処理時間がかかるクエリーは無い事が分かった。</p>
<h3 class="subtitle">どこをチューニングすれば良い？</h3>
<p>チューニングポイントの候補としては、(1) Apache, (2) WordPress (3) MySQL, (4) PHP だと思う。</p>
<p>まず、(1) Apache だが、今回の測定結果から現在の状態では Request rate: 4.7 req/s が上限となっていることが分かった。つまり、同時に 4.7 人以上の接続があると、サーバに余裕がなくなり徐々に Request rate が低下していくと予想できる。そのため Apache の MaxClient を極端な値にすると 5 とか、20 に設定することで現時点での最高の Request rate でリクエストに答えることができる。しかし、Request rate: 4.7 req/s は、かなり低い数字だと思うので、この Request rate を上げるためのチューニングを行いたい。</p>
<p>そのために 1 ページを表示するのに 20 回のクエリーを実行している (2) WordPress 本体を改造する方法があると思う。こちらのサイト</p>
<blockquote><p>WordPress チューニング<br />
<a href="http://WordPress.rauru-block.org/index.php/1589">http://WordPress.rauru-block.org/index.php/1589</a></p></blockquote>
<p>を読むと、やはり無駄なクエリーが多数あるようで、最終的に 4 回のクエリーで表示させれるようになるようだ。(これは凄い！凄く効果がありそうだ) 他には、こちらのサイト</p>
<blockquote><p>WordPressが重くなる理由わかった～結局さくらサーバ移転へ｜高橋文樹.com<br />
<a href="http://takahashifumiki.com/web/603/">http://takahashifumiki.com/web/603/</a></p></blockquote>
<p>によると、プラグインで外部 Web サービスに接続しているのがボトルネックとなっている場合も多いみたいだ。今回の測定では外部 Web サービスに接続を行うようなプラグインは使用していない (デフォルトで組み込まれているプラグインのみ) ので関係ないが、一応紹介しておく。しかし、WordPress 本体を改造するのは、少し敷居が高くなるので今回は行わない。</p>
<p>その代わり、(3) MySQL のクエリーキャッシュと、memcached による分散キャッシュサーバを用いる事で、クエリーの負荷を減らす方法がある。なかなか面白い内容なので別のページにて紹介したいと思う。しかし、今回の測定で、恐らく MySQL よりも Apache+PHP 側がボトルネックになっている可能性が高いと考えられる。</p>
<p>最後に、(4) PHP のチューニングがある。PHP はスクリプト言語のため実行する度に機械語に変換するコンパイル処理が発生している。これは非常に重たいため APC（Alternative PHP Cache）モジュールを導入することによって、PHP の中間コードのキャッシュや最適化を行うことができる。なかなか面白い内容なので別のページにて紹介したいと思う。</p>
]]></content:encoded>
			<wfw:commentRss>http://na-ga.net/blog/?feed=rss2&amp;p=544</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>httperf の &#8211;wsesslog オプション</title>
		<link>http://na-ga.net/blog/?p=535</link>
		<comments>http://na-ga.net/blog/?p=535#comments</comments>
		<pubDate>Wed, 11 Nov 2009 16:31:06 +0000</pubDate>
		<dc:creator>na-ga</dc:creator>
				<category><![CDATA[httperf]]></category>

		<guid isPermaLink="false">http://na-ga.net/blog/?p=535</guid>
		<description><![CDATA[--wsesslog オプションは複雑だけど、使いこなせるようになるとすごく便利。自分も完全に理解していない可能性があるけど、分かる範囲で紹介。間違っていたら指摘してください。

man 日本語訳
--wsesslog=N,X,F
これは、--wsess と同様にセッション負荷生成を指定します。--wsesslog を用いると、URI のシーケンスと数、リクエストメソッド、think-time と burst-length パラメーターを含む、多数のユーザーセッションの特徴を、入力ファイル F に指定できます。--wsess と同様の 2 つのパラメーターがあり、N は生成するセッション数で、X は burst と burst 間の user think-time です。user think-time は、入力ファイル F でも指定できるので、この X はデフォルト値となります。簡単な入力ファイルの例で、設定できるパラメーターを示します。
PLAIN TEXT
CODE:




# コメント行は # で始まります。&#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; 


# スペースのみの行は、セッションを分けます。&#160; &#160; &#160; &#160; &#160; &#160;


# 複数の空行が null セッションを生成する事はありません。


# 他のすべての行は、URI [...]]]></description>
			<content:encoded><![CDATA[<p>--wsesslog オプションは複雑だけど、使いこなせるようになるとすごく便利。自分も完全に理解していない可能性があるけど、分かる範囲で紹介。間違っていたら指摘してください。<br />
<span id="more-535"></span></p>
<h3 class="subtitle">man 日本語訳</h3>
<p>--wsesslog=N,X,F</p>
<p>これは、--wsess と同様にセッション負荷生成を指定します。--wsesslog を用いると、URI のシーケンスと数、リクエストメソッド、think-time と burst-length パラメーターを含む、多数のユーザーセッションの特徴を、入力ファイル F に指定できます。--wsess と同様の 2 つのパラメーターがあり、N は生成するセッション数で、X は burst と burst 間の user think-time です。user think-time は、入力ファイル F でも指定できるので、この X はデフォルト値となります。簡単な入力ファイルの例で、設定できるパラメーターを示します。</p>
<div class="igBar"><span id="lcode-79"><a href="#" onclick="javascript:showCodeTxt('code-79'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-79">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># コメント行は # で始まります。&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># スペースのみの行は、セッションを分けます。&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># 複数の空行が null セッションを生成する事はありません。</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># 他のすべての行は、URI シーケンスを指定します。&nbsp; &nbsp; &nbsp; &nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># 行頭の文字がスペースで始まる場合、&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># その URI は burst の一部と成ります。&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># セッション <span style="color:#800000;color:#800000;">1</span> 定義 <span style="color:#006600; font-weight:bold;">&#40;</span>this is a comment<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">/foo.<span style="">html</span> think=<span style="color:#800000;color:#800000;">2</span>.<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &nbsp;/pict1.<span style="">gif</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &nbsp;/pict2.<span style="">gif</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">/foo2.<span style="">html</span> method=POST contents=’Post data’</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &nbsp;/pict3.<span style="">gif</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &nbsp;/pict4.<span style="">gif</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># セッション <span style="color:#800000;color:#800000;">2</span> 定義</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">/foo3.<span style="">html</span> method=POST contents=<span style="color:#CC0000;">"Multiline<span style="color:#000099; font-weight:bold;">\n</span>data"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">/foo4.<span style="">html</span> method=HEAD </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>上の例では、2 つのセッションを指定しています。1 つ目のセッションは、/foo.html に対してリクエストを出します。この /foo.html のレスポンスが返ってきたときに、バーストの /pict1.gif と /pict2.gif の 2 つのリクエストを出します。これらのリクエストが返ってきたときに、user think-time 2.0 秒間待機します。その後、/foo2.htmlに対してリクエストを出します。このリクエストは POST メソッドを送信します。POST されたデータは、シングルまたはダブルクオーテーションで囲みます。この /foo2.html のレスポンスが返ってきたときに、バーストの /pict3.gif と /pict4.gif のリクエストを出して、このセッションを終わります。</p>
<p>2 つ目のセッションは、--wsesslog オプションの X パラメーターで指定された user think-time のデフォルト値で区切られた 2 つのリクエストから成ります。もし、--wsesslog オプションの N パラメーターが入力ファイル F で定義したセッション数 (今回の場合 2 セッション定義している) より大きいなら、定義したセッションを N セッション作成されるまで繰り返し使用します。</p>
<p>セッションの振る舞いを制御する httperf のオプションを --wsesslog と一緒に使用するのを避けるべきです。URI のワークロード、すなわち、--burst-length、--wsess、--wlog、--wset オプション。</p>
<h3 class="subtitle">入力ファイルの例</h3>
<p>バーストとセッションが出てくるが、簡単に言うと、</p>
<table id="table-2rows">
<tr>
<td id="item">バースト</td>
<td id="value">あるページが複数のファイルから構成されている場合、それら一連のファイルをまとめてバーストと呼ぶ</td>
</tr>
<tr>
<td id="item">セッション</td>
<td id="value">ユーザーがあるサイトに接続し、色々とページを開き、サイトを去るまでの一連の行動をセッションと呼ぶ</td>
</tr>
</table>
<p>例えば、wordpress の /?p=1 ページに開いた場合、関連する合計 7 ファイルがダウンロードされるので、これら一連のファイルをバーストと呼ぶ。単純に /?p=1 ページを開いてサイトを去った場合の、1 バースト、1 セッションを入力ファイル wplog に記述すると、このようになる。</p>
<div class="igBar"><span id="lcode-80"><a href="#" onclick="javascript:showCodeTxt('code-80'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-80">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># --wsessglog=N,X,wplog</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">/wordpress/?p=<span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/style.<span style="">css</span> </div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-includes/js/comment-reply.<span style="">js</span>?ver=<span style="color:#800000;color:#800000;">20090102</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/images/kubrickbgcolor.<span style="">jpg</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/images/kubrickbgwide.<span style="">jpg</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/images/kubrickfooter.<span style="">jpg</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/images/kubrickheader.<span style="">jpg</span> </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>少し付け加えて、/?p=1 ページを開いた 10 秒後に、/?p=2 ページを開いて、その後 /?p=3 ページを開いてサイトを去った場合の、3 バースト・1セッションを入力ファイル wplog2 に記述すると、このようになる。</p>
<div class="igBar"><span id="lcode-81"><a href="#" onclick="javascript:showCodeTxt('code-81'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-81">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># --wsessglog=N,X,wplog2</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">/wordpress/?p=<span style="color:#800000;color:#800000;">1</span> think=<span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/style.<span style="">css</span> </div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-includes/js/comment-reply.<span style="">js</span>?ver=<span style="color:#800000;color:#800000;">20090102</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/images/kubrickbgcolor.<span style="">jpg</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/images/kubrickbgwide.<span style="">jpg</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/images/kubrickfooter.<span style="">jpg</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/images/kubrickheader.<span style="">jpg</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">/wordpress/?p=<span style="color:#800000;color:#800000;">2</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/style.<span style="">css</span> </div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-includes/js/comment-reply.<span style="">js</span>?ver=<span style="color:#800000;color:#800000;">20090102</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/images/kubrickbgcolor.<span style="">jpg</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/images/kubrickbgwide.<span style="">jpg</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/images/kubrickfooter.<span style="">jpg</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/images/kubrickheader.<span style="">jpg</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">/wordpress/?p=<span style="color:#800000;color:#800000;">3</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/style.<span style="">css</span> </div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-includes/js/comment-reply.<span style="">js</span>?ver=<span style="color:#800000;color:#800000;">20090102</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/images/kubrickbgcolor.<span style="">jpg</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/images/kubrickbgwide.<span style="">jpg</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/images/kubrickfooter.<span style="">jpg</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/images/kubrickheader.<span style="">jpg</span> </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>その後、別のサイトに接続した場合の、4 バースト・2 セッションを入力ファイル wplog3 に記述すると、このようになる。</p>
<div class="igBar"><span id="lcode-82"><a href="#" onclick="javascript:showCodeTxt('code-82'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-82">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># --wsessglog=N,X,wplog3</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">/wordpress/?p=<span style="color:#800000;color:#800000;">1</span> think=<span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/style.<span style="">css</span> </div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-includes/js/comment-reply.<span style="">js</span>?ver=<span style="color:#800000;color:#800000;">20090102</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/images/kubrickbgcolor.<span style="">jpg</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/images/kubrickbgwide.<span style="">jpg</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/images/kubrickfooter.<span style="">jpg</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/images/kubrickheader.<span style="">jpg</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">/wordpress/?p=<span style="color:#800000;color:#800000;">2</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/style.<span style="">css</span> </div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-includes/js/comment-reply.<span style="">js</span>?ver=<span style="color:#800000;color:#800000;">20090102</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/images/kubrickbgcolor.<span style="">jpg</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/images/kubrickbgwide.<span style="">jpg</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/images/kubrickfooter.<span style="">jpg</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/images/kubrickheader.<span style="">jpg</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">/wordpress/?p=<span style="color:#800000;color:#800000;">3</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/style.<span style="">css</span> </div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-includes/js/comment-reply.<span style="">js</span>?ver=<span style="color:#800000;color:#800000;">20090102</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/images/kubrickbgcolor.<span style="">jpg</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/images/kubrickbgwide.<span style="">jpg</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/images/kubrickfooter.<span style="">jpg</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; /wordpress/wp-content/themes/default/images/kubrickheader.<span style="">jpg</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">/diary/index.<span style="">html</span> </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<h3 class="subtitle">実際のコマンド例</h3>
<p>例えば、入力ファイル wplog3 を指定して、合計 4 セッション生成する場合、このようになる。</p>
<div class="igBar"><span id="lcode-83"><a href="#" onclick="javascript:showCodeTxt('code-83'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-83">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"># httperf --hog --server=<span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --wsesslog=<span style="color:#800000;color:#800000;">4</span>,<span style="color:#800000;color:#800000;">3</span>,wplog3</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; httperf --hog --client=<span style="color:#800000;color:#800000;">0</span>/<span style="color:#800000;color:#800000;">1</span> --server=<span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> --port=<span style="color:#800000;color:#800000;">80</span> --uri=/ --send-buffer=<span style="color:#800000;color:#800000;">4096</span> --recv-buffer=<span style="color:#800000;color:#800000;">16384</span> --wsesslog=<span style="color:#800000;color:#800000;">4</span>,<span style="color:#800000;color:#800000;">3</span>.<span style="color:#800000;color:#800000;">000</span>,wplog3</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Maximum connect burst length: <span style="color:#800000;color:#800000;">1</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Total: connections <span style="color:#800000;color:#800000;">4</span> requests <span style="color:#800000;color:#800000;">44</span> replies <span style="color:#800000;color:#800000;">44</span> test-duration <span style="color:#800000;color:#800000;">28</span>.<span style="color:#800000;color:#800000;">796</span> s</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection rate: <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span> conn/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">7198</span>.<span style="color:#800000;color:#800000;">9</span> ms/conn, &lt;=<span style="color:#800000;color:#800000;">2</span> concurrent connections<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: min <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">3</span> avg <span style="color:#800000;color:#800000;">7198</span>.<span style="color:#800000;color:#800000;">9</span> max <span style="color:#800000;color:#800000;">14399</span>.<span style="color:#800000;color:#800000;">2</span> median <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">5</span> stddev <span style="color:#800000;color:#800000;">8310</span>.<span style="color:#800000;color:#800000;">7</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: connect <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">8</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Connection length <span style="color:#006600; font-weight:bold;">&#91;</span>replies/conn<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">11</span>.<span style="color:#800000;color:#800000;">000</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Request rate: <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">5</span> req/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">654</span>.<span style="color:#800000;color:#800000;">4</span> ms/req<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Request size <span style="color:#006600; font-weight:bold;">&#91;</span>B<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">110</span>.<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply rate <span style="color:#006600; font-weight:bold;">&#91;</span>replies/s<span style="color:#006600; font-weight:bold;">&#93;</span>: min <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span> avg <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">2</span> max <span style="color:#800000;color:#800000;">4</span>.<span style="color:#800000;color:#800000;">4</span> stddev <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">9</span> <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">5</span> samples<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply time <span style="color:#006600; font-weight:bold;">&#91;</span>ms<span style="color:#006600; font-weight:bold;">&#93;</span>: response <span style="color:#800000;color:#800000;">62</span>.<span style="color:#800000;color:#800000;">6</span> transfer <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">4</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply size <span style="color:#006600; font-weight:bold;">&#91;</span>B<span style="color:#006600; font-weight:bold;">&#93;</span>: header <span style="color:#800000;color:#800000;">235</span>.<span style="color:#800000;color:#800000;">0</span> content <span style="color:#800000;color:#800000;">5340</span>.<span style="color:#800000;color:#800000;">0</span> footer <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span> <span style="color:#006600; font-weight:bold;">&#40;</span>total <span style="color:#800000;color:#800000;">5575</span>.<span style="color:#800000;color:#800000;">0</span><span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Reply status: 1xx=<span style="color:#800000;color:#800000;">0</span> 2xx=<span style="color:#800000;color:#800000;">42</span> 3xx=<span style="color:#800000;color:#800000;">2</span> 4xx=<span style="color:#800000;color:#800000;">0</span> 5xx=<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; CPU time <span style="color:#006600; font-weight:bold;">&#91;</span>s<span style="color:#006600; font-weight:bold;">&#93;</span>: user <span style="color:#800000;color:#800000;">7</span>.<span style="color:#800000;color:#800000;">83</span> system <span style="color:#800000;color:#800000;">20</span>.<span style="color:#800000;color:#800000;">97</span> <span style="color:#006600; font-weight:bold;">&#40;</span>user <span style="color:#800000;color:#800000;">27</span>.<span style="color:#800000;color:#800000;">2</span>% system <span style="color:#800000;color:#800000;">72</span>.<span style="color:#800000;color:#800000;">8</span>% total <span style="color:#800000;color:#800000;">100</span>.<span style="color:#800000;color:#800000;">0</span>%<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Net I/O: <span style="color:#800000;color:#800000;">8</span>.<span style="color:#800000;color:#800000;">5</span> KB/s <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">1</span>*<span style="color:#800000;color:#800000;">10</span>^<span style="color:#800000;color:#800000;">6</span> bps<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Errors: total <span style="color:#800000;color:#800000;">0</span> client-timo <span style="color:#800000;color:#800000;">0</span> socket-timo <span style="color:#800000;color:#800000;">0</span> connrefused <span style="color:#800000;color:#800000;">0</span> connreset <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Errors: fd-unavail <span style="color:#800000;color:#800000;">0</span> addrunavail <span style="color:#800000;color:#800000;">0</span> ftab-full <span style="color:#800000;color:#800000;">0</span> other <span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Session rate <span style="color:#006600; font-weight:bold;">&#91;</span>sess/s<span style="color:#006600; font-weight:bold;">&#93;</span>: min <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">00</span> avg <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">14</span> max <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">40</span> stddev <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">18</span> <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">4</span>/<span style="color:#800000;color:#800000;">4</span><span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Session: avg <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">00</span> connections/session</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Session lifetime <span style="color:#006600; font-weight:bold;">&#91;</span>s<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">7</span>.<span style="color:#800000;color:#800000;">2</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Session failtime <span style="color:#006600; font-weight:bold;">&#91;</span>s<span style="color:#006600; font-weight:bold;">&#93;</span>: <span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; Session length histogram: <span style="color:#800000;color:#800000;">0</span> <span style="color:#800000;color:#800000;">2</span> <span style="color:#800000;color:#800000;">0</span> <span style="color:#800000;color:#800000;">0</span> <span style="color:#800000;color:#800000;">0</span> <span style="color:#800000;color:#800000;">0</span> <span style="color:#800000;color:#800000;">0</span> <span style="color:#800000;color:#800000;">0</span> <span style="color:#800000;color:#800000;">0</span> <span style="color:#800000;color:#800000;">0</span> <span style="color:#800000;color:#800000;">0</span> <span style="color:#800000;color:#800000;">0</span> <span style="color:#800000;color:#800000;">0</span> <span style="color:#800000;color:#800000;">0</span> <span style="color:#800000;color:#800000;">0</span> <span style="color:#800000;color:#800000;">0</span> <span style="color:#800000;color:#800000;">0</span> <span style="color:#800000;color:#800000;">0</span> <span style="color:#800000;color:#800000;">0</span> <span style="color:#800000;color:#800000;">0</span> <span style="color:#800000;color:#800000;">0</span> <span style="color:#800000;color:#800000;">2</span> </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>通常、バーストの一連のファイルはサーバー側の KeepAlive によって 1 つのコネクションで処理される。また、上記結果からわかるように、各セッションごとに新しいコネクションが作られている。今回は 1 セッションにつき 1 コネクションで処理が完了しているが、入力ファイルのバーストが多い場合、またはサーバー側の KeepAlive の各設定値によっては 1 セッションにつき複数のコネクションが必要な場合もある。なお、サーバー側では、このようなログが記録されている。</p>
<div class="igBar"><span id="lcode-84"><a href="#" onclick="javascript:showCodeTxt('code-84'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-84">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span> - - <span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">12</span>/Nov/<span style="color:#800000;color:#800000;">2009</span>:<span style="color:#800000;color:#800000;">00</span>:<span style="color:#800000;color:#800000;">57</span>:<span style="color:#800000;color:#800000;">23</span> +<span style="color:#800000;color:#800000;">0900</span><span style="color:#006600; font-weight:bold;">&#93;</span> <span style="color:#CC0000;">"GET /wordpress/?p=1 HTTP/1.1"</span> <span style="color:#800000;color:#800000;">200</span> <span style="color:#800000;color:#800000;">6916</span> <span style="color:#CC0000;">"-"</span> <span style="color:#CC0000;">"httperf/0.9.0"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span> - - <span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">12</span>/Nov/<span style="color:#800000;color:#800000;">2009</span>:<span style="color:#800000;color:#800000;">00</span>:<span style="color:#800000;color:#800000;">57</span>:<span style="color:#800000;color:#800000;">23</span> +<span style="color:#800000;color:#800000;">0900</span><span style="color:#006600; font-weight:bold;">&#93;</span> <span style="color:#CC0000;">"GET /wordpress/wp-content/themes/default/style.css HTTP/1.1"</span> <span style="color:#800000;color:#800000;">200</span> <span style="color:#800000;color:#800000;">10220</span> <span style="color:#CC0000;">"-"</span> <span style="color:#CC0000;">"httperf/0.9.0"</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span> - - <span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">12</span>/Nov/<span style="color:#800000;color:#800000;">2009</span>:<span style="color:#800000;color:#800000;">00</span>:<span style="color:#800000;color:#800000;">57</span>:<span style="color:#800000;color:#800000;">23</span> +<span style="color:#800000;color:#800000;">0900</span><span style="color:#006600; font-weight:bold;">&#93;</span> <span style="color:#CC0000;">"GET /wordpress/wp-includes/js/comment-reply.js?ver=20090102 HTTP/1.1"</span> <span style="color:#800000;color:#800000;">200</span> <span style="color:#800000;color:#800000;">786</span> <span style="color:#CC0000;">"-"</span> <span style="color:#CC0000;">"httperf/0.9.0"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span> - - <span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">12</span>/Nov/<span style="color:#800000;color:#800000;">2009</span>:<span style="color:#800000;color:#800000;">00</span>:<span style="color:#800000;color:#800000;">57</span>:<span style="color:#800000;color:#800000;">23</span> +<span style="color:#800000;color:#800000;">0900</span><span style="color:#006600; font-weight:bold;">&#93;</span> <span style="color:#CC0000;">"GET /wordpress/wp-content/themes/default/images/kubrickbgcolor.jpg HTTP/1.1"</span> <span style="color:#800000;color:#800000;">200</span> <span style="color:#800000;color:#800000;">556</span> <span style="color:#CC0000;">"-"</span> <span style="color:#CC0000;">"httperf/0.9.0"</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span> - - <span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">12</span>/Nov/<span style="color:#800000;color:#800000;">2009</span>:<span style="color:#800000;color:#800000;">00</span>:<span style="color:#800000;color:#800000;">57</span>:<span style="color:#800000;color:#800000;">23</span> +<span style="color:#800000;color:#800000;">0900</span><span style="color:#006600; font-weight:bold;">&#93;</span> <span style="color:#CC0000;">"GET /wordpress/wp-content/themes/default/images/kubrickbgwide.jpg HTTP/1.1"</span> <span style="color:#800000;color:#800000;">200</span> <span style="color:#800000;color:#800000;">1014</span> <span style="color:#CC0000;">"-"</span> <span style="color:#CC0000;">"httperf/0.9.0"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span> - - <span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">12</span>/Nov/<span style="color:#800000;color:#800000;">2009</span>:<span style="color:#800000;color:#800000;">00</span>:<span style="color:#800000;color:#800000;">57</span>:<span style="color:#800000;color:#800000;">23</span> +<span style="color:#800000;color:#800000;">0900</span><span style="color:#006600; font-weight:bold;">&#93;</span> <span style="color:#CC0000;">"GET /wordpress/wp-content/themes/default/images/kubrickfooter.jpg HTTP/1.1"</span> <span style="color:#800000;color:#800000;">200</span> <span style="color:#800000;color:#800000;">2443</span> <span style="color:#CC0000;">"-"</span> <span style="color:#CC0000;">"httperf/0.9.0"</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span> - - <span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">12</span>/Nov/<span style="color:#800000;color:#800000;">2009</span>:<span style="color:#800000;color:#800000;">00</span>:<span style="color:#800000;color:#800000;">57</span>:<span style="color:#800000;color:#800000;">23</span> +<span style="color:#800000;color:#800000;">0900</span><span style="color:#006600; font-weight:bold;">&#93;</span> <span style="color:#CC0000;">"GET /wordpress/wp-content/themes/default/images/kubrickheader.jpg HTTP/1.1"</span> <span style="color:#800000;color:#800000;">200</span> <span style="color:#800000;color:#800000;">7868</span> <span style="color:#CC0000;">"-"</span> <span style="color:#CC0000;">"httperf/0.9.0"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span> - - <span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">12</span>/Nov/<span style="color:#800000;color:#800000;">2009</span>:<span style="color:#800000;color:#800000;">00</span>:<span style="color:#800000;color:#800000;">57</span>:<span style="color:#800000;color:#800000;">33</span> +<span style="color:#800000;color:#800000;">0900</span><span style="color:#006600; font-weight:bold;">&#93;</span> <span style="color:#CC0000;">"GET /wordpress/?p=2 HTTP/1.1"</span> <span style="color:#800000;color:#800000;">301</span> - <span style="color:#CC0000;">"-"</span> <span style="color:#CC0000;">"httperf/0.9.0"</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span> - - <span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">12</span>/Nov/<span style="color:#800000;color:#800000;">2009</span>:<span style="color:#800000;color:#800000;">00</span>:<span style="color:#800000;color:#800000;">57</span>:<span style="color:#800000;color:#800000;">34</span> +<span style="color:#800000;color:#800000;">0900</span><span style="color:#006600; font-weight:bold;">&#93;</span> <span style="color:#CC0000;">"GET /wordpress/wp-content/themes/default/style.css HTTP/1.1"</span> <span style="color:#800000;color:#800000;">200</span> <span style="color:#800000;color:#800000;">10220</span> <span style="color:#CC0000;">"-"</span> <span style="color:#CC0000;">"httperf/0.9.0"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span> - - <span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">12</span>/Nov/<span style="color:#800000;color:#800000;">2009</span>:<span style="color:#800000;color:#800000;">00</span>:<span style="color:#800000;color:#800000;">57</span>:<span style="color:#800000;color:#800000;">34</span> +<span style="color:#800000;color:#800000;">0900</span><span style="color:#006600; font-weight:bold;">&#93;</span> <span style="color:#CC0000;">"GET /wordpress/wp-includes/js/comment-reply.js?ver=20090102 HTTP/1.1"</span> <span style="color:#800000;color:#800000;">200</span> <span style="color:#800000;color:#800000;">786</span> <span style="color:#CC0000;">"-"</span> <span style="color:#CC0000;">"httperf/0.9.0"</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span> - - <span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">12</span>/Nov/<span style="color:#800000;color:#800000;">2009</span>:<span style="color:#800000;color:#800000;">00</span>:<span style="color:#800000;color:#800000;">57</span>:<span style="color:#800000;color:#800000;">34</span> +<span style="color:#800000;color:#800000;">0900</span><span style="color:#006600; font-weight:bold;">&#93;</span> <span style="color:#CC0000;">"GET /wordpress/wp-content/themes/default/images/kubrickbgcolor.jpg HTTP/1.1"</span> <span style="color:#800000;color:#800000;">200</span> <span style="color:#800000;color:#800000;">556</span> <span style="color:#CC0000;">"-"</span> <span style="color:#CC0000;">"httperf/0.9.0"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span> - - <span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">12</span>/Nov/<span style="color:#800000;color:#800000;">2009</span>:<span style="color:#800000;color:#800000;">00</span>:<span style="color:#800000;color:#800000;">57</span>:<span style="color:#800000;color:#800000;">34</span> +<span style="color:#800000;color:#800000;">0900</span><span style="color:#006600; font-weight:bold;">&#93;</span> <span style="color:#CC0000;">"GET /wordpress/wp-content/themes/default/images/kubrickbgwide.jpg HTTP/1.1"</span> <span style="color:#800000;color:#800000;">200</span> <span style="color:#800000;color:#800000;">1014</span> <span style="color:#CC0000;">"-"</span> <span style="color:#CC0000;">"httperf/0.9.0"</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span> - - <span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">12</span>/Nov/<span style="color:#800000;color:#800000;">2009</span>:<span style="color:#800000;color:#800000;">00</span>:<span style="color:#800000;color:#800000;">57</span>:<span style="color:#800000;color:#800000;">34</span> +<span style="color:#800000;color:#800000;">0900</span><span style="color:#006600; font-weight:bold;">&#93;</span> <span style="color:#CC0000;">"GET /wordpress/wp-content/themes/default/images/kubrickfooter.jpg HTTP/1.1"</span> <span style="color:#800000;color:#800000;">200</span> <span style="color:#800000;color:#800000;">2443</span> <span style="color:#CC0000;">"-"</span> <span style="color:#CC0000;">"httperf/0.9.0"</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#800000;color:#800000;">10</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">0</span>.<span style="color:#800000;color:#800000;">3</span> - - <span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">12</span>/Nov/<span style="color:#800000;color:#800000;">2009</span>:<s