<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=utf-8">
<META content="MSHTML 6.00.6000.17097" name=GENERATOR>
<STYLE>@font-face {
        font-family: 宋体;
}
@font-face {
        font-family: Verdana;
}
@font-face {
        font-family: @宋体;
}
@page Section1 {size: 595.3pt 841.9pt; margin: 72.0pt 90.0pt 72.0pt 90.0pt; layout-grid: 15.6pt; }
P.MsoNormal {
        TEXT-JUSTIFY: inter-ideograph; FONT-SIZE: 10.5pt; MARGIN: 0cm 0cm 0pt; FONT-FAMILY: "Times New Roman"; TEXT-ALIGN: justify
}
LI.MsoNormal {
        TEXT-JUSTIFY: inter-ideograph; FONT-SIZE: 10.5pt; MARGIN: 0cm 0cm 0pt; FONT-FAMILY: "Times New Roman"; TEXT-ALIGN: justify
}
DIV.MsoNormal {
        TEXT-JUSTIFY: inter-ideograph; FONT-SIZE: 10.5pt; MARGIN: 0cm 0cm 0pt; FONT-FAMILY: "Times New Roman"; TEXT-ALIGN: justify
}
A:link {
        COLOR: blue; TEXT-DECORATION: underline
}
SPAN.MsoHyperlink {
        COLOR: blue; TEXT-DECORATION: underline
}
A:visited {
        COLOR: purple; TEXT-DECORATION: underline
}
SPAN.MsoHyperlinkFollowed {
        COLOR: purple; TEXT-DECORATION: underline
}
SPAN.EmailStyle17 {
        FONT-WEIGHT: normal; COLOR: windowtext; FONT-STYLE: normal; FONT-FAMILY: Verdana; TEXT-DECORATION: none; mso-style-type: personal-compose
}
DIV.Section1 {
        page: Section1
}
UNKNOWN {
        FONT-SIZE: 10pt
}
BLOCKQUOTE {
        MARGIN-TOP: 0px; MARGIN-BOTTOM: 0px; MARGIN-LEFT: 2em
}
OL {
        MARGIN-TOP: 0px; MARGIN-BOTTOM: 0px
}
UL {
        MARGIN-TOP: 0px; MARGIN-BOTTOM: 0px
}
</STYLE>
</HEAD>
<BODY style="FONT-SIZE: 10pt; MARGIN: 10px; FONT-FAMILY: verdana">
<DIV><FONT face=Verdana color=#000080 size=2>i think you&nbsp;could see the key 
word "[debug]", can't you ? that means it is NOT an error, just a normal 
case.</FONT></DIV>
<DIV><FONT color=#000080>u can configure nginx to use the&nbsp;accept mutex 
lock.</FONT></DIV>
<DIV><FONT color=#000080>these may be the&nbsp;case&nbsp;:</FONT></DIV>
<DIV><FONT color=#000080>&nbsp;worker proccess 1:</FONT></DIV>
<DIV style="TEXT-INDENT: 2em"><FONT color=#000080>1. try to get accept mutex 
lock,&nbsp;let's assume it &nbsp;success to get lock, it will add the listen fd 
to epoll </FONT></DIV>
<DIV style="TEXT-INDENT: 2em"><FONT color=#000080>2. epoll_wait with 
max&nbsp;500ms timer, then&nbsp;deal with&nbsp;events return from 
epoll_wait.</FONT>&nbsp;</DIV>
<DIV>&nbsp;worker proccess 2:</DIV>
<DIV><FONT face=Verdana color=#000080 size=2>
<DIV style="TEXT-INDENT: 2em"><FONT color=#000080>1. try to get accept mutex 
lock,&nbsp;let's assume it &nbsp;does NOT success to get lock, it will&nbsp; NOT 
add the listen fd to epoll </FONT></DIV>
<DIV style="TEXT-INDENT: 2em"><FONT color=#000080>2. epoll_wait with 
max&nbsp;500ms timer, then&nbsp;deal with&nbsp;events return from 
epoll_wait.</FONT></DIV>
<DIV style="TEXT-INDENT: 2em">&nbsp;</DIV>
<DIV>accept mutex lock is useful in some system that still have thunder-herd 
problems, and it is said that linux does NOT have this problem now.</DIV>
<DIV>&nbsp;</DIV></FONT></DIV>
<DIV><FONT face=Verdana color=#000080 size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Verdana color=#c0c0c0 size=2>2011-06-08 </FONT></DIV><FONT 
face=Verdana color=#000080 size=2>
<HR style="WIDTH: 100px" align=left color=#b5c4df SIZE=1>
</FONT>
<DIV><FONT face=Verdana color=#c0c0c0 size=2><SPAN>tegrof</SPAN> </FONT></DIV>
<HR color=#b5c4df SIZE=1>

