From 3a4e7455c7ca6faf3e16c823f29a06389b722470 Mon Sep 17 00:00:00 2001 From: Alan Orth Date: Sat, 9 May 2015 12:34:45 +0300 Subject: [PATCH] roles/php5-fpm: Tweak opcache settings Reduce memory allocation from 128 -> 72M because after a few days of running it's only using 64 or so, so it's really just a waste of memory. Also, disable opcache for CLI. What the hell do you need opcaching in the CLI invocation for? It only persists for one process! Signed-off-by: Alan Orth --- roles/php5-fpm/defaults/main.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/roles/php5-fpm/defaults/main.yml b/roles/php5-fpm/defaults/main.yml index b8489b1..d9d57fe 100644 --- a/roles/php5-fpm/defaults/main.yml +++ b/roles/php5-fpm/defaults/main.yml @@ -7,8 +7,8 @@ cgi_fix_pathinfo: 0 # some sane defaults for PHP 5.5+ Opcache # see: https://php.net/manual/en/opcache.installation.php opcache_enable: 1 -opcache_enable_cli: 1 -opcache_memory_consumption: 128 +opcache_enable_cli: 0 +opcache_memory_consumption: 72 opcache_interned_strings_buffer: 8 opcache_max_accelerated_files: 4000 opcache_use_cwd: 1