php-fpm-healthcheck
php-fpm-healthcheck copied to clipboard
Ubuntu - cgi-fcgi isn't terminating
Hi all,
When trying to use this script with ubuntu I'm seeing an ever-growing number of active cgi-fcgi instances and the health checks aren't terminating. Any idea why?
Hey @far-blue, I'd need more details, like logs, current configuration, exit status codes, and the flags you're using in the command!
Morning :)
Thanks for the quick response - I have managed to work out the problem and it's not cgi-fcgi or your script causing it.
For the benefit of anyone else hitting the same issue, the problem was that I'd setup apache with 'enablereuse' set to 'on' in the php proxy config. This was holding connections to all the php workers open and causing other scripts (i.e. the health check script) to queue indefinitely.
One possible improvement for your script might be to set a timeout and output a message rather than queue indefinitely because unless you are investigating in the container you simply won't notice the possibly hundreds of hanging scripts :)
That's a great idea to implement a timeout, is that something you'd like to work on?