<DIV><FONT face=Verdana size=2><STRONG>发件人:</STRONG> Zhu Qun-Ying </FONT></DIV>
<DIV><FONT face=Verdana size=2><STRONG>发送时间:</STRONG> 2011-06-08&nbsp; 01:48:31 
</FONT></DIV>
<DIV><FONT face=Verdana size=2><STRONG>收件人:</STRONG> nginx-devel </FONT></DIV>
<DIV><FONT face=Verdana size=2><STRONG>抄送:</STRONG> </FONT></DIV>
<DIV><FONT face=Verdana size=2><STRONG>主题:</STRONG> multiple worker processes 
(problem or normal?) </FONT></DIV>
<DIV><FONT face=Verdana size=2></FONT> </DIV>
<DIV><FONT face=Verdana size=2>
<DIV>Hi,</DIV>
<DIV></DIV>
<DIV>When&nbsp;testing&nbsp;nginx&nbsp;1.0.4,&nbsp;I&nbsp;found&nbsp;the&nbsp;error&nbsp;message&nbsp;from&nbsp;error.log:</DIV>
<DIV></DIV>
<DIV>2011/06/07&nbsp;10:36:29&nbsp;[debug]&nbsp;10939#0:&nbsp;timer&nbsp;delta:&nbsp;501</DIV>
<DIV>2011/06/07&nbsp;10:36:29&nbsp;[debug]&nbsp;10939#0:&nbsp;posted&nbsp;events&nbsp;00000000</DIV>
<DIV>2011/06/07&nbsp;10:36:29&nbsp;[debug]&nbsp;10939#0:&nbsp;worker&nbsp;cycle</DIV>
<DIV>2011/06/07&nbsp;10:36:29&nbsp;[debug]&nbsp;10939#0:&nbsp;accept&nbsp;mutex&nbsp;lock&nbsp;failed:&nbsp;0</DIV>
<DIV>2011/06/07&nbsp;10:36:29&nbsp;[debug]&nbsp;10939#0:&nbsp;epoll&nbsp;timer:&nbsp;500</DIV>
<DIV>2011/06/07&nbsp;10:36:29&nbsp;[debug]&nbsp;10939#0:&nbsp;timer&nbsp;delta:&nbsp;500</DIV>
<DIV>2011/06/07&nbsp;10:36:29&nbsp;[debug]&nbsp;10939#0:&nbsp;posted&nbsp;events&nbsp;00000000</DIV>
<DIV>2011/06/07&nbsp;10:36:29&nbsp;[debug]&nbsp;10939#0:&nbsp;worker&nbsp;cycle</DIV>
<DIV>2011/06/07&nbsp;10:36:29&nbsp;[debug]&nbsp;10939#0:&nbsp;accept&nbsp;mutex&nbsp;lock&nbsp;failed:&nbsp;0</DIV>
<DIV>2011/06/07&nbsp;10:36:29&nbsp;[debug]&nbsp;10939#0:&nbsp;epoll&nbsp;timer:&nbsp;500</DIV>
<DIV>2011/06/07&nbsp;10:36:30&nbsp;[debug]&nbsp;10939#0:&nbsp;timer&nbsp;delta:&nbsp;501</DIV>
<DIV>2011/06/07&nbsp;10:36:30&nbsp;[debug]&nbsp;10939#0:&nbsp;posted&nbsp;events&nbsp;00000000</DIV>
<DIV>2011/06/07&nbsp;10:36:30&nbsp;[debug]&nbsp;10939#0:&nbsp;worker&nbsp;cycle</DIV>
<DIV>2011/06/07&nbsp;10:36:30&nbsp;[debug]&nbsp;10939#0:&nbsp;accept&nbsp;mutex&nbsp;lock&nbsp;failed:&nbsp;0</DIV>
<DIV>2011/06/07&nbsp;10:36:30&nbsp;[debug]&nbsp;10939#0:&nbsp;epoll&nbsp;timer:&nbsp;500</DIV>
<DIV>2011/06/07&nbsp;10:36:30&nbsp;[debug]&nbsp;10939#0:&nbsp;timer&nbsp;delta:&nbsp;501</DIV>
<DIV>2011/06/07&nbsp;10:36:30&nbsp;[debug]&nbsp;10939#0:&nbsp;posted&nbsp;events&nbsp;00000000</DIV>
<DIV>2011/06/07&nbsp;10:36:30&nbsp;[debug]&nbsp;10939#0:&nbsp;worker&nbsp;cycle</DIV>
<DIV>2011/06/07&nbsp;10:36:30&nbsp;[debug]&nbsp;10939#0:&nbsp;accept&nbsp;mutex&nbsp;lock&nbsp;failed:&nbsp;0</DIV>
<DIV>2011/06/07&nbsp;10:36:30&nbsp;[debug]&nbsp;10939#0:&nbsp;epoll&nbsp;timer:&nbsp;500</DIV>
<DIV>2011/06/07&nbsp;10:36:31&nbsp;[debug]&nbsp;10939#0:&nbsp;timer&nbsp;delta:&nbsp;500</DIV>
<DIV></DIV>
<DIV>It&nbsp;keeps&nbsp;repeating&nbsp;itself&nbsp;every&nbsp;half&nbsp;a&nbsp;second&nbsp;trying&nbsp;to&nbsp;acquired&nbsp;the&nbsp;&nbsp;</DIV>
<DIV>accept&nbsp;lock.</DIV>
<DIV>&nbsp;&nbsp;&nbsp;Does&nbsp;it&nbsp;normal?</DIV>
<DIV></DIV>
<DIV>My&nbsp;system&nbsp;is&nbsp;Slackware&nbsp;13.37,&nbsp;uname&nbsp;-a&nbsp;output:</DIV>
<DIV></DIV>
<DIV>Linux&nbsp;qy83&nbsp;2.6.39.1&nbsp;#1&nbsp;SMP&nbsp;PREEMPT&nbsp;Fri&nbsp;Jun&nbsp;3&nbsp;14:00:11&nbsp;PDT&nbsp;2011&nbsp;i686&nbsp;&nbsp;</DIV>
<DIV>Intel(R)&nbsp;Core(TM)2&nbsp;Duo&nbsp;CPU&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;E8400&nbsp;&nbsp;@&nbsp;3.00GHz&nbsp;GenuineIntel&nbsp;GNU/Linux</DIV>
<DIV></DIV>
<DIV>ps&nbsp;output:</DIV>
<DIV></DIV>
<DIV>10937&nbsp;?&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Ss&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;0:00&nbsp;nginx:&nbsp;master&nbsp;process&nbsp;/usr/sbin/nginx&nbsp;-c&nbsp;&nbsp;</DIV>
<DIV>/etc/nginx/n</DIV>
<DIV>10938&nbsp;?&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;S&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;0:00&nbsp;nginx:&nbsp;worker&nbsp;process</DIV>
<DIV>10939&nbsp;?&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;S&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;0:00&nbsp;nginx:&nbsp;worker&nbsp;process</DIV>
<DIV></DIV>
<DIV>nginx&nbsp;-V&nbsp;output:</DIV>
<DIV>nginx:&nbsp;nginx&nbsp;version:&nbsp;nginx/1.0.4</DIV>
<DIV>nginx:&nbsp;TLS&nbsp;SNI&nbsp;support&nbsp;enabled</DIV>
<DIV>nginx:&nbsp;configure&nbsp;arguments:&nbsp;--prefix=/usr&nbsp;--sbin-path=/usr/sbin/nginx&nbsp;&nbsp;</DIV>
<DIV>--conf-path=/etc/nginx/nginx.conf&nbsp;--pid-path=/var/run/nginx.pid&nbsp;&nbsp;</DIV>
<DIV>--lock-path=/var/lock/nginx&nbsp;--user=nobody&nbsp;--group=nogroup&nbsp;&nbsp;</DIV>
<DIV>--error-log-path=/var/log/nginx/error.log&nbsp;&nbsp;</DIV>
<DIV>--http-log-path=/var/log/nginx/access.log&nbsp;--with-rtsig_module&nbsp;&nbsp;</DIV>
<DIV>--with-select_module&nbsp;--with-poll_module&nbsp;--with-http_ssl_module&nbsp;&nbsp;</DIV>
<DIV>--with-http_realip_module&nbsp;--with-http_addition_module&nbsp;&nbsp;</DIV>
<DIV>--with-http_xslt_module&nbsp;--with-http_sub_module&nbsp;--with-http_dav_module&nbsp;&nbsp;</DIV>
<DIV>--with-http_flv_module&nbsp;--with-http_gzip_static_module&nbsp;&nbsp;</DIV>
<DIV>--with-http_random_index_module&nbsp;--with-http_secure_link_module&nbsp;&nbsp;</DIV>
<DIV>--with-http_stub_status_module&nbsp;--with-http_perl_module&nbsp;&nbsp;</DIV>
<DIV>--with-perl_modules_path=/usr/lib/perl5/vendor_perl/5.12.3&nbsp;&nbsp;</DIV>
<DIV>--http-client-body-temp-path=/var/tmp/nginx_client_body_temp&nbsp;&nbsp;</DIV>
<DIV>--http-proxy-temp-path=/var/tmp/nginx_proxy_temp&nbsp;&nbsp;</DIV>
<DIV>--http-fastcgi-temp-path=/dev/shm&nbsp;--without-mail_pop3_module&nbsp;&nbsp;</DIV>
<DIV>--without-mail_imap_module&nbsp;--without-mail_smtp_module&nbsp;--with-debug</DIV>
<DIV></DIV>
<DIV></DIV>
<DIV>cat&nbsp;/proc/cpuinfo</DIV>
<DIV>processor :&nbsp;0</DIV>
<DIV>vendor_id :&nbsp;GenuineIntel</DIV>
<DIV>cpu&nbsp;family :&nbsp;6</DIV>
<DIV>model :&nbsp;23</DIV>
<DIV>model&nbsp;name 
:&nbsp;Intel(R)&nbsp;Core(TM)2&nbsp;Duo&nbsp;CPU&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;E8400&nbsp;&nbsp;@&nbsp;3.00GHz</DIV>
<DIV>stepping :&nbsp;10</DIV>
<DIV>cpu&nbsp;MHz :&nbsp;2000.000</DIV>
<DIV>cache&nbsp;size :&nbsp;6144&nbsp;KB</DIV>
<DIV>physical&nbsp;id :&nbsp;0</DIV>
<DIV>siblings :&nbsp;2</DIV>
<DIV>core&nbsp;id :&nbsp;0</DIV>
<DIV>cpu&nbsp;cores :&nbsp;2</DIV>
<DIV>apicid :&nbsp;0</DIV>
<DIV>initial&nbsp;apicid :&nbsp;0</DIV>
<DIV>fdiv_bug :&nbsp;no</DIV>
<DIV>hlt_bug :&nbsp;no</DIV>
<DIV>f00f_bug :&nbsp;no</DIV>
<DIV>coma_bug :&nbsp;no</DIV>
<DIV>fpu :&nbsp;yes</DIV>
<DIV>fpu_exception :&nbsp;yes</DIV>
<DIV>cpuid&nbsp;level :&nbsp;13</DIV>
<DIV>wp :&nbsp;yes</DIV>
<DIV>flags 
:&nbsp;fpu&nbsp;vme&nbsp;de&nbsp;pse&nbsp;tsc&nbsp;msr&nbsp;pae&nbsp;mce&nbsp;cx8&nbsp;apic&nbsp;sep&nbsp;mtrr&nbsp;pge&nbsp;mca&nbsp;cmov&nbsp;pat&nbsp;&nbsp;</DIV>
<DIV>pse36&nbsp;clflush&nbsp;dts&nbsp;acpi&nbsp;mmx&nbsp;fxsr&nbsp;sse&nbsp;sse2&nbsp;ss&nbsp;ht&nbsp;tm&nbsp;pbe&nbsp;nx&nbsp;lm&nbsp;constant_tsc&nbsp;&nbsp;</DIV>
<DIV>arch_perfmon&nbsp;pebs&nbsp;bts&nbsp;aperfmperf&nbsp;pni&nbsp;dtes64&nbsp;monitor&nbsp;ds_cpl&nbsp;vmx&nbsp;smx&nbsp;est&nbsp;tm2&nbsp;&nbsp;</DIV>
<DIV>ssse3&nbsp;cx16&nbsp;xtpr&nbsp;pdcm&nbsp;sse4_1&nbsp;xsave&nbsp;lahf_lm&nbsp;dts&nbsp;tpr_shadow&nbsp;vnmi&nbsp;flexpriority</DIV>
<DIV>bogomips :&nbsp;6000.17</DIV>
<DIV>clflush&nbsp;size :&nbsp;64</DIV>
<DIV>cache_alignment :&nbsp;64</DIV>
<DIV>address&nbsp;sizes 
:&nbsp;36&nbsp;bits&nbsp;physical,&nbsp;48&nbsp;bits&nbsp;virtual</DIV>
<DIV>power&nbsp;management:</DIV>
<DIV></DIV>
<DIV>processor :&nbsp;1</DIV>
<DIV>vendor_id :&nbsp;GenuineIntel</DIV>
<DIV>cpu&nbsp;family :&nbsp;6</DIV>
<DIV>model :&nbsp;23</DIV>
<DIV>model&nbsp;name 
:&nbsp;Intel(R)&nbsp;Core(TM)2&nbsp;Duo&nbsp;CPU&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;E8400&nbsp;&nbsp;@&nbsp;3.00GHz</DIV>
<DIV>stepping :&nbsp;10</DIV>
<DIV>cpu&nbsp;MHz :&nbsp;2000.000</DIV>
<DIV>cache&nbsp;size :&nbsp;6144&nbsp;KB</DIV>
<DIV>physical&nbsp;id :&nbsp;0</DIV>
<DIV>siblings :&nbsp;2</DIV>
<DIV>core&nbsp;id :&nbsp;1</DIV>
<DIV>cpu&nbsp;cores :&nbsp;2</DIV>
<DIV>apicid :&nbsp;1</DIV>
<DIV>initial&nbsp;apicid :&nbsp;1</DIV>
<DIV>fdiv_bug :&nbsp;no</DIV>
<DIV>hlt_bug :&nbsp;no</DIV>
<DIV>f00f_bug :&nbsp;no</DIV>
<DIV>coma_bug :&nbsp;no</DIV>
<DIV>fpu :&nbsp;yes</DIV>
<DIV>fpu_exception :&nbsp;yes</DIV>
<DIV>cpuid&nbsp;level :&nbsp;13</DIV>
<DIV>wp :&nbsp;yes</DIV>
<DIV>flags 
:&nbsp;fpu&nbsp;vme&nbsp;de&nbsp;pse&nbsp;tsc&nbsp;msr&nbsp;pae&nbsp;mce&nbsp;cx8&nbsp;apic&nbsp;sep&nbsp;mtrr&nbsp;pge&nbsp;mca&nbsp;cmov&nbsp;pat&nbsp;&nbsp;</DIV>
<DIV>pse36&nbsp;clflush&nbsp;dts&nbsp;acpi&nbsp;mmx&nbsp;fxsr&nbsp;sse&nbsp;sse2&nbsp;ss&nbsp;ht&nbsp;tm&nbsp;pbe&nbsp;nx&nbsp;lm&nbsp;constant_tsc&nbsp;&nbsp;</DIV>
<DIV>arch_perfmon&nbsp;pebs&nbsp;bts&nbsp;aperfmperf&nbsp;pni&nbsp;dtes64&nbsp;monitor&nbsp;ds_cpl&nbsp;vmx&nbsp;smx&nbsp;est&nbsp;tm2&nbsp;&nbsp;</DIV>
<DIV>ssse3&nbsp;cx16&nbsp;xtpr&nbsp;pdcm&nbsp;sse4_1&nbsp;xsave&nbsp;lahf_lm&nbsp;dts&nbsp;tpr_shadow&nbsp;vnmi&nbsp;flexpriority</DIV>
<DIV>bogomips :&nbsp;5999.65</DIV>
<DIV>clflush&nbsp;size :&nbsp;64</DIV>
<DIV>cache_alignment :&nbsp;64</DIV>
<DIV>address&nbsp;sizes 
:&nbsp;36&nbsp;bits&nbsp;physical,&nbsp;48&nbsp;bits&nbsp;virtual</DIV>
<DIV>power&nbsp;management:</DIV>
<DIV>_______________________________________________</DIV>
<DIV>nginx-devel&nbsp;mailing&nbsp;list</DIV>
<DIV>nginx-devel@nginx.org</DIV>
<DIV>http://nginx.org/mailman/listinfo/nginx-devel</DIV>
<DIV></DIV></FONT></DIV></BODY></HTML>