<?xml version="1.0" encoding="UTF-8" ?>
<rss version="2.0">
<channel>
<title><![CDATA[向东博客 专注WEB应用 构架之美 --- 构架之美，在于尽态极妍 | 应用之美，在于药到病除]]></title> 
<link>http://jackxiang.com/index.php</link> 
<description><![CDATA[赢在IT，Playin' with IT,Focus on Killer Application,Marketing Meets Technology.]]></description> 
<language>zh-cn</language> 
<copyright><![CDATA[向东博客 专注WEB应用 构架之美 --- 构架之美，在于尽态极妍 | 应用之美，在于药到病除]]></copyright>
<item>
<link>http://jackxiang.com/post//</link>
<title><![CDATA[[个人原创]配置并查看 Nginx 的工作状态]]></title> 
<author>jack &lt;xdy108@126.com&gt;</author>
<category><![CDATA[Unix/LinuxC技术]]></category>
<pubDate>Sun, 11 Sep 2011 04:40:31 +0000</pubDate> 
<guid>http://jackxiang.com/post//</guid> 
<description>
<![CDATA[ 
	先说我的简单配置：<br/><textarea name="code" class="html" rows="15" cols="100">
 server
 &#123;
&nbsp;&nbsp; listen&nbsp;&nbsp;80;
&nbsp;&nbsp; server_name&nbsp;&nbsp;status.jackxiang.com;

&nbsp;&nbsp; location / &#123;
&nbsp;&nbsp; stub_status on;
&nbsp;&nbsp; access_log&nbsp;&nbsp; off;
&nbsp;&nbsp; &#125;
 &#125;
</textarea><br/><br/>访问：<br/>http://status.jackxiang.com/<br/><textarea name="code" class="html" rows="15" cols="100">
Active connections: 2 
server accepts handled requests
 22 22 66 
Reading: 0 Writing: 1 Waiting: 1 
</textarea><br/>然后看是怎么配置和相关模块，及参数含义，如下：<br/>http_stub_ status这个模块能够获取Nginx自上次启动以来的工作状态 此模块非核心模块，需要在编译的时候手动添加编译参数 --with-http_stub_ status _module ,配置说明:<br/><textarea name="code" class="html" rows="15" cols="100">
location /nginx_status &#123;
&nbsp;&nbsp;&nbsp;&nbsp;# copied from http://blog.kovyrin.net/2006/04/29/monitoring-nginx-with-rrdtool/
&nbsp;&nbsp;&nbsp;&nbsp;stub_status on;
&nbsp;&nbsp;&nbsp;&nbsp;access_log&nbsp;&nbsp; off;
&nbsp;&nbsp;&nbsp;&nbsp;allow SOME.IP.ADD.RESS;
&nbsp;&nbsp;&nbsp;&nbsp;deny all;
&#125;

</textarea><br/><br/>指令<br/>stub_status<br/><br/> <br/><br/> <br/><br/>stub_status<br/>语法: stub_status on<br/><br/>默认值: None<br/><br/>作用域: location<br/><br/>创建一个 location 区域启用 stub_status<br/><br/>&quot;stub status&quot; 模块返回的状态信息跟 mathopd&#039;s 的状态信息很相似. 返回的状态信息如下：<br/><br/>Active connections: 291<br/>server accepts handled requests<br/> 16630948 16630948 31070465<br/>Reading: 6 Writing: 179 Waiting: 106active connections -- 对后端发起的活动连接数<br/><br/>server accepts handled requests -- nginx 总共处理了 16630948 个连接, 成功创建 16630948 次握手 (证明中间没有失败的), 总共处理了 31070465 个请求 (平均每次握手处理了 1.8个数据请求)<br/><br/>reading -- nginx 读取到客户端的Header信息数<br/><br/>writing -- nginx 返回给客户端的Header信息数<br/><br/>waiting -- 开启 keep-alive 的情况下，这个值等于 active - (reading + writing)， 意思就是Nginx说已经处理完正在等候下一次请求指令的驻留连接<br/><br/>
]]>
</description>
</item><item>
<link>http://jackxiang.com/post//#blogcomment</link>
<title><![CDATA[[评论] [个人原创]配置并查看 Nginx 的工作状态]]></title> 
<author> &lt;user@domain.com&gt;</author>
<category><![CDATA[评论]]></category>
<pubDate>Thu, 01 Jan 1970 00:00:00 +0000</pubDate> 
<guid>http://jackxiang.com/post//#blogcomment</guid> 
<description>
<![CDATA[ 
	
]]>
</description>
</item>
</channel>
</rss>