divemasterza

Active Member
Feb 2, 2013
32
2
58
South Africa
cPanel Access Level
Root Administrator
Twitter

divemasterza

Active Member
Feb 2, 2013
32
2
58
South Africa
cPanel Access Level
Root Administrator
Twitter
I figured out the 503 issues ...

Code:
mkdir -p /home/$<user>/run/
I ran this as root and obviously the owner was root and not the user ...

A missing step also missing from the docs is the session.save_path (line 225 of the $<user>.conf file)

I had to:
  • Change to value to /home/$<user>/tmp/session
  • mkdir -p /home/$<user>/tmp/session
  • chown $<user>:$<user> /home/$<user>/tmp/session
I'll probably need also to set up a cron to cleanup this /session once a day

I see a noticeable speed improvement for websites running FPM/FastCGI API especially relating to TTFB


I hope that once EA4 is fully released in 11.56, we can look forward for a script to automate this :)

Now figuring out the subdomains issue...
 
Last edited:

divemasterza

Active Member
Feb 2, 2013
32
2
58
South Africa
cPanel Access Level
Root Administrator
Twitter
Actually yes :)

let say the subdomain is --> sub.example.com

create the following two directories:
Code:
mkdir -p /etc/apache2/conf.d/userdata/std/2_4/$<user>/sub.example.com
mkdir -p /etc/apache2/conf.d/userdata/ssl/2_4/$<user>/sub.example.com
place an fpm.conf in each of these:

Code:
<IfModule proxy_fcgi_module>
ProxyPassMatch "^/(.*\.php(/.*)?)$" "unix:/home/$<user>/run/php56-fpm.sock|fcgi://127.0.0.1/home/$<user>/public_html/sub"
DirectoryIndex index.php
</IfModule>
rebuild http conf and restart
Code:
/scripts/rebuildhttpdconf; /scripts/restartsrv_httpd
To test:

Code:
echo "<?php phpinfo(); ?>" > /home/$<user>/public_html/sub/info.php
Look at the output in your browser it should say FPM/FastCGI in the server API
 
  • Like
Reactions: swany

swany

Member
Sep 21, 2011
23
1
53
cPanel Access Level
Website Owner
  • Like
Reactions: Daniel Gheorghe

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,908
2,216
463
Hello :)

I am happy to see the initial issues were resolved. Thank you for updating us with the outcome.