Erro 500/503

1

Eu recebo um erro 500 / 503. Minha teoria era que o php5-fpm estava sendo morto e re-spawn a cada segundo devido a mensagens como esta no php5-fpm.log

[27-Jan-2015 08:21:34] NOTICE: fpm is running, pid 30045
[27-Jan-2015 08:21:34] NOTICE: ready to handle connections
[27-Jan-2015 08:21:44] NOTICE: Finishing ...
[27-Jan-2015 08:21:44] NOTICE: exiting, bye-bye!
[27-Jan-2015 08:21:44] NOTICE: configuration file /etc/php5/fpm/php-fpm.conf test is successful

[27-Jan-2015 08:21:44] NOTICE: fpm is running, pid 30066
[27-Jan-2015 08:21:44] NOTICE: ready to handle connections
[27-Jan-2015 08:21:54] NOTICE: Finishing ...
[27-Jan-2015 08:21:54] NOTICE: exiting, bye-bye!
[27-Jan-2015 08:21:55] NOTICE: configuration file /etc/php5/fpm/php-fpm.conf test is successful

Concluí que isso é um comportamento normal. Meu erro 500/503 deve estar vindo de outra coisa. Quando eu pressiono F5 várias vezes, o erro ocorre. alguma idéia?

PHP

PHP 5.4.36-0+deb7u3 (cli) (built: Jan  9 2015 08:07:06)
Copyright (c) 1997-2014 The PHP Group
Zend Engine v2.4.0, Copyright (c) 1998-2014 Zend Technologies

Lighttpd

lighttpd/1.4.31 (ssl) - a light and fast webserver
Build-Date: Mar 13 2014 02:17:09

www.conf

[www]
;prefix = /path/to/pools/$pool
user = www-data
group = www-data
listen = /var/run/php5-fpm.sock
;listen = 127.0.0.1:9000
;listen.backlog = 128
listen.owner = www-data
listen.group = www-data
listen.mode = 0660
;listen.allowed_clients = 127.0.0.1
; process.priority = -19
pm = static
pm.max_children = 5
pm.start_servers = 2
pm.min_spare_servers = 1
pm.max_spare_servers = 3
pm.process_idle_timeout = 10s;
;pm.max_requests = 500
;pm.status_path = /status
;ping.path = /ping
;ping.response = pong
;access.log = log/$pool.access.log
;access.format = "%R - %u %t \"%m %r%Q%q\" %s %f %{mili}d %{kilo}M %C%%"
;slowlog = log/$pool.log.slow
;request_slowlog_timeout = 0
;request_terminate_timeout = 0
;rlimit_files = 1024
;rlimit_core = 0
;chroot =
chdir = /

php5-fpm.log

[27-Jan-2015 08:21:55] NOTICE: fpm is running, pid 30087
[27-Jan-2015 08:21:55] NOTICE: ready to handle connections
[27-Jan-2015 08:22:05] NOTICE: Finishing ...
[27-Jan-2015 08:22:05] NOTICE: exiting, bye-bye!
[27-Jan-2015 08:22:05] NOTICE: configuration file /etc/php5/fpm/php-fpm.conf test is successful

[27-Jan-2015 08:22:05] NOTICE: fpm is running, pid 30108
[27-Jan-2015 08:22:05] NOTICE: ready to handle connections
[27-Jan-2015 08:22:15] NOTICE: Finishing ...
[27-Jan-2015 08:22:15] NOTICE: exiting, bye-bye!
[27-Jan-2015 08:22:15] NOTICE: configuration file /etc/php5/fpm/php-fpm.conf test is successful

Lighttps Error.Log

2015-01-27 08:36:22: (mod_fastcgi.c.2543) unexpected end-of-file (perhaps the fastcgi process died): pid: 0 socket: unix:/var/run/php5-fpm.sock

2015-01-27 08:36:22: (mod_fastcgi.c.3329) response not received, request sent: 1184 on socket: unix:/var/run/php5-fpm.sock for /index.php?, closing connection
    
por acanessa 28.01.2015 / 16:01

1 resposta

1

O mais provável é que seu script PHP tenha um erro. para ver mais, use a diretiva de log de erros do php no php-fpm.conf.

php_admin_flag[log_errors]=On
php_admin_value[error_reporting]=E_ALL
php_admin_value[error_log]=/var/log/php-errors.log
    
por 28.01.2015 / 16:32