Optimizing NGINX and PHP-fpm for high traffic sites

After 7 years of using NGINX with PHP, we learned a couple of things about how to best optimize NGINX and PHP-fpm for high traffic sites. Below is a collection of tips and recommendations: 1. Switch from TCP to UNIX domain sockets UNIX domain sockets offer better performance than TCP sockets over loopback interface (less copying ...

Quickly check installed version(s) of PHP

In order to quickly check installed version(s) of PHP run: /usr/local/cpanel/bin/rebuild_phpconf --current

How to find path to php.ini file

No matter what control panel you are using, the complete way to find what php.ini file to edit for specific domain is following: Create file inside your site, name it for example info.php , with content: <? phpinfo() ?> Open file in your browser window, like http://domain.tld/info.php Search for line Loaded Configuration File, it will show you full ...