502 Bad Gateway

Hi all,

I have a simple setup with Nginx in front Apache, under debian wheezy
(nginx for static content, apache for php)
Since the last Nginx update (1.1.17-2 via apt-get), every night after
daily crons i have a 502 error (bad gateway) until i reload apache.
Everything was fine before.
I tried to reload apache after nginx in the logrotate daily task, but
without effect.
In my logs i just have :

[error] 22332#0: *10804 connect() failed (111: Connection refused) while
connecting to upstream

Where should i look at?

Thanks!

PHP is a common cause of such an error

Il 26/03/2012 13:41, Raphael Marot ha scritto:

[error] 22332#0: *10804 connect() failed (111: Connection refused)
while connecting to upstream

Where should i look at?

Look at Apache’s logs. It seems that apache does not restart correctly
after che log rotate, and a manual restart fix it. The error tells you
that nginx can’t communicate with apache.

Le 26/03/2012 13:45, [email protected] a crit :

In my logs i just have :


nginx mailing list
[email protected]
nginx Info Page

Thanks!
Indeed I have an error in my apache log.
seg fault or similar nasty error detected in the parent process

It is definitely php related and has nothing to do with Nginx.
I think i uninstalled a php module which is still called in the php.ini,
and maybe this is the cause…

Hello!

On Thu, May 17, 2012 at 07:33:52PM -0400, SolarWonk wrote:

Any update on this?

The problem was found to be in a backend, not in nginx (well,
actually it was clear for the original error message referenced,
and even from the subject). What update do you expect to see
here?

Maxim D.

Any update on this?

Posted at Nginx Forum: