I'm new here and I hope someone can point me in the right direction.
All was working well with my RPi Wordpress setup (Stretch Lite, nginx, php7.0, MariaDB, Adminer, Wordpress) until about a week ago when I noticed that upon booting the PHP7.0-fpm service was no longer starting. This of course was giving my visitors(me) the 502 Gateway error.
Manually starting the service with "sudo service php7.0-fpm start" gets the service running again without any issue.
The only feedback I'm getting is this from syslog:
Apr 4 14:59:04 MICROPIXELPUMPER systemd: php7.0-fpm.service: Start operation timed out. Terminating.
Apr 4 14:59:04 MICROPIXELPUMPER systemd: Failed to start The PHP 7.0 FastCGI Process Manager.
Apr 4 14:59:04 MICROPIXELPUMPER systemd: php7.0-fpm.service: Unit entered failed state.
Apr 4 14:59:04 MICROPIXELPUMPER systemd: php7.0-fpm.service: Failed with result 'timeout'.
I've tried changing the /etc/php/7.0/fpm/php.ini to log errors but the log stays error free.
I didn't do much between the time it was working to and the time I noticed it not working. But I do remember doing these things:
- updates: libsound2 and possibly python3-six (but i'm pretty certain that I had noticed the problem before the python update)
[UPDATE: made a backup of the working backup and used that SD image to update/upgrade the installation. PHP-7.0-FPM was starting fine - so the updates were not the problem]
- Installs: dnsutils, figlet
[UPDATE: the working setup does have dnsutils installed - that's not the problem]
- Enable ipv6 on my LAN - hmm... now that I write this maybe I can try turning it off... [UPDATE: Nope - going back to an IPv4 only LAN didn't change things]
- Possibly installed Webmin - but I have a feeling that all was working after this install, i'm just not sure. [UPDATE: Used a backup SD card from a few weeks ago and Webmin was installed and PHP7.0-FPM was starting fine]
What I know:
My php7.0-fpm configuration is correct - otherwise it would ALWAYS not start. And I did not modify it.
I found only one reference to this problem in my searches but it was related to php7.2 not php7.0 and the discussion was over my head because people were talking about kernel versions and virtual machines. I did not change the kernel.
It seems to me that something changed in the startup order or timing which causes the timeout. Starting php7.0-fpm manually doesn't fail because everything it needs is already loaded and running.
I've had a really fun time with my Raspberry Pi 3 B+ and this server setup. So much so that I just bought another one and got my original Pi B (with only 256 MB) off the shelf and working as a poor man's NAS. Fun times!