• Our team is looking to connect with folks who use email services provided by Plesk, or a premium service. If you'd like to be part of the discovery process and share your experiences, we invite you to complete this short screening survey. If your responses match the persona we are looking for, you'll receive a link to schedule a call at your convenience. We look forward to hearing from you!
  • The BIND DNS server has already been deprecated and removed from Plesk for Windows.
    If a Plesk for Windows server is still using BIND, the upgrade to Plesk Obsidian 18.0.70 will be unavailable until the administrator switches the DNS server to Microsoft DNS. We strongly recommend transitioning to Microsoft DNS within the next 6 weeks, before the Plesk 18.0.70 release.
  • The Horde component is removed from Plesk Installer. We recommend switching to another webmail software supported in Plesk.

"Custom error documents" not working when PHP run as a "FPM application"

vkleinhenz

New Pleskian
When PHP runs as a FPM application, the server displays "File not found." for missing files. Checking "Custom error documents", defining "ErrorDocument" in .htaccess or "Additional Apache directives" all have no effect. Is there any way to get around this bug?
 
My setup is as follows:
OS ‪Ubuntu 14.04.4 LTS‬
Plesk version 12.5.30 Update #25
PHP 7.0.4
If I run PHP 7.0.4 as a FPM application, the error message is "File not found." (no HTML formatting, just the string). PHP 7.0.4 as a FastCGI application, however, returns the error documents defined in .htaccess.
 
This doesn't work. As I mentioned twice before, the response I get is just "File not found." in plain text. The status of these missing .php pages is "HTTP/1.1 404 Not Found" but no error page is displayed. Apparently, the ".php" in the URLs screws something up. I tested this with and without .htaccess in the root folder.
 
Last edited:
vkleinhenz, thanks for reporting.
I was able to reproduce the problem in our local environment. The issue is reported to development team as PPP-21577 for your reference.
Also, adding directive
Code:
ProxyErrorOverride on
into Additional Apache directives (Domain -> Apache & nginx Settings) solved the problem for me
 
error description? some details would be useful. Try to inspect webserver and vhost logs.
 
Not sure if that is a related error:

[Tue Mar 22 05:34:31.575192 2016] [proxy_fcgi:error] [pid 1072:tid 139939186419456] [client 8.37.71.109:35253] AH01071: Got error 'Primary script unknown\n'


I'm getting these errors in my browser:

The ... page isn’t working

... didn’t send any data.
ERR_EMPTY_RESPONSE
 
Hi,

adding ProxyErrorOverride solved the issue for me, thank you!

Instead of adding this option via additional Apache directives to each domain separately, I created a custom web server configuration file:
/opt/psa/admin/conf/templates/custom/service/php_over_fpm.php

Code:
<IfModule mod_proxy_fcgi.c>
    <Files ~ (\.php$)>
        ProxyErrorOverride on
        SetHandler proxy:<?php echo $VAR->domain->physicalHosting->fpmSocket ?>|fcgi://127.0.0.1:9000
    </Files>
</IfModule>

I hope this will get fixed soon...
 
Back
Top