Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use PHP-FPM instead of mod_php #750

Open
jamesmontalvo3 opened this issue Jun 9, 2017 · 1 comment
Open

Use PHP-FPM instead of mod_php #750

jamesmontalvo3 opened this issue Jun 9, 2017 · 1 comment

Comments

@jamesmontalvo3
Copy link
Contributor

From https://www.mediawiki.org/wiki/Manual:Performance_tuning

if you use Apache as web server, use PHP-FPM, not mod_php. PHP-FPM optimizes re-use of PHP processes.
switch Apache to use the event MPM instead of the prefork MPM.

@jamesmontalvo3
Copy link
Contributor Author

I briefly tried PHP-FPM while trying to figure out #995. These articles were helpful:

My final proxypassmatch:

ProxyPassMatch ^/(.*\.php(/.*)?)$ "unix:/run/php-fpm/www.sock|fcgi://localhost/opt/htdocs/$1"

However, this didn't take into account required rewrite rule:

RewriteRule ^(?!mediawiki(?:/|$))[^/]+(?:/(.*))?$ mediawiki/$1

Make sure to yum install php70u-fpm

Was this necessary? I did it: yum install mod_fcgid

I may have edited all of these:

/etc/httpd/conf.modules.d/10-php.conf
/etc/httpd/conf.d/php.conf
/etc/php-fpm.d/www.conf

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant