Welcome! Log In Create A New Profile

Advanced

php-cgi process dies from time to time in low traffic

Posted by kabs 
Re: php-cgi process dies from time to time in low traffic
June 25, 2009 02:41AM
you should pastebin that, your client stripped out all of the xml it seems.


On Wed, Jun 24, 2009 at 8:37 PM, kabs<nginx-forum@nginx.us> wrote:
>
> Mike, did your changes and still got 502 on my bulk deletes. Davy here is my php-fpm.com file.
>
> ====================================================================
>
> <?xml version="1.0" ?>
>
>
>        All relative paths in this config are relative to php's install prefix
>
>
>
>                Pid file
>                /usr/local/logs/php-fpm.pid
>
>                Error log file
>                /usr/local/logs/php-fpm.log
>
>                Log level
>                notice
>
>                When this amount of php processes exited with SIGSEGV or SIGBUS ...
>                10
>
>                ... in a less than this interval of time, a graceful restart will be initiated.
>                Useful to work around accidental curruptions in accelerator's shared memory.
>                1m
>
>                Time limit on waiting child's reaction on signals from master
>                5s
>
>                Set to 'no' to debug fpm
>                yes
>
>
>
>
>
>
>
>                        Name of pool. Used in logs and stats.
>                        default
>
>                        Address to accept fastcgi requests on.
>                        Valid syntax is 'ip.ad.re.ss:port' or just 'port' or '/path/to/unix/socket'
>                        127.0.0.1:9000
>
>
>
>                                Set listen(2) backlog
>                                -1
>
>                                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.
>                                www-data
>                                www-data
>                                0666
>
>
>                        Additional php.ini defines, specific to this pool of workers.
>
>                <!--            /usr/sbin/sendmail -t -i            -->
>                <!--            0                                                          -->
>
>
>                        Unix user of processes
>                        www-data
>
>                        Unix group of processes
>                        www-data
>
>                        Process manager settings
>
>
>                                Sets style of controling worker process count.
>                                Valid values are 'static' and 'apache-like'
>                                static
>
>                                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.
>                                10
>
>                                Settings group for 'apache-like' pm style
>
>
>                                        Sets the number of server processes created on startup.
>                                        Used only when 'apache-like' pm_style is selected
>                                        20
>
>                                        Sets the desired minimum number of idle server processes.
>  Used only when 'apache-like' pm_style is selected
>                                        5
>
>                                        Sets the desired maximum number of idle server processes.
>                                        Used only when 'apache-like' pm_style is selected
>                                        35
>
>
>
>
>
>                        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'
>                        5s
>
>                        The timeout (in seconds) for serving of single request after which a php backtrace will be dumped to slow.log file
>                        '0s' means 'off'
>                        5s
>
>                        The log file for slow requests
>                        logs/slow.log
>
>                        Set open file desc rlimit
>                        1024
>
>                        Set max core size rlimit
>                        0
>
>                        Chroot to this directory at the start, absolute path
>
>
>                        Chdir to this directory at the start, absolute path
>
>
>                        Redirect workers' stdout and stderr into main error log.
>                        If not set, they will be redirected to /dev/null, according to FastCGI specs
>                        yes
>
>                        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
>                        1000
>
>                        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.
>                        127.0.0.1
>
>                        Pass environment variables like LD_LIBRARY_PATH
>                        All $VARIABLEs are taken from current environment
>
>                                $HOSTNAME
>                                /usr/local/bin:/usr/bin:/bin
>                                /tmp
>                                /tmp
>                                /tmp
>                                $OSTYPE
>                                $MACHTYPE
>                                2
>
>
>
>
>
>
>
>
> ===================================================================
>
> Posted at Nginx Forum: http://forum.nginx.org/read.php?3,2847,3348#msg-3348
>
>
Re: php-cgi process dies from time to time in low traffic
June 25, 2009 04:16PM
Sorry about that. Here is the code again

[code]
<?xml version="1.0" ?>
<configuration>

All relative paths in this config are relative to php's install prefix

<section name="global_options">

Pid file
<value name="pid_file">/usr/local/logs/php-fpm.pid</value>

Error log file
<value name="error_log">/usr/local/logs/php-fpm.log</value>

Log level
<value name="log_level">notice</value>

When this amount of php processes exited with SIGSEGV or SIGBUS ...
<value name="emergency_restart_threshold">10</value>

... in a less than this interval of time, a graceful restart will be initiated.
Useful to work around accidental curruptions in accelerator's shared memory.
<value name="emergency_restart_interval">1m</value>

Time limit on waiting child's reaction on signals from master
<value name="process_control_timeout">5s</value>

Set to 'no' to debug fpm
<value name="daemonize">yes</value>

</section>

<workers>

<section name="pool">

Name of pool. Used in logs and stats.
<value name="name">default</value>

Address to accept fastcgi requests on.
Valid syntax is 'ip.ad.re.ss:port' or just 'port' or '/path/to/unix/socket'
<value name="listen_address">127.0.0.1:9000</value>

<value name="listen_options">

Set listen(2) backlog
<value name="backlog">-1</value>

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 name="owner">www-data</value>
<value name="group">www-data</value>
<value name="mode">0666</value>
</value>

Additional php.ini defines, specific to this pool of workers.
<value name="php_defines">
<!-- <value name="sendmail_path">/usr/sbin/sendmail -t -i</value> -->
<!-- <value name="display_errors">0</value> -->
</value>

