Created
December 11, 2023 06:22
-
-
Save denihida1216/5366a793c3cfe91c4fbb8714dadd6ba2 to your computer and use it in GitHub Desktop.
Tuning Cache Connection Best Performance
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
PHP-FPM Configuration (php-fpm.conf or www.conf): | |
location /etc/php/7.4/fpm/pool.d/www.conf | |
pm.max_children = 50 | |
pm.start_servers = 5 | |
pm.min_spare_servers = 5 | |
pm.max_spare_servers = 35 | |
pm.process_idle_timeout = 10s | |
pm.max_requests = 500 | |
Opcache: | |
Enable and configure OPcache to cache compiled PHP code. | |
location /etc/php/7.4/fpm | |
opcache.enable = 1 | |
opcache.memory_consumption = 128 | |
opcache.max_accelerated_files = 4000 | |
opcache.revalidate_freq = 2 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment