Linux中Nginx安装与配置详解(3)

Set permissions for unix socket, if one used.
    In Linux read/write permissions must be set in order to allow connections from web server.
    Many BSD-derrived systems allow connections regardless of permissions.
    <value></value>
    <value></value>
    <value>0666</value>
   </value>

Additional php.ini defines, specific to this pool of workers.
   <value>
  <!--  <value>/usr/sbin/sendmail -t -i</value>  -->
    <value>1</value>       
   </value>

Unix user of processes
   <value>www</value>   

Unix group of processes
   <value>www</value> 

Process manager settings
   <value>

Sets style of controling worker process count.
    Valid values are 'static' and 'apache-like'
    <value>static</value>

Sets the limit on the number of simultaneous requests that will be served.
    Equivalent to Apache MaxClients directive.
    Equivalent to PHP_FCGI_CHILDREN environment in original php.fcgi
    Used with any pm_style.
    <value>384</value>

Settings group for 'apache-like' pm style
    <value>

Sets the number of server processes created on startup.
     Used only when 'apache-like' pm_style is selected
     <value>20</value>

Sets the desired minimum number of idle server processes.
     Used only when 'apache-like' pm_style is selected
     <value>5</value>

Sets the desired maximum number of idle server processes.
     Used only when 'apache-like' pm_style is selected
     <value>35</value>

</value>

</value>

The timeout (in seconds) for serving a single request after which the worker process will be terminated
   Should be used when 'max_execution_time' ini option does not stop script execution for some reason
   '0s' means 'off'
   <value>30s</value>

The timeout (in seconds) for serving of single request after which a php backtrace will be dumped to slow.log file
   '0s' means 'off'
                        <value>0s</value>

The log file for slow requests
   <value>/data0/logs/php/slow.log</value>

Set open file desc rlimit
   <value>51200</value>

Set max core size rlimit
   <value>0</value>

Chroot to this directory at the start, absolute path
   <value></value>

Chdir to this directory at the start, absolute path
   <value></value>

Redirect workers' stdout and stderr into main error log.
   If not set, they will be redirected to /dev/null, according to FastCGI specs
   <value>yes</value>

How much requests each process should execute before respawn.
   Useful to work around memory leaks in 3rd party libraries.
   For endless request processing please specify 0
   Equivalent to PHP_FCGI_MAX_REQUESTS
   <value>1024</value>

Comma separated list of ipv4 addresses of FastCGI clients that allowed to connect.
   Equivalent to FCGI_WEB_SERVER_ADDRS environment in original php.fcgi (5.2.2+)
   Makes sense only with AF_INET listening socket.
   <value>127.0.0.1</value>

Pass environment variables like LD_LIBRARY_PATH
   All $VARIABLEs are taken from current environment
   <value>
    <value>$HOSTNAME</value>
    <value>/usr/local/bin:/usr/bin:/bin</value>
    <value>/tmp</value>
    <value>/tmp</value>
    <value>/tmp</value>
    <value>$OSTYPE</value>
    <value>$MACHTYPE</value>
    <value>2</value>
   </value>

</section>

</workers>

</configuration>


    2) 重启php-fpm与nginx
    # cd /usr/local/php5/sbin
    # ./php-fpm restart
    # cd /usr/local/nginx/sbin
    # ./nginx -s reload

内容版权声明:除非注明,否则皆为本站原创文章。

转载注明出处:https://www.heiqu.com/2730d7e122a7e7d14a5c60d54a66a5a4.html