Unix user of processes
<value name="user">www-data</value>

Unix group of processes
<value name="group">www-data</value>

Process manager settings
<value name="pm">

Sets style of controling worker process count.
Valid values are 'static' and 'apache-like'
<value name="style">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 name="max_children">10</value>

Settings group for 'apache-like' pm style
<value name="apache_like">

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

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

Sets the desired maximum number of idle server processes.
Used only when 'apache-like' pm_style is selected
<value name="MaxSpareServers">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 name="request_terminate_timeout">5s</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 name="request_slowlog_timeout">5s</value>

The log file for slow requests
<value name="slowlog">logs/slow.log</value>

Set open file desc rlimit
<value name="rlimit_files">1024</value>

Set max core size rlimit
<value name="rlimit_core">0</value>

Chroot to this directory at the start, absolute path
<value name="chroot"></value>

Chdir to this directory at the start, absolute path
<value name="chdir"></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 name="catch_workers_output">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 name="max_requests">1000</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 name="allowed_clients">127.0.0.1</value>

Pass environment variables like LD_LIBRARY_PATH
All $VARIABLEs are taken from current environment
<value name="environment">
<value name="HOSTNAME">$HOSTNAME</value>
<value name="PATH">/usr/local/bin:/usr/bin:/bin</value>
<value name="TMP">/tmp</value>
<value name="TMPDIR">/tmp</value>
<value name="TEMP">/tmp</value>
<value name="OSTYPE">$OSTYPE</value>
<value name="MACHTYPE">$MACHTYPE</value>
<value name="MALLOC_CHECK_">2</value>
</value>

</section>

</workers>

</configuration>


[/code]
Re: php-cgi process dies from time to time in low traffic
June 25, 2009 05:18PM
still shot.
just http://pastebin.com it :)

On Thu, Jun 25, 2009 at 1:16 PM, kabs wrote:

>
> Sorry about that. Here is the code again
>
>
>
>
>
> All relative paths in this config are relative to php's install
> prefix
>
>
>
> Pid file
> /usr/local/logs/php-fpm.pid
>
> Error log file
> /usr/local/logs/php-fpm.log
>
> Log level
> notice
>
> When this amount of php processes exited with SIGSEGV or
> SIGBUS ...
> 10
>
> ... in a less than this interval of time, a graceful restart
> will be initiated.
> Useful to work around accidental curruptions in
> accelerator's shared memory.
> 1m
>
> Time limit on waiting child's reaction on signals from
> master
> 5s
>
> Set to 'no' to debug fpm
> yes
>
>
>
>
>
>
>
> Name of pool. Used in logs and stats.
> default
>
> Address to accept fastcgi requests on.
> Valid syntax is 'ip.ad.re.ss:port' or just 'port' or
> '/path/to/unix/socket'
> 127.0.0.1:9000
>
>
>
> Set listen(2) backlog
> -1
>
> 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.
> www-data
> www-data
> 0666
>
>
> Additional php.ini defines, specific to this pool of
> workers.
>
>
>
>
>
> Unix user of processes
> www-data
>
> Unix group of processes
> www-data
>
> Process manager settings
>
>
> Sets style of controling worker process
> count.
> Valid values are 'static' and 'apache-like'
> static
>
> 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.
> 10
>
> Settings group for 'apache-like' pm style
>
>
> Sets the number of server processes
> created on startup.
> Used only when 'apache-like'
> pm_style is selected
> 20
>
> Sets the desired minimum number of
> idle server processes.
> Used only when 'apache-like' pm_style is selected
> 5
>
> Sets the desired maximum number of
> idle server processes.
> Used only when 'apache-like'
> pm_style is selected
> 35
>
>
>
>
>
> 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'
> 5s
>
> The timeout (in seconds) for serving of single
> request after which a php backtrace will be dumped to slow.log file
> '0s' means 'off'
> 5s
>
> The log file for slow requests
> logs/slow.log
>
> Set open file desc rlimit
> 1024
>
> Set max core size rlimit
> 0
>
> Chroot to this directory at the start, absolute path
>
>
> Chdir to this directory at the start, absolute path
>
>
> Redirect workers' stdout and stderr into main error
> log.
> If not set, they will be redirected to /dev/null,
> according to FastCGI specs
> yes
>
> 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
> 1000
>
> 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.
> 127.0.0.1
>
> Pass environment variables like LD_LIBRARY_PATH
> All $VARIABLEs are taken from current environment
>
> $HOSTNAME
> /usr/local/bin:/usr/bin:/bin
> /tmp
> /tmp
> /tmp
> $OSTYPE
> $MACHTYPE
> 2
>
>
>
>
>
>
>
>
>
>
>
> Posted at Nginx Forum:
> http://forum.nginx.org/read.php?3,2847,3384#msg-3384
>
>
Re: php-cgi process dies from time to time in low traffic
June 26, 2009 04:26AM
mike here

http://pastebin.com/m4908c2c9
Re: php-cgi process dies from time to time in low traffic
June 26, 2009 03:06PM
next step
remove php-fpm.log

restart php-fpm fresh

once this issue occurs, can you pastebin that next?



On Fri, Jun 26, 2009 at 1:26 AM, kabs wrote:

>
> mike here
>
> http://pastebin.com/m4908c2c9
>
> Posted at Nginx Forum:
> http://forum.nginx.org/read.php?3,2847,3409#msg-3409
>
>
Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 134
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 500 on July 15, 2024
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready