PHP-FPM Log buffer length limit issue needs resolving
There is an issue on servers configured by Cloudways, in which the PHP-FPM log buffer (error msg length) is set to 1028 bytes. This is too short for many errors messages generated by Wordpress.
It results in many entries of:
"Message":"AH01071: Got error 'the log buffer is full (1024). The access log request has been truncated.'"
In the PHP error logs views in Application Manager. So rather than seeing the actual error, you end up just seeing this message. Which is, obviously, very unhelpful.
Apparently it's due to the setting of log_limit
setting in PHP-FPM, complied with Nginx.
You can read about this here: https://serverfault.com/questions/256459/nginx-php-fpm-long-log-lines-get-truncated
PHP-FPM will need to re recompiled with a patch. See here https://forums.freebsd.org/threads/howto-stop-nginx-php-fpm-from-truncating-your-stack-trace-error-message.56543/
Anyway... I found a workaround solution is to add the following to the PHP Advanced Settings on the Application:
phpadminvalue[logerrorsmax_len] = 2048
Once that is added, property (and useful) error messages are now accessible in the error logs.
I suggest Cloudways either compile PHP-FPM with a higher log_limit, or implement the PHP change I've mentioned, by default on all applications. This would save the customer from having to deal with this issue.
Regards,
Jonathan

-
Giorgos Grispos commented
Having the same issue, increasing the logerrorsmax to 2048 not solving the issue.
-
MOJTABA commented
same issue...
-
Anonymous commented
I have this issue on Cloudways too! So frustrating!