0

Caveat - Newbie nginx/php5-fpm/ubuntu

I inherited a couple linux boxes and have had the same thing happen on both. I assume it's user error, but for the life of me I don't know what I did.

Symptoms: server working ok nginx to php5-fpm and back. I run a cookbook (made by others) that go some git gyrations, sym links, etc. and composure updates. Generally things just work.

The most recent time, I wasn't seeing my latest code be served up (or perhaps cached somewhere??) and I did a sudo service php5-fpm restart.

After this last time, nothing goes through. NGINX complains of time outs on ever single call: 2016/02/09 16:06:26 [error] 24102#0: *1 upstream timed out (110: Connection timed out) while reading response header from upstream, client: xx.xx.xx.xx, server: yyy.yyyy.com, request: "GET /v2/phpinfo.php HTTP/1.1", upstream: "fastcgi://unix:/var/run/php5-fpm.sock:", host: "yyy.yyyy.com"

I've restarted php5-fpm and nginx. I've updated configs for both to go to 127.0.0.1:9000 and demonstrated in each of the respective log files that they switched over. I then switched them back to the unix sock listed above.

I'm at a complete loss as to why they don't seem to hook up.

And I don't think I did anything other than restart php5-fpm. Does it matter which directory I'm in when I restarted php5-fpm?

Thanks for any help you can offer!

EDIT: I confirmed that the *.sock file disappeared when I went to the port 9000 and reappeared when I reconfigured. I even renamed the .sock file to test it, in case it mattered.

EDIT: PHP5-fpm log doesn't show much: [10-Feb-2016 09:12:20] WARNING: [pool www] child 26295 exited on signal 11 (SIGSEGV - core dumped) after 1383.735723 seconds from start [10-Feb-2016 09:12:20] NOTICE: [pool www] child 26346 started

from apport.log: is_closing_session(): no DBUS_SESSION_BUS_ADDRESS in environment

  • 1
    Check the web application. – Michael Hampton Feb 09 '16 at 23:57
  • Check the application and php logs, post any relevant contents. Directory makes no difference to service restart. – Tim Feb 10 '16 at 01:51
  • @MichaelHampton... Apache2 is installed but not running. This is an API only machine. It should just receive and serve up php files for JSON consumption. I don't know if there are other pieces I'm missing. What 'web application'? I'm hitting this with Postman JSON requests or even just trying to serve up phpinfo.php. – Mike Jensen Feb 10 '16 at 16:51
  • @Tim, what other logs should I look into? I only know the nginx and php5-fpm. – Mike Jensen Feb 10 '16 at 16:51
  • You don't just run PHP, you run an application written in PHP. Probably not relevant, but worth looking at. Given the core dump I might reinstall, but I'm not really an expert in this area. What does google say when you search for "SIGSEGV php5" or "SIGSEGV php5-fpm"? – Tim Feb 10 '16 at 19:03
  • Tracking this down, the closest I've found is the apport error and crash file: is_closing_session(): no DBUS_SESSION_BUS_ADDRESS in environment Is there a chance I did something by doing an SUDO service restart as non-root when the service was running as root? NOTE: api code (app) was running just fine until apparently I did a restart on the PHP5-FPM service and now it's in this stuck state. – Mike Jensen Feb 10 '16 at 21:58

1 Answers1

0

For me it turned out to be xdebug configuration. I'd been working to enable xdebug a few days ago to no avail. Nothing was even taking effect (affect?)

Last night it hit me that perhaps xdebug was hanging. I commented out the xdebug configuration, restarted PHP5-fpm and things freed up.

I, unfortunately, didn't see anything in any of the logs to point to XDEBUG config.