Bug #69777 [NoF->Csd]: 502 Bad Gateway when getting response

From: Date: Wed, 19 Aug 2015 13:22:25 +0000
Subject: Bug #69777 [NoF->Csd]: 502 Bad Gateway when getting response
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-195337@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=69777&edit=1

 ID:                 69777
 User updated by:    sb at firstvector dot org
 Reported by:        sb at firstvector dot org
 Summary:            502 Bad Gateway when getting response
-Status:             No Feedback
+Status:             Closed
 Type:               Bug
 Package:            FPM related
 Operating System:   OS X Yosemite 10.10.3 (14D136)
-PHP Version:        5.6.9, 5.6.10
+PHP Version:        5.6.9, 5.6.10, 5.6.11, 5.6.12
 Block user comment: N
 Private report:     N

 New Comment:

NGINX error log message:
2015/08/19 16:18:58 [error] 39704#0: *3 upstream prematurely closed connection while reading
response header from upstream, client: 127.0.0.1, server: unga.loc, request: "GET /
HTTP/1.1", upstream: "fastcgi://127.0.0.1:9000", host: "unga.loc",
referrer: "http://unga.loc/user"

PHP-FPM log contains:
[19-Aug-2015 16:20:42] WARNING: [pool www] child 39743 exited on signal 11 (SIGSEGV) after
485.838010 seconds from start
[19-Aug-2015 16:20:42] NOTICE: [pool www] child 39826 started


Previous Comments:
------------------------------------------------------------------------
[2015-08-02 04:22:15] php-bugs at lists dot php dot net

No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Re-Opened". Thank you.

------------------------------------------------------------------------
[2015-07-22 10:00:23] mike@php.net

Any hints in the (error) logs?

------------------------------------------------------------------------
[2015-07-07 07:31:12] sb at firstvector dot org

Bug still reproduced on 5.6.10

------------------------------------------------------------------------
[2015-06-08 21:03:54] sb at firstvector dot org

Description:
------------
Using PHP-FPM 5.6.9 I've getting the error while working with cURL, for example. When I
commented the code that does remote requests then everything's fine, otherwise error log
contains an errors like:

upstream prematurely closed connection while reading response header from upstream, client:
127.0.0.1, server: unga.loc, request: "GET / HTTP/1.1", upstream:
"fastcgi://127.0.0.1:9000", host: "unga.loc", referrer: "http://unga.loc/content/test-project-4"

For solving this problem I've tried to use UNIX socket and TCP connection - no result. So,
I've think that is an error.

Used software:
nginx 1.8.0 (also tested on 1.6.3)
php-fpm 5.6.9 (works fine on 5.6.7)

Test script:
---------------
// Execution of this (and similar) code will ends by 502 error.
$ch = curl_init('https://php.net');
curl_setopt_array($ch, [
  CURLOPT_HTTPGET => true,
  CURLOPT_RETURNTRANSFER => true,
]);
$response = curl_exec($ch);
curl_close($ch);
var_dump($response);



------------------------------------------------------------------------



--
Edit this bug report at https://bugs.php.net/bug.php?id=69777&edit=1


Thread (8 messages)

« previous php.bugs (#195337) next »