Countermeasure for “504 Gateway Time-out” error in PHP Nginx PHP-FPM environment

If you are getting “504 Gateway Time-out” errors in a PHP Nginx PHP-FPM environment, review the following settings.

  • php.ini: max_execution_time = 300
  • php-fpm.conf: request_terminate_timeout 300
  • nginx.conf: fastcgi_read_timeout 300

However, if these settings do not resolve the error, you may be able to resolve the problem by setting fastcgi_read_timeout 300 in default.conf instead of nginx.conf.

Reference site: https://system.hot-maker.com/90/

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top